/* ============================================================
   Torn Metal — Direction B (Atelier)
   Editorial / typographic. Serif display + mono platform labels.
   ============================================================ */

:root {
  --bg: #0d0d10;
  --ink: #f4f1ea;
  --dim: rgba(244, 241, 234, 0.55);
  --dim-strong: rgba(244, 241, 234, 0.75);
  --line: rgba(244, 241, 234, 0.10);
  --accent: #22C55E;

  --serif: "Instrument Serif", "Times New Roman", Times, serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --sans: "Geist", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --gutter: 56px;
  --side-col: 120px;
}

@media (max-width: 900px) {
  :root {
    --gutter: 24px;
    --side-col: 88px;
  }
}

@media (max-width: 640px) {
  :root {
    --gutter: 18px;
  }
}

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

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: inherit; }

.at-accent { color: var(--accent); font-style: italic; }
.at-h1__dim { color: var(--dim); font-style: italic; }

/* Platform chips — horizontal pill: icon left, full product name right ---- */
.at-chip {
  display: inline-flex;
  align-items: center;
  background: transparent;
  color: var(--ink);
  border: 1px solid rgba(244, 241, 234, 0.22);
  flex: 0 0 auto;
  font-family: var(--mono);
  line-height: 1;
  white-space: nowrap;
}
.at-chip--inverted {
  background: var(--accent);
  color: var(--bg);
  border-color: transparent;
}
.at-chip__glyph {
  fill: none;
  stroke: currentColor;
  stroke-width: var(--gw, 2);
  stroke-linejoin: round;
  display: block;
  flex: 0 0 auto;
}
.at-chip__glyph .d-thin { stroke-width: calc(var(--gw, 2) * 0.43); }
.at-chip__glyph .d-stub { stroke-width: calc(var(--gw, 2) * 0.93); }
.at-chip__glyph .notch { fill: var(--bg); }
.at-chip--inverted .at-chip__glyph .notch { fill: var(--accent); }

.at-chip__label {
  font-family: var(--mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1;
  font-weight: 500;
  white-space: nowrap;
}

.at-chip--sm {
  height: 28px;
  padding: 0 12px 0 10px;
  gap: 7px;
  border-radius: 3px;
}
.at-chip--sm .at-chip__glyph { width: 15px; height: 15px; --gw: 1.5; }
.at-chip--sm .at-chip__label { font-size: 10px; }

.at-chip--md {
  height: 38px;
  padding: 0 18px 0 14px;
  gap: 10px;
  border-radius: 4px;
}
.at-chip--md .at-chip__glyph { width: 20px; height: 20px; --gw: 2; }
.at-chip--md .at-chip__label { font-size: 11.5px; }

.at-chip--lg {
  height: 56px;
  padding: 0 26px 0 20px;
  gap: 14px;
  border-radius: 6px;
}
.at-chip--lg .at-chip__glyph { width: 30px; height: 30px; --gw: 3; }
.at-chip--lg .at-chip__label { font-size: 14px; }

/* ============================ NAV ============================ */
.at-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(13, 13, 16, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line);
}
.at-nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px var(--gutter);
}
.at-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--ink);
}
.at-brand__mark {
  width: 32px;
  height: 32px;
  border: 1px solid var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  flex: 0 0 auto;
}
.at-brand__name {
  font-family: var(--serif);
  font-style: italic;
  font-size: 26px;
  line-height: 1;
  letter-spacing: -0.005em;
  white-space: nowrap;
}
.at-brand__divider {
  width: 1px;
  height: 18px;
  background: var(--line);
  margin-left: 6px;
}
.at-brand__vol {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--dim);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
}
.at-nav__links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.at-nav__links a {
  color: var(--ink);
  text-decoration: none;
}
.at-nav__links a:hover { color: var(--accent); }
.at-nav__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid var(--accent);
  color: var(--accent) !important;
}
.at-nav__dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  display: inline-block;
}

