/* Nawal download site.
 *
 * Palette is taken from the app's own mark (Nawal/Views/Components/BrandMark.swift)
 * so the site and the product look like the same thing. This design commits to
 * the dark brand ground on purpose — the mark is a neon triad on deep-space
 * violet and there is no light-mode version of it.
 */

:root {
  --bg-top:    #16092B;   /* Brand.cyberBGTop    */
  --bg-bottom: #050410;   /* Brand.cyberBGBottom */
  --cyan:      #21E7FF;
  --magenta:   #FF2D87;
  --violet:    #9B5CFF;
  --hot:       #E9FDFF;

  --text:      #E9EDF5;
  --text-dim:  #9BA3B8;
  --surface:   rgba(255, 255, 255, 0.04);
  --border:    rgba(155, 92, 255, 0.28);

  --measure: 62ch;
  --radius: 14px;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/IBMPlexMono-SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

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

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, var(--bg-top) 0%, var(--bg-bottom) 55%) no-repeat;
  background-color: var(--bg-bottom);
  color: var(--text);
  font: 400 17px/1.65 ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI",
        Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 1rem; top: 1rem;
  z-index: 10;
  padding: 0.6rem 1rem;
  background: var(--bg-top);
  color: var(--text);
  border-radius: 8px;
  border: 1px solid var(--cyan);
}

/* --- header --------------------------------------------------------------- */

.site {
  max-width: 1040px;
  margin: 0 auto;
  padding: 1.75rem 1.5rem 0;
}
.brand { display: flex; align-items: center; gap: 0.7rem; }
.mark { border-radius: 8px; display: block; }
.wordmark {
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: 0.16em;
}

/* --- hero ----------------------------------------------------------------- */

.hero {
  max-width: 1040px;
  margin: 0 auto;
  padding: 3.5rem 1.5rem 1rem;
  text-align: center;
}
.hero-mark {
  border-radius: 26px;
  margin-bottom: 1.75rem;
  box-shadow: 0 0 60px rgba(33, 231, 255, 0.16),
              0 0 120px rgba(255, 45, 135, 0.10);
}
h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 6vw, 3.25rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-weight: 650;
}
.lede {
  max-width: var(--measure);
  margin: 0 auto 2.25rem;
  color: var(--text-dim);
  font-size: 1.06rem;
}

/* --- download ------------------------------------------------------------- */

.download {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  padding: 1rem 2.25rem;
  border-radius: var(--radius);
  text-decoration: none;
  color: #08010F;
  background: linear-gradient(135deg, var(--cyan), var(--violet));
  box-shadow: 0 8px 30px rgba(33, 231, 255, 0.22);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.download:hover { transform: translateY(-2px); box-shadow: 0 12px 38px rgba(33, 231, 255, 0.3); }
.download:focus-visible { outline: 3px solid var(--hot); outline-offset: 3px; }
.download-main { font-size: 1.12rem; font-weight: 700; letter-spacing: -0.01em; }
.download-meta { font-size: 0.82rem; font-weight: 600; opacity: 0.72; }

.price {
  max-width: 48ch;
  margin: 1.15rem auto 0;
  color: var(--text);
  font-size: 0.95rem;
}
.price strong { color: var(--cyan); }

.requirements {
  max-width: 48ch;
  margin: 0.9rem auto 0;
  color: var(--text-dim);
  font-size: 0.9rem;
}

/* --- features ------------------------------------------------------------- */

.features {
  max-width: 1040px;
  margin: 4.5rem auto 0;
  padding: 0 1.5rem;
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.feature {
  padding: 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.feature h2 {
  margin: 0 0 0.6rem;
  font-size: 1.02rem;
  letter-spacing: 0.01em;
  color: var(--hot);
}
.feature p { margin: 0; color: var(--text-dim); font-size: 0.94rem; }

/* --- platforms ------------------------------------------------------------ */

.download.pending {
  cursor: default;
  opacity: 0.75;
}
.direct {
  margin: 0.9rem 0 0;
  font-size: 0.9rem;
  color: var(--text-dim);
}
.direct a { color: inherit; }

.cli {
  max-width: 1040px;
  margin: 4.5rem auto 0;
  padding: 0 1.5rem;
}
.cli h2 {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--text-dim);
  margin: 0 0 1rem;
  font-weight: 600;
}
.cli p {
  max-width: 640px;
  margin: 0;
  color: var(--text-dim);
  line-height: 1.6;
}
.cli code {
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 0.92em;
}

.platforms {
  max-width: 1040px;
  margin: 4.5rem auto 0;
  padding: 0 1.5rem;
}
.platforms h2 {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--text-dim);
  margin: 0 0 1rem;
  font-weight: 600;
}
.tiles {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.tile {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 1.25rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
}
.tile-name { font-size: 1.05rem; font-weight: 650; }
.tile-state { font-size: 0.85rem; font-weight: 600; }
.tile-detail { font-size: 0.82rem; color: var(--text-dim); }

.tile.available { border-color: rgba(33, 231, 255, 0.5); }
.tile.available .tile-state { color: var(--cyan); }

.tile.soon { opacity: 0.66; }
.tile.soon .tile-state { color: var(--magenta); }

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

.site-footer {
  max-width: 1040px;
  margin: 5rem auto 0;
  padding: 2rem 1.5rem 3rem;
  border-top: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 0.85rem;
}
.site-footer p { margin: 0 0 0.4rem; }
.hash { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.fine { font-size: 0.8rem; opacity: 0.8; }
.site-footer a { color: var(--cyan); text-decoration-thickness: 1px; text-underline-offset: 2px; }
.site-footer a:hover { color: var(--hot); }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  .download:hover { transform: none; }
}
