/* ============================================================
   jahe.dev — landing page
   Design tokens mirror gogame's warm dark / honey-gold palette so the
   hub and the games read as one site.
   ============================================================ */
:root {
  --bg:           #0f1114;
  --bg-elev:      #16191e;
  --panel:        #1a1d22;
  --panel-hi:     #23272e;
  --border:       #2b2f36;
  --border-hi:    #3a3f48;
  --text:         #f3ede0;
  --text-dim:     #b4ad9f;
  --muted:        #7c7568;
  --brand:        #f0b840;
  --accent:       #d4a24c;

  --shadow-sm:    0 2px 8px rgba(0, 0, 0, .3);
  --shadow-md:    0 6px 20px rgba(0, 0, 0, .4);
  --shadow-lg:    0 24px 64px rgba(0, 0, 0, .55);

  --ease:         cubic-bezier(.2, .8, .3, 1);
}

* { box-sizing: border-box; }
html, body { margin: 0; }

body {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font: 400 15px/1.6 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
}

/* warm glow behind the masthead */
.glow {
  position: fixed;
  inset: -20vh 0 auto 0;
  height: 80vh;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(60vw 40vh at 50% 0%, rgba(240, 184, 64, .13), transparent 70%),
    radial-gradient(40vw 30vh at 15% 10%, rgba(212, 162, 76, .07), transparent 70%);
}

.wrap {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  margin: 0 auto;
  padding: clamp(48px, 9vw, 104px) clamp(20px, 5vw, 40px) 56px;
}

/* ---------- masthead ---------- */

.masthead { margin-bottom: clamp(40px, 6vw, 64px); }

.wordmark {
  margin: 0;
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 800;
  font-size: clamp(38px, 7vw, 62px);
  line-height: 1.05;
  letter-spacing: -.02em;
  color: var(--text);
}
.wordmark .dot { color: var(--brand); }

.tagline {
  margin: 14px 0 0;
  max-width: 46ch;
  font-size: clamp(15px, 1.7vw, 17px);
  color: var(--text-dim);
}

.section-label {
  margin: 0 0 18px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- card grid ---------- */

.grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: clamp(16px, 2.4vw, 24px);
}

.card {
  --accent-glow: rgba(240, 184, 64, .5);

  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: linear-gradient(180deg, var(--panel-hi) 0%, var(--panel) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04), var(--shadow-sm);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition:
    transform .28s var(--ease),
    border-color .28s var(--ease),
    box-shadow .28s var(--ease);
}

a.card:hover,
a.card:focus-visible {
  transform: translateY(-4px);
  border-color: var(--border-hi);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .06),
    var(--shadow-lg),
    0 0 0 1px var(--accent-glow),
    0 18px 50px -24px var(--accent-glow);
  outline: none;
}
a.card:focus-visible { border-color: var(--brand); }
a.card:active { transform: translateY(-1px); }

.card[data-accent="go"]      { --accent-glow: rgba(230, 192, 135, .45); }
.card[data-accent="mancala"] { --accent-glow: rgba(240, 184, 64, .45); }
.card[data-accent="dxyball"] { --accent-glow: rgba(127, 180, 255, .45); }

/* ---------- thumbnail ---------- */

.thumb {
  position: relative;
  border-bottom: 1px solid var(--border);
  background: #0b0d10;
  overflow: hidden;
}
.thumb svg {
  display: block;
  width: 100%;
  height: auto;
  transition: transform .45s var(--ease);
}
a.card:hover .thumb svg { transform: scale(1.045); }

/* subtle top-down darkening so the title sits comfortably below */
.thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(15, 17, 20, .35) 100%);
  pointer-events: none;
}

.thumb-soon {
  background: repeating-linear-gradient(
    45deg, #14171b 0 10px, #111417 10px 20px);
}

/* ---------- card body ---------- */

.card-body {
  padding: 18px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.card-title {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  font-size: 21px;
  letter-spacing: -.01em;
  color: var(--text);
}

.arrow {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: var(--brand);
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity .28s var(--ease), transform .28s var(--ease);
}
a.card:hover .arrow,
a.card:focus-visible .arrow { opacity: 1; transform: translateX(0); }

.card-desc {
  margin: 0;
  font-size: 14px;
  color: var(--text-dim);
  flex: 1;
}

.meta {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 6px 0 0;
  padding: 0;
}
.meta li {
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: .02em;
  color: var(--muted);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .02);
  border-radius: 999px;
  padding: 3px 9px;
}

/* ---------- "more soon" placeholder ---------- */

.card-soon {
  border-style: dashed;
  background: transparent;
  box-shadow: none;
}
.card-soon .card-title,
.card-soon .card-desc { color: var(--muted); }
.card-soon .thumb { border-bottom-style: dashed; }

/* ---------- footer ---------- */

.foot {
  margin-top: clamp(48px, 7vw, 80px);
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  font-size: 13.5px;
  color: var(--muted);
}
.foot p { margin: 0; }
.foot-links { display: flex; gap: 8px; }
.foot a {
  color: var(--text-dim);
  text-decoration: none;
  border-bottom: 1px solid var(--border-hi);
  transition: color .2s, border-color .2s;
}
.foot a:hover { color: var(--brand); border-color: var(--brand); }

/* ---------- shared "back to jahe.dev" pill, used by the games ---------- */

.site-home {
  position: fixed;
  left: 14px;
  top: 14px;
  z-index: 200;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px 7px 11px;
  border-radius: 999px;
  border: 1px solid var(--border-hi);
  background: rgba(22, 25, 30, .82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--text-dim);
  font: 500 13px/1 'Inter', system-ui, sans-serif;
  text-decoration: none;
  transition: color .2s, border-color .2s, background .2s;
}
.site-home:hover { color: var(--brand); border-color: var(--brand); }

@media (max-width: 560px) {
  .foot { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition-duration: .001ms !important; animation-duration: .001ms !important; }
  a.card:hover { transform: none; }
  a.card:hover .thumb svg { transform: none; }
}
