:root {
  --fo-bg: #0b1020;
  --fo-bg-elev: #121a33;
  --fo-surface: #1a2448;
  --fo-border: #26315c;
  --fo-text: #e6e9f5;
  --fo-muted: #9aa3c7;
  --fo-primary: #6d8cff;
  --fo-primary-strong: #4b6dff;
  --fo-accent: #22d3ee;
  --fo-success: #34d399;
  --fo-danger: #f87171;
}

html, body { height: 100%; }

body {
  background: radial-gradient(1200px 600px at 10% -10%, rgba(109,140,255,0.25), transparent),
              radial-gradient(900px 500px at 100% 0%, rgba(34,211,238,0.18), transparent),
              var(--fo-bg);
  color: var(--fo-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

a { color: var(--fo-primary); text-decoration: none; }
a:hover { color: var(--fo-accent); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: saturate(160%) blur(12px);
  background: rgba(11,16,32,0.72);
  border-bottom: 1px solid var(--fo-border);
}

.navbar { padding-top: .75rem; padding-bottom: .75rem; }

.brand-mark {
  display: inline-flex;
  width: 34px; height: 34px;
  align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--fo-primary), var(--fo-accent));
  color: #0b1020;
  font-weight: 800;
  border-radius: 8px;
  margin-right: .5rem;
}

.brand-text { color: var(--fo-text); letter-spacing: .2px; }

.navbar-brand { display: inline-flex; align-items: center; }

.nav-link { color: var(--fo-muted) !important; font-weight: 500; }
.nav-link:hover, .nav-link.active { color: var(--fo-text) !important; }

