/* ===================================================================
   Mailproof — design system (v2)
   Distinctive, professional look: emerald + ink + warm amber.
   Layered on top of the Tailwind CDN. Class names referenced by JS
   (blob, animate-reveal, animate-fade-up, check-row, score-ring__*,
   spinner, skeleton, btn-press, focus-ring, lift) are preserved.
   =================================================================== */

:root {
  --ink: #0a1628;            /* deep navy-black for dark sections */
  --ink-soft: #101b30;
  --brand: #059669;          /* emerald-600 — primary */
  --brand-600: #059669;
  --brand-700: #047857;
  --brand-400: #34d399;
  --teal: #0d9488;           /* teal-600 — gradient partner */
  --accent: #f59e0b;         /* amber-500 — warm accent */
  --ok: #059669;
  --warn: #d97706;
  --bad: #e11d48;            /* rose-600 */
  --bg: #f5f7f6;             /* warm off-white page bg */
  --ring: rgba(15, 23, 42, 0.08);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  background-color: var(--bg);
  background-image:
    radial-gradient(900px circle at 100% -10%, rgba(5, 150, 105, 0.06), transparent 45%),
    radial-gradient(800px circle at -10% 10%, rgba(13, 148, 136, 0.05), transparent 40%);
  background-attachment: fixed;
}

/* Display font for headings — geometric, designed, not-generic. */
h1, h2, h3, .font-display {
  font-family: 'Space Grotesk', 'Inter', ui-sans-serif, system-ui, sans-serif;
  letter-spacing: -0.02em;
}

