/*
  Byte Flux Studios — site system.

  Palette, type scale, band rhythm, nav pill and footer panel are ported from
  the Whetstone system (whop/project-4, itself measured off project-03).
  Everything under APP SHOWCASE and LEGAL PAGES is specific to this site.
*/

:root {
  /* grounds — every one of these is a full-bleed band, never a card on white */
  --lime: #d2e823;
  --blue: #2665d6;
  --berry: #780016;
  --purple: #502274;
  --gold: #d6a336;
  --sage: #e8efd6;
  --paper: #f3f3f1;
  --white: #ffffff;

  /* inks — always paired to a ground, and usually saturated themselves */
  --forest: #254f1a;
  --lilac: #e9c0e9;
  --ink: #1e2330;
  --mute: #676b5f;

  --r-pill: 9999px;
  --r-panel: 64px;
  --r-card: 32px;
  --r-inset: 16px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--berry);
  color: var(--ink);
  font-family: 'Plus Jakarta Sans', -apple-system, 'Helvetica Neue', Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ---------- type ---------- */

.disp {
  font-size: clamp(38px, 5.4vw, 72px);
  line-height: 1.07;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
}

.sect {
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.06;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
}

.sub {
  font-size: clamp(18px, 1.8vw, 24px);
  line-height: 1.4;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin: 0;
}

.body { font-size: 18px; line-height: 1.55; font-weight: 400; letter-spacing: -0.01em; margin: 0; }
.fine { font-size: 13px; line-height: 1.5; font-weight: 400; letter-spacing: 0.01em; }

.wordmark { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.wordmark-sm { font-size: 18px; font-weight: 800; letter-spacing: -0.02em; }

.eyebrow {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 0 0 20px;
  opacity: 0.62;
}

/* ---------- motion ---------- */

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

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

@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

/* entrance: nav fades in, masthead content and cards rise in with a stagger,
   the footer panel settles in last */

.nav-outer { animation: fadeIn 0.7s ease-out backwards; }

.mast > * { opacity: 0; animation: enterUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.mast .sect { animation-delay: 0.05s; }
.mast .sub { animation-delay: 0.18s; }
.mast .fine { animation-delay: 0.18s; }
.mast .toc { animation-delay: 0.3s; }
.mast .cta-row { animation-delay: 0.3s; }

.feat-head { opacity: 0; animation: enterUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.1s forwards; }

.apps-grid .fcard,
.prose-grid .prose-card,
.info-tiles .info-tile {
  opacity: 0;
  animation: enterUp 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  transition: transform 0.25s ease;
}

.apps-grid .fcard:hover { transform: translateY(-6px); }

.apps-grid .fcard:nth-child(1) { animation-delay: 0.08s; }
.apps-grid .fcard:nth-child(2) { animation-delay: 0.18s; }
.apps-grid .fcard:nth-child(3) { animation-delay: 0.28s; }
.apps-grid .fcard:nth-child(4) { animation-delay: 0.38s; }
.apps-grid .fcard:nth-child(5) { animation-delay: 0.48s; }

.prose-grid .prose-card:nth-child(1) { animation-delay: 0.1s; }
.prose-grid .prose-card:nth-child(2) { animation-delay: 0.22s; }

.info-tiles .info-tile:nth-child(1) { animation-delay: 0.1s; }
.info-tiles .info-tile:nth-child(2) { animation-delay: 0.2s; }

.legal-col > * { opacity: 0; animation: enterUp 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.legal-col > *:nth-child(1) { animation-delay: 0.05s; }
.legal-col > *:nth-child(2) { animation-delay: 0.12s; }
.legal-col > *:nth-child(3) { animation-delay: 0.19s; }

.close { opacity: 0; animation: enterUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) forwards; }

.foot-wrap { opacity: 0; animation: fadeIn 0.8s ease-out 0.2s forwards; }

@media (prefers-reduced-motion: reduce) {
  .anim,
  .nav-outer,
  .mast > *,
  .feat-head,
  .apps-grid .fcard,
  .prose-grid .prose-card,
  .info-tiles .info-tile,
  .legal-col > *,
  .close,
  .foot-wrap {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

/* ---------- bands ---------- */

.wrap { max-width: 1280px; margin: 0 auto; padding: 0 64px; }

.band-lime { background: var(--lime); color: var(--forest); overflow: hidden; }
.band-blue { background: var(--blue); color: var(--white); }
.band-berry { background: var(--berry); color: var(--white); }
.band-paper { background: var(--paper); color: var(--ink); }
.band-sage { background: var(--sage); color: var(--ink); }

/* ---------- floating nav pill ---------- */

.nav-outer { padding: 28px 0 0; position: relative; z-index: 3; }

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 71px;
  background: var(--white);
  color: var(--ink);
  border-radius: var(--r-pill);
  padding: 10px 14px 10px 30px;
  gap: 16px;
}

.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }

.nav-links { display: flex; align-items: center; gap: 28px; font-size: 16px; font-weight: 500; color: var(--mute); }
.nav-links a { color: var(--mute); text-decoration: none; }
.nav-links a:hover { color: var(--ink); }

.nav-cta {
  display: inline-flex;
  align-items: center;
  height: 51px;
  padding: 0 26px;
  border-radius: var(--r-pill);
  background: var(--ink);
  color: var(--paper);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 56px;
  padding: 0 32px;
  border-radius: var(--r-pill);
  font-size: 17px;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}

.btn-forest { background: var(--forest); color: var(--paper); }
.btn-lilac { background: var(--lilac); color: var(--berry); }
.btn-ghost-forest { box-shadow: inset 0 0 0 2px rgba(37, 79, 26, 0.34); color: var(--forest); }
.btn-ghost-white { box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.4); color: var(--white); }

/* ---------- masthead: lime band, nav + title, shared by index / about / legal ---------- */

.mast { padding-top: 72px; padding-bottom: 88px; }
.mast .sect { color: var(--forest); max-width: 820px; }
.mast .sub { color: rgba(37, 79, 26, 0.82); margin-top: 18px; max-width: 620px; }
.mast .fine { color: rgba(37, 79, 26, 0.72); margin-top: 18px; }
.mast .cta-row { margin-top: 34px; }

/* ---------- closing band: berry, before the footer panel ---------- */

.close { padding-top: 100px; padding-bottom: 64px; text-align: center; }
.close .sect { color: var(--lilac); max-width: 760px; margin: 0 auto; }
.close .sub { color: rgba(233, 192, 233, 0.82); margin: 18px auto 0; max-width: 560px; }
.close .cta-row { justify-content: center; margin-top: 32px; }

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

.toc { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }

.toc span, .toc a {
  background: rgba(37, 79, 26, 0.12);
  color: var(--forest);
  border-radius: var(--r-pill);
  padding: 9px 16px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-decoration: none;
}

/* ---------- centred section heading ---------- */

.feat { padding-top: 96px; padding-bottom: 104px; }
.feat-head { text-align: center; max-width: 760px; margin: 0 auto; }
.feat-head .body { margin: 20px auto 0; max-width: 560px; color: var(--mute); }

/* ======================================================================
   APP SHOWCASE — saturated cards, icon at top, meta at the foot
   ====================================================================== */

.apps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 56px;
}

