/* =========================================================
   Guard PC Info – Home
   ========================================================= */
:root,
[data-theme="dark"] {
  --bg: #0a0f1d;
  --bg-header: #0b1120;
  --bg-hero: #0c1323;
  --surface: #111a2e;
  --surface-2: #131d33;
  --border: #1e2940;
  --border-strong: #2a3854;
  --heading: #f1f5f9;
  --text: #cbd5e1;
  --muted: #94a3b8;
  --accent: #38bdf8;
  --accent-2: #818cf8;
  --accent-soft: rgba(56, 189, 248, 0.12);
  --accent-line: rgba(56, 189, 248, 0.45);
  --glow-1: rgba(56, 132, 220, 0.22);
  --glow-2: rgba(99, 102, 241, 0.16);
  --art-1: #1d4566;
  --art-2: #303763;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  color-scheme: dark;
}
[data-theme="light"] {
  --bg: #f5f7fb;
  --bg-header: #ffffff;
  --bg-hero: #eef3fa;
  --surface: #ffffff;
  --surface-2: #f1f5fb;
  --border: #dde4ef;
  --border-strong: #c9d3e3;
  --heading: #0f172a;
  --text: #334155;
  --muted: #5b6577;
  --accent: #0369a1;
  --accent-2: #4f46e5;
  --accent-soft: rgba(3, 105, 161, 0.09);
  --accent-line: rgba(3, 105, 161, 0.35);
  --glow-1: rgba(56, 189, 248, 0.25);
  --glow-2: rgba(129, 140, 248, 0.22);
  --art-1: #cfe6f7;
  --art-2: #d9dcf7;
  --shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  transition: background-color .25s, color .25s;
}
h1, h2, h3, p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
svg { flex-shrink: 0; }

.wrap { width: 100%; max-width: 990px; margin: 0 auto; padding: 0 24px; }

.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  padding: 8px 14px;
  border-radius: 8px;
  background: var(--accent);
  color: #04121f;
  font-weight: 700;
  text-decoration: none;
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* ---------------- Header ---------------- */
.header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--bg-header);
  border-bottom: 1px solid var(--border);
}
.header__inner { display: flex; align-items: center; justify-content: space-between; height: 50px; }

