/* ============================================================
   HariSree SSL Alerts — design tokens
   Palette grows from the logo: deep navy + signal teal + coral
   alert accent. Fraunces for display type (echoes the wordmark's
   serif), Inter for everything functional.
============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,600;9..144,700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --navy: #0A2740;
  --navy-2: #0E3A56;
  --navy-deep: #071B2E;
  --teal: #1BC7B5;
  --teal-dark: #109385;
  --coral: #FF6F5E;
  --amber: #E6A700;
  --red: #D8453A;
  --bg: #F3F6F7;
  --paper: #FFFFFF;
  --ink: #12232F;
  --muted: #5B707C;
  --line: #E1E8EA;

  --radius: 10px;
  --shadow: 0 1px 2px rgba(10,39,64,0.04), 0 8px 24px rgba(10,39,64,0.06);
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  position: relative;
}
/* Very subtle grain for a tactile, less "flat digital" feel — barely
   perceptible, tiled as a fixed background so it doesn't move on scroll. */
body::before {
  content: '';
  position: fixed; inset: 0; z-index: 9999; pointer-events: none;
  opacity: 0.025; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
h1, h2, h3, .display {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--navy);
  margin: 0;
  line-height: 1.15;
}
a { color: inherit; }
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em; background: #EAF2F5; color: var(--navy-2);
  padding: 1px 6px; border-radius: 5px;
}
button { font-family: var(--sans); cursor: pointer; }
img, svg { display: block; max-width: 100%; }

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  transition: transform .12s ease, box-shadow .12s ease, background .12s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--navy); color: #fff; box-shadow: inset 0 1px 0 rgba(255,255,255,0.12), 0 2px 8px rgba(10,39,64,0.18); }
.btn-primary:hover { background: var(--navy-2); }
.btn-accent { background: var(--teal); color: var(--navy-deep); box-shadow: inset 0 1px 0 rgba(255,255,255,0.35), 0 2px 10px rgba(16,147,133,0.25); }
.btn-accent:hover { background: var(--teal-dark); color: #fff; }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--navy); }
.btn-block { width: 100%; }
.btn-sm { padding: 8px 14px; font-size: 13px; }
.btn-danger { background: transparent; color: var(--red); border-color: #F3D6D3; }
.btn-danger:hover { background: #FCEEEC; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------- Top nav (sticky, glass on scroll) ---------- */
.topnav-wrap {
  position: sticky; top: 0; z-index: 50;
  border-bottom: 1px solid transparent;
  transition: background-color .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.topnav-wrap.scrolled {
  background: rgba(243, 246, 247, 0.78);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
  box-shadow: 0 8px 30px rgba(10, 39, 64, 0.06);
}
.topnav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 0;
}
.topnav-links { display: flex; gap: 28px; }
.topnav-links a {
  color: var(--navy-2); text-decoration: none; font-size: 14px; font-weight: 500;
}
.topnav-links a:hover { color: var(--teal-dark); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { width: 34px; height: 34px; }
.brand-word { font-family: var(--serif); font-weight: 600; font-size: 20px; color: var(--navy); }

/* ---------- Landing hero ---------- */
.site-glow { display: none; } /* reserved for future global background accents */

.hero-section { position: relative; overflow: hidden; }
.hero-aurora {
  position: absolute; inset: -10% -10% -30% -10%; z-index: 0; pointer-events: none;
  background:
    radial-gradient(38% 45% at 78% 18%, rgba(27, 199, 181, 0.20), transparent 70%),
    radial-gradient(30% 38% at 15% 70%, rgba(255, 111, 94, 0.14), transparent 70%),
    radial-gradient(45% 50% at 50% 100%, rgba(10, 39, 64, 0.06), transparent 70%);
  animation: auroraDrift 22s ease-in-out infinite alternate;
}
@keyframes auroraDrift {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  100% { transform: translate3d(-2%, 2%, 0) scale(1.05); }
}

.hero {
  position: relative; z-index: 1;
  padding: 64px 0 40px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}
.hero h1 { font-size: 44px; letter-spacing: -0.5px; }
.hero .lede { color: var(--muted); font-size: 18px; max-width: 46ch; margin-top: 18px; }
.hero .cta-row { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px;
  background: #E9FBF8; color: var(--teal-dark);
  font-size: 13px; font-weight: 600; margin-bottom: 18px;
}

/* The one bold moment: a real 3D-perspective stack of certificate cards.
   The card needing attention (critical) sits physically closest to the
   viewer; the healthy one recedes — depth encodes urgency, not decoration. */
.hero-stage {
  position: relative;
  height: 440px;
  perspective: 1400px;
}
.hero-scene {
  position: relative; width: 100%; height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.4s cubic-bezier(.2, .8, .2, 1);
}
.cert-card-3d {
  position: absolute; left: 50%; top: 50%; width: 320px; margin-left: -160px;
  transform-style: preserve-3d;
}
.cert-card-3d.depth-back  { margin-top: -186px; transform: translateZ(-70px) rotateY(-9deg) rotateX(6deg) scale(0.9); z-index: 1; }
.cert-card-3d.depth-mid   { margin-top: -96px;  transform: translateZ(-15px) rotateY(4deg) rotateX(-2deg) scale(0.97); z-index: 2; }
.cert-card-3d.depth-front { margin-top: 6px;    transform: translateZ(35px) rotateY(-4deg) rotateX(-1deg) scale(1.05); z-index: 3; }

.cert-card {
  background: var(--paper);
  border-radius: 12px;
  padding: 18px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  animation: cardFloat 6.5s ease-in-out infinite;
}
.depth-back .cert-card  { box-shadow: 0 14px 26px rgba(10, 39, 64, 0.10); animation-delay: -1.2s; }
.depth-mid .cert-card   { box-shadow: 0 20px 36px rgba(10, 39, 64, 0.14); animation-delay: -3.6s; }
.depth-front .cert-card { box-shadow: 0 32px 56px rgba(10, 39, 64, 0.22); animation-delay: 0s; }
.cert-card-critical {
  box-shadow: 0 32px 56px rgba(10, 39, 64, 0.24), 0 0 0 1px rgba(255, 111, 94, 0.35), 0 0 44px rgba(255, 111, 94, 0.22) !important;
}
@keyframes cardFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-9px); }
}
.cert-host { font-weight: 600; font-size: 14px; color: var(--navy); }
.cert-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }

