/* ── AmpInvoice Global Styles ─────────────────────────────── */
:root {
  --navy:   #0B1120;
  --panel:  #111827;
  --edge:   #1E293B;
  --edge2:  #334155;
  --amber:  #F59E0B;
  --amber-l:#FCD34D;
  --amber-d:#B45309;
  --ice:    #F8FAFC;
  --muted:  #94A3B8;
  --dim:    #475569;
  --green:  #10B981;
  --red:    #EF4444;
  --radius: 14px;
  --radius-lg: 20px;
}

*, *::before, *::after { box-sizing: border-box; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--navy);
  color: var(--ice);
  margin: 0; min-height: 100vh;
}

h1,h2,h3,h4,h5 { font-family: 'Sora', sans-serif; margin: 0; }

a { color: var(--amber); text-decoration: none; }
a:hover { color: var(--amber-l); }

/* ── Layout ────────────────────────────────── */
.container { max-width: 960px; margin: 0 auto; padding: 0 24px; }
.container-sm { max-width: 520px; margin: 0 auto; padding: 0 24px; }
.container-lg { max-width: 1100px; margin: 0 auto; padding: 0 24px; }

/* ── Nav ───────────────────────────────────── */
.nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 0; border-bottom: 1px solid var(--edge);
}
.nav-logo {
  display: flex; align-items: center; gap: 10px;
  font-family: 'Sora', sans-serif; font-size: 20px; font-weight: 800;
  color: var(--ice); text-decoration: none;
}
.nav-logo span { color: var(--amber); }
.nav-links { display: flex; align-items: center; gap: 20px; }
.nav-links a { font-size: 14px; color: var(--muted); transition: color .15s; }
.nav-links a:hover { color: var(--ice); }
.nav-cta {
  font-size: 13px; font-weight: 600;
  background: var(--amber); color: var(--navy);
  padding: 8px 18px; border-radius: 8px;
  transition: background .15s;
}
.nav-cta:hover { background: var(--amber-l); color: var(--navy); }

/* ── Wire ──────────────────────────────────── */
@keyframes wire-pulse {
  0%   { opacity:0; transform:scaleX(0); }
  50%  { opacity:1; transform:scaleX(1); }
  100% { opacity:.45; }
}
.wire {
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--amber) 30%, var(--amber-l) 50%, var(--amber) 70%, transparent);
  transform-origin: left;
  animation: wire-pulse 1.2s ease forwards;
}

