@charset "UTF-8";

/*!
Theme Name: Cocoon Child
Description: Cocoon専用の子テーマ
Theme URI: https://wp-cocoon.com/
Author: わいひら
Author URI: https://nelog.jp/
Template:   cocoon-master
Version:    1.1.3
*/

/************************************
** 子テーマ用のスタイルを書く
************************************/

/* YuLab Web ブランド基準色 */
:root {
  --yulab-blue: #2563EB;
  --yulab-blue-dark: #1E3A8A;
  --yulab-bg: #F5F7FB;
  --yulab-white: #FFFFFF;
  --yulab-heading: #1F2937;
  --yulab-text: #374151;
  --yulab-line: #E5E7EB;
}

/* YuLab Web シグネチャー：C-2 Y一体型ノート */
.header-container .site-name-text {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.56em;
}

.header-container .site-name-text::before {
  content: "Y";
  display: inline-grid;
  width: 1.64em;
  height: 1.64em;
  place-items: center;
  flex: 0 0 1.64em;
  border-radius: 0.42em 0.42em 0.42em 0.18em;
  background: linear-gradient(145deg, #3B82F6 0%, var(--yulab-blue) 56%, var(--yulab-blue-dark) 100%);
  box-shadow: 0.18em 0.2em 0 rgba(31, 41, 55, 0.08);
  color: var(--yulab-white);
  font-size: 0.74em;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.06em;
  clip-path: polygon(0 0, 74% 0, 100% 26%, 100% 100%, 0 100%);
}

.header-container .site-name-text::after {
  content: "";
  position: absolute;
  left: 1.06em;
  top: 0.05em;
  width: 0.42em;
  height: 0.42em;
  border-radius: 0 0.12em 0 0.12em;
  background: rgba(255, 255, 255, 0.92);
  transform: rotate(45deg);
  transform-origin: center;
  pointer-events: none;
}

/* 記事見出し：左アクセントと右上の紙折り返し */
.article .entry-content h2 {
  position: relative;
  margin: 2.8em 0 1.2em;
  padding: 1.05em 2.2em 1em 1.2em;
  background: #f8fafc;
  border: 1px solid var(--yulab-line);
  border-left: 4px solid var(--yulab-blue);
  border-radius: 12px;
  color: var(--yulab-heading);
  font-size: 1.45em;
  line-height: 1.5;
  letter-spacing: 0.01em;
  box-shadow: 0 8px 20px rgba(31, 41, 55, 0.035);
}

.article .entry-content h2::after {
  content: "";
  position: absolute;
  top: -1px;
  right: -1px;
  width: 1.18em;
  height: 1.18em;
  background: linear-gradient(225deg, #dbeafe 0%, #bfdbfe 100%);
  clip-path: polygon(0 0, 100% 0, 100% 100%);
  border-top-right-radius: 11px;
  opacity: 0.78;
  pointer-events: none;
}

/* H3：H2より軽く、同じブルーの軸で階層を明確化 */
.article .entry-content h3 {
  margin: 2.15em 0 0.9em;
  padding: 0.2em 0 0.38em 0.82em;
  background: transparent;
  border: 0;
  border-left: 3px solid var(--yulab-blue);
  border-bottom: 1px solid var(--yulab-line);
  color: var(--yulab-heading);
  font-size: 1.2em;
  line-height: 1.55;
  letter-spacing: 0.01em;
}

/* 記事タイトル周り：情報の優先順位を整理 */
.article-header .entry-title {
  margin-bottom: 0.65em;
  color: #202938;
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  line-height: 1.45;
  letter-spacing: -0.015em;
}

.article-header .entry-title::after {
  display: block;
  width: 56px;
  height: 4px;
  margin-top: 0.55em;
  border-radius: 999px;
  background: #2563eb;
  content: "";
}

.article-header .sns-share {
  margin-top: 1.1em;
  margin-bottom: 0.45em;
}

.article-header .date-tags {
  color: #6b7280;
  font-size: 0.9em;
}

/* 目次：記事内ナビとして見やすく整理 */
.article .toc {
  margin: 2.2em auto;
  padding: 1.15em 1.35em;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-left: 4px solid #2563eb;
  border-radius: 10px;
  box-shadow: none;
}

.article .toc .toc-title {
  color: #1f2937;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.article .toc .toc-list {
  margin-top: 0.75em;
}

.article .toc .toc-list li {
  margin: 0.4em 0;
  line-height: 1.65;
}

.article .toc .toc-list a {
  color: #374151;
  text-decoration: none;
}

.article .toc .toc-list a:hover {
  color: #2563eb;
  text-decoration: underline;
}

/* サイドバー：標準感を抑えて記事との統一感を追加 */
#sidebar .widget {
  position: relative;
  margin-bottom: 1.4em;
  padding: 1.45em 1.3em 1.3em;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(31, 41, 55, 0.03);
}

#sidebar .widget::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 1.1em;
  width: 2.35em;
  height: 0.38em;
  border-radius: 0 0 0.34em 0.34em;
  background: #60a5fa;
  opacity: 0.78;
}

