/* ==========================================================
   PrimexHost — Design tokens
   Palette: cool corporate whites + deep navy + electric-blue CTA + teal signal
   Type: Space Grotesk (display) / Inter (body) / IBM Plex Mono (specs & stats)
   ========================================================== */
:root {
  --bg: #ffffff;
  --bg-soft: #f5f7fb;
  --bg-navy: #0e1f3d;
  --ink: #101828;
  --ink-muted: #5b6472;
  --ink-faint: #98a2b3;
  --primary: #14294f;
  --primary-2: #1b3a6b;
  --accent: #2f6feb;
  --accent-2: #5a8dff;
  --teal: #0ea5a4;
  --border: #e4e8f0;
  --border-soft: #eef1f6;
  --danger: #d0342c;
  --radius: 10px;
  --radius-lg: 18px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.06);
  --shadow-md: 0 8px 24px rgba(16, 24, 40, 0.08);
  --shadow-lg: 0 24px 48px rgba(14, 31, 61, 0.14);
  --container: 1180px;
  --font-display: "Space Grotesk", "Inter", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}
p { margin: 0 0 1em; color: var(--ink-muted); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
.mono { font-family: var(--font-mono); letter-spacing: -0.01em; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn-primary { background: var(--accent); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: #2a63d6; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-outline { background: transparent; border-color: var(--border); color: var(--ink); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }
.btn-block { width: 100%; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* Top nav */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border-soft);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
}
.brand-mark {
  width: 30px; height: 30px;
  border-radius: 8px;
  background: linear-gradient(155deg, var(--accent), var(--primary-2));
  position: relative;
  flex-shrink: 0;
}
.brand-mark::before, .brand-mark::after {
  content: "";
  position: absolute;
  left: 7px; right: 7px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
}
.brand-mark::before { top: 10px; }
.brand-mark::after { top: 16px; }
.nav-links {
  display: flex;
  gap: 28px;
  align-items: center;
  list-style: none;
  margin: 0; padding: 0;
}
.nav-links a { font-size: 14.5px; font-weight: 500; color: var(--ink-muted); }
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav-cta { display: flex; align-items: center; gap: 14px; }
.nav-toggle { display: none; }
.dropdown { position: relative; }
.dropdown-menu {
  position: absolute;
  top: 130%;
  left: 0;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 8px;
  min-width: 230px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: all 0.15s ease;
}
.dropdown:hover .dropdown-menu, .dropdown:focus-within .dropdown-menu {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.dropdown-menu a {
  display: block;
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--ink);
}
.dropdown-menu a:hover { background: var(--bg-soft); }

/* Hero */
.hero {
  padding: 76px 0 40px;
  position: relative;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--teal);
  background: rgba(14, 165, 164, 0.08);
  border: 1px solid rgba(14, 165, 164, 0.25);
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 20px;
}
.eyebrow::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 3px rgba(14, 165, 164, 0.18);
}
.hero h1 { font-size: clamp(32px, 4.2vw, 52px); }
.hero .lede { font-size: 18px; max-width: 46ch; }
.hero-actions { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }

/* Stat strip */
.stat-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-top: 44px;
  background: var(--bg-soft);
}
.stat-strip div { padding: 20px 18px; border-right: 1px solid var(--border); }
.stat-strip div:last-child { border-right: none; }
.stat-num { font-family: var(--font-mono); font-size: 24px; font-weight: 600; color: var(--primary-2); }
.stat-label { font-size: 12.5px; color: var(--ink-muted); margin-top: 4px; }