/* ── Gradient text ── */
.text-gradient {
  background: linear-gradient(120deg, var(--brand-600) 0%, var(--teal) 55%, #0ea5a4 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.text-gradient-warm {
  background: linear-gradient(120deg, #fbbf24, #f59e0b 60%, #f97316);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font-weight: 600; border-radius: 0.85rem;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease, filter 0.18s ease;
  cursor: pointer;
}
.btn-primary {
  background: linear-gradient(135deg, #10b981 0%, #059669 45%, #0d9488 100%);
  color: #fff;
  box-shadow: 0 10px 22px -10px rgba(5, 150, 105, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
.btn-primary:hover { transform: translateY(-1px); filter: brightness(1.04); box-shadow: 0 16px 30px -10px rgba(5, 150, 105, 0.7); }
.btn-dark {
  background: var(--ink); color: #fff;
  box-shadow: 0 10px 22px -12px rgba(2, 6, 23, 0.6);
}
.btn-dark:hover { transform: translateY(-1px); background: #0d1b34; }
.btn-white { background: #fff; color: var(--ink); box-shadow: 0 8px 20px -10px rgba(2, 6, 23, 0.25); }
.btn-white:hover { transform: translateY(-1px); background: #f8fafc; }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--ring); }
.btn-ghost:hover { background: rgba(15, 23, 42, 0.04); }
.btn-press:active { transform: scale(0.97); }

/* ── Cards ── */
.card {
  background: #fff;
  border-radius: 1.25rem;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 12px 30px -18px rgba(15, 23, 42, 0.18);
  border: 1px solid rgba(15, 23, 42, 0.06);
}
.card-glow { position: relative; }
.card-glow::before {
  content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.5), rgba(13, 148, 136, 0.15) 40%, transparent 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none;
}

/* Hover lift for cards / features. */
.lift { transition: transform 0.25s ease, box-shadow 0.25s ease; }
.lift:hover { transform: translateY(-5px); box-shadow: 0 24px 44px -24px rgba(15, 23, 42, 0.32); }

/* ── Glass header ── */
.glass-header {
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
}

/* ── Pills / badges ── */
.pill {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.375rem 0.85rem; border-radius: 9999px;
  font-size: 0.8rem; font-weight: 600;
}

/* ── Hero grid + glow (no external images) ── */
.hero-grid {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 46px 46px;
  -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 35%, #000 35%, transparent 100%);
  mask-image: radial-gradient(ellipse 75% 65% at 50% 35%, #000 35%, transparent 100%);
}
.hero-glow {
  background:
    radial-gradient(560px circle at 50% -5%, rgba(16, 185, 129, 0.35), transparent 60%),
    radial-gradient(420px circle at 85% 20%, rgba(245, 158, 11, 0.18), transparent 55%),
    radial-gradient(420px circle at 12% 30%, rgba(13, 148, 136, 0.22), transparent 55%);
}

/* Decorative blurred blobs (kept for compatibility). */
.blob { position: absolute; border-radius: 9999px; filter: blur(80px); opacity: 0.3; z-index: 0; pointer-events: none; }

/* ── Animations ── */
@keyframes reveal { from { opacity: 0; transform: translateY(16px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
.animate-reveal { animation: reveal 0.45s cubic-bezier(0.22, 1, 0.36, 1) both; }

@keyframes fadeInUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
.animate-fade-up { animation: fadeInUp 0.55s cubic-bezier(0.22, 1, 0.36, 1) both; }
.check-row { animation: fadeInUp 0.35s ease-out both; }

@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
.floaty { animation: floaty 6s ease-in-out infinite; }

@keyframes pulseRing { 0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.45); } 70% { box-shadow: 0 0 0 12px rgba(16, 185, 129, 0); } 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); } }
.pulse-ring { animation: pulseRing 2.2s infinite; }

/* Marquee for the "works with" strip. */
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.marquee-track { display: flex; width: max-content; animation: marquee 26s linear infinite; }
.marquee-mask { -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }

/* ── Score ring (result card) ── */
.score-ring__track { stroke: #e2e8f0; }
.score-ring__bar {
  transition: stroke-dashoffset 1.1s cubic-bezier(0.22, 1, 0.36, 1), stroke 0.4s ease;
  stroke-linecap: round; transform: rotate(-90deg); transform-origin: 50% 50%;
}

/* ── Spinner ── */
@keyframes spin { to { transform: rotate(360deg); } }
.spinner { width: 1.25rem; height: 1.25rem; border: 2.5px solid rgba(255, 255, 255, 0.4); border-top-color: #fff; border-radius: 9999px; animation: spin 0.7s linear infinite; }

/* ── Skeleton shimmer ── */
@keyframes shimmer { 0% { background-position: -400px 0; } 100% { background-position: 400px 0; } }
.skeleton { background: linear-gradient(90deg, #eef2f7 25%, #e2e8f0 37%, #eef2f7 63%); background-size: 800px 100%; animation: shimmer 1.4s ease-in-out infinite; border-radius: 0.5rem; }

/* Accessible focus ring. */
.focus-ring:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

/* ── Pay-as-you-go range slider ── */
.payg-range {
  -webkit-appearance: none;
  appearance: none;
  height: 10px;
  border-radius: 9999px;
  background: linear-gradient(90deg, #10b981 0%, #0d9488 var(--fill, 25%), #e2e8f0 var(--fill, 25%));
  outline: none;
  cursor: pointer;
}
.payg-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 26px; height: 26px;
  border-radius: 9999px;
  background: #fff;
  border: 3px solid #059669;
  box-shadow: 0 4px 12px -2px rgba(5, 150, 105, 0.5);
  transition: transform 0.15s ease;
}
.payg-range::-webkit-slider-thumb:hover { transform: scale(1.12); }
.payg-range::-moz-range-thumb {
  width: 26px; height: 26px;
  border-radius: 9999px;
  background: #fff;
  border: 3px solid #059669;
  box-shadow: 0 4px 12px -2px rgba(5, 150, 105, 0.5);
  transition: transform 0.15s ease;
}
.payg-range::-moz-range-thumb:hover { transform: scale(1.12); }
.payg-range:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }

/* Nice custom scrollbar for result tables. */
.thin-scroll::-webkit-scrollbar { width: 10px; height: 10px; }
.thin-scroll::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 9999px; border: 2px solid #fff; }
.thin-scroll::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* Reduced-motion respect. */
@media (prefers-reduced-motion: reduce) {
  .animate-reveal, .animate-fade-up, .check-row, .floaty, .pulse-ring, .marquee-track { animation: none !important; }
  html { scroll-behavior: auto; }
}
