/* ═══════════════════════════════════════════════════════════
   UX ELEVATE — Hostiny front-end cohesion layer (loaded last)
   Signature: "signal rail" — a thin latency/uptime accent that
   reads as infrastructure, not generic glassmorphism.
   ═══════════════════════════════════════════════════════════ */

:root {
  --ink: #07101c;
  --panel-elevated: rgba(19, 31, 56, 0.88);
  --text-bright: #f4f8ff;
  --muted-2: #8fa3c7;
  --signal: #5ea3ff;
  --signal-soft: rgba(94, 163, 255, 0.16);
  --uptime: #3fd6b0;
  --rail: linear-gradient(90deg, transparent, var(--signal) 20%, var(--uptime) 80%, transparent);
  --type-display: clamp(1.85rem, 1.2rem + 2.4vw, 3.15rem);
  --type-lead: clamp(1.02rem, 0.95rem + 0.45vw, 1.2rem);
  --space-section: clamp(3.25rem, 2.5rem + 3vw, 5.5rem);
  --focus-ring: 0 0 0 3px rgba(94, 163, 255, 0.35);
}

/* ─── Global readability & focus ─────────────────────────── */
body {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 10px;
}

.btn:focus-visible,
.site-nav a:focus-visible,
.segment-chip:focus-visible,
.sidebar-links a:focus-visible {
  box-shadow: var(--focus-ring);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ─── Header: clearer hierarchy + signal rail ────────────── */
.premium-header .nav-shell {
  min-height: 72px;
  gap: 1rem;
}

.premium-brand .brand-copy strong {
  letter-spacing: -0.01em;
  font-weight: 700;
}

.premium-brand .brand-copy small {
  color: var(--muted-2);
  font-size: 0.78rem;
  line-height: 1.35;
}

.premium-header::after {
  content: "";
  display: block;
  height: 2px;
  width: 100%;
  background: var(--rail);
  opacity: 0.55;
  transform: scaleX(0.35);
  transform-origin: center;
  transition: transform 0.5s var(--ease-smooth, cubic-bezier(0.22, 1, 0.36, 1)), opacity 0.35s ease;
}

.premium-header.is-scrolled::after {
  transform: scaleX(1);
  opacity: 0.9;
}

.site-nav a {
  font-weight: 500;
  font-size: 0.94rem;
}

.nav-actions .btn-sm {
  min-height: 40px;
  padding-inline: 1.05rem;
}

.cart-chip {
  border-radius: 999px;
  border: 1px solid rgba(94, 163, 255, 0.28);
  background: rgba(94, 163, 255, 0.08);
}

/* ─── Home hero: trust + speed thesis ────────────────────── */
.page-home .home-hero {
  padding-block: clamp(2.5rem, 2rem + 3vw, 4.5rem) var(--space-section);
}

.page-home .home-hero-copy h1 {
  font-size: var(--type-display);
  line-height: 1.25;
  letter-spacing: -0.02em;
  max-width: 18ch;
  margin-bottom: 1rem;
}

.page-home .home-hero-copy .lead {
  font-size: var(--type-lead);
  color: var(--muted-2);
  max-width: 42ch;
  line-height: 1.75;
}

.page-home .hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.35rem;
}

.page-home .hero-actions .btn {
  min-height: 48px;
  padding-inline: 1.35rem;
  font-weight: 600;
}

.page-home .hero-trust-rail {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1rem;
  margin-top: 1.15rem;
  padding: 0.7rem 0.9rem;
  border-radius: 14px;
  border: 1px solid rgba(94, 163, 255, 0.18);
  background:
    linear-gradient(135deg, rgba(94, 163, 255, 0.08), rgba(63, 214, 176, 0.05)),
    rgba(9, 17, 31, 0.45);
}

.page-home .hero-trust-rail span {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-bright);
  font-size: 0.86rem;
  font-weight: 500;
}

.page-home .hero-trust-rail span::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--uptime);
  box-shadow: 0 0 0 4px rgba(63, 214, 176, 0.18);
}

.page-home .home-proof-grid {
  margin-top: 1.5rem;
  gap: 0.85rem;
}

.page-home .home-proof-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--panel-elevated);
  backdrop-filter: blur(12px);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.page-home .home-proof-card:hover {
  transform: translateY(-3px);
  border-color: rgba(94, 163, 255, 0.35);
  box-shadow: 0 16px 36px rgba(2, 8, 23, 0.28);
}