@media (prefers-reduced-motion: reduce) {
  .hero-aurora, .cert-card { animation: none; }
  .hero-scene { transition: none; }
}

/* ---------- Trust strip ---------- */
.trust-strip {
  display: flex; flex-wrap: wrap; gap: 12px 32px; justify-content: center;
  padding: 22px 24px; margin: 8px auto 0;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.trust-item {
  display: flex; align-items: center; gap: 9px;
  font-size: 14px; color: var(--navy-2); font-weight: 500;
}
.trust-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); flex-shrink: 0; }

/* One orchestrated scroll reveal for the features section only. */
.reveal-group { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal-group.revealed { opacity: 1; transform: translateY(0); }

/* ---------- FAQ (condensed — full documentation lives at /docs.html) ---------- */
.faq-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 24px; }
.faq-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; background: var(--paper); }
.faq-card h3 { font-family: var(--sans); font-size: 15px; font-weight: 600; color: var(--navy); margin-bottom: 6px; }
.faq-card p { color: var(--muted); font-size: 14px; }
.docs-cta-link { color: var(--teal-dark); font-weight: 600; font-size: 14px; text-decoration: none; }
.docs-cta-link:hover { text-decoration: underline; }

/* ---------- Footer (redesigned) ---------- */
.site-footer-new { background: var(--navy-deep); color: #C9D6DC; padding: 56px 0 0; margin-top: 24px; }
.footer-grid {
  display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 40px;
  padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-brand .brand-word { color: #fff; }
.footer-brand p { color: #94A7B0; font-size: 14px; margin: 14px 0 18px; max-width: 32ch; }
.social-links { display: flex; gap: 10px; }
.social-icon {
  width: 34px; height: 34px; border-radius: 9px; background: rgba(255,255,255,0.06);
  display: flex; align-items: center; justify-content: center; color: #C9D6DC;
  transition: background .15s ease, color .15s ease;
}
.social-icon svg { width: 17px; height: 17px; }
a.social-icon:hover { background: var(--teal); color: var(--navy-deep); }
.social-icon.disabled { opacity: 0.35; cursor: default; }
.footer-col-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: #6E828C; margin-bottom: 14px; }
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: #C9D6DC; text-decoration: none; font-size: 14px; }
.footer-col a:hover { color: var(--teal); }
.footer-bottom { padding: 20px 0; font-size: 13px; color: #6E828C; }

@media (max-width: 700px) {
  .faq-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; text-align: center; }
  .footer-brand .brand { justify-content: center; }
  .footer-brand p { margin-left: auto; margin-right: auto; }
  .social-links { justify-content: center; }
}


/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section-head { max-width: 60ch; margin-bottom: 36px; }
.section-head h2 { font-size: 30px; }
.section-head p { color: var(--muted); margin-top: 10px; font-size: 16px; }

/* ---------- Product preview mockup ---------- */
.product-preview {
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center;
}
.preview-frame { perspective: 1200px; }
.preview-frame > .preview-chrome { transform: rotateY(-6deg) rotateX(2deg); transform-style: preserve-3d; }
.preview-chrome {
  background: #E4EAEC; border-radius: 14px 14px 0 0; padding: 12px 16px;
  display: flex; align-items: center; gap: 7px;
  box-shadow: 0 40px 70px rgba(10, 39, 64, 0.20);
}
.preview-chrome span { width: 10px; height: 10px; border-radius: 50%; background: #C7D1D4; }
.preview-url {
  margin-left: 10px; background: var(--paper); border-radius: 6px; padding: 4px 12px;
  font-size: 12px; color: var(--muted); flex: 1;
}
.preview-body {
  background: var(--paper); border-radius: 0 0 14px 14px; padding: 18px;
  display: flex; flex-direction: column; gap: 10px;
  transform: rotateY(-6deg) rotateX(2deg) translateZ(-1px);
  box-shadow: 0 40px 70px rgba(10, 39, 64, 0.14);
}
.preview-row { display: flex; align-items: center; gap: 12px; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.preview-row .dot { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.preview-row > div:nth-child(2) { flex: 1; min-width: 0; }
.preview-host { font-weight: 600; font-size: 13px; color: var(--navy); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.preview-sub { font-size: 11px; color: var(--muted); margin-top: 1px; }
.preview-row .pill { font-size: 10px; padding: 3px 8px; flex-shrink: 0; }
.preview-copy h2 { font-size: 28px; }
.preview-copy p { color: var(--muted); font-size: 16px; margin: 14px 0 24px; max-width: 42ch; }
@media (max-width: 860px) {
  .product-preview { grid-template-columns: 1fr; }
  .preview-copy { text-align: center; }
  .preview-copy p { margin-left: auto; margin-right: auto; }
  .preview-chrome, .preview-body { transform: none; }
}

/* ---------- How it works (a real sequence, so numbered markers earn their place) ---------- */
.steps {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
  position: relative;
}
.steps::before {
  content: ''; position: absolute; top: 22px; left: 12%; right: 12%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--line) 15%, var(--line) 85%, transparent);
  z-index: 0;
}
.step { position: relative; z-index: 1; }
.step-marker {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--navy); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-size: 18px; font-weight: 600;
  margin-bottom: 16px;
  box-shadow: 0 0 0 6px var(--bg), 0 8px 18px rgba(10, 39, 64, 0.22);
}
.step h3 { font-size: 17px; font-family: var(--sans); font-weight: 600; color: var(--navy); }
.step p { color: var(--muted); font-size: 14px; margin-top: 6px; }

.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  background: var(--paper);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }
.feature .icon {
  width: 38px; height: 38px; border-radius: 9px;
  background: linear-gradient(155deg, var(--navy-2), var(--navy-deep));
  color: var(--teal);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; margin-bottom: 14px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 6px 14px rgba(10,39,64,0.18);
}
.feature h3 { font-size: 17px; font-family: var(--sans); font-weight: 600; color: var(--navy); }
.feature p { color: var(--muted); font-size: 14px; margin-top: 6px; }

/* ---------- Pricing ---------- */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.plan-card {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 28px 24px;
  position: relative;
  overflow: hidden; /* keeps the corner ribbon from poking past the card edge and causing scroll on narrow screens */
  clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 0 100%);
  transition: transform .25s ease, box-shadow .25s ease;
}
.plan-card:hover { transform: translateY(-4px); }
.plan-card.featured {
  border-color: var(--teal);
  box-shadow: 0 0 0 1px var(--teal), 0 20px 44px rgba(16, 147, 133, 0.18);
  transform: scale(1.03);
}
.plan-card.featured:hover { transform: scale(1.03) translateY(-4px); }
.plan-card .tag {
  position: absolute; top: 16px; right: -34px;
  background: var(--coral); color: #fff; font-size: 11px; font-weight: 700;
  padding: 4px 36px; transform: rotate(45deg); letter-spacing: 0.5px;
}
.plan-card h3 { font-family: var(--sans); font-size: 15px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.6px; }
.plan-card .price { font-family: var(--serif); font-size: 42px; color: var(--navy); margin: 10px 0 2px; }
.plan-card .price span { font-size: 15px; color: var(--muted); font-family: var(--sans); font-weight: 500; }
.plan-card ul { list-style: none; padding: 0; margin: 20px 0 24px; color: var(--muted); font-size: 14px; }
.plan-card li { padding: 6px 0; display: flex; gap: 8px; }
.plan-card li::before { content: '✓'; color: var(--teal-dark); font-weight: 700; }

/* ---------- Auth panels ---------- */
.auth-wrap {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.auth-side {
  background: var(--navy);
  color: #fff;
  padding: 56px;
  display: flex; flex-direction: column; justify-content: center;
  position: relative;
  overflow: hidden;
}
.auth-side::before {
  content: '';
  position: absolute; inset: -30%;
  background: radial-gradient(circle at 70% 30%, rgba(27,199,181,0.28), transparent 55%);
}
.auth-side h2 { color: #fff; font-size: 32px; position: relative; }
.auth-side p { color: #B9C7CF; margin-top: 14px; max-width: 40ch; position: relative; }
.auth-form-wrap {
  display: flex; align-items: center; justify-content: center; padding: 40px;
}
.auth-form {
  width: 100%; max-width: 380px;
}
.auth-form h1 { font-size: 26px; margin-bottom: 6px; }
.auth-form .sub { color: var(--muted); font-size: 14px; margin-bottom: 26px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: var(--navy); margin-bottom: 6px; }
.field input {
  width: 100%; padding: 11px 13px; border-radius: 8px;
  border: 1px solid var(--line); font-size: 14px; font-family: var(--sans);
  background: var(--paper);
}
.field input:focus { outline: 2px solid var(--teal); outline-offset: 1px; border-color: transparent; }
.form-error {
  background: #FCEEEC; color: var(--red); border: 1px solid #F3D6D3;
  padding: 10px 12px; border-radius: 8px; font-size: 13px; margin-bottom: 16px; display: none;
}
.form-error.visible { display: block; }
.auth-switch { margin-top: 20px; font-size: 14px; color: var(--muted); text-align: center; }

/* ---------- Dashboard shell ---------- */
.app-shell { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.sidebar {
  background: var(--navy); color: #fff; padding: 24px 18px;
  display: flex; flex-direction: column;
}
.sidebar .brand-word { color: #fff; }
.sidebar nav { margin-top: 40px; display: flex; flex-direction: column; gap: 4px; }
.sidebar nav a, .sidebar-user {
  color: #C9D6DC; text-decoration: none; padding: 10px 12px; border-radius: 8px; font-size: 14px; font-weight: 500;
}
.sidebar nav a.active, .sidebar nav a:hover { background: rgba(255,255,255,0.08); color: #fff; }
.plan-widget {
  margin-top: auto; background: rgba(255,255,255,0.06); border-radius: 10px; padding: 16px;
}
.plan-widget .name { font-size: 13px; color: #9FB2BB; text-transform: uppercase; letter-spacing: 0.4px; }
.plan-widget .usage { font-family: var(--serif); font-size: 20px; color: #fff; margin: 6px 0 10px; }
.usage-bar { height: 6px; border-radius: 999px; background: rgba(255,255,255,0.15); overflow: hidden; }
.usage-bar > div { height: 100%; background: var(--teal); }

.main {
  padding: 32px 40px;
}
.main-head {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; flex-wrap: wrap; gap: 16px;
}
.main-head h1 { font-size: 26px; }
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 28px; }
.stat-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px;
}
.stat-card .n { font-family: var(--serif); font-size: 28px; color: var(--navy); }
.stat-card .l { font-size: 13px; color: var(--muted); margin-top: 4px; }

.add-domain-form {
  display: flex; gap: 10px; margin-bottom: 12px; flex-wrap: wrap;
}
.add-domain-form input[type="text"] {
  flex: 1; min-width: 220px; padding: 12px 14px; border-radius: 8px; border: 1px solid var(--line); font-size: 14px;
}
.add-domain-form input:focus { outline: 2px solid var(--teal); outline-offset: 1px; border-color: transparent; }
.add-domain-form select {
  padding: 12px 14px; border-radius: 8px; border: 1px solid var(--line); font-size: 14px;
  background: var(--paper); color: var(--ink); max-width: 180px;
}
.new-group-row {
  display: flex; gap: 10px; margin-bottom: 24px; flex-wrap: wrap;
}
.new-group-row input {
  flex: 1; min-width: 200px; padding: 10px 13px; border-radius: 8px; border: 1px solid var(--line); font-size: 14px;
}

/* ---------- Internal certificate (pasted PEM) ---------- */
.add-internal-row {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 20px;
}
.add-internal-hint { font-size: 13px; color: var(--muted); }
.internal-cert-panel {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; margin-bottom: 24px;
}
.internal-cert-panel label {
  display: block; font-size: 13px; font-weight: 600; color: var(--navy); margin-bottom: 6px;
}
.internal-cert-panel input,
.internal-cert-panel textarea {
  width: 100%; padding: 11px 13px; border-radius: 8px; border: 1px solid var(--line);
  font-size: 14px; font-family: var(--sans); margin-bottom: 16px; background: var(--paper);
}
.internal-cert-panel textarea {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px; line-height: 1.5; resize: vertical;
}
.internal-cert-panel input:focus,
.internal-cert-panel textarea:focus {
  outline: 2px solid var(--teal); outline-offset: 1px; border-color: transparent;
}
.internal-cert-actions { display: flex; gap: 10px; }
.source-tag {
  font-size: 11px; font-weight: 600; color: var(--navy-2); background: #EAF2F5;
  padding: 2px 8px; border-radius: 999px; display: inline-block;
}

.active-filter-bar {
  display: flex; align-items: center; justify-content: space-between;
  background: #EAF2F5; border: 1px solid var(--line); border-radius: 8px;
  padding: 10px 14px; margin-bottom: 16px; font-size: 14px; color: var(--navy);
}

.billing-paused-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  background: #FDE9E3; border: 1px solid #F3C7BB; border-radius: 8px;
  padding: 12px 16px; margin-bottom: 20px; font-size: 14px; color: #A3402E; font-weight: 500;
}

.stat-card { cursor: pointer; transition: box-shadow .12s ease, border-color .12s ease; }
.stat-card:hover { box-shadow: var(--shadow); }
.stat-card.active { border-color: var(--teal); box-shadow: 0 0 0 1px var(--teal); }

.group-tag {
  font-size: 11px; font-weight: 600; color: var(--navy-2); background: #EAF2F5;
  padding: 2px 8px; border-radius: 999px; margin-top: 4px; display: inline-block;
}

/* ---------- Mobile top bar + slide-in sidebar ---------- */
.mobile-topbar { display: none; }
.hamburger {
  background: var(--paper); border: 1px solid var(--line); border-radius: 8px;
  width: 40px; height: 40px; font-size: 18px; color: var(--navy);
}
.sidebar-overlay {
  display: none; position: fixed; inset: 0; background: rgba(10,39,64,0.5); z-index: 90;
}

.domain-list { display: flex; flex-direction: column; gap: 10px; }
.domain-row {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px; display: flex; align-items: center; gap: 16px;
}
.domain-row .dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.domain-row .host { font-weight: 600; color: var(--navy); font-size: 15px; }
.domain-row .meta { font-size: 13px; color: var(--muted); margin-top: 2px; }
.domain-row .spacer { flex: 1; }
.pill {
  font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; text-transform: uppercase; letter-spacing: 0.4px;
}
.pill-valid { background: #E7F8F1; color: #1B8F5C; }
.pill-warning { background: #FDF2DA; color: #A8760A; }
.pill-critical { background: #FDE9E3; color: #C6472F; }
.pill-expired { background: #FBDEDA; color: var(--red); }
.pill-error { background: #EFEFEF; color: #6B6B6B; }
.pill-pending { background: #EAF2F5; color: var(--navy-2); }

.empty-state {
  text-align: center; padding: 60px 20px; color: var(--muted);
  border: 1px dashed var(--line); border-radius: var(--radius); background: var(--paper);
}
.empty-state h3 { color: var(--navy); margin-bottom: 8px; font-family: var(--sans); font-weight: 600; }

.toast {
  position: fixed; bottom: 24px; right: 24px;
  background: var(--navy); color: #fff; padding: 14px 18px; border-radius: 10px;
  font-size: 14px; box-shadow: var(--shadow); opacity: 0; transform: translateY(8px);
  transition: opacity .2s ease, transform .2s ease; pointer-events: none; max-width: 320px;
}
.toast.visible { opacity: 1; transform: translateY(0); }
.toast.error { background: var(--red); }

.admin-table-wrap { overflow-x: auto; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th, .admin-table td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.admin-table th { color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: 0.4px; }
.admin-table tr:last-child td { border-bottom: none; }
.plan-chip { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; text-transform: capitalize; }
.plan-chip-trial { background: #EAF2F5; color: var(--navy-2); }
.plan-chip-starter { background: #E9FBF8; color: var(--teal-dark); }
.plan-chip-pro { background: #FDE9E3; color: var(--coral); }
.plan-chip-unlimited { background: #0A2740; color: #fff; }

/* ---------- Upgrade modal ---------- */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(10,39,64,0.55);
  display: none; align-items: center; justify-content: center; padding: 20px; z-index: 100;
}
.modal-overlay.visible { display: flex; }
.modal {
  background: var(--paper); border-radius: 16px; padding: 28px;
  max-width: 760px; width: 100%; box-shadow: var(--shadow);
}
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.modal-head h2 { font-size: 22px; }
.modal-close {
  background: none; border: none; font-size: 18px; color: var(--muted);
  width: 32px; height: 32px; border-radius: 8px;
}
.modal-close:hover { background: var(--bg); color: var(--navy); }
.modal-plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; }
.modal-plan {
  border: 1px solid var(--line); border-radius: 12px; padding: 20px;
  display: flex; flex-direction: column;
}
.modal-plan.current { border-color: var(--teal); background: #F3FCFB; }
.modal-plan .mp-name { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--muted); }
.modal-plan .mp-price { font-family: var(--serif); font-size: 32px; color: var(--navy); margin: 8px 0 4px; }
.modal-plan .mp-price span { font-size: 13px; color: var(--muted); font-family: var(--sans); }
.modal-plan .mp-detail { font-size: 13px; color: var(--muted); margin-bottom: 16px; flex: 1; }
.modal-plan .mp-current-badge {
  font-size: 12px; font-weight: 700; color: var(--teal-dark); margin-top: 6px; text-align: center;
}
@media (max-width: 560px) {
  .modal-plans { grid-template-columns: 1fr; }
}

/* ---------- Documentation page ---------- */
.docs-layout {
  display: grid; grid-template-columns: 220px 1fr; gap: 48px;
  padding: 48px 0 80px; align-items: start;
}
.docs-toc {
  position: sticky; top: 84px;
  display: flex; flex-direction: column; gap: 2px;
  font-size: 14px;
}
.docs-toc-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--muted); margin-bottom: 8px; }
.docs-toc a {
  color: var(--muted); text-decoration: none; padding: 6px 10px; border-radius: 6px; border-left: 2px solid transparent;
}
.docs-toc a:hover { color: var(--navy); background: #EAF2F5; }

.docs-content h1 { font-size: 34px; }
.docs-lede { color: var(--muted); font-size: 17px; margin-top: 10px; max-width: 62ch; }
.docs-section { margin-top: 44px; padding-top: 8px; border-top: 1px solid var(--line); }
.docs-section h2 { font-size: 22px; margin-bottom: 12px; }
.docs-section p { color: var(--ink); font-size: 15px; line-height: 1.7; margin-bottom: 12px; max-width: 68ch; }
.docs-list { margin: 0 0 12px; padding-left: 20px; max-width: 68ch; }
.docs-list li { color: var(--ink); font-size: 15px; line-height: 1.7; margin-bottom: 8px; }
.docs-faq-item { margin-bottom: 20px; }
.docs-faq-item h3 { font-family: var(--sans); font-size: 15px; font-weight: 600; color: var(--navy); margin-bottom: 4px; }
.docs-faq-item p { color: var(--muted); font-size: 14px; margin-bottom: 0; }
.docs-support {
  margin-top: 48px; padding: 20px 24px; background: #EAF2F5; border-radius: var(--radius);
  font-size: 14px; color: var(--navy-2);
}
.docs-support a { color: var(--teal-dark); font-weight: 600; }

@media (max-width: 860px) {
  .docs-layout { grid-template-columns: 1fr; padding: 28px 0 60px; }
  .docs-toc {
    position: static; flex-direction: row; flex-wrap: wrap; gap: 6px;
    padding-bottom: 20px; margin-bottom: 20px; border-bottom: 1px solid var(--line);
  }
  .docs-toc-title { width: 100%; }
  .docs-toc a { background: var(--paper); border: 1px solid var(--line); font-size: 13px; }
}

/* ---------- DNS lookup tool ---------- */
.lookup-panel { max-width: 720px; margin: 0 auto; }
.lookup-form { display: flex; gap: 10px; margin-bottom: 16px; }
.lookup-form input {
  flex: 1; padding: 13px 16px; border-radius: 10px; border: 1px solid var(--line);
  font-size: 15px; background: var(--paper);
}
.lookup-form input:focus { outline: 2px solid var(--teal); outline-offset: 1px; border-color: transparent; }
.lookup-types { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 24px; }
.type-pill {
  padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--paper);
  font-size: 13px; font-weight: 600; color: var(--navy-2); cursor: pointer;
}
.type-pill:hover { border-color: var(--navy); }
.type-pill.active { background: var(--navy); color: #fff; border-color: var(--navy); }
.lookup-status { color: var(--muted); font-size: 14px; padding: 20px 0; text-align: center; }
.lookup-status.lookup-error { color: var(--red); }
.lookup-group {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px; margin-bottom: 12px;
}
.lookup-group-type {
  font-size: 11px; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase;
  color: var(--teal-dark); margin-bottom: 8px;
}
.lookup-table { width: 100%; border-collapse: collapse; }
.lookup-table td { padding: 6px 0; border-top: 1px solid var(--line); font-size: 13px; }
.lookup-table tr:first-child td { border-top: none; }
.lookup-value {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: var(--ink); word-break: break-all;
}
.lookup-meta { color: var(--muted); text-align: right; white-space: nowrap; padding-left: 12px; }
.lookup-empty { color: var(--muted); font-size: 13px; }

.tools-cta { padding-top: 0; }
.tools-cta-card {
  background: var(--navy); border-radius: 20px; padding: 36px 40px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.tools-cta-card h2 { color: #fff; font-size: 22px; }
.tools-cta-card p { color: #B9C7CF; font-size: 14px; margin-top: 8px; max-width: 48ch; }

@media (max-width: 700px) {
  .lookup-form { flex-direction: column; }
  .tools-cta-card { flex-direction: column; text-align: center; }
  .tools-cta-card p { margin-left: auto; margin-right: auto; }
}

/* ---------- Account settings page ---------- */
.account-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; max-width: 860px; }
.account-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px;
}
.account-card h2 { font-family: var(--sans); font-size: 16px; font-weight: 700; color: var(--navy); margin-bottom: 18px; }
.account-card .field input:disabled { background: var(--bg); color: var(--muted); cursor: not-allowed; }
.field-hint { font-size: 12px; color: var(--muted); margin-top: -10px; margin-bottom: 16px; }
.form-success {
  background: #E7F8F1; color: #1B8F5C; border: 1px solid #BEE9D6;
  padding: 10px 12px; border-radius: 8px; font-size: 13px; margin-bottom: 16px; display: none;
}
.form-success.visible { display: block; }
.plan-summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.plan-summary-name { font-family: var(--serif); font-size: 20px; color: var(--navy); }
.plan-summary-detail { font-size: 13px; color: var(--muted); margin-top: 4px; }
@media (max-width: 760px) {
  .account-grid { grid-template-columns: 1fr; }
}

footer.site-footer {
  border-top: 1px solid var(--line); padding: 28px 0; color: var(--muted); font-size: 13px;
  display: flex; justify-content: space-between;
}

@media (max-width: 860px) {
  .topnav {
    flex-direction: column; align-items: center; justify-content: center;
    gap: 14px; padding: 18px 0 22px;
  }
  .topnav-links { gap: 22px; order: 2; }
  #navButtons { justify-content: center; width: 100%; order: 3; }

  .hero { grid-template-columns: 1fr; text-align: center; }
  .hero .cta-row { justify-content: center; }

  /* The 3D fan is a desktop moment — on mobile it collapses to a simple
     flat stack inside a navy card, same as the original static layout. */
  .hero-stage {
    height: auto; perspective: none; max-width: 440px; margin: 0 auto;
    background: var(--navy); border-radius: 20px; padding: 28px;
  }
  .hero-scene {
    transform: none !important; position: static;
    display: flex; flex-direction: column; gap: 12px;
  }
  .cert-card-3d { position: static; width: auto; margin: 0 !important; transform: none !important; }
  .cert-card { animation: none; box-shadow: var(--shadow) !important; }

  .section-head { text-align: center; margin-left: auto; margin-right: auto; }
  .features, .pricing-grid, .steps { grid-template-columns: 1fr; }
  .steps::before { display: none; }
  .step { text-align: center; }
  .step-marker { margin-left: auto; margin-right: auto; }
  .feature { text-align: center; }
  .feature .icon { margin-left: auto; margin-right: auto; }
  .pricing-grid { max-width: 420px; margin: 0 auto; }

  /* The rotated corner ribbon looks clipped/broken on narrow screens —
     swap it for a plain inline badge above the plan name instead. */
  .plan-card { text-align: center; }
  .plan-card.featured { transform: none; }
  .plan-card.featured:hover { transform: translateY(-4px); }
  .plan-card ul { text-align: left; display: inline-block; }
  .plan-card .tag {
    position: static; display: inline-block; transform: none;
    background: var(--coral); color: #fff; font-size: 11px; font-weight: 700;
    letter-spacing: 0.5px; padding: 4px 10px; border-radius: 6px; margin-bottom: 10px;
  }

  .auth-wrap { grid-template-columns: 1fr; }
  .auth-side { display: none; }

  .app-shell { grid-template-columns: 1fr; }
  .mobile-topbar {
    display: flex; align-items: center; gap: 14px;
    padding: 14px 0 20px; border-bottom: 1px solid var(--line); margin-bottom: 20px;
  }
  .sidebar {
    position: fixed; top: 0; left: 0; bottom: 0; width: 260px; z-index: 100;
    transform: translateX(-100%); transition: transform .2s ease;
  }
  .sidebar.open { transform: translateX(0); }
  .sidebar-overlay.visible { display: block; }
  .main { padding: 16px 18px 24px; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .add-domain-form select { max-width: none; flex: 1; }
  .domain-row { flex-wrap: wrap; }
  .domain-row .spacer { display: none; }

  footer.site-footer { flex-direction: column; align-items: center; text-align: center; gap: 8px; }
}

@media (max-width: 480px) {
  .container { padding: 0 20px; }
  .hero { padding: 32px 0 24px; }
  .hero h1 { font-size: 28px; }
  .hero .lede { font-size: 15px; margin-left: auto; margin-right: auto; }
  .hero-badge { margin-bottom: 12px; }
  .section { padding: 36px 0; }
  .section-head h2 { font-size: 22px; }
  .plan-card .price { font-size: 32px; }
  .main { padding: 14px 14px 20px; }
  .main-head h1 { font-size: 21px; }
  .stat-card { padding: 14px 14px; }
  .stat-card .n { font-size: 22px; }
  .domain-row { padding: 12px 14px; gap: 10px; }
  .domain-row .host { font-size: 14px; }
}
