/* ============================================
   SpamJammer — Split Screen Design System
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Instrument+Sans:wght@400;500;600;700&family=Figtree:wght@400;500;600;700&display=swap');

/* --- CSS Variables --- */
:root {
  --dark: #0a0a0a;
  --dark-surface: #141414;
  --dark-border: #2a2a2a;
  --light: #fafafa;
  --light-surface: #f0f0f0;
  --light-border: #e0e0e0;
  --accent: #22C55E;
  --accent-dark: #16a34a;
  --accent-glow: rgba(34, 197, 94, 0.15);
  --text-dark: #fafafa;
  --text-dark-muted: #a0a0a0;
  --text-light: #0a0a0a;
  --text-light-muted: #666666;
  --font-heading: 'Instrument Sans', 'Segoe UI', sans-serif;
  --font-body: 'Figtree', 'Segoe UI', sans-serif;
  --split-divider: 2px;
  --nav-height: 72px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Reset --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background: var(--dark);
  color: var(--text-dark);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

ul, ol {
  list-style: none;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.15;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 3vw, 1.8rem); }
h4 { font-size: 1.2rem; }

p {
  line-height: 1.7;
  font-size: 1.05rem;
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 1000;
  display: flex;
  align-items: center;
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--dark-border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--text-dark);
}

.nav-logo .logo-icon {
  width: 32px;
  height: 32px;
  background: var(--accent);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: var(--dark);
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-dark-muted);
  transition: color var(--transition);
  position: relative;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-dark);
}

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 1px;
}

.nav-cta {
  background: var(--accent) !important;
  color: var(--dark) !important;
  padding: 0.55rem 1.4rem;
  border-radius: 8px;
  font-weight: 600 !important;
  font-size: 0.9rem !important;
  transition: background var(--transition), transform var(--transition) !important;
}

.nav-cta:hover {
  background: var(--accent-dark) !important;
  transform: translateY(-1px);
}

.nav-mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
}

.nav-mobile-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-dark);
  border-radius: 2px;
  transition: var(--transition);
}

/* --- Split Layout Core --- */
.split {
  display: flex;
  min-height: 100vh;
  width: 100%;
}

.split--half .split-pane { flex: 1; }
.split--60-40 .split-pane:first-child { flex: 6; }
.split--60-40 .split-pane:last-child { flex: 4; }
.split--40-60 .split-pane:first-child { flex: 4; }
.split--40-60 .split-pane:last-child { flex: 6; }

.split--auto {
  min-height: auto;
}

.split-pane {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4rem 3.5rem;
  position: relative;
  overflow: hidden;
}

.split-pane--dark {
  background: var(--dark);
  color: var(--text-dark);
}

.split-pane--dark-surface {
  background: var(--dark-surface);
  color: var(--text-dark);
}

.split-pane--light {
  background: var(--light);
  color: var(--text-light);
}

.split-pane--light-surface {
  background: var(--light-surface);
  color: var(--text-light);
}

.split-pane--accent {
  background: var(--accent);
  color: var(--dark);
}

.split-divider {
  width: var(--split-divider);
  background: var(--dark-border);
  flex-shrink: 0;
}

/* --- Scroll Animations --- */
.slide-in-left,
.slide-in-right,
.fade-up {
  opacity: 0;
  transition: opacity var(--transition-slow), transform var(--transition-slow);
}

.slide-in-left { transform: translateX(-60px); }
.slide-in-right { transform: translateX(60px); }
.fade-up { transform: translateY(40px); }

.slide-in-left.visible,
.slide-in-right.visible,
.fade-up.visible {
  opacity: 1;
  transform: translate(0);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  border-radius: 10px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
}

.btn--primary {
  background: var(--accent);
  color: var(--dark);
}

.btn--primary:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(34, 197, 94, 0.3);
}

.btn--outline {
  background: transparent;
  color: var(--text-dark);
  border: 1.5px solid var(--dark-border);
}

