:root {
  --bg: #0b0b0c;
  --text: #f5f7fa;
  --muted: #9aa3ad;
  --accent: #9cd1ff;
  --card: rgba(255,255,255,0.06);
  --card-stroke: rgba(255,255,255,0.14);
  --card-hover: rgba(255,255,255,0.1);
  --shadow: 0 10px 30px rgba(0,0,0,0.35);
  --radius: 18px;
  --radius-lg: 22px;
  --container: 1120px;
  --header-h: 64px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, Arial, sans-serif;
  background: radial-gradient(1200px 800px at 80% -10%, #1a2846 0%, transparent 60%),
              radial-gradient(800px 600px at -20% 20%, #2a1a3a 0%, transparent 55%),
              var(--bg);
  color: var(--text);
  background: var(--bg);
  position: relative;
  display: flex;
  flex-direction: column;
  padding-top: var(--header-h);
}

main {
  flex: 1;
}

body::before {
  content: "";
  position: fixed;        /* stays put while scrolling */
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(1200px 800px at 80% -10%, #1a2846 0%, rgba(26,40,70,0) 60%),
    radial-gradient(900px 700px at -20% 20%, #2a1a3a 0%, rgba(42,26,58,0) 55%);
  background-repeat: no-repeat;
  will-change: transform; /* helps Safari/WebKit avoid 1px seams */
  transform: translateZ(0); /* forces its own layer */
}

.container {
  max-width: var(--container);
  margin: auto;
  padding-inline: clamp(16px, 4vw, 28px);
}

.section { padding: 80px 0; }
.section-header { display:flex; justify-content:space-between; align-items:center; margin-bottom:24px; }

/* Sticky Header */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;

  backdrop-filter: blur(16px) saturate(180%);
  background: rgba(10,10,12,0.55);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.nav-bar { 
  display:flex; justify-content:space-between; align-items:center;
  height: var(--header-h);
}
.brand { color: var(--text); text-decoration:none; font-weight:600; }
.nav { display:flex; gap:18px; }
.nav-link { color: var(--muted); text-decoration:none; padding:10px 12px; border-radius:10px; }
.nav-link:hover { color: var(--text); background: none; }

/* Hero */
.hero { text-align:center; padding:120px 0 80px; }
.hero-title { font-size:64px; margin:0 0 12px; }
.hero-sub { color: var(--muted); margin:0 0 24px; }
.accent { background: linear-gradient(90deg, #c3e4ff, #a0bfff, #e3d7ff); -webkit-background-clip:text; color:transparent; }

/* Buttons */
.btn { display:inline-flex; align-items:center; justify-content:center; padding:10px 14px; border-radius:999px; text-decoration:none; border:1px solid transparent; font-weight:600; }
.btn-primary { background: rgba(255,255,255,0.08); border-color: var(--card-stroke); }
.btn-ghost { color: var(--text); border-color: rgba(255,255,255,0.12); }
.btn-mini { font-size:12px; padding:8px 10px; }

/* Cards */
.glass.card {
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  border: 1px solid var(--card-stroke);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px) saturate(140%);
  padding: 20px;
  transition: transform .25s ease;
}
.glass.card:hover { transform: translateY(-2px); }

.grid { display:grid; gap:18px; }

.site-footer {
  text-align: center;
  padding: 30px 0 50px;
  color: var(--muted);
  margin-top: 20px;
}

/* Button and link text colors */
.btn,
.btn-mini,
.btn-primary,
.btn-ghost,
a.btn {
  color: #ffffff; /* normal white text */
}

/* On hover — soft blue or grey tint */
.btn:hover,
.btn-mini:hover,
.btn-primary:hover,
.btn-ghost:hover,
a.btn:hover {
  color: #9cd1ff; /* subtle light blue (you can change to #cfd6de for grey) */
}

.link,
.link.subtle,
a {
  color: #ffffff;
  text-decoration: none;
}

.link:hover,
.link.subtle:hover,
a:hover {
  color: #9cd1ff; /* same hover tone */
}

.actions {
  display: flex;
  justify-content: center;
  margin-top: 48px;
  padding-top: 12px;
}

.card-thumb {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius);
  margin-bottom: 14px;
}

.card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, opacity 0.3s ease;
}

.glass.card:hover .card-thumb img {
  transform: scale(1.05);
  opacity: 0.95;
}

.grid.three { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.glass.card:hover .card-thumb img { transform: scale(1.05); opacity: .95; }

section[id] { scroll-margin-top: calc(var(--header-h) + 20px); }


/* ========== responsive ========== */

/* Large tablets / small laptops */
@media (max-width: 1024px) {
  .section { padding: 64px 0; }
  .hero { padding: 96px 0 64px; }
  .hero-title { font-size: 48px; }
  .grid { gap: 16px; }
}

/* Tablets & most phones */
@media (max-width: 720px) {
  :root { --header-h: 56px; }              /* shorter fixed header on phones */
  body { padding-top: var(--header-h); }   /* keep content below header */

  .container { padding-inline: 16px; }
  .section { padding: 56px 0; }
  .section-header { margin-bottom: 18px; }

  /* Nav: keep visible, allow horizontal scroll if crowded */
  .nav { 
    gap: 10px; 
    overflow-x: auto; 
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    white-space: nowrap;
  }
  .nav::-webkit-scrollbar { display: none; }
  .brand { font-size: 18px; }
  .nav-link { padding: 8px 10px; font-size: 14px; }

  /* Hero */
  .hero { padding: 88px 0 56px; }
  .hero-title { font-size: 36px; }
  .hero-sub { font-size: 14px; }

  /* Buttons */
  .btn { padding: 9px 12px; }
  .btn-mini { padding: 7px 9px; font-size: 12px; }

  /* Cards & grid */
  .glass.card { padding: 16px; }
  .card-thumb { margin-bottom: 12px; }
  .actions { margin-top: 32px; }

  /* Footer spacing a bit tighter on phones */
  .site-footer { padding: 24px 0 40px; }
}

/* Small phones */
@media (max-width: 420px) {
  .hero { padding: 80px 0 48px; }
  .hero-title { font-size: 30px; }
  .nav { gap: 8px; }
  .nav-link { padding: 8px 8px; font-size: 13px; }

  .grid { gap: 14px; }
  .grid.three { grid-template-columns: 1fr; } /* single column when very narrow */
}
