/* SoleroTone - all styles for every page.
   Colours live here as variables: change one line to recolour the whole site. */

:root {
  --bg: #161514;          /* charcoal-black (page background) */
  --bg-2: #1f1e1c;        /* slightly lighter charcoal (panels) */
  --ink: #f3efe8;         /* warm white (text, light section) */
  --ink-dim: #a7a198;     /* secondary text on dark */
  --orange: #ff6b1a;      /* SoleroTone orange */
  --orange-deep: #e2550a; /* hover / text on light backgrounds */
  --line: rgba(243, 239, 232, 0.12);

  --font: "Archivo", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --gutter: clamp(16px, 4vw, 48px);
  --radius: 14px;
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }

/* Small monospace label, like printing on a synth panel */
.label {
  display: inline-flex; align-items: center; gap: 0.6em;
  margin: 0 0 1.25rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.label__wave { /* small square-wave symbol before the label */
  width: 22px; height: 10px;
  fill: none; stroke: var(--orange); stroke-width: 1.5;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px;
  padding: 0 1.5rem;
  border-radius: 999px;
  font: 600 0.95rem/1 var(--font);
  font-stretch: 110%;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s, transform 0.2s;
}
.btn--solid { background: var(--orange); color: #161514; border: 0; }
.btn--solid:hover { background: var(--ink); }
.btn--ghost { border: 1px solid var(--line); color: var(--ink); background: transparent; min-height: 40px; padding: 0 1.1rem; }
.btn--ghost:hover { border-color: var(--orange); color: var(--orange); }

/* ---------- Header ---------- */
.site-header {
  position: absolute; top: 0; left: 0; right: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px var(--gutter);
}
.site-header--solid { position: static; border-bottom: 1px solid var(--line); }

/* Brand switcher: SoleroTone + SoleroSupply logos. The active brand shows its title;
   the other is just a grey logo. Sizes/offsets match Larnce's "LOGO AND TITLE" SVGs. */
.brands { --h: 28px; display: flex; align-items: flex-start; gap: 14px; }
.brands__item {
  position: relative;
  display: flex; align-items: flex-start;
  padding: 0; border: 0; background: none; color: inherit;
  text-decoration: none; cursor: pointer;
}
.brands__mark {
  height: var(--h); width: auto;
  opacity: 0.3;
  transition: opacity 0.35s;
}
.brands__item:hover .brands__mark { opacity: 0.6; }
.brands__item.is-active .brands__mark { opacity: 1; }

.brands__title {
  display: block; overflow: hidden;
  width: 0; margin-left: 0;
  opacity: 0;
  transition: width 0.55s cubic-bezier(0.65, 0, 0.35, 1), margin-left 0.55s cubic-bezier(0.65, 0, 0.35, 1), opacity 0.35s;
}
.brands__title img { display: block; height: 100%; width: auto; max-width: none; }
.brands__item.is-active .brands__title { margin-left: calc(var(--h) * 0.186); opacity: 1; transition-delay: 0.1s; }

[data-brand="tone"] .brands__title { height: calc(var(--h) * 0.715); margin-top: calc(var(--h) * 0.138); }
[data-brand="tone"].is-active .brands__title { width: calc(var(--h) * 4.856); }
[data-brand="supply"] .brands__title { height: calc(var(--h) * 0.929); margin-top: calc(var(--h) * 0.147); }
[data-brand="supply"].is-active .brands__title { width: calc(var(--h) * 5.545); }

.brands__soon {
  position: absolute; left: calc(var(--h) * 1.1); top: calc(var(--h) + 10px);
  font-family: var(--mono); font-size: 0.65rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--orange); white-space: nowrap;
  opacity: 0; transform: translateY(-4px);
  transition: opacity 0.3s, transform 0.3s;
  pointer-events: none;
}
.brands__item.is-active .brands__soon { opacity: 1; transform: none; transition-delay: 0.4s; }

@media (prefers-reduced-motion: reduce) {
  .brands__title, .brands__mark, .brands__soon { transition: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  align-content: end;
  gap: 32px;
  padding: 120px var(--gutter) clamp(32px, 6vw, 64px);
  overflow: hidden;
  /* oscilloscope graticule */
  background:
    linear-gradient(var(--line) 1px, transparent 1px) 0 50% / 100% 12.5%,
    linear-gradient(90deg, var(--line) 1px, transparent 1px) 50% 0 / 10% 100%,
    radial-gradient(ellipse at 50% 45%, #232120 0%, var(--bg) 70%);
}
.hero::after { /* soft vignette so text stays readable over the trace */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(22,21,20,0.85) 0%, rgba(22,21,20,0) 55%);
}
.scope { position: absolute; top: 0; left: 0; width: 100%; } /* top + height set by js/main.js */

.hero__content { position: relative; z-index: 2; }
.hero__content { max-width: 720px; }

.hero__title {
  margin: 0 0 1.25rem;
  font-size: clamp(3rem, 9vw, 7.75rem);
  font-weight: 800;
  font-stretch: 112%;
  line-height: 0.92;
  letter-spacing: -0.035em;
}
.hero__lede { max-width: 34em; margin: 0 0 2rem; color: var(--ink-dim); font-size: 1.15rem; }

/* ---------- Ticker strip ---------- */
.ticker {
  overflow: hidden;
  background: var(--orange);
  color: #161514;
  padding: 14px 0;
}
.ticker__track {
  display: flex; width: max-content;
  animation: ticker 100s linear infinite;
  will-change: transform;
}
.ticker span {
  display: inline-flex; align-items: center;
  font-weight: 800; font-stretch: 120%; font-style: italic;
  font-size: 1.05rem; text-transform: uppercase; letter-spacing: 0.02em;
  white-space: nowrap;
}
.ticker span::after { /* square-wave symbol between words (same shape as the hero label) */
  content: ""; width: 1.4em; height: 0.65em; margin: 0 1.4rem;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 10'%3E%3Cpath d='M1 9V1h5v8h5V1h5v8h5' fill='none' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 10'%3E%3Cpath d='M1 9V1h5v8h5V1h5v8h5' fill='none' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E") center / contain no-repeat;
}
@keyframes ticker { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker__track { animation: none; } }

/* ---------- The story ---------- */
.story { padding: clamp(72px, 12vw, 140px) var(--gutter) 0; }
.story__grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: start; }
.story__statement {
  margin: 0;
  font-size: clamp(2rem, 4.4vw, 3.75rem); font-weight: 800; font-stretch: 112%;
  line-height: 1; letter-spacing: -0.03em;
}
.story__body p { margin: 0 0 1.25rem; color: var(--ink-dim); font-size: 1.15rem; }
.story__body p:first-child { color: var(--ink); }

/* ---------- Principles ---------- */
.principles { padding: clamp(56px, 9vw, 110px) var(--gutter) clamp(72px, 12vw, 140px); }
.section-title {
  margin: 0 0 clamp(32px, 6vw, 64px);
  font-family: var(--mono); font-weight: 500;
  font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-dim);
}
.principles__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 4vw, 56px); }
.principle { border-top: 1px solid var(--line); padding-top: 24px; }
.principle__num { font-family: var(--mono); font-size: 0.8rem; color: var(--orange); }
.principle h3 {
  margin: 0.75rem 0 0.75rem;
  font-size: clamp(1.6rem, 2.6vw, 2.2rem); font-weight: 700; font-stretch: 110%;
  line-height: 1.05; letter-spacing: -0.02em;
}
.principle p { margin: 0; color: var(--ink-dim); }

