/* ============================================================
   POSLINK Marketing Site — Design Tokens
   ============================================================ */
:root {
  --color-primary: #4338ca;
  --color-primary-light: #6366f1;
  --color-primary-dark: #312e81;
  --color-accent: #f97316;
  --color-accent-alt: #ec4899;
  --color-success: #10b981;

  --color-bg: #ffffff;
  --color-surface: #f8fafc;
  --color-surface-alt: #eef2ff;
  --color-text: #0f172a;
  --color-text-muted: #64748b;
  --color-border: #e2e8f0;
  --color-header-bg: rgba(255, 255, 255, 0.85);

  --gradient-brand: linear-gradient(135deg, var(--color-primary-dark) 0%, var(--color-primary) 45%, var(--color-accent-alt) 100%);
  --gradient-warm: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-alt) 100%);

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 24px 48px -12px rgba(67, 56, 202, 0.25);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-full: 999px;

  --container-width: 1160px;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-primary: #818cf8;
    --color-primary-light: #a5b4fc;
    --color-primary-dark: #312e81;
    --color-accent: #fb923c;
    --color-accent-alt: #f472b6;

    --color-bg: #0b1120;
    --color-surface: #121a2e;
    --color-surface-alt: #1a2440;
    --color-text: #e6ebf5;
    --color-text-muted: #94a3b8;
    --color-border: #26314d;
    --color-header-bg: rgba(11, 17, 32, 0.85);

    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.35);
    --shadow-lg: 0 24px 48px -12px rgba(0, 0, 0, 0.5);
    color-scheme: dark;
  }
}

/* ============================================================
   Reset & base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; cursor: pointer; }

h1, h2, h3, h4 {
  margin: 0 0 0.5em;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}
h1 { font-size: clamp(2.25rem, 4vw + 1rem, 3.75rem); }
h2 { font-size: clamp(1.75rem, 2.5vw + 1rem, 2.75rem); }
h3 { font-size: 1.375rem; }
p { margin: 0 0 1em; color: var(--color-text-muted); }

.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

section { padding: 96px 0; }
@media (max-width: 768px) { section { padding: 64px 0; } }

.section-header { max-width: 680px; margin: 0 auto 56px; text-align: center; }
.section-header p { font-size: 1.125rem; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-primary);
  background: var(--color-surface-alt);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 16px;
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.95rem;
  border: 1px solid transparent;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--gradient-warm); color: #fff; box-shadow: 0 10px 24px -8px rgba(249, 115, 22, 0.55); }
.btn-primary:hover { box-shadow: 0 14px 28px -8px rgba(249, 115, 22, 0.65); }
.btn-light { background: #fff; color: var(--color-primary-dark); }
.btn-outline { background: transparent; border-color: var(--color-border); color: var(--color-text); }
.btn-outline:hover { border-color: var(--color-primary); color: var(--color-primary); }
.btn-ghost-invert { background: rgba(255, 255, 255, 0.12); color: #fff; border-color: rgba(255, 255, 255, 0.35); }
.btn-ghost-invert:hover { background: rgba(255, 255, 255, 0.2); }
.btn-block { width: 100%; }
.btn-lg { padding: 16px 32px; font-size: 1.05rem; }

/* ============================================================
   Header / Nav
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--color-header-bg);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.15rem; }
.brand img { width: 34px; height: 34px; }
.nav-links { display: none; align-items: center; gap: 32px; font-weight: 600; font-size: 0.95rem; }
.nav-links a { color: var(--color-text-muted); transition: color 0.15s ease; }
.nav-links a:hover, .nav-links a.active { color: var(--color-primary); }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-actions .btn-outline { display: none; }
.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px; height: 42px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  background: var(--color-bg);
}
.nav-toggle svg { width: 20px; height: 20px; }

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 12px 0 20px;
  border-top: 1px solid var(--color-border);
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  padding: 12px 4px;
  font-weight: 600;
  color: var(--color-text);
  border-bottom: 1px solid var(--color-border);
}
.mobile-menu .btn { margin-top: 12px; }

@media (min-width: 900px) {
  .nav-links { display: flex; }
  .nav-actions .btn-outline { display: inline-flex; }
  .nav-toggle { display: none; }
  .mobile-menu { display: none !important; }
}

/* ============================================================
   Hero
   ============================================================ */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--gradient-brand);
  color: #fff;
  padding: 80px 0 120px;
}
.hero-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.55;
}
.hero-blob--1 { width: 420px; height: 420px; background: var(--color-accent); top: -160px; right: -120px; }
.hero-blob--2 { width: 320px; height: 320px; background: var(--color-accent-alt); bottom: -140px; left: -100px; opacity: 0.4; }
.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 48px;
  align-items: center;
}
.hero-copy p { color: rgba(255,255,255,0.85); font-size: 1.15rem; max-width: 520px; }
.hero-copy h1 { color: #fff; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }
.hero-trust { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 24px; color: rgba(255,255,255,0.75); font-size: 0.875rem; }
.hero-trust span { display: flex; align-items: center; gap: 8px; }
.hero-art { position: relative; }

@media (min-width: 960px) {
  .hero-grid { grid-template-columns: 1.1fr 1fr; }
}

/* ============================================================
   Logo strip
   ============================================================ */
.logo-strip { padding: 40px 0; border-bottom: 1px solid var(--color-border); }
.logo-strip p { text-align: center; font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 24px; }
.logo-row { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 40px; opacity: 0.65; }
.logo-row span { font-weight: 800; font-size: 1.1rem; color: var(--color-text-muted); }

/* ============================================================
   Feature grid & cards
   ============================================================ */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-2, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }

