/* hotwire.audio landing page */

:root {
  color-scheme: dark;
  --bg: #05060a;
  --bg2: #0b0e17;
  --fg: #eef1f7;
  --dim: #8a93a8;
  --dim2: #5d667a;
  --line: rgba(255, 255, 255, 0.08);
  --glass: rgba(255, 255, 255, 0.04);
  --accent: #4ea1ff;
  /* the cable rainbow - also used by the wordmark and the primary button ring */
  --rainbow: #ff3b5c, #ff8a2b, #ffd23b, #3bff8a, #2bd2ff, #6b7bff, #d85bff, #ff3b5c;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sans: system-ui, -apple-system, "Segoe UI", Inter, Roboto, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 400 16px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
}

body { overflow-x: hidden; }

a { color: inherit; }

/* ---------------------------------------------------------------- backdrop */
#wires {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
}

.grain {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.35;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.5 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

main { position: relative; z-index: 2; }

/* ---------------------------------------------------------------- hero */
/* top two thirds: Hotwire. bottom third: xfEdit. */
.hero {
  min-height: 66svh;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 0.9rem;
  padding: clamp(1.5rem, 4vh, 3rem) 1.25rem 1.5rem;
  text-align: center;
}

.brand {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
}

.wordmark {
  position: relative;
  margin: 0;
  font-size: clamp(3rem, 11vw, 8.5rem);
  font-weight: 900;
  letter-spacing: 0.12em;
  margin-right: -0.12em;
  line-height: 0.95;
  text-transform: uppercase;
  background: linear-gradient(100deg, var(--rainbow));
  background-size: 300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: hue 14s linear infinite;
  filter: drop-shadow(0 0 18px rgba(255, 120, 60, 0.35)) drop-shadow(0 0 60px rgba(60, 120, 255, 0.25));
}

/* a second, blurred copy underneath = the neon bloom */
.wordmark::before {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  z-index: -1;
  background: inherit;
  background-size: inherit;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: blur(22px) saturate(1.6);
  opacity: 0.55;
  animation: inherit;
}

@keyframes hue {
  to { background-position: 300% 0; }
}

.chip {
  margin-top: 0.9em;
  padding: 0.3em 0.7em 0.26em;
  font: 700 0.62rem/1 var(--mono);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
}

.tagline {
  margin: 0;
  max-width: 44ch;
  color: var(--dim);
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  text-wrap: balance;
}

.tagline em { color: var(--fg); font-style: italic; }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  padding: 0.9rem 1.6rem;
  border-radius: 14px;
  text-decoration: none;
  font-weight: 600;
  letter-spacing: 0.01em;
  border: 1px solid var(--line);
  background: var(--glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  will-change: transform;
}

.btn:hover { transform: translateY(-2px); background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.18); }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.btn-primary {
  position: relative;
  isolation: isolate;
  padding: 1.15rem 2.6rem 1rem;
  font-size: 1.35rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #0b0e17;
  background: transparent;
  border: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  filter: drop-shadow(0 0 22px rgba(255, 170, 90, 0.35)) drop-shadow(0 12px 30px rgba(0, 0, 0, 0.5));
}

/* rotating rainbow ring (bottom layer) ... */
.btn-primary::before {
  content: "";
  position: absolute;
  inset: -3px;
  z-index: -2;
  border-radius: 17px;
  background: conic-gradient(from var(--a, 0deg), var(--rainbow));
  animation: spin 4s linear infinite;
}

/* ... with the white face on top of it, leaving a 3px rainbow rim */
.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: 14px;
  background: #f4f6fb;
  transition: background 0.18s ease;
}

@property --a { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@keyframes spin { to { --a: 360deg; } }

.btn-primary:hover { transform: translateY(-2px) scale(1.02); }
.btn-primary:hover::after { background: #ffffff; }

.btn-primary .btn-sub {
  font: 500 0.7rem/1.2 var(--mono);
  letter-spacing: 0.04em;
  text-transform: none;
  color: #4d566b;
}

.btn-ghost {
  flex-direction: row;
  gap: 0.5rem;
  padding: 0.7rem 1.2rem;
  font-size: 0.95rem;
  color: var(--fg);
}

.discord { color: #c7cbff; border-color: rgba(114, 137, 218, 0.4); }
.discord:hover { background: rgba(114, 137, 218, 0.16); border-color: rgba(114, 137, 218, 0.7); }

/* ---------------------------------------------------------------- downloads */
.cta {
  display: grid;
  justify-items: center;
  gap: 1.6rem;
  margin-top: 0.6rem;
}

.dl-group { display: grid; gap: 0.6rem; justify-items: center; }

.dl-head {
  display: flex;
  align-items: baseline;
  gap: 0.8rem;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim2);
}

.dl-meta {
  font: 600 0.78rem/1 var(--mono);
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--fg);
  padding: 0.35em 0.6em;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
}

.dl-meta .d { color: var(--dim); }
.dl-meta .d::before { content: "·"; margin: 0 0.5em; color: var(--dim2); }

.dl-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
}