.btn--outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

.btn--outline-dark {
  background: transparent;
  color: var(--text-light);
  border: 1.5px solid var(--light-border);
}

.btn--outline-dark:hover {
  border-color: var(--accent);
  color: var(--accent-dark);
  transform: translateY(-2px);
}

.btn--dark {
  background: var(--dark);
  color: var(--text-dark);
}

.btn--dark:hover {
  background: #1a1a1a;
  transform: translateY(-2px);
}

.btn--large {
  padding: 1rem 2.6rem;
  font-size: 1.1rem;
  border-radius: 12px;
}

.btn-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* --- Section Utility --- */
.section-label {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}

.section-label--dark {
  color: var(--accent-dark);
}

/* --- Footer --- */
.footer {
  background: var(--dark);
  border-top: 1px solid var(--dark-border);
  padding: 3rem 2rem 2rem;
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2rem;
}

.footer-brand {
  max-width: 300px;
}

.footer-brand .nav-logo {
  margin-bottom: 1rem;
}

.footer-brand p {
  font-size: 0.9rem;
  color: var(--text-dark-muted);
  line-height: 1.6;
}

.footer-col h4 {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dark-muted);
  margin-bottom: 1rem;
}

.footer-col a {
  display: block;
  font-size: 0.95rem;
  color: var(--text-dark-muted);
  padding: 0.3rem 0;
  transition: color var(--transition);
}

.footer-col a:hover {
  color: var(--accent);
}

.footer-bottom {
  max-width: 1400px;
  margin: 2rem auto 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--dark-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--text-dark-muted);
}

/* --- Cards --- */
.card {
  background: var(--dark-surface);
  border: 1px solid var(--dark-border);
  border-radius: 14px;
  padding: 2rem;
  transition: all var(--transition);
}

.card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.card--light {
  background: #fff;
  border-color: var(--light-border);
  color: var(--text-light);
}

.card--light:hover {
  border-color: var(--accent);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

/* --- Pricing --- */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.pricing-card {
  background: var(--dark-surface);
  border: 1px solid var(--dark-border);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  transition: all var(--transition);
}

.pricing-card:hover {
  transform: translateY(-4px);
}

.pricing-card--highlighted {
  border-color: var(--accent);
  background: linear-gradient(180deg, rgba(34, 197, 94, 0.06) 0%, var(--dark-surface) 40%);
  box-shadow: 0 0 50px rgba(34, 197, 94, 0.08);
  position: relative;
}

.pricing-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: var(--dark);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.35rem 1.2rem;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.pricing-card h3 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
}

.pricing-card .price {
  font-size: 2.8rem;
  font-weight: 700;
  font-family: var(--font-heading);
  margin: 0.5rem 0 0.25rem;
}

.pricing-card .price span {
  font-size: 1rem;
  font-weight: 400;
  color: var(--text-dark-muted);
}

.pricing-card .price-desc {
  font-size: 0.9rem;
  color: var(--text-dark-muted);
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--dark-border);
}

.pricing-features {
  flex: 1;
  margin-bottom: 2rem;
}

.pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.95rem;
  padding: 0.4rem 0;
  color: var(--text-dark-muted);
}

.pricing-features li .check {
  color: var(--accent);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 2px;
}

.pricing-card .btn {
  width: 100%;
  justify-content: center;
}

/* --- FAQ --- */
.faq-item {
  border-bottom: 1px solid var(--dark-border);
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  color: inherit;
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  padding: 1.5rem 0;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  transition: color var(--transition);
}

.faq-question:hover {
  color: var(--accent);
}

.faq-question .faq-icon {
  font-size: 1.4rem;
  font-weight: 300;
  transition: transform var(--transition);
  flex-shrink: 0;
}

.faq-item.open .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-item.open .faq-answer {
  max-height: 300px;
}

.faq-answer p {
  padding-bottom: 1.5rem;
  color: var(--text-dark-muted);
  font-size: 1rem;
  line-height: 1.7;
}

