/* ──────────────────────────────────────────────────────────────────────────
 * FIELDDAY · Account flow
 * Shared stylesheet for the four /account-* routes.
 * Design parity with team-*.html .signup-* styles, renamed to .acct-* to
 * keep the team-page overlay separate during the v1 transition.
 * ────────────────────────────────────────────────────────────────────────── */

:root {
  --acct-black: #0a0a0a;
  --acct-white: #f5f0e8;
  --acct-violet: #9b5eff;
  --acct-red: #ff3131;
  --acct-blue: #3b7fff;
  --acct-green: #00d26a;
  --acct-muted: #b4b0aa;
  --acct-dim: #6a6862;

  /* Team accent — overridden per page by the welcome screen */
  --team-accent: var(--acct-violet);
  --team-accent-soft: rgba(155, 94, 255, 0.12);
  --team-accent-border: rgba(155, 94, 255, 0.35);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--acct-black);
  color: var(--acct-white);
  font-family: 'DM Sans', sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: var(--team-accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ── Top bar ───────────────────────────────────────────────────────────── */
.acct-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 32px;
  border-bottom: 1px solid rgba(245, 240, 232, 0.08);
}

.acct-logo {
  font-family: 'Anton', sans-serif;
  font-size: 22px;
  letter-spacing: 4px;
  color: var(--team-accent);
  text-decoration: none;
}

.acct-step-pill {
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--acct-muted);
  padding: 6px 12px;
  border: 1px solid rgba(245, 240, 232, 0.18);
  border-radius: 999px;
}

/* ── Main column ───────────────────────────────────────────────────────── */
main.acct-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
}

.acct-panel {
  width: 100%;
  max-width: 480px;
  position: relative;
  background: linear-gradient(180deg, var(--team-accent-soft), transparent 80%);
  border: 1px solid rgba(245, 240, 232, 0.06);
  padding: 40px 32px 32px;
}

.acct-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--team-accent), transparent);
  opacity: 0.7;
}

.acct-eyebrow {
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--team-accent);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.acct-eyebrow::before {
  content: '';
  width: 28px;
  height: 2px;
  background: var(--team-accent);
}

.acct-title {
  font-family: 'Anton', sans-serif;
  font-size: 44px;
  line-height: 0.95;
  letter-spacing: -1px;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.acct-title .accent {
  color: var(--team-accent);
}

.acct-lede {
  font-size: 13px;
  line-height: 1.6;
  color: var(--acct-muted);
  margin: 8px 0 24px;
}

/* ── Form fields ───────────────────────────────────────────────────────── */
.acct-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.acct-row {
  display: flex;
  gap: 14px;
}

.acct-row.phone-row .code-field {
  flex: 0 0 124px;
}

.acct-row.phone-row .acct-field:not(.code-field) {
  flex: 1;
}

.acct-field {
  position: relative;
  display: flex;
  flex-direction: column;
}

.acct-label {
  font-family: 'Space Mono', monospace;
  font-size: 9px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--acct-muted);
  margin-bottom: 6px;
}

.acct-input {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1.5px solid rgba(245, 240, 232, 0.2);
  color: var(--acct-white);
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  padding: 8px 0 10px;
  outline: none;
  letter-spacing: 0.3px;
  transition: border-color 0.3s;
}

.acct-input::placeholder {
  color: rgba(245, 240, 232, 0.28);
}

.acct-input:focus {
  border-bottom-color: var(--team-accent);
}

.acct-select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'><path fill='none' stroke='%23f5f0e8' stroke-width='1.5' d='M1 1l4 4 4-4'/></svg>");
  background-repeat: no-repeat;
  background-position: right 4px center;
  padding-right: 18px;
}

.acct-select option {
  background: var(--acct-black);
  color: var(--acct-white);
}

.acct-input.code-input {
  font-family: 'Space Mono', monospace;
  font-size: 24px;
  letter-spacing: 10px;
  text-align: center;
}

/* ── Buttons ───────────────────────────────────────────────────────────── */
.acct-submit {
  background: var(--team-accent);
  color: var(--acct-black);
  font-family: 'Anton', sans-serif;
  font-size: 15px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  padding: 18px 24px;
  border: none;
  cursor: pointer;
  transition:
    transform 0.2s,
    filter 0.2s,
    opacity 0.3s;
  margin-top: 4px;
}

.acct-submit:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.acct-submit:not(:disabled):hover {
  transform: translateY(-2px);
  filter: brightness(1.12);
}

.acct-secondary {
  background: transparent;
  color: var(--acct-muted);
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 12px 16px;
  border: 1px solid rgba(245, 240, 232, 0.18);
  cursor: pointer;
  transition:
    border-color 0.2s,
    color 0.2s;
}

.acct-secondary:hover:not(:disabled) {
  border-color: var(--team-accent);
  color: var(--team-accent);
}

.acct-secondary:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.acct-ghost-btn {
  background: transparent;
  color: var(--acct-muted);
  border: none;
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  cursor: pointer;
  padding: 8px 4px;
}

.acct-ghost-btn:hover:not(:disabled) {
  color: var(--team-accent);
}

.acct-ghost-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* "Sprint in with Google" — disabled in v1 */
.acct-oauth {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: transparent;
  color: var(--acct-white);
  border: 1px solid rgba(245, 240, 232, 0.25);
  padding: 14px 18px;
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  cursor: not-allowed;
  opacity: 0.55;
  position: relative;
}

.acct-oauth[disabled] {
  cursor: not-allowed;
}

.acct-oauth[data-tooltip]:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--acct-white);
  color: var(--acct-black);
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 1.5px;
  padding: 6px 10px;
  white-space: nowrap;
  z-index: 10;
}

