/* ============================================================
   Game Dog — PC Gaming Club
   Full-width swiss-grid layout. No centered max-width container.
   Palette: light #f7f7f5 · dark #111214 · accent-1 #5b5bff · accent-2 #c6ff5e
   Type: Space Grotesk (display) · Manrope (UI/body)
   ============================================================ */

:root {
  --bg-light: #f7f7f5;
  --bg-dark: #111214;
  --ink-dark: #111214;   /* text on light */
  --ink-light: #f7f7f5;  /* text on dark  */
  --accent-1: #5b5bff;
  --accent-2: #c6ff5e;
  --line: rgba(128, 128, 131, 0.16);
  --pad: 24px;           /* global edge gutter */
  --nav-h: 72px;
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Manrope", system-ui, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg-light);
  color: var(--ink-dark);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  line-height: 1.55;
}

img { display: block; max-width: 100%; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; margin: 0; line-height: 1.02; }
a { color: inherit; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--accent-2); color: var(--ink-dark);
  padding: 10px 16px; font-weight: 700; text-decoration: none;
}
.skip-link:focus { left: 8px; top: 8px; }

/* ---------- GLOBAL GRID OVERLAY ---------- */
.grid-overlay {
  position: fixed; inset: 0; z-index: 1;
  pointer-events: none;
  padding: 0 var(--pad);
}
.grid-overlay__inner {
  height: 100%;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
}
.grid-overlay__inner span { position: relative; }
.grid-overlay__inner span::before,
.grid-overlay__inner span.edge::after {
  content: ""; position: absolute; top: 0; bottom: 0; width: 1px;
  background: var(--line);
  transform: scaleY(0); transform-origin: top;
}
.grid-overlay__inner span::before { left: 0; }
.grid-overlay__inner span.edge::after { right: 0; }
.grid-overlay.ready span::before,
.grid-overlay.ready span.edge::after {
  transition: transform 800ms cubic-bezier(.22,1,.36,1);
  transition-delay: calc(var(--i) * 60ms);
  transform: scaleY(1);
}

/* ---------- NAV ---------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg-light) 88%, transparent);
  backdrop-filter: blur(8px);
  transition: height .25s ease, background .25s ease, border-color .25s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled { border-bottom-color: var(--line); background: color-mix(in srgb, var(--bg-light) 96%, transparent); }
.nav__row {
  height: var(--nav-h);
  padding: 0 var(--pad);
  display: flex; align-items: center; justify-content: space-between;
  transition: height .25s ease;
}
.nav.scrolled .nav__row { height: 56px; }
.nav__logo {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-weight: 700; font-size: 1.15rem;
  letter-spacing: -.01em; text-decoration: none;
}
.nav__mark {
  display: grid; place-items: center;
  width: 28px; height: 28px; border-radius: 8px;
  background: var(--ink-dark); color: var(--accent-2);
  font-size: .95rem; font-weight: 700;
}
.nav__menu { display: flex; align-items: center; gap: clamp(14px, 2vw, 32px); }
.nav__menu a { text-decoration: none; font-weight: 600; font-size: .95rem; position: relative; }
.nav__menu a:not(.nav__cta)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 2px;
  background: var(--accent-1); transform: scaleX(0); transform-origin: left;
  transition: transform .25s ease;
}
.nav__menu a:not(.nav__cta):hover::after,
.nav__menu a.active::after { transform: scaleX(1); }
.nav__cta {
  background: var(--accent-2); color: var(--ink-dark);
  padding: 10px 18px; border-radius: 20px; font-weight: 700;
  transition: transform .2s ease; transform-origin: left;
}
.nav__cta:hover { transform: scaleX(1.03); }

/* ---------- SHARED SECTION FRAME ---------- */
.section {
  position: relative;
  padding: clamp(64px, 9vw, 130px) var(--pad) clamp(56px, 7vw, 104px);
  z-index: 2;
}
.section--light { background: var(--bg-light); color: var(--ink-dark); }
.section--dark  { background: var(--bg-dark);  color: var(--ink-light); }

