/* ========== ENTERPRISE VISUAL POLISH OVERRIDES ========== */

/* Improve buttons with better depth and shadows */
.btn {
  padding: 13px 28px !important;
  border-radius: 10px !important;
  font-weight: 600;
  transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2) !important;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.btn:hover::before {
  opacity: 1;
}

.btn-primary {
  background: linear-gradient(135deg, #00ff88 0%, #00e676 100%) !important;
  box-shadow: 0 4px 16px rgba(0, 230, 118, 0.25), 0 0 32px rgba(0, 230, 118, 0.15) !important;
}

.btn-primary:hover {
  box-shadow: 0 8px 28px rgba(0, 230, 118, 0.35), 0 0 48px rgba(0, 230, 118, 0.25) !important;
  transform: translateY(-3px) !important;
}

.btn-secondary {
  background: rgba(255,255,255,0.08) !important;
  border: 1.5px solid rgba(255,255,255,0.15) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.btn-secondary:hover {
  background: rgba(0, 230, 118, 0.08) !important;
  border-color: var(--accent) !important;
  box-shadow: 0 8px 24px rgba(0, 230, 118, 0.15) !important;
}

/* Enhanced hero visual with gradients and depth */
.hero-visual {
  background: linear-gradient(135deg, rgba(0, 230, 118, 0.08) 0%, rgba(0, 230, 118, 0.02) 50%, transparent 100%);
  border-radius: 20px;
  border: 1px solid rgba(0, 230, 118, 0.2);
  box-shadow: 0 0 60px rgba(0, 230, 118, 0.15), inset 0 0 60px rgba(0, 230, 118, 0.05);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  position: relative;
  overflow: hidden;
}

.hero-visual::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 40%, rgba(0, 255, 136, 0.1) 0%, transparent 50%),
              radial-gradient(circle at 70% 60%, rgba(0, 204, 106, 0.05) 0%, transparent 50%);
  pointer-events: none;
}

.hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(45deg, transparent 48%, rgba(0, 230, 118, 0.05) 49%, rgba(0, 230, 118, 0.05) 51%, transparent 52%);
  background-size: 8px 8px;
  opacity: 0.3;
  pointer-events: none;
}

/* Card polish with better shadows and gradients */
.card {
  background: linear-gradient(180deg, rgba(20, 20, 24, 0.8) 0%, rgba(14, 14, 17, 0.8) 100%) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.3), 0 8px 32px rgba(0, 0, 0, 0.2) !important;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0, 255, 136, 0.05) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.card:hover {
  border-color: rgba(0, 230, 118, 0.5) !important;
  background: linear-gradient(180deg, rgba(20, 20, 24, 0.95) 0%, rgba(10, 30, 20, 0.9) 100%) !important;
  box-shadow: 0 0 40px rgba(0, 230, 118, 0.2), 0 0 0 1px rgba(0, 230, 118, 0.3) !important;
  transform: translateY(-6px) !important;
}

.card:hover::before {
  opacity: 1;
}

/* Tier/pricing card polish */
.tier {
  background: linear-gradient(180deg, rgba(20, 20, 24, 0.7) 0%, rgba(10, 10, 13, 0.7) 100%) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2) !important;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
  position: relative;
  overflow: hidden;
}

.tier::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0, 255, 136, 0.03) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.tier:hover {
  border-color: rgba(255, 255, 255, 0.2) !important;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.3) !important;
  transform: translateY(-6px) !important;
}

.tier:hover::after {
  opacity: 1;
}

.tier.featured {
  background: linear-gradient(180deg, rgba(0, 230, 118, 0.08) 0%, rgba(0, 230, 118, 0.02) 50%, rgba(10, 10, 13, 0.8) 100%) !important;
  border: 1.5px solid rgba(0, 230, 118, 0.4) !important;
  box-shadow: 0 0 40px rgba(0, 230, 118, 0.2), 0 0 0 1px rgba(0, 230, 118, 0.25), 0 24px 72px rgba(0, 230, 118, 0.15) !important;
}

.tier.featured:hover {
  box-shadow: 0 0 60px rgba(0, 230, 118, 0.3), 0 0 0 1px rgba(0, 230, 118, 0.4), 0 32px 96px rgba(0, 230, 118, 0.2) !important;
}