.brand { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; }
.brand__icon {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 7px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
}
[data-theme="dark"] .brand__icon { background: linear-gradient(135deg, #38bdf8, #818cf8); }
.brand__icon svg { width: 14px; height: 14px; }
.brand__name { font-size: 18.5px; font-weight: 700; color: var(--heading); letter-spacing: -0.2px; word-spacing: 3px; }
.brand__pc { color: var(--accent); }

.nav { display: flex; align-items: center; gap: 18px; }
.nav__list { display: flex; align-items: center; gap: 18px; }
.nav__list a {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  transition: color .2s;
}
.nav__list a:hover { color: var(--heading); }

.theme-btn {
  height: 27px;
  padding: 0 9px;
  border: 1px solid var(--border-strong);
  border-radius: 7px;
  background: var(--surface);
  color: var(--heading);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  transition: border-color .2s, background .2s;
}
.theme-btn:hover { border-color: var(--accent); }

.menu-btn {
  display: none;
  position: relative;
  width: 34px;
  height: 30px;
  padding: 0;
  border: 1px solid var(--border-strong);
  border-radius: 7px;
  background: var(--surface);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.menu-btn span { display: block; width: 16px; height: 2px; border-radius: 2px; background: var(--heading); transition: transform .25s, opacity .2s; }
.header.menu-open .menu-btn span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.header.menu-open .menu-btn span:nth-child(2) { opacity: 0; }
.header.menu-open .menu-btn span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------------- Hero ---------------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse 260px 220px at 0% 0%, var(--glow-1), transparent 70%),
    radial-gradient(ellipse 240px 220px at 100% 0%, var(--glow-2), transparent 70%),
    var(--bg-hero);
  border-bottom: 1px solid var(--border);
}
.hero__inner { display: flex; flex-direction: column; align-items: center; padding-top: 56px; padding-bottom: 48px; text-align: center; }

.pill {
  display: inline-block;
  padding: 3px 11px;
  border: 1px solid var(--accent-line);
  border-radius: 999px;
  color: var(--accent);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 1.3px;
  text-transform: uppercase;
}
.hero__title {
  margin-top: 14px;
  font-size: 45px;
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -1.3px;
  color: var(--heading);
}
.grad-text {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
[data-theme="dark"] .grad-text { background-image: linear-gradient(90deg, #38bdf8 10%, #818cf8 100%); }
.hero__text { max-width: 540px; margin-top: 10px; font-size: 15px; line-height: 1.62; color: var(--muted); }

.hero__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 24px; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 43px;
  padding: 0 21px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  transition: transform .2s, box-shadow .2s, border-color .2s, background .2s, filter .2s;
}
.btn--primary { background: linear-gradient(90deg, #38bdf8, #818cf8); color: #fff; }
.btn--primary:hover { filter: brightness(1.08); box-shadow: 0 8px 22px rgba(56, 189, 248, .28); transform: translateY(-1px); }
.btn--ghost { background: var(--bg-header); border-color: var(--border-strong); color: var(--heading); }
.btn--ghost:hover { border-color: var(--accent); }
.btn--sm { height: 33px; padding: 0 15px; font-size: 13px; border-radius: 7px; }

/* ---------------- Sections ---------------- */
.section--featured { padding-top: 44px; }
.section--guides { padding: 37px 0 66px; }
.section__title { font-size: 20px; line-height: 1.3; font-weight: 700; color: var(--heading); letter-spacing: -0.3px; }
.section__title--guides { margin-top: 26px; }
.count { font-size: 15px; font-weight: 500; color: var(--muted); }

/* Featured card */
.featured {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  margin-top: 22px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  transition: border-color .2s, transform .25s, box-shadow .25s;
}
.featured:hover { border-color: var(--accent-line); box-shadow: var(--shadow); transform: translateY(-2px); }
.featured__body { padding: 36px 29px 34px; }
.featured__kicker {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--accent);
  text-decoration: underline;
}
.featured__title {
  margin-top: 9px;
  font-size: 16.8px;
  line-height: 1.35;
  font-weight: 700;
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.featured__text { margin-top: 8px; font-size: 13px; line-height: 1.6; color: var(--muted); text-decoration: underline; text-decoration-color: var(--border-strong); }
.featured__meta { display: flex; flex-wrap: wrap; gap: 4px 11px; margin-top: 8px; font-size: 11.5px; text-decoration: underline; }
.featured__meta strong { color: var(--heading); font-weight: 600; }
.featured__meta span { color: var(--muted); }
.featured__art {
  display: grid;
  place-items: center;
  min-height: 160px;
  background: linear-gradient(135deg, var(--art-1), var(--art-2));
}
.lock { width: 80px; height: 80px; filter: drop-shadow(0 6px 12px rgba(0,0,0,.25)); transition: transform .3s; }
.featured:hover .lock { transform: scale(1.06) rotate(-3deg); }

/* Filter chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  height: 27px;
  padding: 0 12px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text);
  font-size: 12px;
  font-weight: 500;
  transition: border-color .2s, background .2s, color .2s;
}
.chip:hover { border-color: var(--accent); color: var(--heading); }
.chip.is-active { border-color: transparent; background: linear-gradient(90deg, #38bdf8, #818cf8); color: #fff; font-weight: 600; }

/* Guide grid */
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 18px; }
.card {
  display: flex;
  flex-direction: column;
  padding: 21px 21px 22px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  text-decoration: none;
  transition: border-color .2s, transform .25s, box-shadow .25s;
}
.card:hover { border-color: var(--accent-line); box-shadow: var(--shadow); transform: translateY(-3px); }
.card[hidden] { display: none; }
.card__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tag {
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 1.1px;
  text-transform: uppercase;
}
.card__time { font-size: 11px; color: var(--muted); }
.card__title { margin-top: 10px; font-size: 17px; line-height: 1.33; font-weight: 700; color: var(--accent); letter-spacing: -0.1px; }
.card:hover .card__title { text-decoration: underline; text-underline-offset: 3px; }
.card__text { margin-top: 7px; font-size: 12.7px; line-height: 1.6; color: var(--muted); }
.card__meta { display: flex; flex-wrap: wrap; gap: 2px 11px; margin-top: 8px; font-size: 11.5px; }
.card__meta strong { color: var(--heading); font-weight: 600; }
.card__meta span { color: var(--muted); }

.empty { margin-top: 18px; color: var(--muted); }

/* ---------------- Footer ---------------- */
.footer { border-top: 1px solid var(--border); background: var(--bg-header); }
.footer__inner { display: flex; justify-content: space-between; gap: 32px; padding-top: 32px; padding-bottom: 24px; }
.footer__about { max-width: 420px; scroll-margin-top: 70px; }
.footer__about p { margin-top: 10px; font-size: 13px; line-height: 1.65; color: var(--muted); }
.footer__links { display: flex; flex-wrap: wrap; align-content: flex-start; gap: 10px 22px; }
.footer__links a,
.link-btn {
  padding: 0;
  border: 0;
  background: none;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  transition: color .2s;
}
.footer__links a:hover,
.link-btn:hover { color: var(--heading); }
.footer__bottom { padding-top: 16px; padding-bottom: 90px; border-top: 1px solid var(--border); font-size: 12px; color: var(--muted); }
body.cookie-done .footer__bottom { padding-bottom: 20px; }

/* ---------------- Cookie banner ---------------- */
.cookie {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  border-top: 1px solid var(--border);
  background: var(--bg-header);
  background: color-mix(in srgb, var(--bg-header) 94%, transparent);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transform: translateY(0);
  transition: transform .3s ease;
}
.cookie[hidden] { display: none; }
.cookie.is-leaving { transform: translateY(110%); }
.cookie__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 12px 24px;
}
.cookie p { font-size: 12.5px; line-height: 1.5; color: var(--muted); }
.cookie p a { color: var(--accent); }
.cookie__actions { display: flex; gap: 14px; flex-shrink: 0; }

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero__title { font-size: 40px; }
  .cookie__inner { flex-direction: column; align-items: stretch; gap: 10px; text-align: center; }
  .cookie__actions { justify-content: center; }
  .footer__bottom { padding-bottom: 125px; }
}

@media (max-width: 700px) {
  /* nav collapses into a menu */
  .menu-btn { display: inline-flex; }
  .nav { gap: 8px; }
  .nav__list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 6px 20px 12px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-header);
    box-shadow: 0 16px 30px rgba(0, 0, 0, .25);
  }
  .header.menu-open .nav__list { display: flex; }
  .nav__list li + li { border-top: 1px solid var(--border); }
  .nav__list a { display: block; padding: 12px 0; font-size: 15px; }

  .featured { grid-template-columns: 1fr; }
  .featured__art { order: -1; min-height: 130px; }
  .featured__body { padding: 22px 20px 24px; }

  .footer__inner { flex-direction: column; gap: 20px; }
}