/* ── Divider ───────────────────────────────────────────────────────────── */
.acct-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 4px 0;
  color: var(--acct-dim);
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.acct-divider::before,
.acct-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(245, 240, 232, 0.12);
}

/* ── Terms / inline help ───────────────────────────────────────────────── */
.acct-terms {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--acct-muted);
}

.acct-help {
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--acct-dim);
  margin-top: 8px;
}

/* ── Toasts ────────────────────────────────────────────────────────────── */
.acct-toasts {
  position: fixed;
  top: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 1000;
  pointer-events: none;
}

.acct-toast {
  background: var(--acct-white);
  color: var(--acct-black);
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  letter-spacing: 1.2px;
  padding: 12px 16px;
  border-left: 4px solid var(--team-accent);
  max-width: 320px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  animation: acct-toast-in 0.2s ease-out;
}

.acct-toast.error {
  border-left-color: var(--acct-red);
}

@keyframes acct-toast-in {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* ── Status / pulses ───────────────────────────────────────────────────── */
.acct-status {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--acct-muted);
}

.acct-pulse {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--team-accent);
  animation: acct-pulse 1.6s ease-in-out infinite;
}

@keyframes acct-pulse {
  0%,
  100% {
    opacity: 0.3;
    transform: scale(0.85);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
}

/* ── Two-pane phone screen ─────────────────────────────────────────────── */
.acct-pane {
  display: none;
}

.acct-pane.active {
  display: block;
}

/* ── Welcome celebration ───────────────────────────────────────────────── */
.acct-welcome .acct-panel {
  text-align: center;
}

.acct-welcome .acct-title {
  font-size: 56px;
  line-height: 0.92;
}

.acct-welcome .acct-subhead {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--team-accent);
  margin: 12px 0 24px;
}

.acct-welcome .acct-cta {
  display: inline-block;
  background: var(--team-accent);
  color: var(--acct-black);
  font-family: 'Anton', sans-serif;
  font-size: 16px;
  letter-spacing: 3px;
  text-transform: uppercase;
  padding: 20px 32px;
  text-decoration: none;
  transition:
    transform 0.2s,
    filter 0.2s;
}

.acct-welcome .acct-cta:hover {
  transform: translateY(-2px);
  filter: brightness(1.12);
  text-decoration: none;
}

/* Confetti chevrons — pure CSS celebration */
.acct-confetti {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.acct-confetti span {
  position: absolute;
  width: 6px;
  height: 14px;
  background: var(--team-accent);
  opacity: 0.7;
  animation: acct-fall 3.4s linear infinite;
}

.acct-confetti span:nth-child(1) {
  left: 8%;
  animation-delay: 0.1s;
}
.acct-confetti span:nth-child(2) {
  left: 22%;
  animation-delay: 0.6s;
  background: var(--acct-white);
}
.acct-confetti span:nth-child(3) {
  left: 38%;
  animation-delay: 1.1s;
}
.acct-confetti span:nth-child(4) {
  left: 54%;
  animation-delay: 0.3s;
  background: var(--acct-white);
}
.acct-confetti span:nth-child(5) {
  left: 70%;
  animation-delay: 1.4s;
}
.acct-confetti span:nth-child(6) {
  left: 86%;
  animation-delay: 0.9s;
  background: var(--acct-white);
}

@keyframes acct-fall {
  0% {
    transform: translateY(-30px) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 0.85;
  }
  100% {
    transform: translateY(120vh) rotate(360deg);
    opacity: 0;
  }
}

/* ── Footer sig ────────────────────────────────────────────────────────── */
.acct-footer-sig {
  font-family: 'Space Mono', monospace;
  font-size: 9px;
  letter-spacing: 2px;
  color: var(--acct-dim);
  text-transform: uppercase;
  padding: 20px 32px;
  border-top: 1px solid rgba(245, 240, 232, 0.06);
  text-align: center;
}

/* ── Turnstile widget housing ──────────────────────────────────────────── */
.acct-turnstile {
  margin: 4px 0 0;
  min-height: 65px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Mobile ────────────────────────────────────────────────────────────── */
@media (max-width: 540px) {
  .acct-nav {
    padding: 16px 20px;
  }

  .acct-panel {
    padding: 32px 22px 26px;
  }

  .acct-title {
    font-size: 34px;
  }

  .acct-welcome .acct-title {
    font-size: 42px;
  }

  .acct-row {
    flex-wrap: wrap;
  }

  .acct-row.phone-row .code-field {
    flex: 1 1 100%;
  }
}

/* ── D13 — Cap-overflow page ───────────────────────────────────────────
 * The overflow page reuses .acct-panel + .acct-form. These additions are
 * scoped to .acct-overflow / .acct-overflow-* selectors so they don't
 * leak into the other account-* routes.
 */
.acct-overflow {
  text-align: left;
}

.acct-overflow-footnote {
  margin-top: 18px;
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--acct-muted);
  text-transform: uppercase;
}

.acct-overflow-success {
  position: relative;
  text-align: center;
  padding: 24px 8px 8px;
}

.acct-overflow-success .acct-confetti {
  /* Confetti host overlays the success card without pushing layout. */
  inset: -16px -16px auto -16px;
  height: 220px;
}

.acct-overflow-success-mark {
  font-family: 'Anton', sans-serif;
  font-size: 72px;
  color: var(--team-accent);
  line-height: 1;
  margin-bottom: 12px;
}

.acct-overflow-success-title {
  font-family: 'Anton', sans-serif;
  font-size: 36px;
  letter-spacing: 3px;
  color: var(--acct-white);
  margin-bottom: 12px;
}

.acct-overflow-success-body {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--acct-muted);
}
