/* =============================================
   HYPEDATA · APP — auth pages (sign in / sign up)
   HypeLabs, LLC · 2026
   ============================================= */

:root {
  --bg:            #0a0908;
  --bg-elev:       #121010;
  --surface:       #1a1714;
  --surface-2:     #221e1a;
  --ink:           #f5efe3;
  --ink-dim:       #b6ac9d;
  --ink-faint:     #6b6458;
  --line:          rgba(245, 239, 227, 0.08);
  --line-2:        rgba(245, 239, 227, 0.16);
  --line-3:        rgba(245, 239, 227, 0.28);
  --amber:         #ffb547;
  --amber-bright:  #ffcc6d;
  --amber-deep:    #c78418;
  --chart:         #d4ff3e;
  --coral:         #ff5a3c;

  --display: 'Fraunces', serif;
  --sans:    'Instrument Sans', system-ui, sans-serif;
  --mono:    'JetBrains Mono', ui-monospace, monospace;

  --e-swift: cubic-bezier(.2,.8,.2,1);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.55;
  font-feature-settings: "ss01", "cv01", "cv11";
  min-height: 100vh;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
::selection { background: var(--amber); color: var(--bg); }

/* grain overlay */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 200;
  opacity: .04;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.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 .75 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* =============================================
   LAYOUT — split-screen
   ============================================= */
.auth-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  position: relative;
}
.auth-aside {
  background: linear-gradient(160deg, #15110e 0%, #0d0b0a 70%);
  border-right: 1px solid var(--line);
  padding: clamp(2rem, 4vw, 3.5rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2.5rem;
  position: relative;
  overflow: hidden;
}
.auth-aside::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 40%, rgba(255,181,71,.08) 0%, transparent 55%);
  pointer-events: none;
}
.auth-main {
  padding: clamp(2rem, 4vw, 3.5rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2rem;
  background: var(--bg);
}

/* TOP BARS */
.auth-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-weight: 450;
  font-size: 1.35rem;
  letter-spacing: -0.025em;
  font-variation-settings: "opsz" 30, "SOFT" 40;
  color: var(--ink);
}
.brand svg { width: 28px; height: 28px; }
.brand-dot {
  display: inline-block;
  width: 7px; height: 7px;
  background: var(--amber);
  border-radius: 50%;
  margin-left: 2px;
  box-shadow: 0 0 12px var(--amber);
}
.auth-back {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  color: var(--ink-faint);
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  transition: color .2s;
}
.auth-back:hover { color: var(--ink); }
.auth-back svg { width: 12px; height: 12px; }

/* =============================================
   ASIDE — visual + marketing
   ============================================= */
.aside-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 3rem;
  flex: 1;
  justify-content: center;
}
.aside-figure {
  width: 100%;
  max-width: 460px;
  margin: 0 auto;
}
.aside-figure svg {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 30px 60px rgba(0,0,0,.4));
}

