/* =========================================================
   資格Life (SHIKAKU-LIFE) — Shared Design System
   ========================================================= */

:root {
  --bg: #f4faff;
  --bg-2: #eaf4ff;
  --card: #ffffff;
  --ink: #1f2937;
  --ink-strong: #0f1b2d;
  --soft: #5b6b7c;
  --muted: #8392a4;
  --primary: #3aa0ff;
  --primary-deep: #1d6fc4;
  --primary-soft: #e3f1ff;
  --orange: #ff8b3d;
  --orange-deep: #f06f17;
  --orange-soft: #fff0e3;
  --mint: #4dd1a8;
  --mint-soft: #defaf0;
  --pink: #ff8db3;
  --pink-soft: #ffe6ee;
  --yellow: #ffcf4d;
  --yellow-soft: #fff7da;
  --violet: #8c8aff;
  --violet-soft: #ecebff;
  --rule: #dde7f1;
  --rule-strong: #c9d6e4;

  --shadow-sm: 0 1px 2px rgba(29, 111, 196, .06);
  --shadow-md: 0 6px 18px rgba(29, 111, 196, .08);
  --shadow-lg: 0 18px 40px rgba(29, 111, 196, .12);
  --shadow-cta: 0 10px 22px rgba(240, 111, 23, .28);

  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 18px;
  --radius-xl: 24px;

  --font-heading: "Zen Maru Gothic", "Hiragino Sans", "Yu Gothic", system-ui, sans-serif;
  --font-body:    "Zen Kaku Gothic New", "Hiragino Sans", "Yu Gothic", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  word-break: auto-phrase;
  line-break: strict;
}

body { word-break: auto-phrase; line-break: strict; }

a { color: var(--primary-deep); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--ink-strong);
  line-height: 1.45;
  margin: 0 0 .5em;
  font-weight: 700;
  text-wrap: pretty;
}
p { margin: 0 0 1em; }

em {
  font-style: normal;
  background: linear-gradient(180deg, transparent 65%, var(--orange-soft) 65%);
  padding: 0 .12em;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}
.container-narrow {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ========== Header ========== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(244, 250, 255, .9);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1.5px solid var(--rule);
}
.site-header .inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 72px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 22px;
  color: var(--ink-strong);
  letter-spacing: .01em;
}
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 38px; height: 38px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 80%);
  display: inline-grid;
  place-items: center;
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  box-shadow: 0 4px 10px rgba(58, 160, 255, .35);
  position: relative;
}
.brand-mark::after {
  content: "";
  position: absolute;
  inset: auto -4px -4px auto;
  width: 14px; height: 14px;
  background: var(--orange);
  border-radius: 50%;
  border: 2.5px solid var(--bg);
}
.brand .sub {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 11px;
  color: var(--soft);
  letter-spacing: .22em;
  display: block;
  margin-top: -4px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.site-nav a {
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--ink);
  font-weight: 500;
  font-size: 15px;
  font-family: var(--font-heading);
}
.site-nav a:hover {
  background: var(--primary-soft);
  text-decoration: none;
  color: var(--primary-deep);
}
.site-nav a.is-active {
  background: var(--ink-strong);
  color: #fff;
}
.site-nav a.is-active:hover { background: var(--ink-strong); color: #fff; }
.nav-cta {
  background: var(--orange) !important;
  color: #fff !important;
  box-shadow: var(--shadow-cta);
  padding: 8px 16px !important;
}
.nav-cta:hover { background: var(--orange-deep) !important; }

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  font-size: 22px;
  cursor: pointer;
  margin-left: auto;
  color: var(--ink);
  padding: 8px 10px;
  border-radius: 10px;
}
.nav-toggle:hover { background: var(--primary-soft); }

