:root {
  color-scheme: light;
  --guide-font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --guide-font-display: "Inter", system-ui, sans-serif;
  --guide-ink: #101728;
  --guide-ink-soft: #3a4763;
  --guide-muted: #697489;
  --guide-line: rgba(16, 23, 40, 0.10);
  --guide-surface: #ffffff;
  --guide-accent: #1f5eff;
  --guide-accent-deep: #1a44b8;
  --guide-accent-2: #11a37f;
  --guide-accent-soft: rgba(31, 94, 255, 0.10);
  --guide-radius-lg: 22px;
  --guide-radius-md: 14px;
  --guide-radius-sm: 10px;
  --guide-shadow-sm: 0 10px 30px rgba(16, 23, 40, 0.07);
  --guide-shadow: 0 24px 60px rgba(16, 23, 40, 0.10);
  font-family: var(--guide-font-body);
}

* { box-sizing: border-box; }

body.guides-shell {
  margin: 0;
  color: var(--guide-ink);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  background:
    radial-gradient(820px 480px at 88% -6%, rgba(31, 94, 255, 0.10), transparent 60%),
    radial-gradient(680px 420px at 4% 2%, rgba(17, 163, 127, 0.09), transparent 58%),
    linear-gradient(180deg, #ffffff 0%, #f5f7fb 360px);
}

.guides-container {
  width: min(1120px, 100% - 40px);
  margin: 0 auto;
}

/* ---------- header ---------- */
.guides-header {
  position: relative;
  z-index: 20;
}
.guides-header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  position: relative;
  z-index: 3000;
}
.guides-header__bar::before {
  content: "";
  position: absolute;
  inset: 0 calc(50% - 50vw);
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--guide-line);
  z-index: -1;
}

.guides-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: var(--guide-ink);
  text-decoration: none;
  font-family: var(--guide-font-display);
}
.guides-brand img {
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.guides-nav {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
}
.guides-nav a {
  color: var(--guide-ink-soft);
  text-decoration: none;
  font-weight: 600;
  padding: 9px 13px;
  border-radius: 10px;
  transition: background .15s ease, color .15s ease;
}
.guides-nav a:hover { background: rgba(16, 23, 40, 0.05); color: var(--guide-ink); }

.guides-btn {
  color: #fff !important;
  background: linear-gradient(135deg, var(--guide-accent), var(--guide-accent-deep));
  border-radius: 12px !important;
  font-weight: 700;
  box-shadow: 0 14px 28px rgba(31, 94, 255, 0.26);
}
.guides-btn:hover { background: linear-gradient(135deg, var(--guide-accent), var(--guide-accent-deep)) !important; transform: translateY(-1px); }

.guides-nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 11px;
  border: 1px solid var(--guide-line);
  background: #fff;
  font-size: 18px;
  cursor: pointer;
}

/* ---------- hero ---------- */
.guides-hero {
  padding: clamp(40px, 6vw, 76px) 0 clamp(26px, 4vw, 44px);
  position: relative;
  z-index: 1;
}
.guides-hero__eyebrow {
  margin: 0 0 14px;
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .16em;
  color: var(--guide-accent);
}
.guides-hero__title {
  margin: 0 0 14px;
  font-size: clamp(32px, 4.4vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.035em;
  font-weight: 800;
  font-family: var(--guide-font-display);
  color: var(--guide-ink);
}
.guides-hero__lead {
  margin: 0;
  max-width: 720px;
  font-size: clamp(15px, 1.7vw, 18px);
  line-height: 1.6;
  color: var(--guide-muted);
}

/* ---------- main + index grid ---------- */
.guides-main {
  padding: clamp(28px, 4vw, 44px) 0 clamp(56px, 8vw, 88px);
}

.guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.guide-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--guide-surface);
  border-radius: var(--guide-radius-lg);
  border: 1px solid var(--guide-line);
  padding: 28px 26px;
  box-shadow: var(--guide-shadow-sm);
  overflow: hidden;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.guide-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, var(--guide-accent), var(--guide-accent-2));
  opacity: 0;
  transition: opacity .18s ease;
}
.guide-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--guide-shadow);
  border-color: rgba(31, 94, 255, 0.28);
}
.guide-card:hover::before { opacity: 1; }

.guide-card__icon {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  margin-bottom: 4px;
  color: var(--guide-accent);
  background: var(--guide-accent-soft);
}
.guide-card__icon svg { width: 19px; height: 19px; }