#sidebar .widget::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 1.1em;
  height: 1.1em;
  background: linear-gradient(225deg, var(--yulab-bg) 0 50%, transparent 50% 100%);
  border-top-right-radius: 13px;
  pointer-events: none;
}

#sidebar .widget h2,
#sidebar .widget .wp-block-heading {
  margin: 0 0 0.9em;
  padding: 0 0 0.55em;
  background: transparent;
  border: 0;
  border-bottom: 1px solid #e5e7eb;
  color: #1f2937;
  font-size: 1.08em;
  line-height: 1.4;
}

#sidebar .widget ul {
  margin: 0;
  padding-left: 0;
  list-style: none;
}

#sidebar .widget li {
  margin: 0;
  padding: 0.55em 0;
  border-bottom: 1px solid #eef2f7;
  line-height: 1.55;
}

#sidebar .widget li:last-child {
  border-bottom: 0;
}

#sidebar .widget a {
  color: #374151;
  text-decoration: none;
}

#sidebar .widget a:hover {
  color: #2563eb;
}

#sidebar .wp-block-search__inside-wrapper {
  gap: 0.55em;
}

#sidebar .wp-block-search__input {
  border: 1px solid #d1d5db;
  border-radius: 8px;
}

#sidebar .wp-block-search__button {
  border: 0;
  border-radius: 8px;
  background: #2563eb;
  color: #ffffff;
}

/* サイト全体：YuLab Webらしい軽いテック感で統一 */
body {
  color: #374151;
  background: #f5f7fb;
}

.header-container {
  background: #ffffff;
  border-bottom: 1px solid #e8edf4;
}

.header-container .tagline {
  color: #6b7280;
  font-size: 0.92em;
  letter-spacing: 0.03em;
}

.header-container .site-name-text {
  color: #1f2937;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.content {
  background: #f5f7fb;
}

.main {
  border: 1px solid #e8edf4;
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(31, 41, 55, 0.05);
}

.article .entry-content {
  color: #374151;
}

.article .entry-content p {
  line-height: 1.95;
}

.article .entry-content strong {
  color: #111827;
}

.article .entry-content a {
  text-underline-offset: 0.16em;
}

.article-header .sns-share-buttons .share-button {
  border-radius: 8px;
  transition: transform 0.18s ease, opacity 0.18s ease;
}

.article-header .sns-share-buttons .share-button:hover {
  transform: translateY(-1px);
  opacity: 0.9;
}

/* 記事末尾CTA：実際の制作物へ自然に誘導 */
.article .entry-content a[href*="APP-003-fruit-pop"] {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  margin: 0.35em 0 0.75em;
  padding: 0.88em 2.2em 0.88em 1.25em;
  background: linear-gradient(135deg, var(--yulab-blue) 0%, #3B82F6 100%);
  border: 1px solid var(--yulab-blue);
  border-radius: 12px;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.16);
  color: #ffffff;
  font-weight: 700;
  text-decoration: none;
  overflow: hidden;
  transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.article .entry-content a[href*="APP-003-fruit-pop"]::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 1.2em;
  height: 1.2em;
  background: rgba(255, 255, 255, 0.95);
  clip-path: polygon(100% 0, 100% 100%, 0 0);
  opacity: 0.92;
}

.article .entry-content a[href*="APP-003-fruit-pop"]:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.2);
  color: #ffffff;
}

.article .entry-content a[href*="/apps/?utm_source=wordpress"] {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin: 0.25em 0 0.5em;
  padding: 0.78em 1.9em 0.78em 1.1em;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  color: var(--yulab-blue);
  font-weight: 700;
  text-decoration: none;
  overflow: hidden;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.article .entry-content a[href*="/apps/?utm_source=wordpress"]::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 1.05em;
  height: 1.05em;
  background: var(--yulab-bg);
  clip-path: polygon(100% 0, 100% 100%, 0 0);
}

.article .entry-content a[href*="/apps/?utm_source=wordpress"]:hover {
  transform: translateY(-1px);
  background: #f8fafc;
  border-color: var(--yulab-blue);
}

/* 記事下部：カテゴリ・タグ・共有を軽く整える */
.entry-categories-tags a {
  display: inline-flex;
  align-items: center;
  margin: 0.2em 0.35em 0.2em 0;
  padding: 0.38em 0.72em;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  color: #475569;
  text-decoration: none;
}