.card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: transparent; }
.card-icon {
  width: 52px; height: 52px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  background: var(--color-surface-alt);
  color: var(--color-primary);
  margin-bottom: 20px;
}
.card-icon svg { width: 26px; height: 26px; }
.card h3 { margin-bottom: 8px; }
.card p { margin: 0; font-size: 0.95rem; }

.feature-detail {
  display: grid;
  gap: 40px;
  align-items: center;
  padding: 56px 0;
  border-bottom: 1px solid var(--color-border);
}
.feature-detail:last-child { border-bottom: none; }
.feature-detail .feature-visual {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px;
}
.feature-detail ul { margin-top: 20px; display: flex; flex-direction: column; gap: 12px; }
.feature-detail li { display: flex; gap: 10px; align-items: flex-start; font-size: 0.95rem; color: var(--color-text); }
.feature-detail li svg { flex-shrink: 0; width: 20px; height: 20px; color: var(--color-success); margin-top: 2px; }
@media (min-width: 900px) {
  .feature-detail { grid-template-columns: 1fr 1fr; }
  .feature-detail.reverse .feature-copy { order: 2; }
}

/* ============================================================
   Stats
   ============================================================ */
.stats-bar {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: 40px;
  display: grid;
  gap: 32px;
  grid-template-columns: repeat(2, 1fr);
  text-align: center;
}
.stats-bar strong { display: block; font-size: 2.25rem; font-weight: 800; color: var(--color-primary); }
.stats-bar span { color: var(--color-text-muted); font-size: 0.9rem; }
@media (min-width: 768px) { .stats-bar { grid-template-columns: repeat(4, 1fr); } }

/* ============================================================
   Pricing
   ============================================================ */
