:root {
  --ink: #17251f;
  --muted: #5b655f;
  --blue: #3a4ee8;
  --blue-dark: #2532a9;
  --blue-soft: #eef0ff;
  --yellow: #eaf45d;
  --yellow-soft: #fafdcf;
  --green: #0c7c68;
  --green-soft: #ddf6ee;
  --red: #c84b3a;
  --red-soft: #ffe9e4;
  --coral: #ff6b4a;
  --line: #d8d8cd;
  --paper: #fffdf7;
  --surface: #f5f4ed;
  --shadow: 8px 9px 0 rgba(23, 37, 31, .12);
  --radius: 16px;
}

body {
  color: var(--ink);
  background-color: var(--paper);
  background-image: radial-gradient(rgba(23,37,31,.045) .65px, transparent .65px);
  background-size: 8px 8px;
}

body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  z-index: 80;
  height: 5px;
  background: linear-gradient(90deg, var(--blue) 0 50%, var(--yellow) 50% 70%, var(--green) 70% 85%, var(--coral) 85% 100%);
}

h1, h2, h3 {
  font-family: Georgia, "Times New Roman", serif;
  letter-spacing: -.045em;
}

h1 { font-weight: 800; }
h2, h3 { font-weight: 750; }

.site-header {
  top: 5px;
  border-bottom: 2px solid var(--ink);
  background: rgba(255,253,247,.96);
}

.header-inner { min-height: 78px; }

.brand {
  gap: .8rem;
  flex: 0 0 auto;
  letter-spacing: -.03em;
}

.brand-mark {
  position: relative;
  width: 42px;
  height: 42px;
  color: white;
  background: var(--blue);
  border: 2px solid var(--ink);
  border-radius: 50% 50% 50% 12px;
  box-shadow: 3px 3px 0 var(--yellow);
  transform: rotate(-3deg);
}

.brand-mark::after {
  content: "";
  position: absolute;
  top: -5px;
  right: -5px;
  width: 11px;
  height: 11px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--coral);
}

.brand-wordmark {
  display: grid;
  gap: .14rem;
  line-height: 1;
}

.brand-wordmark strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: -.045em;
}

.brand-wordmark small {
  color: var(--blue-dark);
  font-size: .75rem;
  font-weight: 900;
  letter-spacing: .075em;
  text-transform: uppercase;
}

.nav a { border: 1px solid transparent; }
.nav a:hover, .nav a:focus-visible, .nav a[aria-current="page"] {
  color: var(--ink);
  border-color: var(--ink);
  background: var(--yellow);
  box-shadow: 2px 2px 0 var(--ink);
}

.hero {
  padding-top: clamp(4rem, 8vw, 7.4rem);
  background:
    radial-gradient(circle at 90% 12%, rgba(234,244,93,.85) 0 8%, transparent 8.2%),
    radial-gradient(circle at 80% 76%, rgba(255,107,74,.12) 0 22%, transparent 22.2%),
    linear-gradient(145deg, rgba(238,240,255,.8), rgba(255,253,247,.94) 58%);
  border-bottom: 2px solid var(--ink);
}

.hero h1 { max-width: 820px; }
.brand-highlight {
  position: relative;
  display: inline-block;
  color: var(--blue-dark);
  white-space: nowrap;
}
.brand-highlight::after {
  content: "";
  position: absolute;
  left: 1%;
  right: -1%;
  bottom: .03em;
  z-index: -1;
  height: .22em;
  border-radius: 99px 55% 99px 35%;
  background: var(--yellow);
  transform: rotate(-1.5deg);
}

.eyebrow {
  padding: .28rem .55rem;
  color: var(--ink);
  background: var(--yellow);
  border: 1.5px solid var(--ink);
  border-radius: 4px;
  box-shadow: 3px 3px 0 var(--ink);
  transform: rotate(-.7deg);
}
.eyebrow::before { display: none; }

.brand-mantra {
  margin: 1.2rem 0 0;
  color: var(--blue-dark);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.05rem;
  font-weight: 800;
}

.button { border-radius: 9px; }
.button-primary {
  color: white;
  background: var(--blue);
  border-color: var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
}
.button-primary:hover { background: var(--blue-dark); transform: translate(1px,1px); box-shadow: 2px 2px 0 var(--ink); }
.button-secondary { border-color: var(--ink); background: var(--paper); }
.button-secondary:hover { background: var(--yellow-soft); }

.hero-panel {
  border: 2px solid var(--ink);
  border-radius: 18px;
  background: var(--paper);
  box-shadow: 10px 11px 0 var(--ink);
  transform: rotate(1deg);
}
.hero-panel::before { width: 86px; height: 17px; top: -9px; right: 24px; border: 1.5px solid var(--ink); background: var(--yellow); transform: rotate(-3deg); }
.mini-card { border-color: var(--ink); border-radius: 10px; background: white; }
.mini-card:nth-of-type(3) { background: var(--yellow-soft); }
.mini-card:nth-of-type(4) { background: var(--green-soft); }

