/* ============================================================
   Gravity Ledge — root portal styles (shared by hub + legal pages)
   ============================================================ */

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

html, body {
  min-height: 100%;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: radial-gradient(ellipse at top, #16213e 0%, #0b1220 48%, #050810 100%);
  background-attachment: fixed;
  color: #e2e8f0;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: #7dd3fc; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ----- Header ----- */
.site-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px; background: rgba(5,8,16,0.7); backdrop-filter: blur(10px);
  border-bottom: 1px solid #1e293b; position: sticky; top: 0; z-index: 100;
}
.brand { display: flex; align-items: center; gap: 11px; }
.brand .logo {
  width: 30px; height: 30px; display: block; border-radius: 8px;
}
.brand h1 {
  font-size: 21px; font-weight: 800; letter-spacing: -0.5px;
  background: linear-gradient(135deg, #f59e0b, #a78bfa 45%, #22d3ee 80%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.site-header nav { display: flex; gap: 18px; font-size: 14px; }
.site-header nav a { color: #cbd5e1; }

/* ----- Layout container ----- */
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }

/* ----- Hero ----- */
.hero { text-align: center; padding: 48px 16px 24px; }
.hero h2 {
  font-size: clamp(28px, 6vw, 46px); font-weight: 900; letter-spacing: -1px;
  line-height: 1.1; margin-bottom: 14px;
}
.hero h2 .accent {
  background: linear-gradient(135deg, #f59e0b, #a78bfa 50%, #22d3ee);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p { color: #94a3b8; font-size: clamp(15px, 2.4vw, 18px); max-width: 620px; margin: 0 auto; }

/* ----- Game grid ----- */
.section-title { font-size: 14px; text-transform: uppercase; letter-spacing: 1.5px; color: #64748b; margin: 32px 0 14px; }

.game-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 16px;
}
.game-card {
  --accent: #38bdf8;
  position: relative; display: flex; flex-direction: column;
  background: linear-gradient(160deg, rgba(30,41,59,0.55), rgba(15,23,42,0.55));
  border: 1px solid #1e293b; border-radius: 16px; padding: 18px;
  color: inherit; text-decoration: none; overflow: hidden;
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.game-card::before {
  content: ""; position: absolute; inset: 0; border-radius: 16px;
  background: radial-gradient(120% 80% at 50% -10%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 60%);
  pointer-events: none;
}
.game-card:hover {
  transform: translateY(-4px); text-decoration: none;
  border-color: color-mix(in srgb, var(--accent) 55%, #1e293b);
  box-shadow: 0 12px 30px -12px color-mix(in srgb, var(--accent) 50%, transparent);
}
.game-card .thumb {
  width: 84px; height: 84px; border-radius: 18px; overflow: hidden;
  background: #0b1220; display: grid; place-items: center;
  border: 1px solid color-mix(in srgb, var(--accent) 40%, #1e293b); margin-bottom: 14px;
}
.game-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.game-card h3 { font-size: 19px; font-weight: 800; margin-bottom: 6px; }
.game-card p { color: #94a3b8; font-size: 14px; flex: 1; }
.game-card .tag {
  display: inline-block; margin-top: 12px; font-size: 11px; letter-spacing: .5px;
  text-transform: uppercase; color: var(--accent);
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 999px; padding: 3px 10px; align-self: flex-start;
}
.game-card .play-btn {
  margin-top: 14px; font-weight: 700; font-size: 14px; color: var(--accent);
}

/* ----- Content sections (about + legal pages) ----- */
.content-section {
  max-width: 760px; margin: 28px auto; padding: 26px 22px;
  background: rgba(15,23,42,0.45); border: 1px solid #1e293b; border-radius: 14px;
}
.content-section h2 { font-size: 26px; font-weight: 800; margin-bottom: 14px; letter-spacing: -0.5px; }
.content-section h3 { font-size: 18px; font-weight: 700; margin: 22px 0 8px; color: #f1f5f9; }
.content-section p, .content-section li { color: #cbd5e1; margin-bottom: 10px; }
.content-section ul { padding-left: 22px; }

/* ----- Ad slots (match per-game styling so AdSense units fit) ----- */
.ad-slot {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  margin: 20px auto; min-height: 90px;
  background: rgba(15,23,42,0.4); border: 1px dashed #334155; border-radius: 10px;
  position: relative; max-width: 970px; width: 100%;
}
.ad-slot .ad-label {
  position: absolute; top: 3px; right: 9px; font-size: 9px; color: #475569;
  text-transform: uppercase; letter-spacing: .5px;
}

/* ----- Footer ----- */
.site-footer {
  margin-top: 48px; padding: 28px 16px 40px; border-top: 1px solid #1e293b;
  text-align: center; color: #64748b; font-size: 13px;
}
.site-footer nav { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 10px; }
.site-footer nav a { color: #94a3b8; }

/* ----- Cookie banner (Consent Mode v2 control) ----- */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0;
  background: rgba(2,6,23,0.95); backdrop-filter: blur(10px);
  padding: 14px calc(20px + env(safe-area-inset-right))
           calc(14px + env(safe-area-inset-bottom)) calc(20px + env(safe-area-inset-left));
  border-top: 1px solid #1e293b;
  display: flex; align-items: center; justify-content: center; gap: 16px;
  z-index: 200; flex-wrap: wrap; font-size: 13px;
}
.cookie-banner[hidden] { display: none !important; }
.cookie-banner button {
  padding: 8px 18px; border-radius: 6px; border: none;
  background: linear-gradient(135deg, #6366f1, #4f46e5); color: white;
  font-weight: 700; cursor: pointer; white-space: nowrap;
}
.cookie-actions { display: flex; gap: 8px; flex-shrink: 0; }
.cookie-btn.cookie-ghost { background: transparent; border: 1px solid #334155; color: #cbd5e1; }
.cookie-btn.cookie-ghost:hover { background: rgba(51,65,85,0.5); }

@media (max-width: 520px) {
  .game-grid { grid-template-columns: 1fr; }
  .hero { padding: 32px 12px 18px; }
}