.pricing-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 32px 0 48px;
  font-weight: 600;
}
.switch { position: relative; width: 56px; height: 30px; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch-track {
  position: absolute; inset: 0; background: var(--color-border);
  border-radius: var(--radius-full); transition: background 0.2s ease; cursor: pointer;
}
.switch-track::before {
  content: ""; position: absolute; width: 24px; height: 24px; left: 3px; top: 3px;
  background: #fff; border-radius: 50%; transition: transform 0.2s ease; box-shadow: var(--shadow-sm);
}
.switch input:checked + .switch-track { background: var(--color-primary); }
.switch input:checked + .switch-track::before { transform: translateX(26px); }
.save-badge {
  background: var(--color-surface-alt); color: var(--color-primary);
  font-size: 0.75rem; font-weight: 700; padding: 4px 10px; border-radius: var(--radius-full);
}

.pricing-grid { display: grid; gap: 24px; align-items: stretch; grid-template-columns: 1fr; }
@media (min-width: 900px) { .pricing-grid { grid-template-columns: repeat(3, 1fr); } }

.price-card {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  background: var(--color-bg);
  display: flex;
  flex-direction: column;
  position: relative;
}
.price-card.highlighted {
  border-color: transparent;
  background: var(--gradient-brand);
  color: #fff;
  box-shadow: var(--shadow-lg);
  transform: scale(1.03);
}
.price-card.highlighted p, .price-card.highlighted .price-muted { color: rgba(255,255,255,0.8); }
.price-card.highlighted li svg { color: #bbf7d0; }
.price-card.highlighted .card-icon { background: rgba(255,255,255,0.15); color: #fff; }
.badge-popular {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
  background: var(--gradient-warm); color: #fff; font-size: 0.75rem; font-weight: 700;
  padding: 6px 16px; border-radius: var(--radius-full); box-shadow: var(--shadow-sm);
}
.price-value { display: flex; align-items: baseline; gap: 6px; margin: 18px 0 4px; }
.price-value strong { font-size: 2.75rem; font-weight: 800; }
.price-card ul { margin: 28px 0; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.price-card li { display: flex; gap: 10px; align-items: flex-start; font-size: 0.925rem; }
.price-card li svg { flex-shrink: 0; width: 20px; height: 20px; color: var(--color-success); margin-top: 1px; }

/* ============================================================
   Testimonials
   ============================================================ */
.testimonial-card {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: 32px;
  border: 1px solid var(--color-border);
}
.stars { display: flex; gap: 4px; color: var(--color-accent); margin-bottom: 16px; }
.stars svg { width: 18px; height: 18px; }
.testimonial-card blockquote { margin: 0 0 20px; font-size: 1.02rem; color: var(--color-text); }
.testimonial-person { display: flex; align-items: center; gap: 12px; }
.avatar {
  width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; color: #fff; font-size: 0.95rem;
}
.testimonial-person strong { display: block; font-size: 0.9rem; }
.testimonial-person span { font-size: 0.8rem; color: var(--color-text-muted); }

/* ============================================================
   FAQ Accordion
   ============================================================ */
.faq-list { max-width: 780px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item { border: 1px solid var(--color-border); border-radius: var(--radius-md); overflow: hidden; background: var(--color-bg); }
.faq-question {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 24px; background: none; border: none; text-align: left;
  font-weight: 700; font-size: 1rem; color: var(--color-text);
}
.faq-question svg { flex-shrink: 0; width: 20px; height: 20px; transition: transform 0.2s ease; color: var(--color-primary); }
.faq-item.open .faq-question svg { transform: rotate(180deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.25s ease; }
.faq-answer div { padding: 0 24px 22px; color: var(--color-text-muted); }
.faq-item.open .faq-answer { max-height: 600px; }

/* ============================================================
   CTA band
   ============================================================ */
.cta-band {
  background: var(--gradient-brand);
  border-radius: var(--radius-lg);
  padding: 64px 40px;
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,0.85); max-width: 520px; margin: 0 auto 28px; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ============================================================
   Forms
   ============================================================ */
.form-grid { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .form-grid.two-col { grid-template-columns: 1fr 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 700; font-size: 0.875rem; }
.field input, .field textarea {
  padding: 13px 16px; border-radius: var(--radius-sm); border: 1px solid var(--color-border);
  background: var(--color-bg); color: var(--color-text); font-family: inherit; font-size: 0.95rem;
}
.field input:focus, .field textarea:focus { outline: 2px solid var(--color-primary-light); outline-offset: 1px; }
.field textarea { resize: vertical; min-height: 140px; }
.field-error { color: #dc2626; font-size: 0.8rem; }
.alert-success {
  background: #ecfdf5; border: 1px solid #a7f3d0; color: #065f46;
  padding: 16px 20px; border-radius: var(--radius-md); margin-bottom: 24px; font-weight: 600;
}
@media (prefers-color-scheme: dark) {
  .alert-success { background: #052e21; border-color: #065f46; color: #a7f3d0; }
}

/* ============================================================
   Contact / About layout helpers
   ============================================================ */
.split { display: grid; gap: 48px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; } }
.contact-info-item { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 24px; }
.contact-info-item .card-icon { margin-bottom: 0; flex-shrink: 0; }

.value-list { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 768px) { .value-list { grid-template-columns: repeat(2, 1fr); } }

/* ============================================================
   Footer
   ============================================================ */
.site-footer { background: var(--color-surface); border-top: 1px solid var(--color-border); padding: 64px 0 32px; }
.footer-grid { display: grid; gap: 40px; grid-template-columns: 1fr; margin-bottom: 48px; }
.footer-brand p { max-width: 320px; }
.footer-col h4 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 18px; }
.footer-col ul { display: flex; flex-direction: column; gap: 12px; }
.footer-col a { color: var(--color-text-muted); font-size: 0.925rem; transition: color 0.15s ease; }
.footer-col a:hover { color: var(--color-primary); }
.footer-bottom {
  display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between;
  padding-top: 24px; border-top: 1px solid var(--color-border); color: var(--color-text-muted); font-size: 0.85rem;
}
.social-row { display: flex; gap: 12px; }
.social-row a {
  width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--color-border);
  display: flex; align-items: center; justify-content: center; color: var(--color-text-muted);
}
.social-row a:hover { color: var(--color-primary); border-color: var(--color-primary); }
.social-row svg { width: 16px; height: 16px; }
@media (min-width: 640px) { .footer-grid { grid-template-columns: 1.4fr repeat(3, 1fr); } }

/* ============================================================
   Legal pages
   ============================================================ */
.legal-content h2 { margin-top: 2em; font-size: 1.4rem; }
.legal-content p, .legal-content li { color: var(--color-text-muted); }
.legal-content { max-width: 780px; margin: 0 auto; }
.legal-updated { color: var(--color-text-muted); font-size: 0.875rem; margin-bottom: 40px; }

/* ============================================================
   404
   ============================================================ */
.error-page { text-align: center; padding: 120px 0; }
.error-code {
  font-size: clamp(4rem, 10vw, 7rem); font-weight: 800; background: var(--gradient-brand);
  -webkit-background-clip: text; background-clip: text; color: transparent; line-height: 1;
}

/* ============================================================
   Reveal animation
   ============================================================ */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.5s ease, transform 0.5s ease; }
.reveal.in-view { opacity: 1; transform: none; }