@media (max-width: 760px) {
  .at-brand__vol, .at-brand__divider { display: none; }
  .at-nav__links { gap: 16px; }
  .at-nav__links a:not(.at-nav__cta) { display: none; }
}

/* ============================ GRID ============================ */
.at-grid {
  display: grid;
  gap: 32px;
}
.at-grid--mast {
  grid-template-columns: var(--side-col) 1fr 280px;
  align-items: flex-start;
}
.at-grid--head {
  grid-template-columns: var(--side-col) 1fr auto;
  align-items: baseline;
}
.at-grid--app {
  grid-template-columns: var(--side-col) 128px 1fr 240px;
  align-items: flex-start;
}
.at-grid--app-big {
  grid-template-columns: var(--side-col) 180px 1fr 320px;
}
.at-grid--key {
  grid-template-columns: var(--side-col) 1fr;
  align-items: flex-start;
}

.at-side {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.6;
}
.at-side--right { text-align: right; }
.at-side--top { padding-top: 0; }
.at-side__id { opacity: 0.7; }

/* ============================ MASTHEAD ============================ */
.at-masthead {
  padding: 80px var(--gutter) 56px;
  border-bottom: 1px solid var(--line);
}
.at-display {
  font-family: var(--serif);
  font-size: clamp(54px, 8vw, 116px);
  line-height: 0.94;
  letter-spacing: -0.025em;
  font-weight: 400;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.at-mast__aside { padding-top: 14px; }
.at-prose {
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--dim);
  margin: 0;
  text-wrap: pretty;
}
.at-rule {
  margin-top: 18px;
  height: 1px;
  background: var(--line);
}
.at-platform-tags {
  margin-top: 14px;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

/* ============================ BADGES ============================ */
.at-badge {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 2px;
}
.at-badge--accent {
  color: var(--accent);
  border: 1px solid var(--accent);
}

/* ============================ SECTION HEADINGS ============================ */
.at-section-heading {
  padding: 56px var(--gutter) 24px;
  border-top: 1px solid var(--line);
}
.at-h2 {
  font-family: var(--serif);
  font-size: clamp(36px, 4.5vw, 54px);
  line-height: 1.0;
  letter-spacing: -0.02em;
  font-weight: 400;
  color: var(--ink);
  margin: 0;
}

/* ============================ APP ROW ============================ */
.at-app {
  padding: 32px var(--gutter);
  border-top: 1px solid var(--line);
}
.at-app__icon img {
  width: 112px;
  height: 112px;
  border-radius: 22px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    inset 0 -1px 0 rgba(0, 0, 0, 0.25),
    0 8px 30px rgba(0, 0, 0, 0.45);
  transition: transform 0.3s ease;
}
.at-app__icon a { display: inline-block; }
.at-app__icon a:hover img { transform: scale(1.04); }

.at-app--big .at-app__icon img {
  width: 160px;
  height: 160px;
  border-radius: 32px;
}

.at-app__title-row {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}
.at-app__title {
  font-family: var(--serif);
  font-size: 42px;
  line-height: 1.0;
  letter-spacing: -0.02em;
  font-weight: 400;
  color: var(--ink);
  margin: 0;
}
.at-app__title--big { font-size: 56px; }

.at-app__blurb {
  margin-top: 14px;
  color: var(--dim);
  font-size: 15px;
  line-height: 1.55;
  max-width: 580px;
}
.at-app__blurb--big { font-size: 17px; }

.at-app__tags {
  margin-top: 22px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.at-app__links {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  padding-top: 6px;
}
.at-link {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
  text-decoration: none;
  letter-spacing: 0.10em;
  text-transform: uppercase;
}
.at-link:hover { color: var(--accent); }
.at-link--primary {
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
  padding-bottom: 2px;
}

/* ============================ PLATFORM KEY ============================ */
.at-platform-key {
  margin-top: 72px;
  padding: 56px var(--gutter);
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.015);
}
.at-key-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}
.at-key {
  border-top: 1px solid var(--line);
  padding-top: 22px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}
