/* NOIR SMS — login & sign-up pages (uses the tokens from /styles.css) */
.auth-page {
  min-height: 100vh; display: flex; flex-direction: column;
  background:
    radial-gradient(circle at 78% 4%, rgba(212,175,55,.12), transparent 38%),
    radial-gradient(circle at 12% 92%, rgba(212,175,55,.05), transparent 34%),
    var(--bg);
}
.auth-page::before {
  content: ""; position: fixed; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 60% 55% at 30% 40%, #000 10%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 60% 55% at 30% 40%, #000 10%, transparent 75%);
  opacity: .35;
}

/* header */
.auth-top { position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 26px 40px 0; }
.auth-back { display: inline-flex; align-items: center; gap: 7px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--line); font-size: 13px; color: var(--muted); transition: border-color .2s, color .2s; }
.auth-back:hover { border-color: var(--line-gold); color: var(--gold-2); }
.auth-back svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }

/* layout */
.auth-main {
  position: relative; z-index: 1; flex: 1; width: 100%; max-width: 1180px; margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 1fr) 440px; align-items: center; gap: 72px;
  padding: 48px 40px 32px;
}
.auth-page--signup .auth-main { grid-template-columns: minmax(0, 1fr) 480px; }

/* pitch (left) */
.auth-pitch { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.auth-logo { display: flex; align-items: center; gap: 16px; }
.auth-logo img { width: 92px; height: 92px; filter: drop-shadow(0 0 18px rgba(212,175,55,.25)); }
.auth-logo span { font-size: 34px; font-weight: 800; letter-spacing: .14em; }
.auth-logo b { color: var(--gold); font-weight: 700; margin-left: 6px; }
.auth-pitch h1 { font-size: clamp(34px, 3.6vw, 44px); font-weight: 800; letter-spacing: -.035em; line-height: 1.1; }
.auth-pitch h1 .gold-text { display: block; }
.auth-pitch > p { margin: 0; max-width: 440px; color: var(--muted); font-size: 16px; line-height: 1.65; }
.auth-feats { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 14px; }
.auth-feats li { display: flex; align-items: center; gap: 12px; }
.auth-feats__ic { flex: none; width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: rgba(212,175,55,.08); border: 1px solid var(--line-gold); }
.auth-feats__ic svg { width: 17px; height: 17px; fill: none; stroke: var(--gold); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.auth-feats b { display: block; font-size: 14.5px; font-weight: 600; }
.auth-feats small { display: block; color: var(--muted); font-size: 13px; }
.auth-flags { display: flex; align-items: center; gap: 10px; margin-top: 4px; font-family: var(--mono); font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.auth-flags img { width: 26px; height: 19px; border-radius: 3px; object-fit: cover; box-shadow: 0 0 0 1px rgba(255,255,255,.12); }

/* card (right) */
.auth-card {
  position: relative; overflow: hidden; width: 100%; justify-self: end;
  display: flex; flex-direction: column; gap: 16px; padding: 30px 28px; border-radius: 22px;
  background: linear-gradient(180deg, rgba(212,175,55,.06), rgba(212,175,55,0) 40%), rgba(18,18,18,.9);
  border: 1px solid var(--line-gold);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 30px 80px -40px rgba(212,175,55,.45), 0 18px 48px rgba(0,0,0,.4);
}
.auth-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px; background: linear-gradient(90deg, transparent, rgba(243,210,122,.7), transparent); }
.auth-card__head { text-align: center; }
.auth-card__logo { display: none; width: 72px; height: 72px; margin: 0 auto 10px; }
.auth-card__head h2 { font-size: 21px; font-weight: 700; letter-spacing: -.02em; }
.auth-card__head p { margin: 6px 0 0; color: var(--muted); font-size: 13.5px; }

.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-form[hidden] { display: none; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.field label, .field__label { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-family: var(--mono); font-size: 11px; letter-spacing: .15em; text-transform: uppercase; color: var(--muted); }
.field__label a, .field label a { font-family: var(--sans); font-size: 12px; letter-spacing: 0; text-transform: none; color: var(--muted); }
.field__label a:hover, .field label a:hover { color: var(--gold-2); }
.opt { padding: 1px 6px; border-radius: 5px; border: 1px solid var(--line); background: rgba(255,255,255,.03); font-size: 10px; letter-spacing: .08em; margin-right: auto; }
.input { position: relative; }
.input > svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 15px; height: 15px; fill: none; stroke: var(--muted); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
.input input {
  width: 100%; height: 46px; padding: 0 14px; border-radius: 12px;
  background: #0c0c0c; border: 1px solid var(--line); color: var(--text);
  font: 500 14px var(--sans); outline: none; transition: border-color .2s, box-shadow .2s;
}
.input > svg ~ input { padding-left: 38px; }
.input input::placeholder { color: #5f5b53; }
.input input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(212,175,55,.14); }
.input input[aria-invalid="true"] { border-color: rgba(255,120,100,.55); }
.input input.mono { font-family: var(--mono); letter-spacing: .06em; }
.input input[readonly] { opacity: .85; cursor: default; }
.input__btn { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 30px; height: 30px; display: grid; place-items: center; border-radius: 8px; border: 0; background: transparent; color: var(--muted); cursor: pointer; }
.input__btn:hover { color: var(--gold-2); background: rgba(255,255,255,.04); }
.input__btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.input--pw input { padding-right: 44px; }
.field__hint { font-size: 12px; color: var(--muted); }
.field__err { font-size: 12px; color: #ff9b8a; }
.field__err:empty { display: none; }

.strength { display: flex; align-items: center; gap: 8px; margin-top: 2px; }
.strength__bar { flex: 1; height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; }
.strength__bar i { display: block; height: 100%; width: 0; border-radius: 3px; background: var(--muted); transition: width .25s, background .25s; }
.strength__label { font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); min-width: 52px; text-align: right; }

.pills { display: flex; flex-wrap: wrap; gap: 7px; }
.pills button { padding: 7px 11px; border-radius: 9px; border: 1px solid var(--line); background: transparent; color: var(--muted); font: 500 13px var(--sans); cursor: pointer; transition: all .18s; }
.pills button:hover { border-color: var(--line-gold); color: var(--text); }
.pills button[aria-pressed="true"] { border-color: var(--gold); background: rgba(212,175,55,.12); color: var(--gold-2); font-weight: 600; }

.check { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; line-height: 1.5; color: var(--muted); cursor: pointer; }
.check input { flex: none; appearance: none; -webkit-appearance: none; width: 19px; height: 19px; margin: 0; border-radius: 6px; border: 1px solid rgba(255,255,255,.18); background: transparent; cursor: pointer; display: grid; place-items: center; transition: all .18s; }
.check input:checked { border-color: var(--gold); background: rgba(212,175,55,.14) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23f3d27a' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 11px no-repeat; }
.check a { color: var(--text); font-weight: 600; text-decoration: underline; text-decoration-color: var(--line-gold); }
.check a:hover { color: var(--gold-2); }

.auth-submit {
  position: relative; display: flex; align-items: center; justify-content: center; gap: 8px;
  height: 50px; border: 0; border-radius: 14px; cursor: pointer;
  background: var(--gold-grad); color: #141005; font: 700 15px var(--sans); letter-spacing: -.01em;
  box-shadow: 0 14px 40px -12px rgba(212,175,55,.7), inset 0 1px 0 rgba(255,255,255,.4);
  transition: transform .2s, box-shadow .2s, opacity .2s;
}
.auth-submit:hover { transform: translateY(-2px); }
.auth-submit:disabled { opacity: .7; cursor: default; transform: none; }
.auth-submit svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.auth-submit .spin { display: none; animation: spin .9s linear infinite; }
.auth-submit.is-loading .spin { display: block; }
.auth-submit.is-loading .arrow { display: none; }

.auth-alt { text-align: center; font-size: 13.5px; color: var(--muted); }
.auth-alt a, .auth-alt button { padding: 0; border: 0; background: none; font: 600 13.5px var(--sans); color: var(--gold-2); cursor: pointer; }
.auth-alt a:hover, .auth-alt button:hover { color: var(--gold); }

.alert { display: flex; align-items: flex-start; gap: 9px; padding: 11px 13px; border-radius: 12px; font-size: 13px; line-height: 1.5; }
.alert[hidden] { display: none; }
.alert svg { flex: none; width: 15px; height: 15px; margin-top: 1px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.alert--err { color: #ff9b8a; border: 1px solid rgba(255,120,100,.3); background: rgba(255,107,85,.08); }
.alert--ok { color: #6fe3a4; border: 1px solid rgba(61,220,132,.3); background: rgba(61,220,132,.08); }
.alert--info { color: var(--gold-2); border: 1px solid var(--line-gold); background: rgba(212,175,55,.08); }

.country-note { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 8px 12px; border-radius: 10px; border: 1px dashed var(--line-gold); background: rgba(212,175,55,.05); font-size: 13px; color: var(--gold-2); }
.country-note[hidden] { display: none; }
.country-note img { width: 20px; height: 15px; border-radius: 2px; object-fit: cover; }

.auth-secure { display: flex; align-items: center; justify-content: center; gap: 7px; padding-top: 2px; font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.auth-secure svg { width: 12px; height: 12px; fill: none; stroke: #3ddc84; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* footer */
.auth-foot { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 0 40px 26px; font-family: var(--mono); font-size: 11px; letter-spacing: .08em; color: var(--muted); }
.auth-foot nav { display: flex; gap: 16px; }
.auth-foot a:hover { color: var(--gold-2); }

/* responsive */
@media (max-width: 1000px) {
  .auth-main, .auth-page--signup .auth-main { grid-template-columns: minmax(0, 480px); justify-content: center; gap: 34px; }
  .auth-pitch { display: none; }
  .auth-card { justify-self: center; }
  .auth-card__logo { display: block; }
}
@media (max-width: 620px) {
  .auth-top { padding: 20px 16px 0; }
  .auth-main { padding: 28px 16px 24px; }
  .auth-card { padding: 26px 20px; }
  .field-row { grid-template-columns: 1fr; }
  .auth-foot { padding: 0 16px 22px; justify-content: center; text-align: center; }
}

/* signed-in panel, inline alert link */
.signed-in { display: flex; flex-direction: column; gap: 16px; }
.signed-in[hidden] { display: none; }
.signed-in__rows { margin: 0; border-top: 1px solid var(--line); }
.signed-in__rows div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.signed-in__rows dt { color: var(--muted); }
.signed-in__rows dd { margin: 0; font-weight: 600; word-break: break-all; text-align: right; }
.signed-in__rows dd.gold-text { font-family: var(--mono); font-size: 18px; }
.signed-in__note { margin: 0; color: var(--muted); font-size: 13.5px; line-height: 1.6; text-align: center; }
.signed-in__actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.alert__link { margin-left: 4px; padding: 0; border: 0; background: none; color: inherit; font: inherit; font-weight: 700; text-decoration: underline; cursor: pointer; }
.alert__link:disabled { opacity: .6; cursor: default; }