/* --- Form --- */
.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 0.4rem;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.8rem 1rem;
  border-radius: 10px;
  border: 1.5px solid var(--dark-border);
  background: var(--dark-surface);
  color: var(--text-dark);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--accent);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

/* light variant */
.form-group--light input,
.form-group--light textarea,
.form-group--light select {
  background: #fff;
  border-color: var(--light-border);
  color: var(--text-light);
}

.form-group--light input:focus,
.form-group--light textarea:focus {
  border-color: var(--accent);
}

/* --- Contact Info --- */
.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.contact-info-icon {
  width: 44px;
  height: 44px;
  background: var(--accent-glow);
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.contact-info-item h4 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-dark-muted);
  margin-bottom: 0.2rem;
  font-weight: 500;
}

.contact-info-item p {
  font-size: 1rem;
  color: var(--text-dark);
}

/* --- Stat --- */
.stat {
  text-align: center;
}

.stat-value {
  font-family: var(--font-heading);
  font-size: 2.8rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-dark-muted);
}

.stat--dark .stat-label {
  color: var(--text-light-muted);
}

/* --- Map placeholder --- */
.map-placeholder {
  width: 100%;
  height: 220px;
  background: var(--dark-surface);
  border: 1px solid var(--dark-border);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dark-muted);
  font-size: 0.95rem;
  margin-top: 2rem;
}

/* --- Logo Grid --- */
.logo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.logo-item {
  height: 64px;
  border: 1px solid var(--light-border);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-light-muted);
  transition: all var(--transition);
}

.logo-item:hover {
  border-color: var(--accent);
  color: var(--accent-dark);
}

/* --- Inbox Demo Animation --- */
.inbox-demo {
  background: var(--dark-surface);
  border: 1px solid var(--dark-border);
  border-radius: 14px;
  overflow: hidden;
  max-width: 480px;
}

.inbox-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--dark-border);
  font-size: 0.9rem;
  font-weight: 600;
}

.inbox-header .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.inbox-header .dot--red { background: #ef4444; }
.inbox-header .dot--yellow { background: #eab308; }
.inbox-header .dot--green { background: #22c55e; }

.inbox-tabs {
  display: flex;
  border-bottom: 1px solid var(--dark-border);
}

.inbox-tab {
  padding: 0.6rem 1.25rem;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-dark-muted);
  border-bottom: 2px solid transparent;
}

.inbox-tab--active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.inbox-messages {
  padding: 0.5rem 0;
  max-height: 320px;
  overflow: hidden;
}

.inbox-msg {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.25rem;
  transition: all 0.5s ease;
  position: relative;
}

.inbox-msg--spam {
  animation: filterSpam 4s ease-in-out infinite;
}

.inbox-msg--spam:nth-child(2) { animation-delay: 0.8s; }
.inbox-msg--spam:nth-child(5) { animation-delay: 1.6s; }

@keyframes filterSpam {
  0%, 40% { opacity: 1; transform: translateX(0); background: transparent; }
  50% { background: rgba(239, 68, 68, 0.08); }
  70% { opacity: 0.3; transform: translateX(40px); }
  80% { opacity: 0; transform: translateX(80px); height: 0; padding: 0 1.25rem; }
  100% { opacity: 1; transform: translateX(0); height: auto; padding: 0.75rem 1.25rem; background: transparent; }
}

.inbox-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
}

.inbox-msg-content {
  flex: 1;
  min-width: 0;
}

.inbox-msg-from {
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inbox-msg-subject {
  font-size: 0.78rem;
  color: var(--text-dark-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inbox-msg-badge {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.inbox-msg-badge--safe {
  background: rgba(34, 197, 94, 0.15);
  color: var(--accent);
}

.inbox-msg-badge--spam {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
}

/* --- Feature Visual Panels --- */
.feature-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 200px;
}

.feature-visual-box {
  width: 100%;
  max-width: 380px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--dark-border);
}

.feature-visual-box--light {
  border-color: var(--light-border);
}

/* chart bars animation */
.chart-bars {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 120px;
  padding: 1.5rem;
}

.chart-bar {
  flex: 1;
  background: var(--accent);
  border-radius: 4px 4px 0 0;
  animation: growBar 2s ease-in-out infinite alternate;
}

.chart-bar:nth-child(1) { height: 40%; animation-delay: 0s; }
.chart-bar:nth-child(2) { height: 70%; animation-delay: 0.15s; }
.chart-bar:nth-child(3) { height: 55%; animation-delay: 0.3s; }
.chart-bar:nth-child(4) { height: 85%; animation-delay: 0.45s; }
.chart-bar:nth-child(5) { height: 60%; animation-delay: 0.6s; }
.chart-bar:nth-child(6) { height: 90%; animation-delay: 0.75s; }
.chart-bar:nth-child(7) { height: 45%; animation-delay: 0.9s; }

@keyframes growBar {
  0% { opacity: 0.5; transform: scaleY(0.7); }
  100% { opacity: 1; transform: scaleY(1); }
}

/* shield animation */
.shield-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2.5rem;
  gap: 1rem;
}

.shield-icon {
  font-size: 4rem;
  animation: shieldPulse 2.5s ease-in-out infinite;
}

@keyframes shieldPulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 8px rgba(34,197,94,0.3)); }
  50% { transform: scale(1.08); filter: drop-shadow(0 0 20px rgba(34,197,94,0.5)); }
}