.at-key__count {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
  letter-spacing: 0.10em;
  text-transform: uppercase;
}

/* ============================ FOOTER ============================ */
.at-footer {
  border-top: 1px solid var(--line);
  padding: 64px var(--gutter) 32px;
}
.at-footer__top {
  display: grid;
  grid-template-columns: 1.6fr 1fr 0.7fr 0.7fr;
  gap: 40px;
  align-items: flex-start;
}
.at-footer__title {
  font-family: var(--serif);
  font-size: 36px;
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--ink);
  max-width: 360px;
}
.at-footer__intro {
  margin-top: 14px;
  font-size: 13.5px;
  color: var(--dim);
  max-width: 360px;
  line-height: 1.55;
}
.at-footer__label {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--dim);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.at-footer__links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.at-footer__links a {
  color: var(--ink);
  font-size: 13.5px;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  padding-bottom: 6px;
}
.at-footer__links a:hover { color: var(--accent); border-bottom-color: var(--accent); }

.at-footer__rule {
  margin-top: 56px;
  height: 1px;
  background: var(--line);
}
.at-footer__base {
  padding-top: 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
  letter-spacing: 0.10em;
  text-transform: uppercase;
  flex-wrap: wrap;
  gap: 12px;
}

/* ============================ BREVO NEWSLETTER OVERRIDES ============================ */
.at-sib { width: 100%; }
.at-sib .sib-form-container { background: transparent; }
.at-sib__row {
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid var(--ink);
}
.at-sib__row--soft {
  border-bottom-color: var(--line);
  margin-bottom: 14px;
}
.at-sib__input {
  background: transparent !important;
  border: none !important;
  outline: none;
  flex: 1;
  color: var(--ink) !important;
  font-size: 14px;
  padding: 8px 0;
  font-family: inherit;
  min-width: 0;
}
.at-sib__input::placeholder { color: var(--dim); }
.at-sib__submit {
  border: none !important;
  background: transparent !important;
  color: var(--ink) !important;
  font-family: var(--mono) !important;
  font-size: 11px !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  cursor: pointer;
  padding: 8px 0 8px 12px !important;
  border-radius: 0 !important;
  font-weight: 500 !important;
  white-space: nowrap;
}
.at-sib__submit:hover { color: var(--accent) !important; }
.at-sib__submit .sib-hide-loader-icon {
  width: 12px;
  height: 12px;
  fill: currentColor;
  margin-right: 6px;
  display: none;
}
/* Brevo success/error messages */
.at-sib-msg {
  display: none;
  margin-top: 12px;
  padding: 10px 12px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid;
}
.at-sib-msg--ok { color: #86EFAC; border-color: rgba(134, 239, 172, 0.4); }
.at-sib-msg--err { color: #FCA5A5; border-color: rgba(252, 165, 165, 0.4); }
.input--hidden { display: none; }

/* Hide the floating reCAPTCHA badge — we show the required notice in-form. */
/* visibility (not display) keeps the widget functional. */
.grecaptcha-badge { visibility: hidden !important; }

.at-sib__legal {
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--dim);
  letter-spacing: 0.04em;
  line-height: 1.6;
}
.at-sib__legal a {
  color: var(--dim);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.at-sib__legal a:hover {
  color: var(--ink);
  border-bottom-color: var(--dim);
}

/* ============================ ABOUT / PRIVACY shared bits ============================ */
.at-page-hero {
  padding: 80px var(--gutter);
  border-bottom: 1px solid var(--line);
}
.at-h1 {
  font-family: var(--serif);
  font-size: clamp(56px, 8.5vw, 110px);
  line-height: 0.94;
  letter-spacing: -0.025em;
  font-weight: 400;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.at-page-hero__body {
  margin-top: 56px;
  display: grid;
  grid-template-columns: var(--side-col) 1fr 1fr;
  gap: 32px;
}
.at-page-hero__body p {
  font-size: 17px;
  line-height: 1.65;
  color: var(--dim);
  margin: 0;
}

.at-numbers-section { padding: 64px var(--gutter); }
.at-numbers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.at-number {
  border-top: 1px solid var(--line);
  padding-top: 18px;
}
.at-number__v {
  font-family: var(--serif);
  font-size: 96px;
  line-height: 0.95;
  font-weight: 400;
  letter-spacing: -0.03em;
}
.at-number__l {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
  letter-spacing: 0.10em;
  text-transform: uppercase;
}

.at-privacy-rows { padding: 24px var(--gutter) 80px; }
.at-privacy-row {
  display: grid;
  grid-template-columns: var(--side-col) 240px 1fr;
  gap: 32px;
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
}
.at-privacy-row h3 {
  font-family: var(--serif);
  font-size: 36px;
  line-height: 1.05;
  font-weight: 400;
  letter-spacing: -0.01em;
  margin: 0;
}
.at-privacy-row p {
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--dim);
  margin: 0;
}
.at-privacy-row__body {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.at-privacy-row ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.at-privacy-row li {
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--dim);
  padding-left: 22px;
  position: relative;
}
.at-privacy-row li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--dim);
  font-family: var(--mono);
}
.at-privacy-row strong {
  color: var(--ink);
  font-weight: 500;
}
.at-privacy-row a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.at-privacy-row a:hover {
  border-bottom-color: var(--accent);
}