@media (max-width: 880px) {
  .site-nav {
    position: fixed;
    inset: 72px 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1.5px solid var(--rule);
    padding: 16px 24px 24px;
    box-shadow: var(--shadow-md);
    transform: translateY(-110%);
    transition: transform .25s ease;
  }
  .site-nav.is-open { transform: translateY(0); }
  .site-nav a { padding: 14px 16px; border-radius: 12px; }
  .nav-toggle { display: inline-flex; }
}

/* ========== Buttons ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 16px;
  border-radius: 999px;
  padding: 14px 26px;
  border: 0;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn-cta {
  background: var(--orange);
  color: #fff;
  box-shadow: var(--shadow-cta);
}
.btn-cta:hover {
  background: var(--orange-deep);
  transform: translateY(-2px);
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(240, 111, 23, .35);
}
.btn-primary {
  background: var(--primary-deep);
  color: #fff;
  box-shadow: 0 8px 18px rgba(29, 111, 196, .25);
}
.btn-primary:hover { background: #155da8; color: #fff; text-decoration: none; transform: translateY(-2px); }
.btn-ghost {
  background: #fff;
  color: var(--primary-deep);
  border: 1.5px solid var(--rule-strong);
}
.btn-ghost:hover { background: var(--primary-soft); border-color: var(--primary); text-decoration: none; }
.btn-sm { padding: 9px 18px; font-size: 14px; }

/* ========== Eyebrows + section headers ========== */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: .28em;
  color: var(--primary-deep);
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
}
.section-head h2 {
  font-size: 28px;
  margin: 6px 0 0;
}
.section-head .more {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
  color: var(--primary-deep);
}

/* ========== Cards ========== */
.card {
  background: var(--card);
  border: 1.5px solid var(--rule);
  border-radius: var(--radius-lg);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-soft);
}