@media (max-width: 600px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  .header__inner { height: 54px; }

  .hero__inner { padding-top: 36px; padding-bottom: 34px; }
  .hero__title { font-size: clamp(27px, 8.4vw, 36px); letter-spacing: -0.9px; }
  .hero__text { font-size: 14.5px; }
  .hero__text br { display: none; }
  .hero__actions { flex-direction: column; align-self: stretch; gap: 10px; }
  .hero__actions .btn { width: 100%; }

  .section--featured { padding-top: 30px; }
  .section--guides { padding: 28px 0 48px; }
  .section__title { font-size: 19px; }

  /* chips scroll sideways instead of wrapping into many rows */
  .chips {
    flex-wrap: nowrap;
    overflow-x: auto;
    margin: 0 -16px;
    padding: 2px 16px 6px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .chips::-webkit-scrollbar { display: none; }
  .chip { flex-shrink: 0; height: 32px; padding: 0 15px; font-size: 13px; }

  .grid { grid-template-columns: 1fr; gap: 12px; }
  .card { padding: 18px 18px 20px; }
  .card:hover { transform: none; }
  .card__title { font-size: 16px; }

  .cookie__inner { padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); }
  .cookie__actions { gap: 10px; }
  .cookie__actions .btn { flex: 1; }
  .footer__bottom { padding-bottom: 150px; }
}

@media (max-width: 360px) {
  .brand__name { font-size: 15.5px; }
  .theme-btn { padding: 0 7px; font-size: 11px; }
  .featured__body { padding: 18px 16px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