.section__head {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  align-items: start;
  gap: 12px 0;
  margin-bottom: clamp(28px, 4vw, 56px);
}
.section__num {
  grid-column: 1 / 4;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(72px, 13vw, 190px); line-height: .8;
  color: transparent; -webkit-text-stroke: 1px currentColor;
  opacity: .28; margin-left: -.06em;
}
.section__head > div { grid-column: 4 / 13; }
.section__title {
  font-size: clamp(40px, 8vw, 96px);
  letter-spacing: -.02em;
  max-width: 14ch;
}
.section__intro {
  grid-column: 4 / 12;
  max-width: 62ch;
  font-size: clamp(1rem, 1.4vw, 1.2rem);
  margin: 0 0 clamp(28px, 4vw, 48px);
}

/* vertical section label at left edge */
.vlabel {
  position: absolute;
  left: 6px; top: clamp(64px, 9vw, 130px);
  writing-mode: vertical-rl; text-orientation: mixed;
  transform: rotate(180deg);
  font-size: .68rem; font-weight: 700; letter-spacing: .2em;
  text-transform: uppercase; opacity: .5;
  display: inline-flex; gap: .04em;
}
.vlabel span { display: inline-block; transform: translateY(-8px); opacity: 0; }
.vlabel.in span { transform: none; opacity: 1; transition: transform .4s ease, opacity .4s ease; transition-delay: calc(var(--c) * 45ms); }

.eyebrow {
  font-size: .74rem; font-weight: 700; letter-spacing: .18em;
  text-transform: uppercase; color: var(--accent-1); margin: 0 0 14px;
}
.section--dark .eyebrow { color: var(--accent-2); }

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 24px; font-weight: 700; font-size: .98rem;
  text-decoration: none; border-radius: 20px; border: 0; cursor: pointer;
  font-family: var(--font-body);
  transition: transform .2s ease, background .2s ease, color .2s ease;
  transform-origin: left;
}
.btn--accent { background: var(--accent-2); color: var(--ink-dark); }
.btn--ghost  { background: transparent; color: inherit; box-shadow: inset 0 0 0 1px currentColor; border-radius: 20px; }
.btn:hover { transform: scaleX(1.02); }
.btn__arrow { transition: transform .2s ease; }
.btn:hover .btn__arrow { transform: translateX(4px); }

/* ---------- HERO (split 5/7) ---------- */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: 5fr 7fr;
  min-height: calc(100vh - var(--nav-h));
  background: var(--bg-light);
  z-index: 2;
}
.hero__text {
  position: relative; overflow: hidden;
  padding: clamp(40px, 6vw, 96px) clamp(24px, 4vw, 64px) clamp(40px, 6vw, 80px) var(--pad);
  display: flex; flex-direction: column; justify-content: center;
  gap: 22px;
}
.hero__title {
  font-size: clamp(40px, 5.2vw, 82px);
  letter-spacing: -.025em; max-width: 15ch;
}
.hero__lede { max-width: 46ch; font-size: clamp(1rem, 1.3vw, 1.18rem); color: #33343a; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero__stats {
  list-style: none; margin: 18px 0 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: clamp(20px, 4vw, 48px);
}
.hero__stats b { display: block; font-family: var(--font-display); font-weight: 700; font-size: clamp(1.5rem, 2.4vw, 2.1rem); }
.hero__stats span { font-size: .8rem; letter-spacing: .06em; text-transform: uppercase; color: #6a6b72; }

.hero__media { position: relative; overflow: hidden; background: var(--bg-dark); }
.hero__media img { width: 100%; height: 100%; object-fit: cover; }

/* breathing gradient mesh */
.hero__mesh { position: absolute; inset: -20%; z-index: 0; pointer-events: none; filter: blur(60px); opacity: .5; }
.mesh { position: absolute; border-radius: 50%; filter: saturate(.6); }
.mesh--1 { width: 46%; height: 46%; left: 8%; top: 12%; background: radial-gradient(circle, var(--accent-1), transparent 68%); animation: mesh1 19s ease-in-out infinite; }
.mesh--2 { width: 40%; height: 40%; right: 4%; top: 30%; background: radial-gradient(circle, var(--accent-2), transparent 66%); animation: mesh2 23s ease-in-out infinite; }
.mesh--3 { width: 34%; height: 34%; left: 26%; bottom: 6%; background: radial-gradient(circle, var(--accent-1), transparent 70%); animation: mesh3 27s ease-in-out infinite; }
.hero__text > :not(.hero__mesh) { position: relative; z-index: 1; }

@keyframes mesh1 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(8%, -6%) scale(1.18); } }
@keyframes mesh2 { 0%,100% { transform: translate(0,0) scale(1.05); } 50% { transform: translate(-7%, 5%) scale(.85); } }
@keyframes mesh3 { 0%,100% { transform: translate(0,0) scale(.95); } 50% { transform: translate(5%, -8%) scale(1.2); } }

