/* =====================================================================
   コツのとびら | Design System
   Minimal & Modern — white base + intelligent teal accent
   ===================================================================== */

/* ---------- Design Tokens ---------- */
:root {
  /* Base surfaces */
  --bg: #ffffff;
  --surface: #f6f7f9;
  --surface-2: #eef1f4;
  --line: #e5e8ec;
  --line-strong: #d3d8df;

  /* Ink */
  --ink: #15181e;
  --ink-2: #3c4350;
  --ink-3: #6b7280;
  --ink-inv: #ffffff;

  /* Brand */
  --brand: #0f766e;
  --brand-ink: #0a5852;
  --brand-soft: #e7f3f1;
  --brand-soft-2: #d3eae6;
  --accent: #f59e0b;            /* highlight / "コツ" emphasis */
  --accent-soft: #fef3e2;

  /* Category wayfinding colors */
  --c-food: #e11d48;
  --c-fashion: #7c3aed;
  --c-hobby: #0891b2;
  --c-sports: #ea580c;
  --c-business: #2563eb;
  --c-relationship: #db2777;
  --c-local: #16a34a;

  /* Typography */
  --font-sans: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
  --font-head: "Zen Kaku Gothic New", "Noto Sans JP", "Hiragino Kaku Gothic ProN", sans-serif;

  /* Layout */
  --container: 1160px;
  --reading: 740px;
  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 22px;
  --header-h: 68px;

  /* Shadow */
  --shadow-sm: 0 1px 2px rgba(20,24,30,.06), 0 1px 3px rgba(20,24,30,.05);
  --shadow: 0 6px 18px rgba(20,24,30,.08), 0 2px 6px rgba(20,24,30,.05);
  --shadow-lg: 0 18px 50px rgba(20,24,30,.14), 0 6px 16px rgba(20,24,30,.08);

  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
body {
  font-family: var(--font-sans);
  color: var(--ink-2);
  background: var(--bg);
  line-height: 1.85;
  font-size: 16px;
  letter-spacing: .01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg, picture { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; padding: 0; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink); line-height: 1.4; font-weight: 700; }

/* ---------- Utilities ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 22px; }
.muted { color: var(--ink-3); }
.center { text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .8rem; font-weight: 700; letter-spacing: .14em;
  color: var(--brand); text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--brand); border-radius: 2px; }
.section { padding: 72px 0; }
.section-head { margin-bottom: 34px; }
.section-head h2 { font-size: clamp(1.5rem, 3.2vw, 2.1rem); letter-spacing: .01em; margin-top: 8px; }
.section-head p { color: var(--ink-3); margin-top: 8px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Reading progress bar ---------- */
.progress-bar {
  position: fixed; top: 0; left: 0; height: 3px; width: 0;
  background: linear-gradient(90deg, var(--brand), #2dd4bf);
  z-index: 200; transition: width .1s linear;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .3s var(--ease), height .3s var(--ease);
}
.site-header.is-scrolled { box-shadow: var(--shadow-sm); }
.header-inner { display: flex; align-items: center; gap: 18px; height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-logo { width: 34px; height: 34px; display: grid; place-items: center; }
.brand-name {
  font-family: var(--font-head); font-weight: 900; font-size: 1.18rem;
  color: var(--ink); letter-spacing: .02em;
}
.brand-name .accent { color: var(--brand); }

.main-nav { margin-left: auto; }
.main-nav ul { display: flex; align-items: center; gap: 4px; }
.main-nav a {
  display: inline-block; padding: 9px 13px; border-radius: 999px;
  font-size: .92rem; font-weight: 500; color: var(--ink-2);
  transition: background .2s, color .2s;
}
.main-nav a:hover { background: var(--brand-soft); color: var(--brand-ink); }
.header-search {
  display: grid; place-items: center; width: 40px; height: 40px;
  border-radius: 999px; color: var(--ink-2); transition: background .2s;
}
.header-search:hover { background: var(--surface-2); }
.nav-toggle { display: none; width: 44px; height: 44px; border-radius: 12px; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 5px auto; border-radius: 2px; transition: transform .3s var(--ease), opacity .2s; }
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero (top page) ---------- */
.hero { position: relative; padding: 64px 0 40px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 70% at 80% -10%, rgba(15,118,110,.10), transparent 60%),
    radial-gradient(50% 60% at 0% 10%, rgba(245,158,11,.08), transparent 55%);
}
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.hero h1 {
  font-size: clamp(2rem, 5.2vw, 3.3rem); line-height: 1.28; letter-spacing: .01em;
  font-weight: 900; color: var(--ink);
}
.hero h1 .hl { position: relative; white-space: nowrap; }
.hero h1 .hl::after {
  content: ""; position: absolute; left: -2%; right: -2%; bottom: .08em; height: .42em; z-index: -1;
  background: linear-gradient(120deg, var(--brand-soft-2), var(--brand-soft));
  border-radius: 6px;
}
.hero .lead { margin-top: 20px; font-size: 1.06rem; color: var(--ink-2); max-width: 30em; }
.hero-cta { margin-top: 28px; display: flex; gap: 14px; flex-wrap: wrap; }
.hero-stats { margin-top: 30px; display: flex; gap: 26px; }
.hero-stats div span { display: block; font-family: var(--font-head); font-weight: 900; font-size: 1.6rem; color: var(--brand); line-height: 1.1; }
.hero-stats div small { color: var(--ink-3); font-size: .82rem; }

/* Button */
.btn {
  display: inline-flex; align-items: center; gap: 9px; padding: 13px 24px;
  border-radius: 999px; font-weight: 700; font-size: .96rem;
  transition: transform .2s var(--ease), box-shadow .2s, background .2s;
}
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 8px 20px rgba(15,118,110,.28); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(15,118,110,.34); }
.btn-ghost { background: #fff; color: var(--ink); border: 1px solid var(--line-strong); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand-ink); transform: translateY(-2px); }
.btn svg { width: 18px; height: 18px; }

/* Hero visual (door illustration card) */
.hero-visual {
  position: relative; aspect-ratio: 1 / .92; border-radius: var(--radius-lg);
  background: linear-gradient(135deg, #0f766e, #115e59 60%, #134e4a);
  box-shadow: var(--shadow-lg); overflow: hidden; display: grid; place-items: center;
}
.hero-visual .float-tag {
  position: absolute; background: #fff; border-radius: 12px; padding: 9px 14px;
  font-size: .82rem; font-weight: 700; color: var(--ink); box-shadow: var(--shadow);
  display: flex; align-items: center; gap: 8px;
}
.float-tag .dot { width: 9px; height: 9px; border-radius: 50%; }
.hero-visual .t1 { top: 26px; left: 22px; animation: floaty 5s var(--ease) infinite; }
.hero-visual .t2 { bottom: 80px; right: 18px; animation: floaty 6s var(--ease) infinite .6s; }
.hero-visual .t3 { bottom: 24px; left: 34px; animation: floaty 5.5s var(--ease) infinite 1.2s; }
@keyframes floaty { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* ---------- Category chips strip ---------- */
.cat-strip { display: flex; gap: 10px; flex-wrap: wrap; }
.cat-chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px;
  border-radius: 999px; background: #fff; border: 1px solid var(--line);
  font-weight: 700; font-size: .9rem; color: var(--ink); transition: all .2s var(--ease);
}
.cat-chip:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); border-color: transparent; }
.cat-chip .ico { width: 9px; height: 9px; border-radius: 3px; }

/* ---------- Category cards grid (top) ---------- */
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.cat-card {
  position: relative; display: block; padding: 24px; border-radius: var(--radius);
  background: #fff; border: 1px solid var(--line); overflow: hidden;
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
}
.cat-card::after {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
  background: var(--cc, var(--brand)); transform: scaleY(0); transform-origin: top; transition: transform .3s var(--ease);
}
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.cat-card:hover::after { transform: scaleY(1); }
.cat-card .cat-ico {
  width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center;
  background: color-mix(in srgb, var(--cc) 12%, #fff); color: var(--cc); margin-bottom: 14px;
}
.cat-card .cat-ico svg { width: 24px; height: 24px; }
.cat-card h3 { font-size: 1.1rem; }
.cat-card p { font-size: .86rem; color: var(--ink-3); margin-top: 6px; }
.cat-card .count { display: inline-block; margin-top: 12px; font-size: .78rem; font-weight: 700; color: var(--cc); }

/* ---------- Article cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.post-card {
  display: flex; flex-direction: column; background: #fff; border-radius: var(--radius);
  border: 1px solid var(--line); overflow: hidden;
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
}
.post-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); border-color: transparent; }
.post-thumb { position: relative; aspect-ratio: 16 / 9; overflow: hidden; }
.post-thumb svg, .post-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s var(--ease); }
.post-card:hover .post-thumb svg, .post-card:hover .post-thumb img { transform: scale(1.05); }
.post-tag {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  padding: 5px 11px; border-radius: 999px; font-size: .74rem; font-weight: 700; color: #fff;
  background: var(--cc, var(--brand)); backdrop-filter: blur(4px);
}
.post-body { padding: 18px 18px 20px; display: flex; flex-direction: column; flex: 1; }
.post-body h3 { font-size: 1.06rem; line-height: 1.5; }
.post-card:hover .post-body h3 { color: var(--brand-ink); }
.post-body .excerpt { font-size: .86rem; color: var(--ink-3); margin-top: 9px; flex: 1; }
.post-meta { display: flex; align-items: center; gap: 12px; margin-top: 14px; font-size: .76rem; color: var(--ink-3); }
.post-meta .read { display: inline-flex; align-items: center; gap: 5px; }
.post-meta .read svg { width: 13px; height: 13px; }

/* Featured (large) card */
.featured { display: grid; grid-template-columns: 1.15fr .85fr; gap: 0; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--line); background: #fff; }
.featured .post-thumb { aspect-ratio: auto; height: 100%; min-height: 320px; }
.featured .post-body { padding: 34px; justify-content: center; }
.featured .post-body h3 { font-size: clamp(1.3rem, 2.6vw, 1.7rem); }
.featured .post-body .excerpt { font-size: .95rem; margin-top: 14px; }

/* ---------- Ad slot ---------- */
.ad-slot {
  margin: 30px auto; max-width: 100%; min-height: 90px; display: grid; place-items: center;
  background: repeating-linear-gradient(45deg, var(--surface), var(--surface) 12px, #fff 12px, #fff 24px);
  border: 1px dashed var(--line-strong); border-radius: var(--radius-sm);
  color: var(--ink-3); font-size: .76rem; letter-spacing: .1em;
}
.ad-slot::before { content: "ADVERTISEMENT"; }
.ad-label { display:block; text-align:center; font-size:.66rem; letter-spacing:.18em; color:var(--ink-3); margin-bottom:4px; }
.ad-inarticle { margin: 38px auto; }

/* ===================================================================
   ARTICLE PAGE
   =================================================================== */
.article-wrap { display: grid; grid-template-columns: minmax(0,1fr) 300px; gap: 48px; align-items: start; padding: 34px 0 60px; }
@media (max-width: 980px) { .article-wrap { grid-template-columns: 1fr; } }

.breadcrumb { font-size: .8rem; color: var(--ink-3); margin-bottom: 18px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.breadcrumb a:hover { color: var(--brand); }
.breadcrumb .sep { opacity: .5; }

.article-header { max-width: var(--reading); }
.article-header .post-tag { position: static; display: inline-block; margin-bottom: 14px; }
.article-header h1 { font-size: clamp(1.6rem, 4vw, 2.4rem); line-height: 1.42; letter-spacing: .01em; }
.article-meta { display: flex; align-items: center; gap: 16px; margin-top: 18px; font-size: .84rem; color: var(--ink-3); flex-wrap: wrap; }
.article-meta .author { display: flex; align-items: center; gap: 9px; }
.article-meta .avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--brand-soft); display: grid; place-items: center; color: var(--brand); font-weight: 800; }

.eyecatch { margin: 26px 0 8px; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); }
.eyecatch svg, .eyecatch img { width: 100%; height: auto; }

/* TOC */
.toc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; margin: 30px 0; }
.toc-title { font-family: var(--font-head); font-weight: 700; color: var(--ink); display: flex; align-items: center; gap: 9px; margin-bottom: 12px; }
.toc-title svg { width: 18px; height: 18px; color: var(--brand); }
.toc ol { counter-reset: toc; }
.toc li { counter-increment: toc; padding: 4px 0; }
.toc li a { color: var(--ink-2); font-size: .9rem; transition: color .2s; display: flex; gap: 9px; }
.toc li a::before { content: counter(toc, decimal-leading-zero); color: var(--brand); font-weight: 700; font-size: .8rem; }
.toc li a:hover, .toc li a.active { color: var(--brand); }
.toc li.lvl-3 { padding-left: 20px; }
.toc li.lvl-3 a::before { content: "—"; }