.aside-quote {
  border-left: 2px solid var(--amber);
  padding: 0 0 0 1.25rem;
  margin: 0;
  max-width: 38ch;
}
.aside-quote p {
  font-family: var(--display);
  font-weight: 380;
  font-size: clamp(1.15rem, 1.7vw, 1.4rem);
  letter-spacing: -0.015em;
  line-height: 1.35;
  color: var(--ink);
  margin: 0 0 1rem;
  font-variation-settings: "opsz" 72, "SOFT" 50;
}
.aside-quote em { color: var(--amber); font-style: italic; }
.aside-quote .who {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.aside-quote .who .name { color: var(--ink); }

/* trust strip */
.aside-trust {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem 2.5rem;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.aside-trust .t {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
}
.aside-trust .t svg { width: 14px; height: 14px; color: var(--chart); }

/* =============================================
   MAIN — form panel
   ============================================= */
.auth-card {
  width: 100%;
  max-width: 420px;
  margin: auto;
  display: flex;
  flex-direction: column;
}

.auth-eyebrow {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: .85rem;
}
.auth-h1 {
  font-family: var(--display);
  font-weight: 360;
  font-size: clamp(2rem, 3.2vw, 2.55rem);
  letter-spacing: -0.025em;
  line-height: 1.02;
  color: var(--ink);
  margin: 0 0 .65rem;
  font-variation-settings: "opsz" 96, "SOFT" 50, "WONK" 1;
}
.auth-h1 em { color: var(--amber); font-style: italic; }
.auth-sub {
  color: var(--ink-dim);
  margin: 0 0 2rem;
  font-size: 15px;
  line-height: 1.55;
}
.auth-sub a {
  color: var(--amber);
  border-bottom: 1px solid rgba(255,181,71,.3);
  transition: all .2s;
}
.auth-sub a:hover { color: var(--amber-bright); border-bottom-color: var(--amber); }

/* signup hero perk pill */
.perk {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  padding: .4rem .85rem .4rem .55rem;
  background: rgba(212,255,62,.06);
  border: 1px solid rgba(212,255,62,.25);
  border-radius: 100px;
  margin-bottom: 1.5rem;
  font-size: 12px;
  color: var(--ink-dim);
}
.perk b { color: var(--ink); font-weight: 500; }
.perk .ico {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(212,255,62,.15);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.perk .ico svg { width: 12px; height: 12px; color: var(--chart); }

/* OAUTH BUTTONS */
.oauth {
  display: flex;
  flex-direction: column;
  gap: .65rem;
  margin-bottom: 1.5rem;
}
.btn-oauth {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .65rem;
  width: 100%;
  padding: .75rem 1rem;
  border: 1px solid var(--line-2);
  border-radius: 9px;
  background: var(--surface);
  color: var(--ink);
  font-size: 14.5px;
  font-weight: 500;
  cursor: pointer;
  transition: border-color .2s var(--e-swift), background .2s var(--e-swift), transform .15s var(--e-swift);
  font-family: inherit;
}
.btn-oauth:hover {
  border-color: var(--line-3);
  background: var(--surface-2);
}
.btn-oauth:active { transform: translateY(1px); }
.btn-oauth svg { width: 18px; height: 18px; flex-shrink: 0; }

/* divider */
.or {
  display: flex;
  align-items: center;
  gap: .9rem;
  margin: 1.25rem 0 1.5rem;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.or::before, .or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

/* FORM */
.field {
  display: flex;
  flex-direction: column;
  gap: .4rem;
  margin-bottom: 1rem;
}
.field-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}
.field label {
  font-size: 12px;
  font-family: var(--mono);
  letter-spacing: .04em;
  color: var(--ink-dim);
  text-transform: uppercase;
}
.field a.hint {
  font-size: 11.5px;
  font-family: var(--mono);
  letter-spacing: .04em;
  color: var(--ink-faint);
  transition: color .2s;
}
.field a.hint:hover { color: var(--amber); }

.input-wrap {
  position: relative;
}
.input-wrap .lead {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ink-faint);
  pointer-events: none;
  width: 16px; height: 16px;
}
.input {
  width: 100%;
  padding: .75rem 1rem .75rem 2.4rem;
  background: var(--bg-elev);
  border: 1px solid var(--line-2);
  border-radius: 9px;
  color: var(--ink);
  font: inherit;
  font-size: 14.5px;
  transition: border-color .2s var(--e-swift), background .2s var(--e-swift);
  outline: 0;
}
.input::placeholder { color: var(--ink-faint); }
.input:hover { border-color: var(--line-3); }
.input:focus {
  border-color: var(--amber);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(255,181,71,.1);
}
.input.no-lead { padding-left: 1rem; }
.input-wrap:has(> .reveal) .input { padding-right: 2.75rem; }

.input-wrap .reveal {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  padding: 6px 8px;
  border-radius: 6px;
  color: var(--ink-faint);
  transition: color .2s, background .2s;
}
.input-wrap .reveal:hover { color: var(--ink); background: rgba(255,255,255,.04); }
.input-wrap .reveal svg { width: 16px; height: 16px; }

.field-help {
  font-size: 12px;
  color: var(--ink-faint);
  font-family: var(--mono);
  letter-spacing: .03em;
  margin-top: 4px;
}
.field-help.error { color: var(--coral); }
.field-help.success { color: var(--chart); }

/* terms checkbox row */
.terms {
  display: flex;
  align-items: flex-start;
  gap: .7rem;
  margin: 0 0 1.25rem;
}
.terms input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  flex-shrink: 0;
  border: 1px solid var(--line-3);
  border-radius: 5px;
  background: var(--bg-elev);
  position: relative;
  cursor: pointer;
  transition: background .2s, border-color .2s;
}
.terms input[type="checkbox"]:hover { border-color: var(--ink-faint); }
.terms input[type="checkbox"]:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px rgba(255,181,71,.25);
}
.terms input[type="checkbox"]:checked {
  background: var(--amber);
  border-color: var(--amber);
}
.terms input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 5px; top: 1px;
  width: 5px; height: 10px;
  border: solid var(--bg);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.terms label {
  flex: 1;
  font-size: 13px;
  color: var(--ink-dim);
  line-height: 1.55;
  cursor: pointer;
}
.terms label a { color: var(--amber); border-bottom: 1px solid rgba(255,181,71,.3); }
.terms label a:hover { color: var(--amber-bright); }