.guide-card__eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--guide-muted);
}
.guide-card__title {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  font-family: var(--guide-font-display);
  color: var(--guide-ink);
}
.guide-card__summary {
  margin: 0;
  color: var(--guide-muted);
  font-size: 14.5px;
}
.guide-card__link {
  margin-top: auto;
  padding-top: 6px;
  font-weight: 700;
  font-size: 14.5px;
  text-decoration: none;
  color: var(--guide-accent);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  transition: gap .15s ease;
}
.guide-card:hover .guide-card__link { gap: 11px; }
.guide-card__link svg { width: 16px; height: 16px; }

/* ---------- article (detail guide pages) ---------- */
.guide-article {
  background: var(--guide-surface);
  border: 1px solid var(--guide-line);
  border-radius: var(--guide-radius-lg);
  box-shadow: var(--guide-shadow-sm);
  padding: clamp(26px, 4vw, 46px);
  max-width: 820px;
  margin-inline: auto;
}
.guide-article header { margin-bottom: 26px; padding-bottom: 22px; border-bottom: 1px solid var(--guide-line); }
.guide-article h1 {
  margin: 0 0 14px;
  font-size: clamp(28px, 3.6vw, 40px);
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-weight: 800;
  font-family: var(--guide-font-display);
}
.guide-meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13px; color: var(--guide-muted); }
.guide-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(16, 23, 40, 0.04);
  border: 1px solid var(--guide-line);
  font-weight: 600;
}

.guide-article section { margin-bottom: 30px; }
.guide-article section:last-of-type { margin-bottom: 0; }
.guide-article h2 {
  margin: 0 0 12px;
  font-size: 23px;
  font-weight: 700;
  letter-spacing: -0.02em;
  font-family: var(--guide-font-display);
}
.guide-article h3 { margin: 22px 0 8px; font-size: 18px; font-weight: 700; }
.guide-article p { margin: 0 0 14px; color: var(--guide-ink-soft); }
.guide-article ul,
.guide-article ol { margin: 0 0 16px; padding-left: 22px; color: var(--guide-ink-soft); }
.guide-article ul li,
.guide-article ol li { margin-bottom: 8px; }
.guide-article ul li::marker { color: var(--guide-accent); }

.guide-chip-list { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0 0 16px; list-style: none; }
.guide-chip {
  padding: 7px 13px;
  border-radius: 999px;
  background: var(--guide-accent-soft);
  border: 1px solid rgba(31, 94, 255, 0.18);
  color: var(--guide-accent);
  font-weight: 700;
  font-size: 12.5px;
}

.guide-callout {
  border-radius: var(--guide-radius-md);
  border: 1px solid rgba(17, 163, 127, 0.24);
  background: rgba(17, 163, 127, 0.07);
  padding: 18px 20px;
  margin: 18px 0;
  color: var(--guide-ink-soft);
}
.guide-callout strong { display: block; margin-bottom: 6px; color: var(--guide-ink); }

/* ---------- footer ---------- */
.guides-footer {
  border-top: 1px solid var(--guide-line);
  padding: 32px 0 44px;
  background: rgba(255, 255, 255, 0.6);
}
.guides-footer__tagline { margin: 0 0 14px; color: var(--guide-muted); max-width: 60ch; }
.guides-footer__links { display: inline-flex; flex-wrap: wrap; gap: 8px 18px; }
.guides-footer__links a { color: var(--guide-ink-soft); text-decoration: none; font-weight: 600; }
.guides-footer__links a:hover { color: var(--guide-accent); }
.guides-footer__copyright { margin: 16px 0 0; color: var(--guide-muted); font-size: 13px; }

/* ---------- responsive ---------- */
@media (max-width: 720px) {
  body.guides-shell { font-size: 15px; }
  .guides-header__bar { padding: 14px 0; }
  .guides-nav-toggle { display: inline-flex; align-items: center; justify-content: center; margin-left: auto; }
  .guides-nav {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    width: min(240px, 80vw);
    background: #fff;
    border: 1px solid var(--guide-line);
    border-radius: 16px;
    padding: 10px;
    box-shadow: var(--guide-shadow);
    z-index: 3200;
  }
  .guides-nav.is-open { display: flex; }
  .guides-nav a { font-size: 14px; }
  .guides-btn { text-align: center; justify-content: center; }
  .guide-grid { grid-template-columns: 1fr; gap: 16px; }
  .guide-card { padding: 22px; }
  .guides-footer__links { justify-content: flex-start; }
}

@media (max-width: 480px) {
  .guides-hero__title { font-size: 30px; }
}