/* Article body typography */
.article-body { max-width: var(--reading); font-size: 1.04rem; }
.article-body > * + * { margin-top: 1.5em; }
.article-body p { color: var(--ink-2); }
.article-body h2 {
  font-size: clamp(1.35rem, 3vw, 1.7rem); margin-top: 2.2em; padding-bottom: .5em; line-height: 1.45;
  border-bottom: 2px solid var(--line); position: relative;
}
.article-body h2::before {
  content: ""; position: absolute; left: 0; bottom: -2px; width: 64px; height: 2px; background: var(--brand);
}
.article-body h3 { font-size: 1.22rem; margin-top: 1.8em; padding-left: 14px; border-left: 4px solid var(--brand); line-height: 1.5; }
.article-body a:not(.btn) { color: var(--brand-ink); border-bottom: 1px solid var(--brand-soft-2); font-weight: 500; }
.article-body a:not(.btn):hover { border-color: var(--brand); }
.article-body strong { color: var(--ink); font-weight: 700; background: linear-gradient(transparent 64%, var(--accent-soft) 64%); padding: 0 1px; }
.article-body ul:not(.plain), .article-body ol { padding-left: 0; }
.article-body ul:not(.plain) li { position: relative; padding-left: 28px; margin-top: .7em; }
.article-body ul:not(.plain) li::before {
  content: ""; position: absolute; left: 4px; top: .62em; width: 8px; height: 8px; border-radius: 50%;
  background: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft);
}
.article-body ol { counter-reset: ol; }
.article-body ol li { position: relative; padding-left: 38px; margin-top: .8em; counter-increment: ol; }
.article-body ol li::before {
  content: counter(ol); position: absolute; left: 0; top: .1em; width: 26px; height: 26px; border-radius: 8px;
  background: var(--brand); color: #fff; font-weight: 800; font-size: .82rem; display: grid; place-items: center; font-family: var(--font-head);
}
.article-body figure { margin: 1.8em 0; }
.article-body figure img, .article-body figure svg { border-radius: var(--radius); box-shadow: var(--shadow-sm); width: 100%; }
.article-body figcaption { text-align: center; font-size: .8rem; color: var(--ink-3); margin-top: 10px; }