/* ---------- Signup (light section) ---------- */
.signup {
  background: var(--ink);
  color: #161514;
  padding: clamp(72px, 12vw, 140px) var(--gutter);
}
.signup__inner { max-width: 1000px; }
.signup__title {
  margin: 0 0 1rem;
  font-size: clamp(2.5rem, 7vw, 5.5rem); font-weight: 800; font-stretch: 112%;
  line-height: 0.95; letter-spacing: -0.035em;
}
.signup__lede { margin: 0 0 2rem; color: #4d4943; max-width: 36em; }

.signup__form { display: flex; gap: 10px; max-width: 560px; }
.signup__form input {
  flex: 1; min-width: 0; min-height: 52px;
  padding: 0 1.25rem;
  border: 1.5px solid #cfc8bc; border-radius: 999px;
  background: #fff; color: #161514;
  font: 1rem var(--font);
}
.signup__form input:focus { outline: none; border-color: var(--orange-deep); }
.signup__form .btn { min-height: 52px; }
.signup__form .btn--solid:hover { background: #161514; color: var(--ink); }
.signup__form.is-sending .btn { opacity: 0.6; pointer-events: none; }

.signup__status { min-height: 1.6em; margin: 0.75rem 0 0; font-weight: 600; }
.signup__status.is-error { color: #b42318; }
.signup__privacy { margin: 0.5rem 0 0; font-size: 0.85rem; color: #6b665e; }

/* ---------- Footer ---------- */
.site-footer {
  display: flex; align-items: center; gap: 14px;
  padding: 28px var(--gutter);
  border-top: 1px solid var(--line);
  font-family: var(--mono); font-size: 0.75rem; color: var(--ink-dim);
}
.site-footer p { margin: 0; flex: 1; }
.site-footer__mark { width: 20px; height: auto; opacity: 0.9; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--orange); }
.site-footer__links { display: flex; align-items: center; gap: 22px; }
.site-footer__larnce { display: inline-flex; padding-left: 22px; border-left: 1px solid var(--line); }
.site-footer__larnce img { height: 22px; width: auto; opacity: 0.6; transition: opacity 0.2s; }
.site-footer__larnce:hover img { opacity: 1; }

/* ---------- Simple text pages (privacy) ---------- */
.prose { max-width: 680px; padding: clamp(48px, 8vw, 96px) var(--gutter); }
.prose h1 { margin: 0 0 1.5rem; font-size: clamp(2.5rem, 6vw, 4rem); font-weight: 800; font-stretch: 112%; letter-spacing: -0.03em; line-height: 1; }
.prose h2 { margin: 2.5rem 0 0.5rem; font-size: 1.35rem; font-stretch: 110%; }
.prose p { color: var(--ink-dim); }
.prose p a:not(.btn) { color: var(--ink); text-decoration-color: var(--orange); text-underline-offset: 3px; }
.prose .btn { margin-top: 1.5rem; }

/* ---------- Mobile ---------- */
@media (max-width: 860px) {
  .hero { padding-top: 104px; }
  .principles__grid { grid-template-columns: 1fr; }
  .story__grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .brands { --h: 22px; gap: 10px; }
  .site-header .btn--ghost { padding: 0 0.9rem; font-size: 0.85rem; }
  .signup__form { flex-direction: column; }
  .site-footer { flex-wrap: wrap; }
  .site-footer p { flex-basis: calc(100% - 40px); }
  .site-footer__links { width: 100%; padding-left: 34px; }
}