/* ── Buttons ───────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: 'Sora', sans-serif; font-weight: 700;
  border: none; cursor: pointer; border-radius: var(--radius);
  transition: background .15s, transform .1s, opacity .15s;
  text-decoration: none;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.btn-primary { background: var(--amber); color: var(--navy); }
.btn-primary:hover { background: var(--amber-l); color: var(--navy); }

.btn-outline { background: transparent; color: var(--amber); border: 1.5px solid var(--amber); }
.btn-outline:hover { background: #F59E0B18; }

.btn-ghost { background: var(--edge); color: var(--ice); }
.btn-ghost:hover { background: var(--edge2); }

.btn-sm  { font-size: 13px; padding: 8px 16px; }
.btn-md  { font-size: 15px; padding: 12px 24px; }
.btn-lg  { font-size: 16px; padding: 14px 28px; }
.btn-full { width: 100%; }

.btn-danger { background: #7f1d1d; color: #fca5a5; border: 1px solid #991b1b55; }
.btn-danger:hover { background: #991b1b; }

/* ── Cards ─────────────────────────────────── */
.card {
  background: var(--panel); border: 1.5px solid var(--edge);
  border-radius: var(--radius-lg); padding: 32px;
  transition: border-color .2s, box-shadow .2s;
}
.card:hover { border-color: var(--edge2); }
.card-pro {
  background: linear-gradient(160deg,#1a1400 0%,#1c1200 40%,var(--navy) 100%);
  border-color: var(--amber-d);
}
.card-pro:hover { border-color: var(--amber); box-shadow: 0 8px 40px rgba(245,158,11,.16); }

/* ── Badges ────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  padding: 3px 10px; border-radius: 999px;
}
.badge-amber { background: #F59E0B22; color: var(--amber); border: 1px solid #F59E0B44; }
.badge-slate { background: var(--edge); color: var(--muted); border: 1px solid var(--edge2); }
.badge-green { background: #065f4622; color: var(--green); border: 1px solid #10b98133; }
.badge-red   { background: #7f1d1d22; color: var(--red);   border: 1px solid #ef444433; }

/* ── Form elements ─────────────────────────── */
.form-group { margin-bottom: 18px; }
.form-label { font-size: 13px; font-weight: 600; color: var(--muted); display: block; margin-bottom: 7px; }
.form-input {
  background: var(--navy); border: 1.5px solid var(--edge);
  border-radius: 10px; color: var(--ice);
  font-size: 15px; padding: 11px 14px; width: 100%;
  outline: none; transition: border-color .2s;
  font-family: 'Inter', sans-serif;
}
.form-input:focus { border-color: var(--amber); }
.form-input.otp-input {
  letter-spacing: .25em; font-size: 24px; text-align: center;
  font-family: 'Sora', sans-serif; font-weight: 700;
}

/* ── Messages ──────────────────────────────── */
.msg { font-size: 13px; padding: 10px 14px; border-radius: 8px; margin-top: 10px; }
.msg-err  { background: #7f1d1d22; border: 1px solid #991b1b55; color: #fca5a5; }
.msg-ok   { background: #065f4622; border: 1px solid #10b98133; color: #6ee7b7; }
.msg-info { background: #1e3a5f22; border: 1px solid #3b82f655; color: #93c5fd; }

/* ── Step indicator ────────────────────────── */
.steps { display: flex; align-items: center; gap: 8px; margin-bottom: 24px; }
.step-line { flex: 1; height: 1px; background: var(--edge); }
.step-num {
  width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0;
  background: var(--edge); border: 1.5px solid var(--edge2);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; color: var(--muted);
}
.step-num.active { background: var(--amber); border-color: var(--amber); color: var(--navy); }
.step-num.done   { background: #F59E0B22;    border-color: var(--amber); color: var(--amber); }

/* ── Auth page layout ──────────────────────── */
.auth-wrap {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 40px 24px;
}
.auth-box {
  background: var(--panel); border: 1.5px solid var(--edge);
  border-radius: var(--radius-lg); padding: 40px 36px;
  width: 100%; max-width: 420px;
}

/* ── Dashboard layout ──────────────────────── */
.dash-wrap { display: flex; min-height: 100vh; }
.sidebar {
  width: 220px; flex-shrink: 0; background: var(--panel);
  border-right: 1px solid var(--edge); padding: 24px 0;
  display: flex; flex-direction: column;
}
.sidebar-logo { padding: 0 20px 24px; border-bottom: 1px solid var(--edge); margin-bottom: 16px; }
.sidebar-nav { flex: 1; }
.sidebar-link {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 20px; font-size: 14px; font-weight: 500;
  color: var(--muted); text-decoration: none; transition: all .15s;
  border-left: 2px solid transparent;
}
.sidebar-link:hover { color: var(--ice); background: var(--edge); }
.sidebar-link.active { color: var(--amber); border-left-color: var(--amber); background: #F59E0B0A; }
.sidebar-link .icon { font-size: 16px; width: 20px; text-align: center; }
.sidebar-pro-badge {
  margin: 0 12px 16px; padding: 10px 14px;
  background: #F59E0B0A; border: 1px solid #F59E0B33;
  border-radius: 10px; font-size: 12px; color: var(--muted);
}
.dash-main { flex: 1; padding: 32px; overflow-y: auto; }
.dash-header { margin-bottom: 28px; }
.dash-title { font-size: 24px; font-weight: 700; margin-bottom: 6px; }
.dash-sub { font-size: 14px; color: var(--muted); }

/* ── Tool card ─────────────────────────────── */
.tool-card {
  background: var(--panel); border: 1.5px solid var(--edge);
  border-radius: var(--radius); padding: 24px;
  transition: border-color .2s;
}
.tool-card:hover { border-color: var(--edge2); }
.tool-result {
  background: var(--navy); border: 1px solid var(--edge);
  border-radius: 10px; padding: 16px; margin-top: 16px;
  font-size: 14px; line-height: 1.7;
}

/* ── Pro gate overlay ──────────────────────── */
.pro-gate {
  position: relative; overflow: hidden;
}
.pro-gate-overlay {
  position: absolute; inset: 0; z-index: 10;
  background: rgba(11,17,32,.85);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  border-radius: var(--radius); text-align: center; padding: 24px;
}

/* ── Billing toggle ────────────────────────── */
.tog-wrap { display: flex; align-items: center; gap: 14px; }
.tog-track {
  width: 48px; height: 26px; background: var(--edge);
  border-radius: 999px; position: relative; cursor: pointer;
  transition: background .2s; border: 1.5px solid var(--edge2);
}
.tog-track.on { background: var(--amber); border-color: var(--amber); }
.tog-thumb {
  position: absolute; top: 2px; left: 2px;
  width: 18px; height: 18px; background: #fff; border-radius: 50%;
  box-shadow: 0 1px 4px rgba(0,0,0,.3); transition: transform .2s;
}
.tog-track.on .tog-thumb { transform: translateX(22px); }
.tog-label { font-size: 14px; font-weight: 500; color: var(--muted); transition: color .15s; }
.tog-label.active { font-weight: 600; color: var(--ice); }

.save-pill {
  transition: opacity .2s, transform .2s;
  opacity: 0; transform: scale(.88); pointer-events: none;
}
.save-pill.show { opacity: 1; transform: scale(1); }

/* ── Pricing grid ──────────────────────────── */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px; align-items: start;
}
.price-amount { font-size: 48px; font-weight: 800; line-height: 1; }
.feature-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 11px; }
.feature-list li { font-size: 14px; display: flex; align-items: flex-start; }
.chk  { color: var(--amber); font-weight: 700; margin-right: 8px; flex-shrink: 0; }
.cross { color: var(--edge2); font-weight: 700; margin-right: 8px; flex-shrink: 0; }

/* ── Divider ───────────────────────────────── */
.divider { border: none; border-top: 1px solid var(--edge); margin: 24px 0; }

/* ── Util ──────────────────────────────────── */
.text-amber { color: var(--amber); }
.text-muted { color: var(--muted); }
.text-green { color: var(--green); }
.text-red   { color: var(--red); }
.mt-4  { margin-top: 4px; }
.mt-8  { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-8  { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.flex  { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center  { justify-content: center; }
.gap-8  { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.text-center { text-align: center; }
.w-full { width: 100%; }
.hidden { display: none !important; }

/* ── Footer ────────────────────────────────── */
.footer {
  border-top: 1px solid var(--edge); padding: 24px;
  text-align: center; font-size: 12px; color: var(--dim);
}

/* ── Mobile ────────────────────────────────── */
@media (max-width: 640px) {
  .auth-box { padding: 28px 20px; }
  .dash-wrap { flex-direction: column; }
  .sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--edge); }
  .dash-main { padding: 20px 16px; }
  .nav-links { gap: 10px; }
}