.fcard {
  border-radius: 40px;
  padding: 36px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.fcard-lilac { background: var(--lilac); color: var(--berry); }
.fcard-lime { background: var(--lime); color: var(--forest); }
.fcard-blue { background: var(--blue); color: var(--white); }
.fcard-sage { background: var(--sage); color: var(--forest); }
.fcard-gold { background: var(--gold); color: var(--ink); }
.fcard-purple { background: var(--purple); color: var(--lilac); }

.ficon {
  width: 72px;
  height: 72px;
  border-radius: 22px;
  object-fit: cover;
  box-shadow: 0 12px 26px -12px rgba(30, 35, 48, 0.35);
}

/* icons with transparent edges get a white backing tile so they don't just
   fade into the saturated card behind them */
.ficon-tile {
  width: 72px;
  height: 72px;
  border-radius: 22px;
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  box-shadow: 0 12px 26px -12px rgba(30, 35, 48, 0.35);
}

.ficon-tile .ficon {
  width: 100%;
  height: 100%;
  object-fit: contain;
  box-shadow: none;
  border-radius: 0;
}

.fstatus {
  align-self: flex-start;
  border-radius: var(--r-pill);
  padding: 8px 15px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin-top: 20px;
  background: rgba(255, 255, 255, 0.32);
}

.fcard .ftitle {
  margin: 20px 0 0;
  font-size: 26px;
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.fcard .fsub {
  margin: 10px 0 0;
  font-size: 15.5px;
  line-height: 1.5;
  letter-spacing: -0.01em;
  opacity: 0.78;
}

.flinks { display: flex; gap: 8px; margin-top: 20px; }

.flinks a {
  background: rgba(255, 255, 255, 0.34);
  border-radius: var(--r-pill);
  padding: 8px 14px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: inherit;
}

.fbadges { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: auto; padding-top: 24px; }
.fbadges img { height: 46px; width: auto; }
.fbadges.coming-soon { opacity: 0.45; }
.fbadges .coming-soon-label { font-size: 13px; font-weight: 700; letter-spacing: -0.01em; }

/* ---------- prose sections (about page) ---------- */

.prose-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 56px; }

.prose-card {
  background: var(--white);
  border-radius: var(--r-card);
  padding: 32px;
}

.prose-card h3 { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); margin: 0 0 12px; }
.prose-card p { font-size: 16px; line-height: 1.6; letter-spacing: -0.01em; color: #43485a; margin: 0 0 12px; }
.prose-card p:last-child { margin-bottom: 0; }

.info-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-top: 24px; }