/* submit button */
.btn-submit {
  width: 100%;
  padding: .8rem 1rem;
  background: var(--ink);
  color: var(--bg);
  font-size: 14.5px;
  font-weight: 500;
  border-radius: 9px;
  cursor: pointer;
  transition: background .25s var(--e-swift), transform .15s var(--e-swift), box-shadow .25s var(--e-swift);
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  position: relative;
}
.btn-submit:hover:not(:disabled) {
  background: var(--amber);
  transform: translateY(-1px);
  box-shadow: 0 10px 30px -10px rgba(255,181,71,.5);
}
.btn-submit:active:not(:disabled) { transform: translateY(0); }
.btn-submit:disabled {
  opacity: .55;
  cursor: not-allowed;
}
.btn-submit svg { width: 14px; height: 14px; }
.btn-submit .spinner {
  width: 14px; height: 14px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin .8s linear infinite;
  display: none;
}
.btn-submit.loading .spinner { display: inline-block; }
.btn-submit.loading .label,
.btn-submit.loading .arrow { display: none; }

@keyframes spin { to { transform: rotate(360deg); } }

/* swap link */
.swap {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  font-size: 14px;
  color: var(--ink-dim);
  text-align: center;
}
.swap a {
  color: var(--amber);
  border-bottom: 1px solid rgba(255,181,71,.3);
  margin-left: 4px;
  transition: all .2s;
}
.swap a:hover { color: var(--amber-bright); border-bottom-color: var(--amber); }

/* SUCCESS STATE */
.success {
  display: none;
  flex-direction: column;
  gap: 1.25rem;
  padding: 2rem 1.75rem;
  border: 1px solid rgba(212,255,62,.25);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(212,255,62,.04), rgba(212,255,62,.01));
  margin-bottom: 1.5rem;
}
.success.is-open { display: flex; }
.success .seal {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: rgba(212,255,62,.12);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.success .seal svg { width: 22px; height: 22px; color: var(--chart); }
.success h3 {
  font-family: var(--display);
  font-weight: 420;
  font-size: 1.35rem;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.015em;
  font-variation-settings: "opsz" 60;
}
.success p { margin: 0; color: var(--ink-dim); font-size: 14.5px; line-height: 1.6; }
.success p code {
  font-family: var(--mono);
  font-size: 12.5px;
  background: rgba(255,255,255,.05);
  border: 1px solid var(--line);
  padding: 1px 6px;
  border-radius: 3px;
  color: var(--ink);
}
.success .resend {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  color: var(--ink-faint);
}
.success .resend a { color: var(--amber); border-bottom: 1px solid rgba(255,181,71,.3); }
.success .resend a:hover { color: var(--amber-bright); }

/* FOOTER inside main */
.auth-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .05em;
  color: var(--ink-faint);
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}
.auth-foot a { color: var(--ink-dim); transition: color .2s; }
.auth-foot a:hover { color: var(--ink); }
.auth-foot-links { display: flex; gap: 1.25rem; }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 980px) {
  .auth-page { grid-template-columns: 1fr; }
  .auth-aside {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding-bottom: 2.5rem;
  }
  .aside-figure { max-width: 280px; }
  .aside-inner { gap: 2rem; }
}
@media (max-width: 560px) {
  .auth-top { flex-direction: column; align-items: flex-start; }
  .auth-foot { flex-direction: column; align-items: flex-start; }
  .auth-foot-links { flex-wrap: wrap; }
}
