/*
 * MasaZ tasarım token'ları.
 * Üst bölüm masaz-app/lib/core/theme/masaz_theme.dart (MasaZColors) ile birebir
 * aynalıdır; değer değişirse iki dosya birlikte güncellenir.
 * "Site" bölümü yalnızca web için türetilmiş tonlardır.
 */
:root {
  /* --- masaz_theme.dart / MasaZColors --- */
  --black: #07090d;
  --midnight: #0b1018;
  --night: #111823;
  --emerald: #16c78a;
  --marquee-gold: #ffd35a;
  --hot-gold: #ffaa1b;
  --ruby: #ff4d68;
  --espresso: #1f140f;
  --wood-dark: #3d2214;
  --wood: #724020;
  --felt: #144a3e;
  --felt-light: #2b6f5d;
  --cream: #f6e8c6;
  --parchment: #f3e6ca;
  --gold: #b88b2d;
  --brass: #e0b662;
  --burgundy: #5e1f26;
  --smoke: #6c5a48;
  --mint: #6dc0a3;

  /* --- masaz_theme.dart / v2 --- */
  --v2-night-900: #140E0B;
  --v2-night-800: #221914;
  --v2-night-700: #2F231C;
  --v2-night-600: #3B2C22;
  --v2-line: #FFFFFF1F;
  --v2-gold: #FFD35A;
  --v2-gold-deep: #FFA51F;
  --v2-gold-lip: #A45A00;
  --v2-gold-ink: #3A1A00;
  --v2-bulb: #FFE9A8;
  --v2-text: #FFFFFF;
  --v2-text-2: #FFFFFFB8;
  --v2-text-3: #FFFFFF7A;
  --v2-tavla: #FF9F1C;
  --v2-tavla-deep: #5A2408;
  --v2-win: #2EE59D;
  --v2-lose: #FF5C7A;
  --v2-font-display: "Baloo 2";
  --v2-font-ui: "Nunito";

  /* --- Tavla Prime / tp (tavla-prime-app design/tokens/v2-tokens.json, uygulama 2712eece) ---
     Yalnızca değişken tanımı; sayfa stilleri henüz kullanmaz. */
  --tp-ground: #2A1508;
  --tp-ground-deep: #1E0E05;
  --tp-scrim: #140803D9;
  --tp-panel-fill: #1E0E05CC;
  --tp-panel-border: #D98A3A66;
  --tp-panel-border-gold: #FFD45A99;
  --tp-line-soft: #FFD98A66;
  --tp-wood-top: #7A3F16;
  --tp-wood-bottom: #3E1C08;
  --tp-wood-rim: #F0B45A;
  --tp-gold-top: #FFE06A;
  --tp-gold-bottom: #F7A400;
  --tp-gold-rim: #FFF3B0;
  --tp-gold-lip: #A85A00;
  --tp-gold: #FFD45A;
  --tp-gold-ring: #FFC83D;
  --tp-gold-ink: #5A2600;
  --tp-cream-top: #FFF6DD;
  --tp-cream-bottom: #F1D29A;
  --tp-text-ivory: #FFE9B8;
  --tp-text-gold: #FFD98A;
  --tp-text-tan: #E8C79A;
  --tp-text-muted: #C9A57A;
  --tp-success: #5BE08A;
  --tp-alert: #FF4B3E;
  --tp-danger: #FF8A7A;
  --tp-bulb-on: #FFF6C2;

  /* --- Site (yalnızca web) --- */
  --felt-deep: #0b2c25;
  --felt-night: #071d19;
  --wood-grain: linear-gradient(135deg, #8b5429 0%, #5a3118 38%, #7a4622 62%, #3d2214 100%);
  --gold-leaf: linear-gradient(180deg, #fff0b8 0%, #ffd35a 48%, #e0a21c 100%);
  --line: rgba(246, 232, 198, 0.16);
  --line-soft: rgba(246, 232, 198, 0.08);
  --line-gold: rgba(224, 182, 98, 0.55);
  --cream-muted: #c9bb9c;

  /* --- Site rampası: ceviz siyahına çekilmiş nötrler, tek vurgu altın --- */
  --bg-deep: #0c0a08;
  --bg: #110f0c;
  --surface: #191612;
  --raised: #221e19;
  --text: #f3ead8;
  --text-2: #b3a894;
  --text-3: #8c8273;
  --hairline: rgba(243, 234, 216, 0.08);
  --hairline-strong: rgba(243, 234, 216, 0.14);
  --accent: var(--marquee-gold);
  --accent-hover: #ffdd7d;
  --accent-ink: var(--espresso);
  --mono: ui-monospace, SFMono-Regular, Menlo, monospace;
  --fast: 150ms;
  --enter: 400ms;

  --page-width: 1200px;
  --gutter: 48px;
  --radius-xl: 20px;
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --font: "Outfit", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

@media (max-width: 1080px) {
  :root { --gutter: 32px; }
}

@media (max-width: 760px) {
  :root { --gutter: 24px; }
}

/* Üst çubuk, düğmeler, indir rozetleri ve temiz masa satırı.
   Ana sayfa bunu main.css üzerinden alır; statik sayfalar /assets/chrome.css olarak.
   Renkler tokens.css'teki site rampasına bağlıdır. */

.shell {
  width: min(var(--page-width, 1200px), 100%);
  margin-inline: auto;
  padding-inline: var(--gutter, 24px);
}

.icon {
  flex-shrink: 0;
}

.btn {
  display: inline-flex;
  height: 48px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-family: var(--font);
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  text-decoration: none;
  transition:
    background-color var(--fast, 150ms) var(--ease-out),
    border-color var(--fast, 150ms) var(--ease-out),
    transform 120ms var(--ease-out);
}
.btn:active { transform: scale(0.98); }
.btn--sm { height: 36px; padding: 0 16px; border-radius: 8px; font-size: 14px; }
.btn--primary { color: var(--accent-ink); background: var(--accent); }
.btn--primary:hover { background: var(--accent-hover); }
.btn--ghost {
  border-color: var(--hairline-strong);
  color: var(--text);
  background: var(--raised);
}
.btn--ghost:hover { border-color: rgba(243, 234, 216, 0.24); }

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  width: 100%;
  border-bottom: 1px solid var(--hairline);
  background: rgba(12, 10, 8, 0.94);
}
/* Altından geçen logo ve ekranların rengi hafifçe sızar; blur yoksa opak kalır. */
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .topbar {
    background: rgba(12, 10, 8, 0.64);
    -webkit-backdrop-filter: blur(20px) saturate(1.2);
    backdrop-filter: blur(20px) saturate(1.2);
  }
}
.topbar a { color: inherit; text-decoration: none; }
.topbar .btn--primary { color: var(--accent-ink); }
.topbar img { display: block; max-width: none; }
.topbar__inner {
  display: flex;
  height: 64px;
  align-items: center;
  gap: 32px;
}
.brand {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 8px;
}
.brand .brand__icon { width: 32px; height: 32px; border-radius: 8px; }
.brand .brand__word { width: auto; height: 44px; }
.topbar__nav {
  display: flex;
  gap: 32px;
  margin-left: auto;
  color: var(--text-2);
  font-family: var(--font);
  font-size: 15px;
  font-weight: 500;
}
.topbar__nav a { transition: color var(--fast, 150ms) var(--ease-out); }
.topbar__nav a:hover { color: var(--text); }

.store-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.store-badge {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  line-height: 1;
  text-decoration: none;
}
button.store-badge {
  appearance: none;
  margin: 0;
  padding: 0;
  border: 0;
  color: inherit;
  background: transparent;
  font: inherit;
}
.store-badge img { display: block; width: auto; }
/* Google rozetinin PNG'si üstte ve altta %12 saydam boşluk taşır; 64px'lik Play, 48px'lik Apple ile aynı boyda görünür. */
.store-badges--lg .store-badge--play img { height: 64px; }
.store-badges--lg .store-badge--apple img { height: 48px; }
.store-badges--sm .store-badge--play img { height: 48px; }
.store-badges--sm .store-badge--apple img { height: 36px; }
.store-badge--soon { cursor: not-allowed; }
.store-badge--soon img { opacity: 0.4; filter: grayscale(1); }
.store-badge__soon {
  color: var(--text-3);
  font-family: var(--font);
  font-size: 12px;
  white-space: nowrap;
}

.temiz-masa {
  max-width: 36rem;
  margin-top: 16px;
  padding-left: 16px;
  border-left: 2px solid var(--accent);
  color: var(--text-2);
  font-size: 15px;
  line-height: 24px;
}
.temiz-masa strong { color: var(--text); font-weight: 500; }

@media (max-width: 960px) {
  .topbar__nav { display: none; }
  .topbar__inner > .btn { margin-left: auto; }
}

.design-note { margin-top: 16px; color: var(--text-2); font-size: 13px; line-height: 20px; }




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

html { scroll-behavior: smooth; scroll-padding-top: 64px; background: var(--bg); }

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  color: var(--text);
  background: var(--bg);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, p, figure { margin: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.site { overflow: clip; }

/* ---------- tipografi ---------- */
h1, h2 {
  color: var(--text);
  font-family: var(--font-display);
  font-weight: 600;
  text-wrap: balance;
}
h1 { font-size: 64px; letter-spacing: -0.03em; line-height: 1.04; }
h2 { font-size: 44px; letter-spacing: -0.02em; line-height: 1.1; }
h3 { color: var(--text); font-size: 18px; font-weight: 500; line-height: 24px; }

.label { margin-bottom: 12px; color: var(--text-3); font-size: 15px; font-weight: 500; }
.lede { max-width: 36rem; margin-top: 24px; color: var(--text-2); font-size: 19px; line-height: 30px; }

/* ---------- hero: salon sahnesi, alttan yükselen lobi ---------- */
.hero {
  position: relative;
  height: clamp(720px, calc(100svh - 64px), 860px);
  overflow: hidden;
  isolation: isolate;
}
.hero__scene {
  position: absolute;
  z-index: -1;
  top: 0;
  right: 0;
  width: 60%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 64%;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 40%), linear-gradient(to top, transparent 0%, #000 28%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, transparent 0%, #000 40%), linear-gradient(to top, transparent 0%, #000 28%);
  mask-composite: intersect;
}
.hero__grid {
  display: grid;
  height: 100%;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 48px;
}
.hero__copy { align-self: center; max-width: 560px; animation: rise var(--enter) var(--ease-out) both; }
.hero__downloads { margin-top: 32px; }
.hero__visual {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: rise var(--enter) 60ms var(--ease-out) both;
}
.hero__visual .phone { width: 340px; margin-bottom: -120px; box-shadow: 0 0 0 1px var(--hairline-strong), 0 24px 64px rgba(0, 0, 0, 0.55); }

@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
}

/* ---------- telefon: ekranın kendi köşe oranı ---------- */
.phone { overflow: hidden; border-radius: 12.5% / 5.75%; background: var(--surface); box-shadow: 0 0 0 1px var(--hairline-strong); }
.phone__screen { aspect-ratio: 1206 / 2622; }
.phone__screen img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- bölümler ---------- */
.section { padding-block: 128px; border-top: 1px solid var(--hairline); }
.section__head { max-width: 720px; margin-bottom: 48px; }
.section__head > p:last-child,
.split__copy > p:not(.label) { max-width: 34rem; margin-top: 20px; color: var(--text-2); font-size: 17px; line-height: 28px; }

/* ---------- oynama biçimleri ---------- */
.game-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.game-card {
  display: flex;
  flex-direction: column;
  padding: 24px;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
.game-card__title { margin-bottom: 12px; color: var(--text); font-size: 20px; line-height: 28px; }
.game-card__line { margin-bottom: 24px; color: var(--text-2); font-size: 16px; line-height: 24px; }
.game-card__meta { margin-top: auto; padding-top: 16px; border-top: 1px solid var(--hairline); color: var(--text-3); font-size: 14px; line-height: 20px; }

/* ---------- iki sütunlu bölümler ---------- */
.split { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 64px; align-items: center; }
.split--reverse { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.split--top { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; }
.split__copy--sticky { position: sticky; top: 96px; }
.split__visual { display: grid; place-items: center; }
.split__visual .phone { width: 300px; }

/* İmza: zar yüzü */
.steps { margin-top: 40px; border-top: 1px solid var(--hairline); }
.steps li { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 20px; padding-block: 24px; border-bottom: 1px solid var(--hairline); }
.steps p { margin-top: 4px; color: var(--text-2); font-size: 15px; line-height: 24px; }
.die {
  display: grid;
  width: 24px;
  height: 24px;
  grid-template: repeat(3, 1fr) / repeat(3, 1fr);
  place-items: center;
  padding: 3px;
  border: 1px solid var(--hairline-strong);
  border-radius: 6px;
  background: var(--raised);
}
.die__pip { width: 4px; height: 4px; border-radius: 50%; background: var(--accent); }

.ticks { display: grid; gap: 12px; margin-top: 32px; }
.ticks li { display: flex; align-items: center; gap: 12px; color: var(--text); font-size: 15px; }
.ticks li::before { content: ""; flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

/* ---------- galeri ---------- */
.gallery { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.gallery__item figcaption { margin-top: 12px; color: var(--text-2); font-size: 14px; line-height: 20px; }

/* ---------- kurallar ---------- */
.deletion {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) 16px;
  gap: 12px;
  align-items: center;
  max-width: 400px;
  margin-top: 32px;
  padding: 12px 16px 12px 12px;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  color: var(--text-3);
  background: var(--surface);
  transition: background-color var(--fast) var(--ease-out), border-color var(--fast) var(--ease-out);
}
.deletion:hover { border-color: var(--hairline-strong); background: var(--raised); }
.deletion__icon { display: grid; width: 40px; height: 40px; place-items: center; border-radius: 4px; color: var(--text-2); background: var(--raised); }
.deletion span:nth-child(2) { display: grid; gap: 2px; }
.deletion strong { color: var(--text); font-size: 15px; font-weight: 500; }
.deletion small { color: var(--text-3); font-size: 13px; }

.legal-list { display: grid; border-top: 1px solid var(--hairline); }
.legal-list a {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) 16px;
  gap: 12px;
  align-items: center;
  min-height: 56px;
  padding-inline: 8px;
  border-bottom: 1px solid var(--hairline);
  color: var(--text-3);
  transition: background-color var(--fast) var(--ease-out), color var(--fast) var(--ease-out);
}
.legal-list a:hover { color: var(--text-2); background: var(--surface); }
.legal-list span { font-family: var(--mono); font-size: 13px; font-variant-numeric: tabular-nums; }
.legal-list strong { color: var(--text); font-size: 15px; font-weight: 500; }

/* ---------- alt bilgi ---------- */
.footer { padding-top: 64px; border-top: 1px solid var(--hairline); background: var(--bg-deep); }
.footer__top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 64px; padding-bottom: 64px; }
.footer__brand .brand .brand__word { width: auto; height: 64px; }
.footer__brand p { max-width: 28ch; margin-top: 16px; color: var(--text-2); font-size: 14px; line-height: 22px; }
.footer__brand .store-badges { margin-top: 20px; }
.footer__links { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.footer__links div { display: grid; align-content: start; gap: 12px; }
.footer__links p { margin-bottom: 4px; color: var(--text-3); font-size: 13px; font-weight: 500; }
.footer__links a { color: var(--text-2); font-size: 14px; transition: color var(--fast) var(--ease-out); }
.footer__links a:hover { color: var(--text); }
.footer__bottom { display: flex; justify-content: space-between; gap: 16px; padding-block: 20px; border-top: 1px solid var(--hairline); color: var(--text-3); font-size: 13px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 1ms !important; animation-duration: 1ms !important; }
}

/* ---------- tablet ---------- */
@media (max-width: 1080px) {
  h1 { font-size: 52px; }
  .hero__visual .phone { width: 300px; }
  .split, .split--reverse, .split--top { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .split--reverse .split__visual { order: 2; }
  .split__copy--sticky { position: static; }
  .footer__top { grid-template-columns: minmax(0, 1fr); gap: 48px; }
}

/* ---------- telefon: metin, sonra sahne ve uygulama ---------- */
@media (max-width: 760px) {
  .hero { height: auto; }
  .hero__scene {
    top: auto;
    bottom: 0;
    width: 100%;
    height: 560px;
    object-position: 50% 70%;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 36%);
    mask-image: linear-gradient(to bottom, transparent 0%, #000 36%);
  }
  .hero__grid { grid-template-columns: minmax(0, 1fr); gap: 48px; padding-top: 48px; }
  h1 { font-size: 40px; letter-spacing: -0.02em; line-height: 1.08; }
  h2 { font-size: 32px; line-height: 1.15; }
  .lede { margin-top: 20px; font-size: 17px; line-height: 28px; }
  .hero__visual { height: 440px; overflow: hidden; }
  .hero__visual .phone { width: 260px; margin-bottom: 0; align-self: flex-start; }

  .section { padding-block: 80px; }
  .section__head { margin-bottom: 32px; }
  .section__head > p:last-child,
  .split__copy > p:not(.label) { font-size: 16px; line-height: 26px; }
  .game-grid { grid-template-columns: minmax(0, 1fr); }
  .split__visual .phone { width: 260px; }

  .gallery {
    display: flex;
    gap: 16px;
    margin-inline: calc(-1 * var(--gutter));
    padding-inline: var(--gutter);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }
  .gallery__item { flex: 0 0 64%; scroll-snap-align: start; scroll-margin-left: var(--gutter); }
  .footer__links { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 32px; }
  .footer__bottom { flex-direction: column; gap: 4px; }
}
