/* =========================================================
   William Lloyd Jenkins — Teal Cinematic Homepage
   Base styles (Home / Gateway Page)
   ========================================================= */

/* ---------- CSS Variables ---------- */
:root {
  --bg-main: #070b10;
  --bg-panel: rgba(16, 28, 36, 0.85);
  --bg-soft: rgba(255, 255, 255, 0.04);

  --text-main: #e7f6f8;
  --text-muted: #a8c3c9;

  --accent-teal: #46f0ff;
  --accent-teal-soft: rgba(70, 240, 255, 0.25);

  --border-soft: rgba(255, 255, 255, 0.12);
  --shadow-deep: 0 20px 60px rgba(0, 0, 0, 0.55);

  --radius-lg: 22px;
  --radius-md: 14px;

  --max-width: 1120px;
}

body { outline: 10px solid red !important; }

/* ---------- Reset / Base ---------- */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text-main);
  position: relative;
  isolation: isolate;
  background:
    radial-gradient(900px 500px at 15% 10%, rgba(70,240,255,0.12), transparent 60%),
    radial-gradient(800px 500px at 80% 30%, rgba(0,140,160,0.12), transparent 60%),
    linear-gradient(180deg, #05080c, #0a1118);
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: min(var(--max-width), calc(100% - 40px));
  margin: 0 auto;
}

/* Accessibility */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: #fff;
  color: #000;
  padding: 10px 14px;
  border-radius: 10px;
  z-index: 999;
}
.skip-link:focus {
  left: 12px;
  top: 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
}

/* ---------- Top Bar ---------- */
.topbar {
  background: rgba(6, 12, 18, 0.75);
  border-bottom: 1px solid var(--border-soft);
  backdrop-filter: blur(10px);
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
}

.topbar__text {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ---------- Header / Nav ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(7, 11, 16, 0.65);
  border-bottom: 1px solid var(--border-soft);
  backdrop-filter: blur(14px);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand__mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(
    135deg,
    rgba(70,240,255,0.35),
    rgba(0,120,140,0.35)
  );
  border: 1px solid var(--border-soft);
  font-weight: 800;
  letter-spacing: 0.08em;
}