/* Terminal/code block polish */
.terminal {
  background: var(--code-bg);
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.3),
              0 20px 56px -20px rgba(0, 0, 0, 0.5),
              inset 0 1px 0 rgba(255,255,255,0.08) !important;
  border-radius: 14px !important;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.terminal .bar {
  background: linear-gradient(180deg, rgba(23, 23, 28, 0.8) 0%, rgba(15, 15, 20, 0.9) 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

/* Cohort cards polish */
.cohort-card {
  background: linear-gradient(180deg, rgba(20, 20, 24, 0.6) 0%, rgba(14, 14, 17, 0.6) 100%) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15) !important;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
  position: relative;
  overflow: hidden;
}

.cohort-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0, 255, 136, 0.04) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.cohort-card:hover {
  border-color: rgba(0, 230, 118, 0.4) !important;
  background: linear-gradient(180deg, rgba(20, 20, 24, 0.8) 0%, rgba(10, 30, 20, 0.7) 100%) !important;
  box-shadow: 0 16px 48px rgba(0, 230, 118, 0.15), 0 0 0 1px rgba(0, 230, 118, 0.2) !important;
  transform: translateY(-8px) !important;
}

.cohort-card:hover::before {
  opacity: 1;
}

/* Eyebrow/status badge polish */
.eyebrow {
  background: linear-gradient(135deg, rgba(0, 230, 118, 0.06) 0%, transparent 100%);
  border: 1px solid rgba(0, 230, 118, 0.3) !important;
  box-shadow: 0 0 24px rgba(0, 230, 118, 0.15), inset 0 0 24px rgba(0, 230, 118, 0.05) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-weight: 600;
  letter-spacing: 0.05em;
}

/* Logo/brand polish */
.logo-wordmark .mark {
  box-shadow: 0 0 24px rgba(0, 230, 118, 0.3), inset 0 0 24px rgba(255,255,255,0.05) !important;
  background: linear-gradient(135deg, #00ff88 0%, #00cc6a 100%) !important;
  position: relative;
}

.logo-wordmark .mark::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.15) 0%, transparent 70%);
  border-radius: 7px;
}

/* Section separators with softer transitions */
.section-stripe::before,
.section-stripe::after {
  height: 64px;
  background: linear-gradient(180deg, var(--bg) 0%, transparent 100%) !important;
}

.section-stripe::after {
  background: linear-gradient(0deg, var(--bg) 0%, transparent 100%) !important;
}

/* Enhanced animations for hero elements */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-8px); }
}

.hero-visual {
  animation: float 6s ease-in-out infinite;
}

/* Better focus states for accessibility */
.btn:focus,
input:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(0, 230, 118, 0.3) !important;
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Text selection polish */
::selection {
  background: rgba(0, 230, 118, 0.25);
  color: var(--fg);
}

/* Improve nav hover states */
nav ul a:hover {
  color: var(--accent) !important;
}

/* Better link underlines */
a {
  position: relative;
  transition: color 0.2s ease;
}

/* Section intro text polish */
.section-intro {
  letter-spacing: -0.003em;
  line-height: 1.7;
}

/* Better heading hierarchy */
h1 {
  text-shadow: 0 0 40px rgba(0, 255, 136, 0.1);
}

h2 {
  letter-spacing: -0.02em;
}

/* Polish the grid backgrounds */
.hero::after {
  opacity: 0.8;
  animation: grid-drift 20s linear infinite;
}

@keyframes grid-drift {
  0% { transform: translate(0, 0); }
  100% { transform: translate(10px, 10px); }
}

/* Responsive polish adjustments */
@media (max-width: 768px) {
  .btn {
    padding: 12px 24px !important;
  }

  .card,
  .tier,
  .cohort-card {
    border-radius: 12px !important;
  }
}

/* ========== HERO TYPOGRAPHY — FIX CASCADE CONFLICT ========== */
/* The legacy `.hero h1` rule blows out the two-column layout. Pin it. */

.hero-left h1 {
  font-size: clamp(42px, 4.2vw, 60px) !important;
  line-height: 1.05 !important;
  letter-spacing: -0.03em !important;
  font-weight: 700 !important;
  max-width: 100% !important;
  margin: 24px 0 22px !important;
}

.hero-left .hero-subline {
  font-size: 18px;
  line-height: 1.6;
  color: var(--fg-mid);
  max-width: 480px;
  margin: 0 0 36px;
  font-weight: 400;
}

/* ========== HERO VISUAL — RESOURCE TOGGLE STACK ========== */
/* Enterprise-grade right-side visual inspired by WorkOS floating cards.
   Six glassmorphic rows showing CelDrive expanding local resources. */

.hero-visual {
  /* override polish float animation on the container itself — the
     inner stack handles its own float */
  animation: none !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  width: 100%;
  max-width: 560px;
  aspect-ratio: auto;
  padding: 0;
  position: relative;
  perspective: 1400px;
  overflow: visible;
}

.hero-visual::before,
.hero-visual::after {
  /* kill the inherited pattern/overlay so they don't clash with the cards */
  display: none !important;
}