.info-tile {
  background: var(--sage);
  border-radius: var(--r-card);
  padding: 24px 26px;
}

.info-tile h4 {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--forest);
  opacity: 0.72;
  margin: 0 0 10px;
}

.info-tile p { font-size: 17px; font-weight: 700; color: var(--ink); margin: 0; }
.info-tile a { color: var(--ink); text-decoration: none; }
.info-tile a:hover { text-decoration: underline; }

/* ======================================================================
   LEGAL PAGES
   ====================================================================== */

.legal-body { padding-top: 80px; padding-bottom: 96px; }
.legal-col { max-width: 780px; }

.legal-lede {
  font-size: 21px;
  line-height: 1.45;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0 0 12px;
}

.legal-col h2 {
  font-size: 26px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 48px 0 14px;
}

.legal-col h3 {
  font-size: 19px;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 30px 0 12px;
}

.legal-col p {
  font-size: 17px;
  line-height: 1.62;
  letter-spacing: -0.01em;
  color: #43485a;
  margin: 0 0 14px;
}

.legal-col ul, .legal-col ol { margin: 0 0 14px; padding-left: 22px; }

.legal-col li {
  font-size: 17px;
  line-height: 1.62;
  letter-spacing: -0.01em;
  color: #43485a;
  margin-bottom: 9px;
}

.legal-col strong { color: var(--ink); font-weight: 700; }

.legal-col table {
  width: 100%;
  border-collapse: collapse;
  margin: 8px 0 24px;
  background: var(--white);
  border-radius: var(--r-inset);
  overflow: hidden;
}

.legal-col th, .legal-col td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid rgba(30, 35, 48, 0.08);
  font-size: 15px;
}

.legal-col th { background: var(--sage); color: var(--forest); font-weight: 700; }
.legal-col td { color: #43485a; }

.legal-note {
  background: var(--sage);
  border-radius: var(--r-card);
  padding: 28px 32px;
  margin: 8px 0 8px;
}

.legal-note .legal-note-t {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--forest);
  margin-bottom: 8px;
}

.legal-note p { margin: 0; color: #3a4633; }

.legal-caution {
  background: rgba(120, 0, 22, 0.06);
  box-shadow: inset 0 0 0 1.5px rgba(120, 0, 22, 0.18);
  border-radius: var(--r-card);
  padding: 24px 28px;
  margin: 8px 0 8px;
}

.legal-caution p { margin: 0; color: var(--berry); font-weight: 600; }

.legal-close {
  margin-top: 32px;
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
}

/* ---------- white footer panel sitting on the berry band ---------- */

.foot-wrap { padding-bottom: 56px; }

.foot {
  background: var(--white);
  color: var(--ink);
  border-radius: var(--r-panel);
  padding: 30px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.foot-links { display: flex; align-items: center; gap: 24px; font-size: 14px; font-weight: 500; color: var(--mute); }
.foot-links a { color: var(--mute); text-decoration: none; }
.foot-links a:hover { color: var(--ink); }
.foot .fine { color: var(--mute); }

/* ======================================================================
   RESPONSIVE
   ====================================================================== */

@media (max-width: 1180px) {
  .wrap { padding-left: 40px; padding-right: 40px; }
  .prose-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .nav-links { display: none; }
  .apps-grid { grid-template-columns: 1fr; }
  .feat, .mast, .legal-body { padding-top: 64px; padding-bottom: 64px; }
}

@media (max-width: 680px) {
  .wrap { padding-left: 20px; padding-right: 20px; }
  .nav { min-height: 62px; padding-left: 20px; }
  .nav-cta { height: 44px; padding: 0 20px; font-size: 14px; }
  .wordmark { font-size: 19px; }

  .fcard { padding: 28px; border-radius: 32px; }
  .fcard .ftitle { font-size: 23px; }

  .foot {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding: 26px;
    border-radius: 36px;
  }

  .foot-links { flex-wrap: wrap; gap: 16px; }
}

@media (max-width: 900px) {
  .foot-links { margin: -8px -12px; }
  .foot-links a, .foot-links span {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 12px;
  }
  .brand { min-height: 44px; }
}