/* Terminal / rack visual (signature element) */
.rack-card {
  background: var(--bg-navy);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow-lg);
  color: #e6ecfb;
}
.rack-card .rack-title {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: #7fa4ff;
  display: flex;
  justify-content: space-between;
  margin-bottom: 14px;
}
.rack-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 8px;
  font-family: var(--font-mono);
  font-size: 13px;
}
.rack-row .tier-name { color: #e6ecfb; font-weight: 600; }
.rack-row .tier-bar {
  flex: 1;
  height: 6px;
  margin: 0 14px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
}
.rack-row .tier-bar span {
  position: absolute; inset: 0 auto 0 0;
  background: linear-gradient(90deg, var(--teal), var(--accent-2));
  border-radius: 4px;
}
.rack-row .tier-pct { color: #7fa4ff; width: 40px; text-align: right; }

/* Sections */
.section { padding: 84px 0; }
.section-soft { background: var(--bg-soft); }
.section-head { max-width: 640px; margin: 0 0 48px; }
.section-head .eyebrow { margin-bottom: 16px; }
.section-head h2 { font-size: clamp(26px, 3vw, 36px); }

/* Category grid on homepage */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}
.cat-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 26px 22px;
  background: #fff;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--accent); }
.cat-index { font-family: var(--font-mono); font-size: 12.5px; color: var(--teal); }
.cat-card h3 { font-size: 19px; }
.cat-card p { font-size: 14px; margin-bottom: 6px; }
.cat-card .cat-link { font-size: 13.5px; font-weight: 600; color: var(--accent); margin-top: auto; }

/* Pricing cards */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 24px;
  align-items: stretch;
}
.price-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 30px 26px;
  background: #fff;
  display: flex;
  flex-direction: column;
  position: relative;
}
.price-card.popular { border-color: var(--accent); box-shadow: var(--shadow-md); }
.price-card .badge {
  position: absolute;
  top: -13px; left: 26px;
  background: var(--accent);
  color: #fff;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 5px 12px;
  border-radius: 999px;
  text-transform: uppercase;
}
.price-card h3 { font-size: 20px; margin-bottom: 4px; }
.price-amount { font-family: var(--font-mono); font-size: 38px; font-weight: 600; color: var(--ink); margin: 14px 0 2px; }
.price-amount sup { font-size: 16px; top: -14px; }
.price-cycle { font-size: 13px; color: var(--ink-muted); margin-bottom: 18px; }
.price-features { list-style: none; margin: 0 0 26px; padding: 0; flex: 1; }
.price-features li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 14px;
  color: var(--ink);
  padding: 7px 0;
  border-top: 1px solid var(--border-soft);
}
.price-features li:first-child { border-top: none; }
.price-features li::before {
  content: "";
  width: 16px; height: 16px;
  margin-top: 2px;
  flex-shrink: 0;
  border-radius: 50%;
  background: rgba(14, 165, 164, 0.12);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%230ea5a4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' d='M3 8l3 3 7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

/* Category hero (inner pages) */
.page-hero {
  padding: 56px 0 40px;
  border-bottom: 1px solid var(--border-soft);
  background: var(--bg-soft);
}
.breadcrumb { font-size: 13px; color: var(--ink-muted); margin-bottom: 14px; }
.breadcrumb a:hover { color: var(--accent); }

/* Feature list generic */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 22px;
}
.feature-item { display: flex; gap: 14px; }
.feature-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: rgba(47, 111, 235, 0.08);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  color: var(--accent);
  font-family: var(--font-mono);
  font-weight: 700;
}
.feature-item h4 { font-size: 15.5px; margin-bottom: 4px; }
.feature-item p { font-size: 13.5px; margin-bottom: 0; }

/* CTA band */
.cta-band {
  background: linear-gradient(120deg, var(--bg-navy), var(--primary-2));
  border-radius: var(--radius-lg);
  padding: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  color: #fff;
  flex-wrap: wrap;
}
.cta-band h2 { color: #fff; margin-bottom: 6px; }
.cta-band p { color: rgba(255, 255, 255, 0.72); margin-bottom: 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--border-soft); background: var(--bg-soft); padding: 56px 0 28px; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 32px;
  margin-bottom: 40px;
}
.footer-grid h4 { font-size: 13px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink-muted); margin-bottom: 16px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.footer-grid a { font-size: 14px; color: var(--ink-muted); }
.footer-grid a:hover { color: var(--accent); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--ink-faint);
  flex-wrap: wrap;
  gap: 12px;
}

/* Terms page */
.legal-content h2 { font-size: 20px; margin-top: 32px; }
.legal-content { max-width: 760px; }
.legal-content p { color: var(--ink); }

/* Responsive */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .stat-strip { grid-template-columns: repeat(2, 1fr); }
  .stat-strip div:nth-child(2) { border-right: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
  .cta-band { flex-direction: column; align-items: flex-start; }
}