.resource-stack {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 22px 18px;
  border-radius: 22px;
  background:
    radial-gradient(ellipse 120% 80% at 50% 0%, rgba(0, 230, 118, 0.10) 0%, transparent 60%),
    linear-gradient(180deg, rgba(20, 20, 26, 0.55) 0%, rgba(8, 8, 12, 0.75) 100%);
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.4),
    0 40px 100px -30px rgba(0, 230, 118, 0.25),
    0 20px 60px -20px rgba(0, 0, 0, 0.8),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  transform-style: preserve-3d;
  transform: perspective(1600px) rotateY(-6deg) rotateX(3deg);
  animation: stack-float 8s ease-in-out infinite;
}

.resource-stack::before {
  /* top edge shine */
  content: "";
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(0, 230, 118, 0.4) 50%, transparent 100%);
  pointer-events: none;
}

.resource-stack-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 4px 10px;
  margin-bottom: 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.rs-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-mid);
}

.rs-chip-dot {
  width: 7px;
  height: 7px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent);
  animation: pulse-ring 2s infinite;
}

.rs-host {
  font-family: "JetBrains Mono", "SF Mono", "Menlo", monospace;
  font-size: 11px;
  color: var(--fg-dim);
  letter-spacing: 0;
}

.resource-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 14px;
  background: linear-gradient(135deg, rgba(24, 24, 30, 0.9) 0%, rgba(14, 14, 18, 0.9) 100%);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  box-shadow:
    0 4px 14px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), border-color 0.3s ease;
}

.resource-card--off {
  opacity: 0.58;
  background: linear-gradient(135deg, rgba(16, 16, 20, 0.7) 0%, rgba(10, 10, 14, 0.7) 100%);
}

.resource-card--focus {
  border-color: rgba(0, 230, 118, 0.45);
  background:
    linear-gradient(135deg, rgba(0, 230, 118, 0.10) 0%, rgba(14, 14, 18, 0.92) 100%);
  box-shadow:
    0 0 0 1px rgba(0, 230, 118, 0.3),
    0 10px 40px -8px rgba(0, 230, 118, 0.35),
    inset 0 1px 0 rgba(0, 230, 118, 0.2);
  transform: translateZ(40px) scale(1.025);
}

/* Toggle pill */
.rc-toggle {
  width: 34px;
  height: 20px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  position: relative;
  flex-shrink: 0;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.rc-knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
  transition: left 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.resource-card--on .rc-toggle {
  background: var(--accent);
  box-shadow: 0 0 14px rgba(0, 230, 118, 0.5);
}

.resource-card--on .rc-knob {
  left: 16px;
}

/* Label block */
.rc-info {
  flex: 1;
  min-width: 0;
}

.rc-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--fg);
  letter-spacing: -0.005em;
  line-height: 1.3;
}

.rc-sub {
  font-family: "JetBrains Mono", "SF Mono", "Menlo", monospace;
  font-size: 11.5px;
  color: var(--fg-dim);
  margin-top: 2px;
  letter-spacing: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Status pill */
.rc-status {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  letter-spacing: 0.02em;
  flex-shrink: 0;
  font-family: "JetBrains Mono", "SF Mono", "Menlo", monospace;
}

.rc-status--on {
  background: rgba(0, 230, 118, 0.12);
  color: var(--accent-bright);
  border: 1px solid rgba(0, 230, 118, 0.32);
  box-shadow: 0 0 12px rgba(0, 230, 118, 0.1);
}

.rc-status--muted {
  background: rgba(255, 255, 255, 0.04);
  color: var(--fg-dim);
  border: 1px solid var(--border);
}

@keyframes stack-float {
  0%, 100% {
    transform: perspective(1600px) rotateY(-6deg) rotateX(3deg) translateY(0);
  }
  50% {
    transform: perspective(1600px) rotateY(-6deg) rotateX(3deg) translateY(-8px);
  }
}

/* ========== HERO GRID RESPONSIVE COLLAPSE ========== */
@media (max-width: 960px) {
  .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 48px !important;
  }
  .hero-left {
    max-width: 100% !important;
  }
  .hero-visual {
    max-width: 480px;
    margin: 0 auto;
  }
  .resource-stack {
    transform: none;
    animation: none;
  }
  .resource-card--focus {
    transform: none;
  }
}

@media (max-width: 520px) {
  .hero-left h1 {
    font-size: 38px !important;
  }
  .resource-stack {
    padding: 16px 12px;
  }
  .resource-card {
    padding: 11px 12px;
    gap: 10px;
  }
  .rc-sub {
    font-size: 10.5px;
  }
  .rc-status {
    font-size: 10px;
    padding: 3px 8px;
  }
  .rs-host {
    display: none;
  }
}
