/* ── Tokens ──────────────────────────────────────────────── */
:root {
  --bg:         #05060a;
  --surface:    #0d1018;
  --surface2:   #131a24;
  --text:       #ede8de;
  --muted:      #7a8a9e;
  --line:       rgba(255, 255, 255, 0.07);
  --cold:       #cfa03c;
  --merge:      #28c4a0;
  --biasly:     #6e8eff;
  --ink:        #05060a;
  --shadow:     0 40px 100px rgba(0, 0, 0, 0.7);
  --display:    'Unbounded', sans-serif;
  --body:       'DM Sans', ui-sans-serif, system-ui, sans-serif;
  --radius:     14px;
}

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

html { scroll-behavior: smooth; }

body {
  min-height: 100dvh;
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 65% 45% at 12% 0%, rgba(207, 160, 60, 0.11) 0%, transparent 70%),
    radial-gradient(ellipse 65% 45% at 88% 0%, rgba(40, 196, 160, 0.09) 0%, transparent 70%);
  color: var(--text);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.65;
}

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

/* ── Header ──────────────────────────────────────────────── */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 26px 0;
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
  animation: fadeDown 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-14px); }
  to   { opacity: 1; transform: translateY(0); }
}

.brand {
  font-family: var(--display);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-decoration: none;
  background: linear-gradient(130deg, var(--cold) 0%, var(--merge) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.site-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.site-nav a {
  font-family: var(--body);
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 8px 18px;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.04);
  outline: none;
}

/* ── Hero ────────────────────────────────────────────────── */
.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 60px;
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
}

.hero-backdrop {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  pointer-events: none;
  user-select: none;
  overflow: hidden;
}

.backdrop-text {
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(7rem, 20vw, 17rem);
  line-height: 1;
  letter-spacing: -0.04em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.045);
  transform: translateX(6%) translateY(10%);
  white-space: nowrap;
  animation: backdropReveal 1.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes backdropReveal {
  from { opacity: 0; transform: translateX(12%) translateY(10%); }
  to   { opacity: 1; transform: translateX(6%)  translateY(10%); }
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 740px;
}