.page-home .hero-logo-stage {
  position: relative;
}

.page-home .hero-logo-stage::before {
  content: "";
  position: absolute;
  inset: 12% 8%;
  border-radius: 28px;
  background: radial-gradient(circle at 40% 30%, rgba(94, 163, 255, 0.22), transparent 55%);
  filter: blur(2px);
  z-index: 0;
  pointer-events: none;
}

/* ─── Sections: denser rhythm, clearer heads ─────────────── */
.section {
  padding-block: var(--space-section);
}

.premium-section-head h2 {
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.section-badge {
  letter-spacing: 0.02em;
  font-weight: 600;
}

.plan-card,
.feature-card,
.pricing-card,
.stat-card,
.testimonial {
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.plan-card:hover,
.feature-card:hover,
.pricing-card:hover,
.stat-card:hover {
  transform: translateY(-4px);
  border-color: rgba(94, 163, 255, 0.32);
  box-shadow: 0 18px 40px rgba(2, 8, 23, 0.3);
}

.plan-card .price-main,
.premium-price-display .price-amount {
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

/* ─── Products page ──────────────────────────────────────── */
.page-products .pricing-hero-card {
  position: relative;
  overflow: hidden;
}

.page-products .pricing-hero-card::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 2px;
  background: var(--rail);
  opacity: 0.7;
}

.page-products .pricing-hero h1 {
  font-size: clamp(1.7rem, 1.2rem + 1.8vw, 2.6rem);
  letter-spacing: -0.02em;
  max-width: 22ch;
}

.page-products .segment-control {
  gap: 0.55rem;
}

.page-products .segment-chip {
  min-height: 42px;
  border-radius: 999px;
  font-weight: 600;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.page-products .segment-chip:hover {
  transform: translateY(-1px);
}

.page-products .segment-chip.active {
  background: linear-gradient(135deg, rgba(94, 163, 255, 0.22), rgba(63, 214, 176, 0.12));
  border-color: rgba(94, 163, 255, 0.45);
  box-shadow: inset 0 0 0 1px rgba(94, 163, 255, 0.18);
}

.premium-pricing-card .pricing-card-head h2 {
  letter-spacing: -0.015em;
}

.premium-pricing-card .inline-actions .btn,
.pricing-card .btn {
  min-height: 44px;
}

/* ─── Auth surfaces ──────────────────────────────────────── */
.auth-shell .modern-auth-card {
  border: 1px solid rgba(94, 163, 255, 0.16);
  background:
    linear-gradient(180deg, rgba(94, 163, 255, 0.06), transparent 28%),
    var(--panel-elevated);
  box-shadow: 0 22px 50px rgba(2, 8, 23, 0.35);
}

.auth-shell .section-head h2 {
  letter-spacing: -0.02em;
}

.auth-shell .field-label {
  font-weight: 600;
  color: var(--text-bright);
}

.auth-shell input[type="text"],
.auth-shell input[type="email"],
.auth-shell input[type="password"],
.auth-shell input[type="tel"],
.modern-form input {
  min-height: 48px;
  border-radius: 12px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.auth-shell input:focus,
.modern-form input:focus {
  border-color: rgba(94, 163, 255, 0.55);
  box-shadow: 0 0 0 4px var(--signal-soft);
}

.auth-tabs .auth-tab .tab-content {
  border-radius: 14px;
}

.page-hero h1 {
  letter-spacing: -0.02em;
}

/* ─── Dashboard UX ───────────────────────────────────────── */
.dashboard-shell {
  padding-block: clamp(1.5rem, 1rem + 2vw, 2.75rem);
}

.dashboard-sidebar-card {
  border: 1px solid rgba(94, 163, 255, 0.14);
  background:
    linear-gradient(180deg, rgba(94, 163, 255, 0.07), transparent 24%),
    var(--panel-elevated);
  position: sticky;
  top: 92px;
}

.dashboard-account-pill {
  margin-top: 0.45rem;
  display: inline-flex;
}

.dashboard-profile-card {
  padding-bottom: 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 0.35rem;
}

.sidebar-links a {
  border-radius: 12px;
  min-height: 42px;
  display: flex;
  align-items: center;
  padding-inline: 0.9rem;
  font-weight: 500;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.sidebar-links a:hover {
  background: rgba(94, 163, 255, 0.1);
  transform: translateX(-2px);
}

.sidebar-links a.active {
  background: linear-gradient(135deg, rgba(94, 163, 255, 0.22), rgba(63, 214, 176, 0.1));
  color: var(--text-bright);
  box-shadow: inset 3px 0 0 var(--signal);
}

/* ─── CTA + footer polish ────────────────────────────────── */
.premium-cta-box {
  border: 1px solid rgba(94, 163, 255, 0.2);
  background:
    radial-gradient(ellipse 70% 80% at 90% 20%, rgba(63, 214, 176, 0.12), transparent 50%),
    radial-gradient(ellipse 60% 70% at 10% 80%, rgba(94, 163, 255, 0.14), transparent 50%),
    var(--panel-elevated);
}

.premium-cta-box h2 {
  letter-spacing: -0.02em;
}

.premium-cta-actions .btn-lg {
  min-height: 50px;
  padding-inline: 1.5rem;
}

.page-about .page-hero p,
.page-faq .page-hero p {
  max-width: 48ch;
  color: var(--muted-2);
  line-height: 1.75;
}

.page-about .panel,
.page-faq .premium-faq-item {
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.premium-faq-question {
  min-height: 56px;
  text-align: right;
  font-weight: 600;
}

.page-hero {
  padding-block: 2.4rem 1.2rem;
}

.page-hero .breadcrumbs {
  margin-bottom: 0.85rem;
  opacity: 0.85;
}

/* ─── Purchase flow rail (cart / checkout) ─────────────────── */
.purchase-flow-rail,
.premium-checkout-progress {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.65rem;
  margin-bottom: 1.1rem;
  padding: 0.65rem 0.9rem;
  border-radius: 14px;
  border: 1px solid rgba(94, 163, 255, 0.16);
  background: rgba(94, 163, 255, 0.06);
  font-size: 0.86rem;
}

.purchase-flow-rail .flow-step,
.premium-checkout-progress .step {
  color: var(--muted-2);
  font-weight: 500;
}

.purchase-flow-rail .flow-step.active,
.premium-checkout-progress .step.active,
.premium-checkout-progress strong.step.active {
  color: var(--text-bright);
  font-weight: 700;
}

.purchase-flow-rail .flow-arrow,
.premium-checkout-progress .arrow {
  color: rgba(143, 163, 199, 0.65);
}

/* ─── Product detail page ────────────────────────────────── */
.page-product-detail .product-hero {
  padding-bottom: 0.5rem;
}

.page-product-detail .product-summary h1 {
  font-size: clamp(1.65rem, 1.1rem + 1.6vw, 2.35rem);
  letter-spacing: -0.02em;
  line-height: 1.28;
  max-width: 22ch;
}

.page-product-detail .product-summary .lead {
  color: var(--muted-2);
  line-height: 1.75;
  max-width: 52ch;
}

.page-product-detail .hero-micro-stats {
  gap: 0.55rem;
  flex-wrap: wrap;
}

.page-product-detail .mini-stat {
  border-radius: 999px;
  border: 1px solid rgba(94, 163, 255, 0.18);
  background: rgba(94, 163, 255, 0.06);
  padding: 0.35rem 0.75rem;
  font-size: 0.82rem;
}

.page-product-detail .detail-stat {
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.page-product-detail .detail-stat:hover {
  transform: translateY(-2px);
  border-color: rgba(94, 163, 255, 0.32);
  box-shadow: 0 12px 28px rgba(2, 8, 23, 0.22);
}

.page-product-detail .purchase-panel {
  border: 1px solid rgba(94, 163, 255, 0.2);
  background:
    radial-gradient(ellipse 80% 60% at 100% 0%, rgba(63, 214, 176, 0.1), transparent 55%),
    var(--panel-elevated);
  box-shadow: 0 22px 48px rgba(2, 8, 23, 0.32);
}

.page-product-detail .purchase-panel-headline strong {
  font-size: 1.05rem;
  letter-spacing: -0.01em;
}

.page-product-detail .purchase-panel-headline span {
  color: var(--muted-2);
  font-size: 0.88rem;
  line-height: 1.55;
}

.page-product-detail .product-price-display .price-amount {
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.page-product-detail .purchase-trust-rail {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.85rem;
  margin: 0.85rem 0 0.35rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.page-product-detail .purchase-trust-rail span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.82rem;
  color: var(--text-bright);
  font-weight: 500;
}

.page-product-detail .purchase-trust-rail span::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--uptime);
}

.page-product-detail .purchase-actions .btn {
  min-height: 46px;
  font-weight: 600;
}

.page-product-detail .premium-launch-steps {
  gap: 1rem;
}

.page-product-detail .premium-launch-step-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.page-product-detail .premium-launch-step-card:hover {
  transform: translateY(-3px);
  border-color: rgba(94, 163, 255, 0.28);
}

.page-product-detail .enhanced-use-case-card {
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.page-product-detail .enhanced-use-case-card:hover {
  transform: translateY(-3px);
  border-color: rgba(94, 163, 255, 0.24);
}

@media (min-width: 981px) {
  .page-product-detail .purchase-panel {
    position: sticky;
    top: 96px;
  }
}

/* ─── Checkout palette alignment ─────────────────────────── */
.checkout-hero h1 {
  background: linear-gradient(135deg, var(--signal), var(--uptime));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.payment-methods-card,
.order-summary-card {
  border-color: rgba(94, 163, 255, 0.16) !important;
}

.payment-method-option:hover,
.payment-method-active {
  border-color: rgba(94, 163, 255, 0.42) !important;
  box-shadow: 0 12px 30px rgba(47, 125, 240, 0.18) !important;
}

.payment-method-badge-active {
  background: rgba(63, 214, 176, 0.16) !important;
  color: var(--uptime) !important;
}

/* ─── Dashboard surfaces ─────────────────────────────────── */
.dashboard-card,
.dashboard-surface-card,
.list-card,
.side-card {
  border: 1px solid rgba(94, 163, 255, 0.12);
  transition: border-color 0.22s ease, box-shadow 0.22s ease;
}

.dashboard-section-hero {
  background:
    linear-gradient(135deg, rgba(94, 163, 255, 0.08), rgba(63, 214, 176, 0.04)),
    var(--panel-elevated);
}

.dashboard-summary-card,
.dashboard-quick-card {
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.dashboard-quick-card:hover {
  transform: translateY(-3px);
  border-color: rgba(94, 163, 255, 0.28);
  box-shadow: 0 14px 32px rgba(2, 8, 23, 0.24);
}

.dashboard-rich-item {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.dashboard-highlight-panel .money-value {
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.cart-item-form select,
.cart-item-form input {
  min-height: 40px;
  border-radius: 10px;
}

/* ─── Domain page ────────────────────────────────────────── */
.page-domain .domain-search-card,
.page-domain .domain-result-card {
  border: 1px solid rgba(94, 163, 255, 0.16);
  background: var(--panel-elevated);
}

.page-domain .domain-search-form .btn,
.page-domain .domain-register-cta {
  min-height: 46px;
  font-weight: 600;
}

.page-domain .domain-ext-card {
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.page-domain .domain-ext-card:hover {
  transform: translateY(-2px);
  border-color: rgba(94, 163, 255, 0.28);
}

.premium-alert,
.alert {
  border-radius: 14px;
}

.empty-state {
  border: 1px dashed rgba(94, 163, 255, 0.28);
  background: rgba(94, 163, 255, 0.04);
  border-radius: 18px;
  padding: 2rem 1.25rem;
  text-align: center;
}

.empty-state .premium-inline-actions,
.empty-state .inline-actions {
  justify-content: center;
  margin-top: 1rem;
  flex-wrap: wrap;
  gap: 0.65rem;
}

/* ─── Mobile refinements ─────────────────────────────────── */
@media (max-width: 980px) {
  .page-home .home-hero-copy h1 {
    max-width: none;
  }

  .dashboard-sidebar-card {
    position: static;
  }

  .premium-header::after {
    transform: scaleX(1);
    opacity: 0.45;
  }
}

@media (max-width: 640px) {
  .page-home .hero-actions {
    flex-direction: column;
  }

  .page-home .hero-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .page-home .hero-trust-rail {
    flex-direction: column;
    align-items: flex-start;
  }

  .page-home .hero-floating-card {
    display: none;
  }

  .page-home .hero-curved-panel {
    margin-top: 1rem;
  }

  .page-product-detail .purchase-panel {
    position: static;
  }

  .checkout-layout {
    grid-template-columns: 1fr !important;
  }

  .nav-actions .btn-sm {
    width: 100%;
    justify-content: center;
  }
}
