/* =========================
   Global Styles — Pocket City Clash
   Fonts are local TTF from Google Fonts (Orbitron, Inter).
   ========================= */

@font-face {
  font-family: "Orbitron";
  src: url("../fonts/Orbitron-Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #0a0b10;
  --bg-soft: #0f1120;
  --ink: #e9f0ff;
  --muted: #a8b0c3;
  --brand: #5ef7ff;     /* cyan glow */
  --brand-2: #ff4df8;   /* magenta glow */
  --accent: #a8ff60;    /* lime accent */
  --line: rgba(255,255,255,.08);
  --shadow: 0 10px 30px rgba(0,0,0,.45);
  --radius: 16px;
  --speed: 260ms;
}

*,
*::before,
*::after { box-sizing: border-box; }

html, body {
  height: 100%;
  background: radial-gradient(1200px 800px at 20% 10%, rgba(94,247,255,0.08), transparent),
              radial-gradient(900px 600px at 80% 0%, rgba(255,77,248,0.08), transparent),
              var(--bg);
  color: var(--ink);
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; width: 100%; height: auto; max-width: 350px; border: 0; }

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

.visually-hidden {
  position: absolute !important; height: 1px; width: 1px;
  overflow: hidden; clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap; border: 0; padding: 0; margin: -1px;
}

/* Layout helpers */
.section-padding { padding: 120px 24px; }

/* Header (fixed) */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  backdrop-filter: blur(8px);
  background: linear-gradient(180deg, rgba(10,11,16,0.95), rgba(10,11,16,0.75));
  border-bottom: 1px solid var(--line);
}
.header-inner {
  max-width: 1240px; margin: 0 auto; padding: 14px 20px;
  display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 16px;
}
.brand {
  font-family: "Orbitron", sans-serif; font-weight: 700; letter-spacing: 0.5px; font-size: 1.1rem;
}
.brand-accent { color: var(--brand-2); text-shadow: 0 0 12px rgba(255,77,248,.5); }

.main-nav ul { display: flex; gap: 20px; list-style: none; margin: 0; padding: 0; }
.main-nav a {
  display: inline-block; padding: 8px 10px; border-radius: 12px;
  transition: transform var(--speed), background var(--speed);
}
.main-nav a:hover { background: rgba(255,255,255,.06); transform: translateY(-1px); }
.main-nav .is-active { color: var(--accent); text-shadow: 0 0 10px rgba(168,255,96,.45); }

/* CTA buttons */
.cta {
  display: inline-block; border: 1px solid var(--line); padding: 10px 14px;
  border-radius: 14px; transition: transform var(--speed), box-shadow var(--speed), background var(--speed);
  will-change: transform;
}
.cta.primary {
  border-color: transparent; background: linear-gradient(90deg, var(--brand), var(--brand-2));
  color: #0a0b10; font-weight: 700; box-shadow: 0 6px 18px rgba(94,247,255,.25), 0 8px 28px rgba(255,77,248,.18);
}
.cta.primary:hover { transform: translateY(-2px) scale(1.01); }
.cta.secondary { color: var(--ink); }
.ghost-glow {
  border-color: rgba(94,247,255,.4); box-shadow: inset 0 0 0 1px rgba(94,247,255,.4);
}
.ghost-glow:hover { box-shadow: 0 0 18px rgba(94,247,255,.4), inset 0 0 0 1px rgba(94,247,255,.6); }

/* Burger + drawer (no external libs) */
.burger { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.burger span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; transition: transform var(--speed), opacity var(--speed); }
.nav-drawer {
  position: fixed; top: 58px; right: 12px; width: 220px; background: var(--bg-soft);
  border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 10px; display: grid; gap: 6px;
}
.drawer-link { padding: 10px 12px; border-radius: 10px; }
.drawer-link:hover { background: rgba(255,255,255,.06); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); background: rgba(10,11,16,.9); }
.footer-inner { max-width: 1240px; margin: 0 auto; padding: 28px 20px; color: var(--muted); }
.foot-note { opacity: .7; }

/* Reveal on scroll base states */
.reveal-on-scroll { opacity: 0; transform: translateY(18px) scale(.98); transition: opacity 600ms ease, transform 600ms ease; }
.reveal-on-scroll.is-visible { opacity: 1; transform: translateY(0) scale(1); }

/* Responsive: start mobile-first and scale up */
@media (max-width: 1024px) {
  .header-inner { grid-template-columns: 1fr auto 40px; }
  .main-nav { display: none; }
  .burger { display: inline-block; }
}
@media (max-width: 720px) {
  .section-padding { padding: 96px 18px; }
}
@media (max-width: 480px) {
  .section-padding { padding: 84px 14px; }
}
/* Важное: скрывать дровер, когда есть атрибут hidden */
.nav-drawer[hidden] { 
  display: none !important;
  opacity: 0;
  transform: translateY(-6px);
}

/* Маленькая анимация появления/скрытия */
.nav-drawer {
  transition: opacity 180ms ease, transform 180ms ease;
}
/* Footer legal links */
.footer-links {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-top: 6px;
  flex-wrap: wrap;
}
.footer-links a {
  color: var(--muted);
  text-decoration: none;
  padding: 4px 6px;
  border-radius: 8px;
  transition: background var(--speed), color var(--speed), transform var(--speed);
}
.footer-links a:hover {
  color: var(--ink);
  background: rgba(255,255,255,.06);
  text-decoration: none;
  transform: translateY(-1px);
}
.footer-links span { color: var(--muted); opacity: .6; }