.hero-tag {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 22px;
  animation: fadeUp 0.7s 0.1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.hero-title {
  font-family: var(--display);
  font-size: clamp(2.2rem, 9.5vw, 8rem);
  font-weight: 900;
  line-height: 0.88;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: 28px;
  animation: fadeUp 0.7s 0.15s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.title-gradient {
  display: block;
  background: linear-gradient(100deg, var(--cold) 0%, var(--merge) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-sub {
  font-size: 1.1rem;
  color: var(--muted);
  line-height: 1.7;
  animation: fadeUp 0.7s 0.22s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Project Grid ────────────────────────────────────────── */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 18px;
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
  padding-bottom: 90px;
  animation: fadeUp 0.7s 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.game-card {
  position: relative;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background-color: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition:
    transform    0.45s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow   0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.game-card:hover { transform: translateY(-8px); }

.coldfile-card:hover {
  box-shadow: var(--shadow), 0 0 70px rgba(207, 160, 60, 0.15);
}
.mergebeat-card:hover {
  box-shadow: var(--shadow), 0 0 70px rgba(40, 196, 160, 0.12);
}
.biasly-card:hover {
  box-shadow: var(--shadow), 0 0 70px rgba(110, 142, 255, 0.14);
}

/* atmospheric top glow per card */
.card-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  transition: opacity 0.45s;
}

.coldfile-card  .card-glow {
  background: radial-gradient(ellipse 85% 50% at 50% -15%, rgba(207, 160, 60, 0.22) 0%, transparent 70%);
}
.mergebeat-card .card-glow {
  background: radial-gradient(ellipse 85% 50% at 50% -15%, rgba(40, 196, 160, 0.18) 0%, transparent 70%);
}
.biasly-card .card-glow {
  background: radial-gradient(ellipse 85% 50% at 50% -15%, rgba(110, 142, 255, 0.18) 0%, transparent 70%);
}

.coldfile-card:hover  .card-glow,
.mergebeat-card:hover .card-glow,
.biasly-card:hover    .card-glow { opacity: 1.5; }

/* image area */
.card-visual {
  display: block;
  position: relative;
  z-index: 1;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background-color: var(--surface2);
}

.card-visual img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  transition: transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}

.game-card:hover .card-visual img { transform: scale(1.05); }

.card-visual--contain img {
  object-fit: contain;
  padding: 26px;
}

/* card text */
.card-body {
  position: relative;
  z-index: 1;
  padding: 30px;
  display: flex;
  flex-direction: column;
}

.card-genre {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.coldfile-card  .card-genre { color: var(--cold); }
.mergebeat-card .card-genre { color: var(--merge); }
.biasly-card    .card-genre { color: var(--biasly); }

.card-title {
  font-family: var(--display);
  font-size: clamp(1.9rem, 4vw, 3rem);
  font-weight: 900;
  line-height: 0.92;
  letter-spacing: -0.025em;
  color: var(--text);
  margin-bottom: 14px;
}

.card-title a {
  text-decoration: none;
  color: inherit;
}

.card-desc {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.65;
  flex: 1;
}

.card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

/* ── Buttons ─────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 20px;
  border-radius: 8px;
  font-family: var(--body);
  font-size: 0.88rem;
  font-weight: 700;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}

.btn:hover  { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-cold {
  background-color: var(--cold);
  color: var(--ink);
}
.btn-cold:hover { box-shadow: 0 6px 20px rgba(207, 160, 60, 0.4); }

.btn-merge {
  background-color: var(--merge);
  color: var(--ink);
}
.btn-merge:hover { box-shadow: 0 6px 20px rgba(40, 196, 160, 0.38); }

.btn-ghost {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  border: 1px solid var(--line);
}
.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.15);
}

.btn-biasly {
  background-color: var(--biasly);
  color: var(--ink);
}
.btn-biasly:hover { box-shadow: 0 6px 20px rgba(110, 142, 255, 0.4); }

/* ── Footer ──────────────────────────────────────────────── */
.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 28px 0 44px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.85rem;
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
}

.site-footer a {
  font-weight: 600;
  text-decoration: none;
  color: var(--text);
  transition: color 0.2s;
}
.site-footer a:hover { color: var(--merge); }

/* ── Redirect pages (privacy.html / support.html) ────────── */
.redirect-shell {
  width: min(1160px, calc(100% - 36px));
  margin-inline: auto;
  min-height: 100vh;
  display: grid;
  place-items: center;
}

.redirect-panel {
  width: min(620px, 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 34px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.redirect-panel h1 {
  font-family: var(--display);
  font-size: clamp(2.2rem, 8vw, 4.2rem);
  font-weight: 900;
  line-height: 0.9;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--merge);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.lead {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.65;
}

.lead a {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}


.btn-appstore {
  background: #1c1c1e;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.12);
  gap: 7px;
}
.btn-appstore:hover {
  background: #2c2c2e;
  box-shadow: 0 6px 20px rgba(0,0,0,0.45);
  border-color: rgba(255,255,255,0.22);
}

.btn-soon-wrap { position: relative; display: inline-flex; }
.btn-soon-tip {
  position: absolute;
  bottom: calc(100% + 9px);
  left: 50%;
  transform: translateX(-50%) translateY(5px);
  white-space: nowrap;
  background: rgba(40,196,160,0.12);
  border: 1px solid rgba(40,196,160,0.35);
  color: var(--merge);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 5px 13px;
  border-radius: 100px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.22s, transform 0.22s;
}
.btn-soon-wrap.tip-show .btn-soon-tip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 820px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero { padding-top: 50px; }

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

@media (max-width: 520px) {
  .site-nav { width: 100%; }

  .backdrop-text { display: none; }

  .card-body { padding: 22px; }

  .card-actions { flex-direction: column; }
  .btn { width: 100%; text-align: center; }

  .site-footer { flex-direction: column; }
}

@media (max-width: 400px) {
  .site-nav a { font-size: 0.75rem; padding: 7px 12px; }
  .hero-sub { font-size: 1rem; }
}
