/* Shared brep components: the base, the bar, buttons, the status dot, form fields, plan cards and the
   footer. Used by brep.si and brep Data (data.brep.si); load after tokens.css and before the page's
   own stylesheet. Change them here, never in a copy. */

/* ── Base ── */
* { box-sizing: border-box; }
body { margin: 0; background: var(--ink); overflow-x: hidden; }
h1, h2, h3, p, figure { margin: 0; }
img, canvas { display: block; }
a { color: inherit; text-underline-offset: 4px; text-decoration-thickness: 1px; }
:focus-visible { outline: 2px solid var(--text); outline-offset: 4px; border-radius: 2px; }
::selection { background: var(--r3); color: var(--ink); }

.skip-link {
  position: absolute; left: 8px; top: 8px; z-index: 20; padding: 12px 16px;
  background: var(--text); color: var(--ink); transform: translateY(-300%);
}
.skip-link:focus { transform: none; }

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

/* ── Bar ── */
.bar {
  position: fixed; inset: 0 0 auto; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: clamp(14px, 1.8vw, 24px) var(--gutter);
  border-bottom: 1px solid transparent;
  transition: background-color .3s ease, border-color .3s ease, padding .3s ease;
}
/* once the hero has scrolled away, the bar sits on a frosted ink backdrop */
.bar.is-solid {
  background: rgba(5, 6, 10, .72); border-bottom-color: var(--hair);
  -webkit-backdrop-filter: blur(14px) saturate(1.2); backdrop-filter: blur(14px) saturate(1.2);
  padding-top: 12px; padding-bottom: 12px;
}
.bar__mark { display: block; width: clamp(74px, 6.6vw, 100px); }
.bar__mark img { width: 100%; height: auto; }
.bar__nav { display: flex; align-items: center; gap: clamp(14px, 2vw, 30px); }
.bar__link {
  font-size: 15px; font-weight: 500; color: var(--text-2); text-decoration: none;
  transition: color .2s ease;
}
.bar__link:hover { color: var(--text); }

/* ── Buttons and status ── */
.status { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 500; }
.status__dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--r3); box-shadow: 0 0 0 4px rgba(147, 214, 255, .14), 0 0 14px rgba(147, 214, 255, .75);
}
.button {
  display: inline-flex; align-items: center; min-height: 46px; padding: 0 22px;
  border: 1px solid rgba(238, 241, 244, .3); border-radius: 999px;
  background: rgba(5, 6, 10, .35);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  font-size: 15px; font-weight: 500; text-decoration: none;
  transition: border-color .2s ease, background-color .2s ease;
}
.button:hover { border-color: var(--text); background: rgba(238, 241, 244, .08); }
/* the one filled button: joining the waitlist */
.button--primary { background: var(--text); border-color: var(--text); color: var(--ink); cursor: pointer; font-family: inherit; }
.button--primary:hover { background: #fff; border-color: #fff; }
.button--primary:disabled { opacity: .6; cursor: progress; }
.button--small { min-height: 38px; padding: 0 18px; font-size: 14px; }

/* ── Form fields: a label wrapping its control, in rows that wrap on narrow screens ── */
.join__row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.join__field { display: grid; gap: 7px; font-size: 14px; font-weight: 500; color: var(--text-2); }
.join__field small { font-weight: 400; color: var(--text-3); }
.join__field input, .join__field select, .join__field textarea {
  width: 100%; min-height: 46px; padding: 0 16px;
  border: 1px solid rgba(238, 241, 244, .3); border-radius: 12px; background: rgba(238, 241, 244, .04);
  font: inherit; font-size: 16px; font-weight: 400; color: var(--text);
  transition: border-color .2s ease, background-color .2s ease;
}
.join__field textarea { min-height: 96px; padding: 12px 16px; resize: vertical; line-height: 1.45; }
.join__field select { appearance: none; padding-right: 40px; cursor: pointer;
  background: rgba(238, 241, 244, .04) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23A7ADBC' stroke-width='1.6'/%3E%3C/svg%3E") right 16px center no-repeat; }
.join__field select:invalid { color: var(--text-3); }
.join__field option { background: var(--ink-2); color: var(--text); }
.join__field ::placeholder { color: var(--text-3); }
.join__field input:focus, .join__field select:focus, .join__field textarea:focus { outline: none; border-color: var(--text); background-color: rgba(238, 241, 244, .07); }

/* ── Plan cards ── */
.plan { display: grid; grid-template-rows: auto auto 1fr auto; align-content: stretch; gap: 10px; padding: clamp(22px, 2.4vw, 32px); border: 1px solid var(--hair); border-radius: var(--radius); background: var(--ink-2); }
.plan h3 { font-size: 19px; font-weight: 500; }
.plan--pick { border-color: rgba(238, 241, 244, .32); }
.plan__price { font-size: clamp(36px, 3.6vw, 52px); letter-spacing: -0.035em; line-height: 1.05; }
.plan__price span { font-size: 17px; letter-spacing: 0; color: var(--text-3); }
.plan > p:not(.plan__price) { color: var(--text-2); }
.plan__cta { justify-self: start; margin-top: 10px; }
.plan__cta[data-checkout][href=""] { display: none; }   /* no Stripe link yet */

/* ── Footer ── */
.foot {
  display: flex; justify-content: space-between; align-items: center; gap: 24px;
  padding: 28px var(--gutter) 36px; border-top: 1px solid var(--hair);
  font-size: 15px; color: var(--text-2);
}
.foot__mark { width: 64px; height: auto; opacity: .8; }
.foot__links { display: flex; gap: 24px; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--text); text-decoration: underline; }

@media (max-width: 760px) {
  .wide-only { display: none; }
  .bar__nav { gap: 16px; }
  .bar__link { font-size: 14px; }
}