.btn-primary {
  background: linear-gradient(135deg, var(--fo-primary), var(--fo-primary-strong));
  border: none;
  color: #fff;
  font-weight: 600;
  letter-spacing: .2px;
}
.btn-primary:hover { filter: brightness(1.08); color: #fff; }

.btn-outline-light { color: var(--fo-text); border-color: var(--fo-border); }
.btn-outline-light:hover { background: var(--fo-surface); border-color: var(--fo-primary); color: var(--fo-text); }

.hero {
  padding: 6rem 0 4rem;
  text-align: center;
}

.hero h1 {
  font-weight: 800;
  font-size: clamp(2rem, 5vw, 3.75rem);
  background: linear-gradient(135deg, #ffffff 20%, var(--fo-primary) 80%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 1rem;
}

.hero p.lead {
  color: var(--fo-muted);
  font-size: 1.15rem;
  max-width: 720px;
  margin: 0 auto 2rem;
}

.card-surface {
  background: var(--fo-bg-elev);
  border: 1px solid var(--fo-border);
  border-radius: 16px;
  padding: 2rem;
}

.upload-dropzone {
  border: 2px dashed var(--fo-border);
  border-radius: 14px;
  padding: 3rem 1.5rem;
  text-align: center;
  transition: border-color .2s ease, background .2s ease;
  background: rgba(18,26,51,0.6);
  cursor: pointer;
}
.upload-dropzone.dragover {
  border-color: var(--fo-primary);
  background: rgba(109,140,255,0.08);
}
.upload-dropzone h3 { font-weight: 700; margin-bottom: .5rem; }
.upload-dropzone .hint { color: var(--fo-muted); }

.form-check-label, .form-label { color: var(--fo-text); }
.form-control, .form-select {
  background: var(--fo-bg);
  color: var(--fo-text);
  border: 1px solid var(--fo-border);
}
.form-control:focus, .form-select:focus {
  background: var(--fo-bg);
  color: var(--fo-text);
  border-color: var(--fo-primary);
  box-shadow: 0 0 0 .2rem rgba(109,140,255,0.2);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.pricing-card {
  background: var(--fo-bg-elev);
  border: 1px solid var(--fo-border);
  border-radius: 16px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
}
.pricing-card.featured {
  border-color: var(--fo-primary);
  box-shadow: 0 0 0 1px var(--fo-primary), 0 12px 40px -12px rgba(109,140,255,0.45);
}
.pricing-card h3 { font-weight: 700; }
.pricing-card .price {
  font-size: 2.6rem;
  font-weight: 800;
  margin: .5rem 0 .25rem;
}
.pricing-card .price .unit { font-size: 1rem; color: var(--fo-muted); font-weight: 500; }
.pricing-card ul { list-style: none; padding: 0; margin: 1.25rem 0; color: var(--fo-muted); }
.pricing-card li { padding: .4rem 0; border-bottom: 1px dashed var(--fo-border); }
.pricing-card li:last-child { border-bottom: none; }
.pricing-card li::before { content: "✓ "; color: var(--fo-success); font-weight: 700; }

.badge-pro {
  background: linear-gradient(135deg, var(--fo-primary), var(--fo-accent));
  color: #0b1020;
  font-weight: 700;
  padding: .25rem .6rem;
  border-radius: 999px;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .5px;
}

.site-footer {
  border-top: 1px solid var(--fo-border);
  padding: 1.5rem 0;
  color: var(--fo-muted);
  font-size: .9rem;
  margin-top: 3rem;
}

.site-footer a { color: var(--fo-muted); }
.site-footer a:hover { color: var(--fo-text); }

.code-block {
  background: #05081a;
  border: 1px solid var(--fo-border);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  color: #cad3ff;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: .9rem;
  overflow-x: auto;
  white-space: pre;
}

.alert { border-radius: 12px; }
.alert-success { background: rgba(52,211,153,0.12); border-color: rgba(52,211,153,0.4); color: #a7f3d0; }
.alert-warning { background: rgba(251,191,36,0.12); border-color: rgba(251,191,36,0.4); color: #fde68a; }
.alert-danger  { background: rgba(248,113,113,0.12); border-color: rgba(248,113,113,0.4); color: #fecaca; }
.alert-info    { background: rgba(34,211,238,0.1);  border-color: rgba(34,211,238,0.4);  color: #a5f3fc; }

.stat-row { display: flex; justify-content: space-between; padding: .6rem 0; border-bottom: 1px solid var(--fo-border); }
.stat-row:last-child { border-bottom: none; }
.stat-row .label { color: var(--fo-muted); }
.stat-row .value { font-weight: 600; }

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 3rem;
}
.feature {
  background: var(--fo-bg-elev);
  border: 1px solid var(--fo-border);
  border-radius: 14px;
  padding: 1.5rem;
}
.feature h4 { font-weight: 700; font-size: 1.1rem; margin-bottom: .5rem; }
.feature p { color: var(--fo-muted); margin: 0; }

.input-file-label {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .55rem 1rem;
  border-radius: 10px;
  background: var(--fo-surface);
  border: 1px solid var(--fo-border);
  color: var(--fo-text);
  cursor: pointer;
}
.input-file-label:hover { border-color: var(--fo-primary); }

/* Identity / auth pages ------------------------------------------------ */
.auth-shell {
  padding: 4rem 0;
  display: flex;
  justify-content: center;
}
.auth-card {
  max-width: 440px;
  margin: 0 auto;
  background: var(--fo-bg-elev);
  border: 1px solid var(--fo-border);
  border-radius: 16px;
  padding: 2.25rem;
  box-shadow: 0 12px 40px -12px rgba(0,0,0,0.4);
}
.auth-card h1, .auth-card h2, .auth-card h3, .auth-card h4 {
  font-weight: 700;
  margin-bottom: 1rem;
}
.auth-card h1 { font-size: 1.6rem; }
.auth-card h2, .auth-card h3 { font-size: 1.2rem; color: var(--fo-muted); font-weight: 500; }
.auth-card hr { border-color: var(--fo-border); opacity: .5; }
.auth-card .row { margin: 0; }
.auth-card .col-md-4, .auth-card .col-md-6, .auth-card .col-md-8 { width: 100%; max-width: 100%; flex: 0 0 100%; padding: 0; }
/* Hide the "Use another service" column — no external providers configured. */
.auth-card .row > .col-md-6,
.auth-card .row > .col-md-6.col-md-offset-2 { display: none; }
.auth-card .form-floating > label { color: var(--fo-muted); }
.auth-card .form-floating > .form-control:focus ~ label,
.auth-card .form-floating > .form-control:not(:placeholder-shown) ~ label { color: var(--fo-primary); }
.auth-card a { color: var(--fo-primary); }
.auth-card a:hover { color: var(--fo-accent); }
.auth-card .btn-primary,
.auth-card .btn-lg.btn-primary {
  width: 100%;
}
.auth-card ul { padding-left: 1.1rem; }
.auth-card .text-danger { color: var(--fo-danger) !important; }
.auth-card .validation-summary-errors ul { color: var(--fo-danger); }