/* ============================ RESPONSIVE ============================ */
@media (max-width: 1024px) {
  .at-grid--mast { grid-template-columns: var(--side-col) 1fr; }
  .at-grid--mast .at-mast__aside { grid-column: 2 / 3; }
  .at-grid--app,
  .at-grid--app-big { grid-template-columns: var(--side-col) 128px 1fr; }
  .at-app__links {
    grid-column: 2 / -1;
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
    gap: 18px;
    margin-top: 18px;
  }
  .at-app--big .at-app__icon img { width: 128px; height: 128px; border-radius: 26px; }
  .at-key-grid { grid-template-columns: repeat(3, 1fr); }
  .at-footer__top { grid-template-columns: 1fr 1fr; }
  .at-page-hero__body { grid-template-columns: var(--side-col) 1fr; }
  .at-page-hero__body p + p { grid-column: 2 / 3; }
}

@media (max-width: 720px) {
  .at-masthead { padding: 56px var(--gutter) 40px; }
  .at-grid--mast,
  .at-grid--head,
  .at-grid--app,
  .at-grid--app-big,
  .at-grid--key,
  .at-page-hero__body { grid-template-columns: 1fr; gap: 20px; }
  .at-side--right { text-align: left; }
  .at-app__icon img,
  .at-app--big .at-app__icon img { width: 96px; height: 96px; border-radius: 22px; }
  .at-app__title { font-size: 36px; }
  .at-app__title--big { font-size: 42px; }
  .at-app__links {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 18px;
  }
  .at-numbers { grid-template-columns: 1fr; }
  .at-number__v { font-size: 72px; }
  .at-key-grid { grid-template-columns: 1fr 1fr; }
  .at-footer__top { grid-template-columns: 1fr; gap: 32px; }
  .at-privacy-row { grid-template-columns: 1fr; gap: 12px; }
  .at-privacy-row h3 { font-size: 28px; }

  /* shrink the biggest chip on small screens so it doesn't crowd the row */
  .at-app--big .at-chip--lg,
  .at-key .at-chip--lg {
    height: 42px;
    padding: 0 18px 0 14px;
    gap: 10px;
    border-radius: 4px;
  }
  .at-app--big .at-chip--lg .at-chip__glyph,
  .at-key .at-chip--lg .at-chip__glyph { width: 22px; height: 22px; --gw: 2.2; }
  .at-app--big .at-chip--lg .at-chip__label,
  .at-key .at-chip--lg .at-chip__label { font-size: 12px; }
}