.entry-categories-tags a:hover {
  border-color: #93c5fd;
  color: #2563eb;
}

.article-footer .sns-share-buttons .share-button {
  border-radius: 8px;
}

/* 余白設計 v2：読みやすさとYuLabらしい落ち着きを強化 */
#content-in {
  /* Cocoonの既存2カラム幅を維持し、sidebarの下回りを防ぐ */
}

.main {
  box-sizing: border-box;
  min-width: 0;
  padding: 2.35rem 2.55rem 2.6rem;
}

.article-header {
  margin-bottom: 1.7rem;
}

.article .entry-content > p {
  margin: 0 0 1.35em;
}

.article .entry-content h2 {
  margin-top: 3.1em;
  margin-bottom: 1.25em;
}

.article .toc {
  margin-top: 2.5em;
  margin-bottom: 2.7em;
}

#sidebar {
  padding-top: 0.15rem;
}

#sidebar .widget {
  margin-bottom: 1.65em;
}

.entry-categories-tags {
  margin-top: 2.3rem;
}

/************************************
** レスポンシブデザイン用のメディアクエリ
************************************/
/*1023px以下*/
@media screen and (max-width: 1023px){
  /*必要ならばここにコードを書く*/
}

/*834px以下*/
@media screen and (max-width: 834px){
  .main {
    padding: 1.55rem 1.35rem 1.9rem;
    border-radius: 12px;
    box-shadow: none;
  }

  .article-header {
    margin-bottom: 1.35rem;
  }

  .article-header .entry-title {
    font-size: clamp(1.6rem, 6vw, 2rem);
  }

  .article .entry-content > p {
    margin-bottom: 1.2em;
  }

  .article .entry-content h2 {
    margin-top: 2.6em;
  }

  .article .toc {
    margin: 2em auto 2.25em;
    padding: 1em 1.1em;
  }
}

/*480px以下*/
@media screen and (max-width: 480px){
  .main {
    padding: 1.25rem 1rem 1.55rem;
  }

  .article-header {
    margin-bottom: 1.15rem;
  }

  .article .entry-content p {
    line-height: 1.85;
  }

  .article .entry-content > p {
    margin-bottom: 1.05em;
  }

  .article .entry-content h2 {
    margin-top: 2.35em;
    margin-bottom: 1.05em;
    padding: 0.95em 1.9em 0.9em 1em;
    font-size: 1.22em;
    line-height: 1.45;
  }

  .article .entry-content h2::after {
    top: -1px;
    right: -1px;
    width: 1.02em;
    height: 1.02em;
  }

  .article .entry-content h3.yulab-step-heading {
    padding-left: 2em;
    font-size: 1.04em;
    line-height: 1.5;
  }

  .article .entry-content h3.yulab-step-heading::before {
    top: 50%;
    width: 1.45em;
    height: 1.45em;
    font-size: 0.7em;
  }

  .article .toc {
    margin: 1.8em auto 2em;
  }

  #content-in {
    gap: 1.4rem;
  }
}


/* YuLab 記事装飾 v1：本文の要点整理・会話・注意・まとめ */
.article .entry-content .yulab-point,
.article .entry-content .yulab-note,
.article .entry-content .yulab-warning,
.article .entry-content .yulab-checklist,
.article .entry-content .yulab-summary {
  margin: 1.8em 0;
  padding: 1.15em 1.2em;
  border: 1px solid var(--yulab-line);
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(31, 41, 55, 0.035);
}

.article .entry-content .yulab-point {
  background: #eff6ff;
  border-left: 4px solid var(--yulab-blue);
}

.article .entry-content .yulab-note {
  background: #f8fafc;
  border-left: 4px solid #94a3b8;
}

.article .entry-content .yulab-warning {
  background: #fff7f7;
  border-left: 4px solid #ef4444;
}