/* ========== Category pill ========== */
.cat-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 12px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary-deep);
  white-space: nowrap;
}
.cat-pill.cat-bilmen { background: var(--mint-soft); color: #1c8a64; }
.cat-pill.cat-ai     { background: var(--violet-soft); color: #4a48d8; }
.cat-pill.cat-law    { background: var(--primary-soft); color: var(--primary-deep); }
.cat-pill.cat-money  { background: var(--yellow-soft); color: #8a5e00; }
.cat-pill.cat-lang   { background: var(--pink-soft); color: #b5407c; }
.cat-pill.cat-story  { background: var(--orange-soft); color: var(--orange-deep); }

/* ========== Article cards ========== */
.article-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
@media (max-width: 880px) {
  .article-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .article-grid { grid-template-columns: 1fr; }
}

.article-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.article-card .thumb {
  aspect-ratio: 16 / 10;
  display: grid;
  place-items: center;
  font-size: 64px;
  background: linear-gradient(135deg, var(--primary-soft), #fff 70%);
  position: relative;
}
.article-card .thumb.t-mint   { background: linear-gradient(135deg, var(--mint-soft), #fff 70%); }
.article-card .thumb.t-orange { background: linear-gradient(135deg, var(--orange-soft), #fff 70%); }
.article-card .thumb.t-violet { background: linear-gradient(135deg, var(--violet-soft), #fff 70%); }
.article-card .thumb.t-pink   { background: linear-gradient(135deg, var(--pink-soft), #fff 70%); }
.article-card .thumb.t-yellow { background: linear-gradient(135deg, var(--yellow-soft), #fff 70%); }
.article-card .thumb .badge {
  position: absolute;
  top: 12px; left: 12px;
}
.article-card .body {
  padding: 18px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}
.article-card h3 {
  font-size: 18px;
  margin: 0;
  line-height: 1.5;
}
.article-card .excerpt {
  color: var(--soft);
  font-size: 14px;
  line-height: 1.7;
  margin: 0;
}
.article-card .meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--muted);
  margin-top: auto;
  padding-top: 8px;
  font-family: var(--font-heading);
}
.article-card .meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--muted); }

/* ========== Bilmen academy band ========== */
.bilmen-band {
  background:
    radial-gradient(60% 120% at 10% 20%, rgba(255, 207, 77, .25), transparent 60%),
    radial-gradient(60% 120% at 90% 80%, rgba(77, 209, 168, .25), transparent 60%),
    linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: 44px 48px;
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 28px;
  align-items: center;
}
@media (max-width: 720px) { .bilmen-band { grid-template-columns: 1fr; padding: 32px 28px; } }
.bilmen-band h2 {
  color: #fff;
  font-size: 28px;
  line-height: 1.4;
  margin: 6px 0 12px;
}
.bilmen-band p { color: rgba(255,255,255,.92); margin: 0 0 18px; font-size: 15px; }
.bilmen-band .eyebrow { color: #fff; opacity: .9; }
.bilmen-band .eyebrow::before { background: #fff; }
.bilmen-band .stickers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.bilmen-band .sticker {
  background: rgba(255,255,255,.13);
  border: 1.5px solid rgba(255,255,255,.25);
  border-radius: 14px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
}
.bilmen-band .sticker .ico {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: rgba(255,255,255,.2);
  display: grid; place-items: center;
  font-size: 20px;
}
.bilmen-band .btn-cta { background: #fff; color: var(--primary-deep); box-shadow: 0 8px 18px rgba(0,0,0,.18); }
.bilmen-band .btn-cta:hover { background: #fff; color: var(--primary-deep); }
.bilmen-band .float {
  position: absolute;
  font-size: 80px;
  opacity: .15;
}
.bilmen-band .float-1 { top: -10px; right: 30%; }
.bilmen-band .float-2 { bottom: -20px; right: 6%; font-size: 110px; }

/* ========== Footer ========== */
.site-footer {
  background: #fff;
  border-top: 1.5px solid var(--rule);
  margin-top: 80px;
  padding: 56px 0 28px;
}
.site-footer .grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
}
@media (max-width: 720px) { .site-footer .grid { grid-template-columns: 1fr 1fr; } }
.site-footer h4 {
  font-size: 13px;
  letter-spacing: .18em;
  color: var(--soft);
  margin: 0 0 14px;
  font-weight: 700;
  text-transform: uppercase;
  font-family: var(--font-heading);
}
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer a { color: var(--ink); font-size: 14px; }
.site-footer .tagline {
  font-size: 13px;
  color: var(--soft);
  line-height: 1.8;
  margin-top: 12px;
}
.site-footer .legal {
  border-top: 1.5px solid var(--rule);
  margin-top: 36px;
  padding-top: 18px;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted);
  flex-wrap: wrap;
  gap: 8px;
}

/* ========== Breadcrumb ========== */
.crumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--soft);
  flex-wrap: wrap;
  font-family: var(--font-heading);
}
.crumbs a { color: var(--soft); }
.crumbs a:hover { color: var(--primary-deep); }
.crumbs .sep { color: var(--muted); }

/* ========== Tags / chips ========== */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1.5px solid var(--rule);
  font-size: 13px;
  font-family: var(--font-heading);
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
  transition: all .15s ease;
}
.chip:hover { border-color: var(--primary); color: var(--primary-deep); }
.chip.is-active {
  background: var(--ink-strong);
  color: #fff;
  border-color: var(--ink-strong);
}

/* ========== Search input ========== */
.search-box {
  position: relative;
  flex: 1;
  min-width: 220px;
}
.search-box input {
  width: 100%;
  border: 1.5px solid var(--rule);
  background: #fff;
  border-radius: 999px;
  padding: 10px 16px 10px 40px;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--ink);
  outline: none;
}
.search-box input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.search-box::before {
  content: "🔍";
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  opacity: .55;
}

/* ========== PR / sponsored bar ========== */
.pr-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--yellow-soft);
  color: #8a5e00;
  border: 1px dashed #d8a200;
  border-radius: 999px;
  padding: 4px 14px;
  font-size: 12px;
  font-family: var(--font-heading);
  font-weight: 500;
}

/* ========== Hide/show utility ========== */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