/* scanning line */
.scan-visual {
  position: relative;
  padding: 2rem;
  height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.6rem;
}

.scan-line {
  height: 10px;
  border-radius: 5px;
  background: var(--dark-border);
  position: relative;
  overflow: hidden;
}

.scan-line::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: scanAcross 2.5s ease-in-out infinite;
}

.scan-line:nth-child(2)::after { animation-delay: 0.3s; }
.scan-line:nth-child(3)::after { animation-delay: 0.6s; }
.scan-line:nth-child(4)::after { animation-delay: 0.9s; }

@keyframes scanAcross {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* --- Full Width CTA Section --- */
.cta-section {
  text-align: center;
  padding: 5rem 2rem;
  background: var(--dark);
  border-top: 1px solid var(--dark-border);
}

.cta-section h2 {
  margin-bottom: 1rem;
}

.cta-section p {
  color: var(--text-dark-muted);
  max-width: 560px;
  margin: 0 auto 2rem;
  font-size: 1.1rem;
}

/* --- Page Hero (non-index pages) --- */
.page-hero {
  padding-top: calc(var(--nav-height) + 4rem);
  padding-bottom: 3rem;
  text-align: center;
  background: var(--dark);
  border-bottom: 1px solid var(--dark-border);
}

.page-hero h1 {
  margin-bottom: 0.75rem;
}

.page-hero p {
  color: var(--text-dark-muted);
  max-width: 560px;
  margin: 0 auto;
  font-size: 1.1rem;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .split-pane {
    padding: 3rem 2.5rem;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
    max-width: 440px;
  }
}

@media (max-width: 768px) {
  .split {
    flex-direction: column;
    min-height: auto;
  }

  .split-divider {
    width: 100%;
    height: var(--split-divider);
  }

  .split-pane {
    padding: 3rem 1.5rem;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    flex-direction: column;
    background: rgba(10, 10, 10, 0.97);
    backdrop-filter: blur(16px);
    padding: 1.5rem 2rem;
    gap: 1.2rem;
    border-bottom: 1px solid var(--dark-border);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-mobile-toggle {
    display: flex;
  }

  .logo-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-inner {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .split-pane {
    padding: 2.5rem 1.25rem;
  }

  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }

  .btn--large {
    padding: 0.85rem 1.8rem;
    font-size: 1rem;
  }
}