.section-soft { background: rgba(245,244,237,.92); }
.choice { border: 1.5px solid var(--ink); background: var(--paper); }
.choice:hover, .choice:focus-visible, .choice[aria-pressed="true"] { border-color: var(--ink); color: var(--ink); background: var(--yellow); box-shadow: 3px 3px 0 var(--ink); }

.recommendation { border: 2px solid var(--ink); border-radius: 14px; background: var(--paper); box-shadow: 6px 6px 0 var(--blue-soft); }
.recommendation-badge { color: var(--ink); background: var(--yellow); border: 1.5px solid var(--ink); border-radius: 50%; }

.content-card, .library-card, .method-card {
  border: 1.5px solid var(--ink);
  border-radius: 14px;
  background: var(--paper);
  box-shadow: 4px 4px 0 rgba(23,37,31,.08);
}
.term-card { border-color: var(--ink); box-shadow: 4px 4px 0 rgba(23,37,31,.08); }
.term-card:nth-child(4n+1) { border-top: 7px solid var(--blue); }
.term-card:nth-child(4n+2) { border-top: 7px solid var(--green); }
.term-card:nth-child(4n+3) { border-top: 7px solid var(--yellow); }
.term-card:nth-child(4n) { border-top: 7px solid var(--coral); }
.alphabet { border: 2px solid var(--ink); background: rgba(255,253,247,.96); box-shadow: 4px 4px 0 var(--yellow); }
.faq-item { border-color: var(--ink); box-shadow: 4px 4px 0 rgba(23,37,31,.08); }
.faq-item[open] { box-shadow: 5px 5px 0 var(--yellow); }
.use-card { border-color: var(--ink); box-shadow: 4px 4px 0 rgba(23,37,31,.08); }
.use-card:nth-child(3n+1) { border-top: 7px solid var(--blue); }
.use-card:nth-child(3n+2) { border-top: 7px solid var(--green); }
.use-card:nth-child(3n) { border-top: 7px solid var(--coral); }
.use-card[open] { box-shadow: 6px 6px 0 var(--yellow); }
.risk-card { box-shadow: 4px 4px 0 rgba(23,37,31,.1); }
.risk-card[open] { box-shadow: 6px 6px 0 var(--coral); }
.tool-family-grid article:nth-child(3n+1) { border-top: 7px solid var(--blue); }
.tool-family-grid article:nth-child(3n+2) { border-top: 7px solid var(--green); }
.tool-family-grid article:nth-child(3n) { border-top: 7px solid var(--coral); }
.prompt-principles article:nth-child(1) { border-top: 7px solid var(--blue); }
.prompt-principles article:nth-child(2) { border-top: 7px solid var(--green); }
.prompt-principles article:nth-child(3) { border-top: 7px solid var(--coral); }
.prompt-principles article:nth-child(4) { border-top: 7px solid var(--yellow); }
.content-card:hover, .library-card:hover { border-color: var(--ink); box-shadow: 7px 7px 0 var(--ink); transform: translate(-2px,-2px) rotate(-.25deg); }
.content-card:nth-child(1), .library-card[data-category="notion"] { border-top: 7px solid var(--blue); }
.content-card:nth-child(2), .library-card[data-category="guide"] { border-top: 7px solid var(--green); }
.content-card:nth-child(3), .library-card[data-category="vigilance"] { border-top: 7px solid var(--coral); }
.content-card:nth-child(4) { border-top: 7px solid var(--yellow); }
.card-icon { border: 1.5px solid var(--ink); border-radius: 50%; }
.library-tag { color: var(--ink); border: 1px solid var(--ink); background: var(--yellow); }
.library-card[data-category="guide"] .library-tag { background: var(--green-soft); }
.library-card[data-category="vigilance"] .library-tag { background: var(--red-soft); }

.path-card { border: 2px solid var(--ink); border-radius: 16px; background: var(--blue-dark); box-shadow: 9px 9px 0 var(--yellow); transform: rotate(-.6deg); }
.path-card .button { border: 2px solid var(--ink); background: var(--yellow); box-shadow: 3px 3px 0 white; }

.trust-strip { border-top: 2px solid var(--ink); background: var(--yellow); }
.trust-grid { border: 2px solid var(--ink); border-radius: 12px; background: var(--ink); }
.trust-grid > div { background: var(--paper); }
.trust-grid > div:nth-child(2) { background: var(--blue-soft); }
.trust-grid > div:nth-child(3) { background: var(--green-soft); }
.trust-grid > div:nth-child(4) { background: var(--yellow-soft); }

.library-hero, .page-hero {
  background:
    linear-gradient(90deg, rgba(58,78,232,.08) 1px, transparent 1px),
    linear-gradient(rgba(58,78,232,.08) 1px, transparent 1px),
    linear-gradient(160deg, var(--blue-soft), var(--paper) 68%);
  background-size: 28px 28px, 28px 28px, auto;
  border-bottom: 2px solid var(--ink);
}