.btn-dl {
  min-width: 11.5rem;
  padding: 0.8rem 1.2rem;
  align-items: flex-start;
  text-align: left;
}

.btn-dl .dl-os { font-size: 1rem; }

.btn-dl .dl-detail {
  font: 500 0.7rem/1.3 var(--mono);
  color: var(--dim);
  letter-spacing: 0.02em;
}

.btn-dl .dl-size { color: var(--dim2); }
.btn-dl .dl-size::before { content: "·"; margin: 0 0.45em; }

.btn-dl.soon {
  pointer-events: none;
  opacity: 0.5;
  border-style: dashed;
}

.btn-dl.soon .dl-detail::after {
  content: "coming soon";
  display: block;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.dl-folder {
  font: 500 0.75rem/1 var(--mono);
  color: var(--dim);
  text-decoration: none;
  border-bottom: 1px dotted var(--dim2);
}
.dl-folder:hover { color: var(--fg); }

/* ---------------------------------------------------------------- notes */
.note {
  margin: 0.8rem 0 0;
  max-width: 52ch;
  color: var(--dim);
  font-size: 0.92rem;
  text-wrap: balance;
}

.scroll-hint {
  display: none;
  align-self: end;
  margin-top: 3rem;
  justify-items: center;
  gap: 0.5rem;
  color: var(--dim2);
  font: 500 0.75rem/1 var(--mono);
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.scroll-hint i {
  width: 1px;
  height: 42px;
  background: linear-gradient(to bottom, var(--dim2), transparent);
  animation: drip 2.2s ease-in-out infinite;
}

@keyframes drip {
  0%, 100% { transform: scaleY(0.4); transform-origin: top; opacity: 0.4; }
  50% { transform: scaleY(1); opacity: 1; }
}

/* ---------------------------------------------------------------- xfEdit */
.xfedit {
  position: relative;
  min-height: 34svh;
  display: grid;
  align-content: center;
  padding: clamp(1.25rem, 3vh, 2.5rem) 1.25rem clamp(1rem, 2vh, 1.5rem);
  border-top: 1px solid var(--line);
  background:
    linear-gradient(to bottom, rgba(5, 6, 10, 0.78), rgba(5, 6, 10, 0.92) 40%, var(--bg));
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.xf-grid {
  width: min(1240px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(220px, 26vw) minmax(0, 1fr);
  gap: clamp(1.25rem, 3vw, 3rem);
  align-items: center;
}

.xf-shot {
  margin: 0;
  position: relative;
  border-radius: 14px;
  perspective: 1200px;
}

.xf-shot img {
  display: block;
  width: 100%;
  max-height: 26svh;
  height: auto;
  object-fit: contain;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(0, 0, 0, 0.6),
    0 0 120px rgba(255, 140, 50, 0.12);
  transform: rotateY(var(--ry, -6deg)) rotateX(var(--rx, 3deg));
  transition: transform 0.25s ease;
}

.xf-shot:hover img { --ry: 0deg; --rx: 0deg; }

.xf-copy h2 {
  margin: 0 0 0.3rem;
  font-size: clamp(1.3rem, 2.2vw, 1.9rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.xf-name {
  font-weight: 900;
  background: linear-gradient(90deg, #ffb13b, #ff6a3b, #ffd23b);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.xf-lede { margin: 0 0 0.9rem; color: var(--dim); font-size: 0.95rem; text-wrap: pretty; }
.xf-lede b { color: var(--fg); }

.xf-copy .dl-group { justify-items: start; }
.xf-copy .dl-row { justify-content: flex-start; }
.dl-row-4 .btn-dl { min-width: 9.5rem; padding: 0.6rem 1rem; }
.dl-row-4 .btn-dl .dl-os { font-size: 0.92rem; }

/* ---------------------------------------------------------------- footer */
footer {
  padding: 0.6rem 1.25rem 1rem;
  background: var(--bg);
  text-align: center;
  color: var(--dim2);
  font-size: 0.8rem;
}

footer a { color: var(--dim); text-decoration: none; border-bottom: 1px dotted var(--dim2); }
footer a:hover { color: var(--fg); }
footer .sep { margin: 0 0.6em; }

/* ---------------------------------------------------------------- responsive / motion */
@media (max-width: 860px) {
  .hero { min-height: 100svh; }
  .xfedit { min-height: 0; }
  .xf-grid { grid-template-columns: 1fr; }
  .xf-shot img { max-height: none; }
  .xf-copy .dl-group { justify-items: center; }
  .xf-copy .dl-row { justify-content: center; }
  .xf-copy { text-align: center; }
  .xf-shot img { --ry: 0deg; --rx: 0deg; }
}

@media (max-width: 520px) {
  .btn-dl { min-width: calc(50% - 0.3rem); }
  .btn-primary { font-size: 1.15rem; padding-inline: 1.8rem; }
}

@media (prefers-reduced-motion: reduce) {
  .wordmark, .wordmark::before, .btn-primary::before, .btn-primary::after, .scroll-hint i { animation: none; }
  .btn, .xf-shot img { transition: none; }
}