.article .entry-content .yulab-summary {
  background: linear-gradient(180deg, #eff6ff 0%, #ffffff 100%);
  border-color: #bfdbfe;
}

.article .entry-content .yulab-box-title {
  margin: 0 0 0.65em;
  color: var(--yulab-heading);
  font-weight: 700;
}

.article .entry-content .yulab-box-title::before {
  display: inline-block;
  margin-right: 0.45em;
  color: var(--yulab-blue);
  font-weight: 800;
}

.article .entry-content .yulab-point .yulab-box-title::before { content: "●"; }
.article .entry-content .yulab-note .yulab-box-title::before { content: "i"; }
.article .entry-content .yulab-warning .yulab-box-title::before { content: "!"; color: #ef4444; }
.article .entry-content .yulab-summary .yulab-box-title::before { content: "✓"; }

.article .entry-content .yulab-marker {
  background: linear-gradient(transparent 62%, #fde68a 62%);
  font-weight: 700;
}

.article .entry-content .yulab-underline {
  text-decoration-line: underline;
  text-decoration-color: #93c5fd;
  text-decoration-thickness: 0.18em;
  text-underline-offset: 0.18em;
  text-decoration-skip-ink: none;
}

.article .entry-content h3.yulab-step-heading {
  position: relative;
  padding-left: 2.35em;
  border-left: 0;
  font-size: 1.14em;
}

.article .entry-content h3.yulab-step-heading::before {
  content: attr(data-step);
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 1.65em;
  height: 1.65em;
  border-radius: 999px;
  background: #4f7fcf;
  color: #fff;
  font-size: 0.74em;
  font-weight: 800;
}

.article .entry-content .yulab-dialogue {
  margin: 1.9em 0;
}

.article .entry-content .yulab-talk {
  display: flex;
  align-items: flex-start;
  gap: 0.8em;
  margin: 1em 0;
}

.article .entry-content .yulab-talk.is-yulab {
  flex-direction: row-reverse;
}

.article .entry-content .yulab-talk-avatar {
  flex: 0 0 58px;
  text-align: center;
}

.article .entry-content .yulab-talk-avatar img {
  display: block;
  width: 58px;
  height: 58px;
  margin: 0 auto 0.3em;
  border: 1px solid var(--yulab-line);
  border-radius: 50%;
  background: #fff;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(31, 41, 55, 0.05);
}

.article .entry-content .yulab-talk-name {
  display: block;
  color: #64748b;
  font-size: 0.72em;
  font-weight: 700;
  line-height: 1.3;
}

.article .entry-content .yulab-bubble {
  position: relative;
  max-width: calc(100% - 74px);
  margin: 0;
  padding: 0.95em 1.05em;
  border: 1px solid var(--yulab-line);
  border-radius: 14px;
  background: #f8fafc;
  line-height: 1.75;
  box-shadow: 0 5px 14px rgba(31, 41, 55, 0.025);
}

.article .entry-content .yulab-talk:not(.is-yulab) .yulab-bubble::before {
  content: "";
  position: absolute;
  left: -0.58em;
  top: 1.05em;
  width: 0.9em;
  height: 0.9em;
  background: #f8fafc;
  border-left: 1px solid var(--yulab-line);
  border-bottom: 1px solid var(--yulab-line);
  transform: rotate(45deg);
}

.article .entry-content .yulab-talk.is-yulab .yulab-bubble {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.article .entry-content .yulab-talk.is-yulab .yulab-bubble::before {
  content: "";
  position: absolute;
  right: -0.58em;
  top: 1.05em;
  width: 0.9em;
  height: 0.9em;
  background: #eff6ff;
  border-top: 1px solid #bfdbfe;
  border-right: 1px solid #bfdbfe;
  transform: rotate(45deg);
}

.article .entry-content .yulab-bubble-label {
  display: none;
}

.article .entry-content .yulab-checklist ul,
.article .entry-content .yulab-summary ul {
  margin: 0.65em 0 0;
  padding-left: 0;
  list-style: none;
}

.article .entry-content .yulab-checklist li,
.article .entry-content .yulab-summary li {
  position: relative;
  margin: 0.55em 0;
  padding-left: 1.8em;
}

.article .entry-content .yulab-checklist li::before,
.article .entry-content .yulab-summary li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--yulab-blue);
  font-weight: 800;
}

@media screen and (max-width: 480px){
  .article .entry-content .yulab-point,
  .article .entry-content .yulab-note,
  .article .entry-content .yulab-warning,
  .article .entry-content .yulab-checklist,
  .article .entry-content .yulab-summary {
    margin: 1.5em 0;
    padding: 1em;
    border-radius: 10px;
  }

  .article .entry-content .yulab-dialogue {
    margin: 1.45em 0;
  }

  .article .entry-content .yulab-talk {
    gap: 0.52em;
    margin: 0.72em 0;
  }

  .article .entry-content .yulab-talk-avatar {
    flex-basis: 44px;
  }

  .article .entry-content .yulab-talk-avatar img {
    width: 44px;
    height: 44px;
    margin-bottom: 0.2em;
  }

  .article .entry-content .yulab-talk-name {
    font-size: 0.68em;
  }

  .article .entry-content .yulab-bubble {
    max-width: calc(100% - 54px);
    padding: 0.74em 0.82em;
    border-radius: 11px;
    line-height: 1.7;
  }

  .article .entry-content .yulab-talk:not(.is-yulab) .yulab-bubble::before,
  .article .entry-content .yulab-talk.is-yulab .yulab-bubble::before {
    top: 0.9em;
    width: 0.78em;
    height: 0.78em;
  }
}