.search-field { border-color: var(--ink); border-radius: 10px; box-shadow: 6px 6px 0 var(--yellow); }
.search-field button { color: var(--ink); border: 1px solid var(--ink); background: var(--yellow); }

.meta-box { border: 2px solid var(--ink); border-radius: 12px; background: var(--paper); box-shadow: 6px 6px 0 var(--yellow); }
.toc a { border-left-color: var(--ink); }
.definition, .warning, .remember { border-radius: 8px; }
.definition { border-left-color: var(--blue); }
.warning { border-left-color: var(--coral); }
.remember { border-left-color: #c3d000; }

.site-footer { border-top: 5px solid var(--yellow); background: var(--ink); }

.course-layout { max-width: 930px; }
.course-intro { max-width: 680px; margin-bottom: 2.5rem; }
.course-map { display: grid; gap: 1.15rem; margin: 0; padding: 0; list-style: none; counter-reset: none; }
.course-step { display: grid; grid-template-columns: 72px 1fr; gap: 1.25rem; align-items: start; padding: 1.4rem; border: 1.5px solid var(--ink); border-radius: 14px; background: var(--paper); box-shadow: 5px 5px 0 rgba(23,37,31,.11); }
.course-step:nth-child(3n+1) { border-left: 8px solid var(--blue); }
.course-step:nth-child(3n+2) { border-left: 8px solid var(--green); }
.course-step:nth-child(3n) { border-left: 8px solid var(--coral); }
.course-number { display: grid; width: 58px; height: 58px; place-items: center; border: 1.5px solid var(--ink); border-radius: 50%; color: var(--ink); background: var(--yellow); font-weight: 900; }
.course-step small { color: var(--blue-dark); font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.course-step h2 { margin: .2rem 0 .4rem; font-size: clamp(1.35rem, 3vw, 1.8rem); }
.course-step p { margin: 0 0 .7rem; }
.course-step a { font-weight: 900; }

.journey-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.journey-card { display: flex; min-height: 430px; flex-direction: column; padding: 1.4rem; border: 2px solid var(--ink); border-radius: 15px; background: var(--paper); box-shadow: 6px 6px 0 var(--ink); }
.journey-card h3 { margin: 1rem 0 .55rem; font-size: clamp(1.55rem, 3vw, 2.05rem); }
.journey-card p { margin: 0; color: var(--muted); }
.journey-card ul { margin: 1.2rem 0 1.5rem; padding-left: 1.2rem; }
.journey-card .button { width: 100%; margin-top: auto; }
.journey-top { display: flex; align-items: center; justify-content: space-between; gap: .8rem; color: var(--muted); font-size: .85rem; font-weight: 800; }
.journey-icon { display: grid; width: 46px; height: 46px; place-items: center; border: 1.5px solid var(--ink); border-radius: 50%; color: var(--ink); background: var(--yellow); font-weight: 900; }
.journey-study { box-shadow: 6px 6px 0 var(--green); }
.journey-study .journey-icon { background: var(--green-soft); }
.journey-work { box-shadow: 6px 6px 0 var(--coral); }
.journey-work .journey-icon { background: var(--red-soft); }
.journey-switch { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.journey-switch a { display: flex; min-height: 120px; flex-direction: column; justify-content: center; padding: 1.25rem; border: 1.5px solid var(--ink); border-radius: 12px; background: var(--paper); box-shadow: 4px 4px 0 var(--yellow); text-decoration: none; }
.journey-switch a:hover { transform: translate(-1px,-1px); box-shadow: 6px 6px 0 var(--ink); }
.journey-switch strong { font-size: 1.2rem; }
.journey-switch span { margin-top: .35rem; color: var(--blue-dark); }
.journey-hero-study { background-color: var(--green-soft); }
.journey-hero-work { background-color: var(--red-soft); }

@media (max-width: 700px) {
  body::before { height: 4px; }
  .site-header { top: 4px; }
  .nav { border: 2px solid var(--ink); background: var(--paper); box-shadow: 6px 6px 0 var(--ink); }
  .hero-panel, .path-card { transform: none; }
  .brand-highlight { white-space: normal; }
  .course-step { grid-template-columns: 1fr; }
  .course-number { width: 48px; height: 48px; }
  .journey-grid, .journey-switch { grid-template-columns: 1fr; }
  .journey-card { min-height: auto; }
}

@media (max-width: 380px) {
  .brand { gap: .65rem; }
  .brand-mark { width: 39px; height: 39px; }
  .brand-wordmark strong { font-size: 1rem; }
  .brand-wordmark small { display: none; }
}

@media (prefers-reduced-motion: no-preference) {
  .brand-mark { animation: brand-arrive .55s cubic-bezier(.2,.8,.2,1) both; }
  @keyframes brand-arrive { from { transform: rotate(-10deg) scale(.8); opacity: 0; } to { transform: rotate(-3deg) scale(1); opacity: 1; } }
}