.brand__text {
  font-weight: 600;
  letter-spacing: 0.02em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

.nav__link {
  padding: 10px 12px;
  color: var(--text-muted);
  border-radius: 10px;
}
.nav__link:hover {
  color: var(--text-main);
  background: var(--bg-soft);
}

/* Mobile toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle__bar {
  width: 26px;
  height: 2px;
  background: var(--text-main);
  margin: 6px 0;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: linear-gradient(
    135deg,
    rgba(70,240,255,0.35),
    rgba(0,140,160,0.25)
  );
  box-shadow: var(--shadow-deep);
  font-weight: 600;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--ghost {
  background: rgba(255,255,255,0.06);
  box-shadow: none;
}

.btn--sm {
  padding: 9px 14px;
  font-size: 0.9rem;
}

/* ---------- Sections ---------- */
.section {
  padding: 80px 0;
}

.section__head {
  max-width: 720px;
  margin-bottom: 26px;
}

.section__head p {
  color: var(--text-muted);
}

/* ---------- Hero ---------- */
.hero {
  padding: 90px 0 50px;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 36px;
  align-items: center;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.hero h1 {
  font-size: clamp(2.3rem, 3vw, 3.4rem);
  line-height: 1.08;
  margin: 12px 0;
}

.lead {
  color: var(--text-muted);
  font-size: 1.1rem;
  line-height: 1.6;
}

.hero__cta {
  display: flex;
  gap: 14px;
  margin: 22px 0;
  flex-wrap: wrap;
}

.hero__stats {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.stat {
  padding: 14px 16px;
  background: rgba(255,255,255,0.05);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
}

.stat__num {
  font-size: 1.4rem;
  font-weight: 800;
}

.stat__label {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ---------- Hero Visual ---------- */
.hero__visual {
  position: relative;
  min-height: 380px;
  border-radius: 30px;
  background:
    radial-gradient(600px 300px at 30% 20%, rgba(70,240,255,0.25), transparent 60%),
    radial-gradient(500px 300px at 70% 70%, rgba(0,120,140,0.25), transparent 60%),
    rgba(255,255,255,0.04);
  border: 1px solid var(--border-soft);
  overflow: hidden;
}

.orb {
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  opacity: 0.5;
}
.orb--one {
  background: rgba(70,240,255,0.25);
  top: -80px;
  left: -60px;
}
.orb--two {
  background: rgba(0,120,140,0.3);
  bottom: -90px;
  right: -70px;
}

.panel {
  position: absolute;
  bottom: 18px;
  left: 18px;
  right: 18px;
  background: var(--bg-panel);
  border-radius: var(--radius-lg);
  padding: 18px;
  border: 1px solid var(--border-soft);
}

.panel__label {
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.panel__title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-top: 6px;
}

.panel__desc {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-top: 6px;
}

/* ---------- Tabs ---------- */
.tabs {
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
}

.tabs__list {
  display: flex;
  gap: 10px;
  padding: 12px;
  border-bottom: 1px solid var(--border-soft);
}

.tabs__tab {
  flex: 1;
  padding: 12px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.06);
  border: 1px solid transparent;
  color: var(--text-muted);
  font-weight: 600;
  cursor: pointer;
}

.tabs__tab.is-active {
  color: var(--text-main);
  background: linear-gradient(
    135deg,
    rgba(70,240,255,0.35),
    rgba(0,140,160,0.25)
  );
  border-color: var(--border-soft);
}

.tabs__panels {
  padding: 20px;
}

.tabs__panel {
  display: none;
}
.tabs__panel.is-active {
  display: block;
}

/* ---------- Cards ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.card {
  padding: 18px;
  background: rgba(255,255,255,0.05);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-soft);
  transition: transform 0.2s ease, background 0.2s ease;
}

.card:hover {
  transform: translateY(-3px);
  background: rgba(255,255,255,0.07);
}

.card p {
  color: var(--text-muted);
  line-height: 1.6;
}

.card__actions {
  margin-top: 14px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ---------- Image Cards + Site Background ---------- */

/* Page background image */
body.has-site-bg::before{
  content:"";
  position: fixed;
  inset: 0;
  z-index: -2;
  background-image: url("../img/site-background.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

body.has-site-bg::after{
  content:"";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(900px 520px at 25% 18%, rgba(70,240,255,0.10), transparent 60%),
    linear-gradient(180deg, rgba(7,11,16,0.78), rgba(7,11,16,0.92));
}

/* Turn certain cards into background-image cards */
.card--image{
  padding: 0;                 /* overlay handles spacing */
  min-height: 260px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
  overflow: hidden;

  /* Optional polish */
  transition: transform 0.22s ease, filter 0.22s ease;
}

.card--image:hover{
  transform: translateY(-3px) scale(1.01);
  filter: brightness(1.05);
}

/* Assign your images */
.card--what-it-feels-like{
  background-image: url("../img/what-it-feels-like.png");
}

.card--start-here{
  background-image: url("../img/start-here.jpeg");
}

.card--epic-fantasy{
  background-image: url("../img/epic-fantasy-card-background.png");
}

/* Readability overlay for text on image cards */
.card__overlay{
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
  padding: 18px;

  background: linear-gradient(
    180deg,
    rgba(0,0,0,0) 0%,
    rgba(0,0,0,0.28) 40%,
    rgba(0,0,0,0.72) 100%
  );
}

/* Optional: tighten text spacing in overlay cards */
.card__overlay p{
  margin: 0;
}

.card__overlay h3{
  margin: 0;
}

/* ---------- Scroll Reveal ---------- */
[data-reveal]{
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .55s ease, transform .55s ease;
}

[data-reveal].is-revealed{
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Series Glow Skins ---------- */
.tabs__panel.skin--relicrunners .card--image:hover{
  box-shadow: 0 0 0 1px rgba(70,240,255,.25), 0 22px 70px rgba(70,240,255,.18);
}

.tabs__panel.skin--balam .card--image:hover{
  box-shadow: 0 0 0 1px rgba(179,92,255,.22), 0 22px 70px rgba(179,92,255,.16);
}


/* ---------- Responsive ---------- */
@media (max-width: 920px) {
  .hero__grid {
    grid-template-columns: 1fr;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .nav {
    position: absolute;
    top: 68px;
    right: 20px;
    background: rgba(8, 14, 20, 0.95);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-soft);
    flex-direction: column;
    padding: 14px;
    display: none;
  }

  .nav.is-open {
    display: flex;
  }

  .nav-toggle {
    display: block;
  }
}