/* Callout: コツ box */
.kotu-box {
  position: relative; background: var(--brand-soft); border: 1px solid var(--brand-soft-2);
  border-radius: var(--radius); padding: 22px 24px 22px 24px; margin: 1.8em 0;
}
.kotu-box .kotu-label {
  display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-head); font-weight: 800;
  color: var(--brand-ink); font-size: .92rem; margin-bottom: 8px;
}
.kotu-box .kotu-label .num { width: 26px; height: 26px; border-radius: 8px; background: var(--brand); color: #fff; display: grid; place-items: center; font-size: .82rem; }
.kotu-box p { color: var(--ink-2); margin: 0; }
.kotu-box p + p { margin-top: .7em; }

/* Point / note boxes */
.note-box { border-radius: var(--radius); padding: 18px 22px; margin: 1.8em 0; border: 1px solid var(--line); background: var(--surface); }
.note-box.tip { background: var(--accent-soft); border-color: #fadfb0; }
.note-box.warn { background: #fef2f2; border-color: #fecaca; }
.note-box .nb-title { font-family: var(--font-head); font-weight: 700; color: var(--ink); margin-bottom: 6px; display:flex; align-items:center; gap:8px; }
.note-box.tip .nb-title { color: #b45309; }
.note-box.warn .nb-title { color: #b91c1c; }
.note-box p { margin: 0; font-size: .96rem; }

/* Comparison / data table */
.article-body table { width: 100%; border-collapse: collapse; font-size: .92rem; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.article-body th { background: var(--brand); color: #fff; font-family: var(--font-head); font-weight: 700; padding: 13px 16px; text-align: left; }
.article-body td { padding: 12px 16px; border-bottom: 1px solid var(--line); background: #fff; }
.article-body tr:nth-child(even) td { background: var(--surface); }

/* Credibility / source box */
.source-box { font-size: .82rem; color: var(--ink-3); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 16px 20px; margin-top: 2.4em; }
.source-box h4 { font-size: .86rem; color: var(--ink-2); margin-bottom: 8px; }
.source-box li { margin-top: 5px; padding-left: 16px; position: relative; }
.source-box li::before { content: "›"; position: absolute; left: 0; color: var(--brand); }

/* Author bio */
.author-box { display: flex; gap: 16px; align-items: flex-start; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-top: 36px; }
.author-box .avatar-lg { width: 56px; height: 56px; border-radius: 50%; background: var(--brand-soft); display: grid; place-items: center; color: var(--brand); font-weight: 800; font-size: 1.2rem; flex-shrink: 0; }
.author-box h4 { font-size: 1rem; }
.author-box p { font-size: .86rem; color: var(--ink-3); margin-top: 6px; }

/* Share */
.share-row { display: flex; gap: 10px; align-items: center; margin-top: 30px; }
.share-row span { font-size: .82rem; font-weight: 700; color: var(--ink-3); }
.share-btn { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); color: var(--ink-2); transition: all .2s; border: 1px solid var(--line); }
.share-btn:hover { background: var(--brand); color: #fff; border-color: var(--brand); transform: translateY(-2px); }
.share-btn svg { width: 18px; height: 18px; }

/* Sidebar */
.sidebar { position: sticky; top: calc(var(--header-h) + 20px); display: flex; flex-direction: column; gap: 24px; }
.side-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.side-card h4 { font-size: .95rem; display: flex; align-items: center; gap: 8px; margin-bottom: 14px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.side-card h4 svg { width: 17px; height: 17px; color: var(--brand); }
.rank-list li { display: flex; gap: 12px; padding: 10px 0; align-items: flex-start; }
.rank-list li + li { border-top: 1px solid var(--line); }
.rank-list .rank-no { font-family: var(--font-head); font-weight: 900; font-size: 1.1rem; color: var(--brand); flex-shrink: 0; width: 22px; }
.rank-list .rank-no.top { color: var(--accent); }
.rank-list a { font-size: .86rem; line-height: 1.5; color: var(--ink-2); }
.rank-list a:hover { color: var(--brand); }
.side-ad { position: sticky; top: calc(var(--header-h) + 20px); }

/* Related */
.related-section { padding-top: 20px; border-top: 1px solid var(--line); margin-top: 44px; }

/* ---------- Newsletter / CTA band ---------- */
.cta-band { background: linear-gradient(135deg, #0f766e, #134e4a); border-radius: var(--radius-lg); padding: 48px; color: #fff; text-align: center; position: relative; overflow: hidden; }
.cta-band::before { content: ""; position: absolute; inset: 0; background: radial-gradient(50% 80% at 20% 0%, rgba(255,255,255,.12), transparent 60%); }
.cta-band h2 { color: #fff; font-size: clamp(1.4rem, 3vw, 2rem); position: relative; }
.cta-band p { color: rgba(255,255,255,.85); margin-top: 10px; position: relative; }
.cta-band form { margin-top: 22px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; position: relative; }
.cta-band input { padding: 13px 18px; border-radius: 999px; border: 0; width: 280px; max-width: 100%; font-size: .95rem; }
.cta-band .btn-primary { background: #fff; color: var(--brand-ink); box-shadow: none; }

/* ---------- Footer ---------- */
.site-footer { background: #0d1117; color: #c5ccd6; margin-top: 80px; padding: 56px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 34px; }
.site-footer .brand-name { color: #fff; }
.site-footer .f-about { font-size: .86rem; color: #9aa3af; margin-top: 14px; max-width: 30em; }
.site-footer .f-company { font-size: .8rem; color: #6b7280; margin-top: 14px; line-height: 1.75; }
.footer-grid h5 { color: #fff; font-family: var(--font-head); font-size: .92rem; margin-bottom: 14px; }
.footer-grid li { margin-top: 9px; }
.footer-grid a { font-size: .86rem; color: #9aa3af; transition: color .2s; }
.footer-grid a:hover { color: #fff; }
.footer-bottom { margin-top: 40px; padding-top: 22px; border-top: 1px solid #232b36; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: .8rem; color: #6b7280; }
.footer-bottom a:hover { color: #fff; }

/* ---------- Back to top ---------- */
.to-top {
  position: fixed; right: 22px; bottom: 22px; width: 48px; height: 48px; border-radius: 50%;
  background: var(--brand); color: #fff; display: grid; place-items: center; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(12px); transition: all .3s var(--ease); z-index: 90;
}
.to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { background: var(--brand-ink); }

/* ---------- Scroll reveal ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; } .reveal.d2 { transition-delay: .16s; } .reveal.d3 { transition-delay: .24s; }

/* ---------- Page hero (category) ---------- */
.cat-hero { padding: 50px 0 30px; position: relative; }
.cat-hero h1 { font-size: clamp(1.8rem, 4.5vw, 2.6rem); }
.cat-hero p { color: var(--ink-3); margin-top: 10px; max-width: 40em; }
.cat-hero .cat-ico-lg { width: 60px; height: 60px; border-radius: 16px; display: grid; place-items: center; margin-bottom: 16px; background: color-mix(in srgb, var(--cc) 12%, #fff); color: var(--cc); }
.cat-hero .cat-ico-lg svg { width: 32px; height: 32px; }
.filter-bar { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 24px; }
.filter-bar button { padding: 8px 16px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-size: .86rem; font-weight: 500; color: var(--ink-2); transition: all .2s; }
.filter-bar button.active, .filter-bar button:hover { background: var(--brand); color: #fff; border-color: var(--brand); }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { max-width: 440px; }
  .featured { grid-template-columns: 1fr; }
  .featured .post-thumb { min-height: 220px; }
  .card-grid, .card-grid.cols-2 { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .main-nav {
    position: fixed; inset: var(--header-h) 0 auto 0; background: #fff; border-bottom: 1px solid var(--line);
    transform: translateY(-120%); transition: transform .35s var(--ease); box-shadow: var(--shadow);
    margin-left: 0; max-height: calc(100vh - var(--header-h)); overflow-y: auto;
  }
  .main-nav.is-open { transform: translateY(0); }
  .main-nav ul { flex-direction: column; align-items: stretch; gap: 0; padding: 12px; }
  .main-nav a { padding: 14px 16px; border-radius: 12px; }
  .nav-toggle { display: block; margin-left: auto; }
  .header-search { display: none; }
}
@media (max-width: 560px) {
  .section { padding: 52px 0; }
  .card-grid, .card-grid.cols-2, .cat-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-stats { gap: 18px; }
  .cta-band { padding: 32px 22px; }
  .article-wrap { gap: 0; }
}

/* =====================================================================
   v2 — Portal brush-up (logo, mega menu, hero search, bento, ranking)
   ===================================================================== */

/* ---- Brand mark (refined) ---- */
.brand-logo svg { border-radius: 9px; box-shadow: 0 4px 12px rgba(15,118,110,.28); }
.brand-name { font-weight: 900; letter-spacing: .01em; line-height: 1.05; }
.brand-name .accent { color: var(--brand); }
.brand-tag { display:block; font-family: var(--font-sans); font-weight:600; font-size:.58rem; letter-spacing:.2em; color: var(--ink-3); margin-top:2px; }
@media (max-width: 480px){ .brand-tag{ display:none; } }

/* ---- Header / mega menu ---- */
.main-nav ul { gap: 2px; }
.has-mega { position: relative; }
.mega-btn { display:inline-flex; align-items:center; gap:6px; padding:9px 13px; border-radius:999px; font-size:.92rem; font-weight:600; color:var(--ink-2); cursor:pointer; }
.mega-btn:hover, .mega-btn[aria-expanded="true"] { background: var(--brand-soft); color: var(--brand-ink); }
.mega-btn svg { width:14px; height:14px; transition: transform .25s var(--ease); }
.mega-btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.mega-panel {
  position: absolute; right: 0; top: calc(100% + 12px); width: min(640px, 86vw);
  background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg);
  padding: 16px; grid-template-columns: repeat(2, 1fr); gap: 6px; display:grid;
  opacity: 0; visibility: hidden; transform: translateY(8px); transition: all .22s var(--ease); z-index: 120;
}
.mega-panel.open { opacity:1; visibility:visible; transform:none; }
.mega-link { display:flex; align-items:center; gap:12px; padding:11px 12px; border-radius:12px; transition: background .18s; }
.mega-link:hover { background: var(--surface); }
.mega-ico { width:38px; height:38px; border-radius:11px; display:grid; place-items:center; background: color-mix(in srgb, var(--cc) 13%, #fff); color: var(--cc); flex-shrink:0; }
.mega-ico svg { width:20px; height:20px; }
.mega-link b { font-family: var(--font-head); font-size:.92rem; color: var(--ink); font-weight:700; display:block; }
.mega-link span { font-size:.74rem; color: var(--ink-3); }

/* ---- Hero v2 (portal) ---- */
.hero2 { position: relative; overflow: hidden; padding: 78px 0 60px; }
.hero2-bg { position:absolute; inset:0; z-index:-1; overflow:hidden; }
.hero2-bg::before, .hero2-bg::after, .hero2-blob { content:""; position:absolute; border-radius:50%; filter: blur(64px); opacity:.5; }
.hero2-bg::before { width:520px; height:520px; right:-120px; top:-180px; background: radial-gradient(circle, #5eead4, transparent 70%); animation: drift 18s var(--ease) infinite alternate; }
.hero2-bg::after { width:440px; height:440px; left:-140px; bottom:-200px; background: radial-gradient(circle, #fcd9a3, transparent 70%); animation: drift 22s var(--ease) infinite alternate-reverse; }
.hero2-blob { width:360px; height:360px; left:48%; top:-120px; background: radial-gradient(circle, #a7f3d0, transparent 70%); animation: drift 26s var(--ease) infinite alternate; }
@keyframes drift { to { transform: translate(40px, 50px) scale(1.12); } }
.hero2 .inner { max-width: 820px; margin: 0 auto; text-align: center; }
.hero2 h1 { font-size: clamp(2.1rem, 5.6vw, 3.6rem); font-weight:900; line-height:1.26; letter-spacing:.01em; }
.hero2 h1 .hl { background: linear-gradient(120deg, var(--brand), #14b8a6 55%, #f59e0b); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero2 .lead { margin: 18px auto 0; font-size: 1.08rem; color: var(--ink-2); max-width: 34em; }
.hero-search { margin: 30px auto 0; max-width: 580px; display:flex; align-items:center; gap:8px; background:#fff; border:1px solid var(--line-strong); border-radius: 999px; padding: 7px 7px 7px 20px; box-shadow: var(--shadow); transition: box-shadow .2s, border-color .2s; }
.hero-search:focus-within { border-color: var(--brand); box-shadow: 0 10px 30px rgba(15,118,110,.16); }
.hero-search svg.mag { width:20px; height:20px; color: var(--ink-3); flex-shrink:0; }
.hero-search input { flex:1; border:0; outline:0; font-size:1rem; background:transparent; padding: 11px 6px; font-family: inherit; }
.hero-search button { flex-shrink:0; padding:12px 24px; border-radius:999px; background: var(--brand); color:#fff; font-weight:700; box-shadow: 0 6px 16px rgba(15,118,110,.3); transition: transform .2s, background .2s; }
.hero-search button:hover { transform: translateY(-1px); background: var(--brand-ink); }
.trend { margin-top: 18px; display:flex; gap:8px; justify-content:center; flex-wrap:wrap; align-items:center; }
.trend .label { font-size:.78rem; font-weight:700; color: var(--ink-3); }
.trend a { font-size:.82rem; padding:6px 13px; border-radius:999px; background:#fff; border:1px solid var(--line); color:var(--ink-2); transition: all .18s; }
.trend a:hover { border-color: var(--brand); color: var(--brand-ink); transform: translateY(-1px); }
.hero-counter { margin-top: 30px; display:inline-flex; gap:30px; padding: 14px 28px; background: rgba(255,255,255,.7); backdrop-filter: blur(8px); border:1px solid var(--line); border-radius: 16px; }
.hero-counter div span { display:block; font-family: var(--font-head); font-weight:900; font-size:1.5rem; color: var(--brand); line-height:1; }
.hero-counter div small { font-size:.74rem; color: var(--ink-3); }

/* ---- Popular ranking strip ---- */
.rank-strip { display:grid; grid-template-columns: repeat(5, 1fr); gap: 14px; }
.rank-item { position:relative; display:block; background:#fff; border:1px solid var(--line); border-radius: var(--radius); overflow:hidden; transition: transform .25s var(--ease), box-shadow .25s, border-color .25s; }
.rank-item:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.rank-item .rk { position:absolute; top:8px; left:8px; z-index:2; width:30px; height:30px; border-radius:9px; display:grid; place-items:center; font-family: var(--font-head); font-weight:900; font-size:1rem; color:#fff; background: rgba(21,24,30,.7); backdrop-filter: blur(4px); }
.rank-item.r1 .rk { background: linear-gradient(135deg,#f59e0b,#d97706); }
.rank-item.r2 .rk { background: linear-gradient(135deg,#94a3b8,#64748b); }
.rank-item.r3 .rk { background: linear-gradient(135deg,#d6a266,#b07b41); }
.rank-item .rk-thumb { aspect-ratio: 16/10; }
.rank-item .rk-thumb svg { width:100%; height:100%; }
.rank-item .rk-body { padding: 12px 13px 15px; }
.rank-item .rk-body .tg { font-size:.7rem; font-weight:700; color: var(--cc); }
.rank-item .rk-body h3 { font-size:.9rem; line-height:1.45; margin-top:4px; }
.rank-item:hover h3 { color: var(--brand-ink); }

/* ---- Bento category grid ---- */
.bento { display:grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 158px; gap: 16px; }
.bento-tile { position:relative; display:flex; flex-direction:column; justify-content:flex-end; padding: 20px; border-radius: 18px; overflow:hidden; color:#fff; isolation:isolate; transition: transform .28s var(--ease), box-shadow .28s; }
.bento-tile:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.bento-tile::before { content:""; position:absolute; inset:0; z-index:-2; background: linear-gradient(150deg, var(--cc), color-mix(in srgb, var(--cc) 55%, #0b1220)); }
.bento-tile::after { content:""; position:absolute; inset:0; z-index:-1; background: radial-gradient(70% 80% at 80% 10%, rgba(255,255,255,.22), transparent 60%); }
.bento-tile .b-ico { position:absolute; top:18px; left:18px; width:42px; height:42px; border-radius:12px; display:grid; place-items:center; background: rgba(255,255,255,.18); backdrop-filter: blur(4px); }
.bento-tile .b-ico svg { width:23px; height:23px; color:#fff; }
.bento-tile h3 { color:#fff; font-size:1.18rem; }
.bento-tile p { font-size:.82rem; color: rgba(255,255,255,.86); margin-top:3px; }
.bento-tile .b-count { margin-top:8px; font-size:.74rem; font-weight:700; color: rgba(255,255,255,.95); display:inline-flex; align-items:center; gap:5px; }
.bento-tile.b-lg { grid-column: span 2; grid-row: span 2; }
.bento-tile.b-lg h3 { font-size:1.7rem; }
.bento-tile.b-lg p { font-size:.95rem; }
.bento-tile.b-wide { grid-column: span 2; }
.bento-deco { position:absolute; right:-20px; bottom:-20px; z-index:-1; opacity:.16; }
.bento-deco svg { width:150px; height:150px; color:#fff; }

/* ---- Portal section heads ---- */
.sec-head2 { display:flex; align-items:flex-end; justify-content:space-between; gap:16px; margin-bottom:28px; flex-wrap:wrap; }
.sec-head2 .t h2 { font-size: clamp(1.45rem, 3.2vw, 2rem); }
.sec-head2 .t .eyebrow { margin-bottom:8px; }
.sec-head2 .more { font-size:.88rem; font-weight:700; color: var(--brand); display:inline-flex; align-items:center; gap:6px; white-space:nowrap; }
.sec-head2 .more:hover { gap:9px; }
.sec-head2 .more svg { width:16px; height:16px; }

/* ---- responsive v2 ---- */
@media (max-width: 1024px){
  .rank-strip { grid-template-columns: repeat(3, 1fr); }
  .rank-item:nth-child(4), .rank-item:nth-child(5){ display:none; }
}
@media (max-width: 860px){
  .bento { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 150px; }
  .bento-tile.b-lg { grid-column: span 2; grid-row: span 1; }
  .bento-tile.b-wide { grid-column: span 2; }
  .mega-panel { grid-template-columns: 1fr; width: min(360px, 90vw); }
}
@media (max-width: 560px){
  .rank-strip { grid-template-columns: 1fr 1fr; }
  .rank-item:nth-child(5){ display:none; }
  .bento { grid-template-columns: 1fr; grid-auto-rows: 132px; }
  .bento-tile.b-lg, .bento-tile.b-wide { grid-column: span 1; }
  .hero-search button span { display:none; }
  .hero-search button { padding:12px 16px; }
}

/* ---- Photo eyecatch (real photo + category-color overlay) ---- */
.ec, .ec-hero { overflow: hidden; background: linear-gradient(135deg, var(--cc,#0f766e), color-mix(in srgb, var(--cc,#0f766e) 46%, #0b1220)); }
.ec { position: absolute; inset: 0; }
.ec-hero { position: relative; aspect-ratio: 16 / 9; border-radius: inherit; }
.ec .ec-img, .ec-hero .ec-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.ec .ec-ov, .ec-hero .ec-ov { position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(120deg, color-mix(in srgb, var(--cc,#0f766e) 55%, transparent), color-mix(in srgb, var(--cc,#0f766e) 14%, transparent) 70%),
    linear-gradient(0deg, rgba(8,12,20,.5), rgba(8,12,20,0) 50%); }
.ec .ec-kick, .ec-hero .ec-kick { position: absolute; left: 16px; bottom: 13px; z-index: 2; color: #fff;
  font-family: var(--font-head); font-weight: 900; font-size: clamp(.95rem, 2vw, 1.3rem); letter-spacing: .05em;
  line-height: 1.1; text-shadow: 0 2px 12px rgba(0,0,0,.45); }
.ec .ec-kick small, .ec-hero .ec-kick small { display: block; font-size: .58em; font-weight: 700; letter-spacing: .2em; opacity: .92; margin-top: 4px; }
.ec-hero .ec-kick { left: 30px; bottom: 24px; font-size: clamp(1.5rem, 3.4vw, 2.5rem); }
.post-card:hover .ec .ec-img, .rank-item:hover .ec .ec-img, .featured:hover .ec .ec-img { transform: scale(1.06); }
.rk-thumb { position: relative; overflow: hidden; }

/* ---- AdSense units ---- */
.ad-unit { margin: 32px auto; text-align:center; max-width:100%; }
.ad-unit.ad-multiplex { margin-top: 40px; }
.ad-feed { grid-column: span 1; align-self:start; min-height: 120px; }
.ad-feed .ad-label, .ad-unit .ad-label { display:block; margin-bottom:4px; }
.side-ad .adsbygoogle { min-height: 250px; }

/* ---- nav desktop/mobile split ---- */
.nav-mega-desktop { display:flex; align-items:center; gap:4px; }
.nav-flat { padding:9px 13px; border-radius:999px; font-size:.92rem; font-weight:600; color:var(--ink-2); transition:background .2s,color .2s; }
.nav-flat:hover { background:var(--brand-soft); color:var(--brand-ink); }
.main-nav .nav-list-mobile { display:none; }
@media (max-width: 860px){
  .main-nav .nav-mega-desktop { display:none; }
  .main-nav .nav-list-mobile { display:flex; }
}

/* ---- grouped mega menu (大→中) ---- */
.mega-grouped { width:min(720px,92vw); grid-template-columns:repeat(2,1fr); gap:6px 20px; padding:18px; }
.mega-group { min-width:0; }
.mega-h { display:flex; align-items:baseline; gap:9px; padding:6px 10px 8px; border-bottom:1px solid var(--line); margin-bottom:4px; }
.mega-h span { font-family:var(--font-head); font-weight:800; font-size:.92rem; color:var(--ink); }
.mega-h small { font-size:.58rem; letter-spacing:.16em; color:var(--ink-3); font-weight:700; }
.m-group-h { padding:14px 16px 4px !important; font-family:var(--font-head); font-weight:800; font-size:.72rem; color:var(--ink-3); letter-spacing:.1em; }
.m-group-h::before { content:none !important; }

/* ---- "ジャンルから探す" grouped category cards ---- */
.jgroups { display:flex; flex-direction:column; gap:36px; }
.jgroup-h { display:flex; align-items:baseline; gap:12px; margin-bottom:16px; }
.jgroup-h h3 { font-size:1.18rem; }
.jgroup-en { font-size:.64rem; font-weight:800; letter-spacing:.2em; color:var(--brand); }
.jgrid { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; }
.jcard { position:relative; display:flex; flex-direction:column; padding:20px 20px 17px; background:#fff; border:1px solid var(--line); border-radius:16px; overflow:hidden; transition:transform .25s var(--ease),box-shadow .25s,border-color .25s; }
.jcard::before { content:""; position:absolute; left:0; top:0; bottom:0; width:4px; background:var(--cc); }
.jcard:hover { transform:translateY(-4px); box-shadow:var(--shadow); border-color:transparent; }
.jcard-ill { position:absolute; right:-16px; bottom:-20px; color:var(--cc); opacity:.10; pointer-events:none; }
.jcard-ill svg { width:124px; height:124px; }
.jcard-ico { width:46px; height:46px; border-radius:13px; display:grid; place-items:center; background:color-mix(in srgb,var(--cc) 13%,#fff); color:var(--cc); margin-bottom:13px; }
.jcard-ico svg { width:24px; height:24px; }
.jcard-body { display:block; }
.jcard-name { display:block; font-family:var(--font-head); font-weight:800; font-size:1.14rem; color:var(--ink); }
.jcard-desc { display:block; font-size:.82rem; color:var(--ink-3); margin-top:3px; }
.jcard-count { margin-top:13px; font-size:.76rem; font-weight:700; color:var(--cc); display:inline-flex; align-items:center; gap:5px; }
.jcard-count svg { width:15px; height:15px; }
@media (max-width:860px){ .jgrid { grid-template-columns:1fr 1fr; } }
@media (max-width:560px){ .jgrid { grid-template-columns:1fr; } }

/* ---- grouped footer ---- */
.footer-top { margin-bottom:36px; max-width:36em; }
.footer-top .brand-name { color:#fff; }
.footer-cats { display:grid; grid-template-columns:repeat(5,1fr); gap:26px; }
.footer-cats h5 { color:#fff; font-family:var(--font-head); font-size:.9rem; margin-bottom:14px; }
.footer-cats li { margin-top:9px; }
.footer-cats a { font-size:.85rem; color:#9aa3af; transition:color .2s; }
.footer-cats a:hover { color:#fff; }
@media (max-width:860px){ .footer-cats { grid-template-columns:repeat(2,1fr); } }
@media (max-width:560px){ .footer-cats { grid-template-columns:1fr 1fr; } }