/* ---------- PRODUCTS TRACK ---------- */
.track {
  display: flex; gap: 20px;
  overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 8px var(--pad) 8px 0;
  margin: 0 calc(var(--pad) * -1);
  padding-left: var(--pad);
  scrollbar-width: none;
  touch-action: pan-x pan-y;
}
.track::-webkit-scrollbar { display: none; }
.card {
  scroll-snap-align: start;
  flex: 0 0 clamp(280px, 34vw, 440px);
  border-radius: 20px;
  padding: 22px;
  display: flex; flex-direction: column; gap: 8px;
  overflow: visible;
  transform: translateX(28px); opacity: 0;
  transition: transform .55s cubic-bezier(.22,1,.36,1), opacity .55s ease, background-color .3s ease;
  transition-delay: calc(var(--rev) * 90ms);
}
.track.in .card { transform: none; opacity: 1; }
.card--a { background: var(--accent-1); color: #fff; }
.card--b { background: var(--accent-2); color: var(--ink-dark); }
.card--c { background: #1d1e22; color: var(--ink-light); }
.card__media {
  position: relative; margin-top: -46px; margin-bottom: 4px;
  aspect-ratio: 1 / 1; display: grid; place-items: end center;
}
.card__media img {
  width: 100%; height: 100%; object-fit: contain;
  transition: transform .35s cubic-bezier(.22,1,.36,1);
  will-change: transform;
}
.card:hover .card__media img { transform: translateY(-8px); }
.card:hover.card--a { background: #4a4aff; }
.card:hover.card--b { background: #d1ff78; }
.card:hover.card--c { background: #26272c; }
.card__kicker { font-size: .72rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; opacity: .75; margin: 0; }
.card__name { font-size: clamp(1.6rem, 2.4vw, 2.2rem); letter-spacing: -.02em; }
.spec { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 8px; }
.spec li { display: flex; justify-content: space-between; gap: 12px; font-size: .92rem; padding-bottom: 8px; border-bottom: 1px solid rgba(128,128,131,.28); }
.spec span { opacity: .8; }
.spec b { font-weight: 700; text-align: right; }
.card__price { font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; margin: 14px 0 0; }

.track__progress { height: 3px; background: rgba(128,128,131,.25); margin-top: 22px; border-radius: 2px; overflow: hidden; }
.track__progress span { display: block; height: 100%; width: 100%; background: var(--accent-2); transform: scaleX(0); transform-origin: left; }

/* ---------- TECHNOLOGY ---------- */
.tech {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(24px, 3vw, 44px);
}
.tech__item { grid-column: span 6; padding-top: 8px; }
.tech__item--wide { grid-column: 1 / 8; }
.tech__item:nth-child(2) { grid-column: 8 / 13; }
.tech__item:nth-child(3) { grid-column: 3 / 10; }
.tech__icon { width: 64px; height: 64px; color: var(--accent-1); margin-bottom: 16px; }
.tech__name { font-size: clamp(1.4rem, 2.2vw, 1.9rem); letter-spacing: -.01em; margin-bottom: 6px; }
.tech__count { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; margin: 0 0 10px; }
.tech__count b { color: var(--accent-1); }
.tech__desc { max-width: 48ch; color: #3a3b41; }
.draw { stroke-dasharray: 240; stroke-dashoffset: 240; }
.tech__item.in .draw { animation: draw 1s ease forwards; }
.tech__item.in .draw:nth-of-type(2) { animation-delay: .18s; }
.tech__item.in .draw:nth-of-type(3) { animation-delay: .34s; }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* ---------- COMPARISON ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.ctable {
  width: 100%; border-collapse: collapse;
  font-size: clamp(.92rem, 1.4vw, 1.05rem);
  min-width: 620px;
}
.ctable th, .ctable td { text-align: left; padding: 16px 18px; border-bottom: 1px solid rgba(247,247,245,.14); }
.ctable thead th {
  font-family: var(--font-display); font-weight: 600; font-size: 1.1rem;
  border-bottom: 1px solid rgba(247,247,245,.3);
}
.ctable tbody th[scope="row"] {
  position: sticky; left: 0; z-index: 1;
  background: var(--bg-dark);
  font-weight: 600; color: var(--accent-2);
  min-width: 160px;
}
.ctable tbody tr { opacity: 0; transform: translateY(10px); }
.ctable.in tbody tr { opacity: 1; transform: none; transition: opacity .4s ease, transform .4s ease; transition-delay: calc(var(--r) * 55ms); }
.ctable td.win {
  background: var(--accent-2); color: var(--ink-dark);
  font-weight: 700; border-radius: 4px;
}

/* ---------- QUOTES ---------- */
.quotes {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(28px, 4vw, 56px);
}
.quote { margin: 0; grid-column: span 12; }
.quote:nth-child(1) { grid-column: 1 / 9; }
.quote:nth-child(2) { grid-column: 4 / 13; }
.quote:nth-child(3) { grid-column: 2 / 11; }
.quote blockquote {
  margin: 0; font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.5rem, 3.4vw, 3rem); line-height: 1.12; letter-spacing: -.02em;
}
.quote__drop {
  float: left; font-size: clamp(3.2rem, 8vw, 6.5rem); line-height: .8;
  padding-right: .1em; margin-top: .04em;
  background-image: linear-gradient(to top, var(--accent-1), var(--accent-1));
  background-repeat: no-repeat; background-position: bottom; background-size: 100% 0%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: #c9cace;
}
.quote.in .quote__drop { animation: dropfill 1s cubic-bezier(.22,1,.36,1) forwards; }
@keyframes dropfill { from { background-size: 100% 0%; } to { background-size: 100% 100%; } }
.quote figcaption { margin-top: 18px; font-size: .9rem; font-weight: 600; letter-spacing: .04em; color: #6a6b72; }

/* ---------- FORM ---------- */
.signup .section__intro { color: #b7b8bd; }
.form {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 20px 24px;
  align-items: end;
}
.form__field { grid-column: span 5; display: flex; flex-direction: column; gap: 8px; }
.form__field:nth-of-type(2) { grid-column: span 5; }
.form__submit { grid-column: span 2; justify-content: center; }
.form label { font-size: .8rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #b7b8bd; }
.form input {
  background: transparent; border: 0; border-bottom: 1px solid rgba(247,247,245,.3);
  color: var(--ink-light); font: inherit; padding: 12px 2px; outline: none;
  position: relative;
}
.form__field { position: relative; }
.form__field::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 100%;
  background: var(--accent-1); transform: scaleX(0); transform-origin: left;
  transition: transform .35s ease;
}
.form__field:focus-within::after { transform: scaleX(1); }
.form input::placeholder { color: #6a6b72; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form__status { grid-column: 1 / 13; margin: 6px 0 0; font-weight: 600; min-height: 1.4em; }
.form__status.success {
  background: var(--accent-2); color: var(--ink-dark);
  display: inline-block; padding: 10px 16px; border-radius: 12px;
  animation: fadeUp .4s ease;
}
.form__status.error { color: #ff8a8a; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- FOOTER ---------- */
.footer {
  position: relative; z-index: 2;
  background: var(--bg-dark); color: var(--ink-light);
  padding: clamp(48px, 6vw, 80px) var(--pad) 40px;
  border-top: 1px solid rgba(247,247,245,.12);
}
.footer__row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 32px; }
.footer__logo { font-size: 1.25rem; }
.footer__slogan { margin: 12px 0 0; color: #9a9ba1; max-width: 32ch; }
.footer__nav { display: flex; flex-wrap: wrap; gap: 20px 28px; align-content: start; }
.footer__nav a { text-decoration: none; font-weight: 600; color: #cfd0d5; transition: color .2s ease; }
.footer__nav a:hover { color: var(--accent-2); }
.footer__copy { margin: clamp(36px, 5vw, 56px) 0 0; font-size: .86rem; color: #78797f; }

/* ---------- SCROLL REVEAL ---------- */
.reveal { opacity: 0; transform: translateY(24px); }
.reveal.in { opacity: 1; transform: none; transition: opacity .6s ease, transform .6s cubic-bezier(.22,1,.36,1); }
.section__title.reveal.in { transition-delay: .05s; }
.section__head .reveal:nth-child(2) { transition-delay: .12s; }

/* ---------- GALLERY ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(10px, 1.4vw, 18px);
}
.gallery__item {
  position: relative;
  grid-column: span 4;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid var(--line);
}
.gallery__item--wide { grid-column: span 8; }
.gallery__item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .5s cubic-bezier(.22,1,.36,1);
  will-change: transform;
}
.gallery__item:hover img { transform: scale(1.05); }
.gallery__cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 14px 16px;
  font-family: var(--font-display); font-weight: 600; font-size: .95rem;
  color: #fff;
  background: linear-gradient(to top, rgba(17,18,20,.82), rgba(17,18,20,0));
}
@media (max-width: 720px) {
  .gallery__item, .gallery__item--wide { grid-column: span 12; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .tech__item, .tech__item--wide,
  .tech__item:nth-child(2), .tech__item:nth-child(3) { grid-column: span 6; }
}

@media (max-width: 768px) {
  :root { --pad: 16px; }
  .hero { grid-template-columns: 1fr; min-height: 0; }
  .hero__media { order: -1; aspect-ratio: 16 / 10; }
  .hero__media img { height: 100%; }
  .hero__text { padding: 40px var(--pad) 56px; }
  .section__head { margin-bottom: 24px; }
  .section__num { grid-column: 1 / 13; }
  .section__head > div, .section__intro { grid-column: 1 / 13; }
  .tech__item, .tech__item--wide,
  .tech__item:nth-child(2), .tech__item:nth-child(3) { grid-column: 1 / 13; }
  .quote:nth-child(1), .quote:nth-child(2), .quote:nth-child(3) { grid-column: 1 / 13; }
  .form__field, .form__field:nth-of-type(2), .form__submit { grid-column: 1 / 13; }
  .vlabel { display: none; }
  .grid-overlay__inner { grid-template-columns: repeat(6, 1fr); }
  .nav__menu { gap: 12px; }
  .nav__menu a:not(.nav__cta) { display: none; }
}

@media (max-width: 480px) {
  .hero__stats { gap: 18px; }
  .card { flex-basis: 82vw; }
}

/* ---------- REDUCED MOTION ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .reveal, .track .card, .ctable tbody tr, .vlabel span { opacity: 1 !important; transform: none !important; }
  .grid-overlay span::before, .grid-overlay span.edge::after { transform: scaleY(1) !important; }
  .draw { stroke-dashoffset: 0 !important; }
  .quote__drop { background-size: 100% 100% !important; }
  .hero__mesh { display: none; }
}
