/* ══════════════════════════════════════════
   Vectail Showcase — Shared Styles
   ══════════════════════════════════════════ */

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

/* ══ DESIGN TOKENS ══ */
:root {
  --bg: #f7f8fb;
  --bg-warm: #eef1f6;
  --surface: #ffffff;
  --surface-glass: rgba(255, 255, 255, 0.72);
  --surface-glass-border: rgba(255, 255, 255, 0.5);
  --text: #0f172a;
  --text-secondary: #4a5568;
  --text-tertiary: #8896a8;
  --navy: #183666;
  --navy-dark: #0f2447;
  --navy-light: #1e4480;
  --primary-50: #eef3fc;
  --primary-100: #dce6f8;
  --primary-200: #b8cdf1;
  --primary-300: #8baae8;
  --primary-400: #558ef7;
  --primary-500: #3a6fe0;
  --primary-600: #183666;
  --primary-700: #0f2447;
  --accent: #558ef7;
  --accent-light: #eef3fc;
  --teal: #2dd4bf;
  --teal-light: #e6fcf7;
  --sky: #38bdf8;
  --sky-light: #e8f7fe;
  --border: #dce2ec;
  --border-light: #eef1f6;
  --shadow-sm: 0 1px 2px rgba(24, 54, 102, 0.04);
  --shadow: 0 4px 16px rgba(24, 54, 102, 0.07);
  --shadow-lg: 0 12px 40px rgba(24, 54, 102, 0.10);
  --shadow-xl: 0 24px 64px rgba(24, 54, 102, 0.12);
  --radius: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --font: 'DM Sans', system-ui, sans-serif;
  --font-heading: 'Space Grotesk', 'DM Sans', sans-serif;
  --ease: cubic-bezier(.4, 0, .2, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
}

/* ══ BASE ══ */
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%
}

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

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

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  line-height: 1.15;
  letter-spacing: -.025em;
  color: var(--text)
}

/* ══ UTILITIES ══ */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0)
}

/* ══ BUTTONS ══ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 30px;
  background: linear-gradient(135deg, #558ef7, #3a6fe0);
  color: #fff;
  font-weight: 600;
  font-size: .938rem;
  border-radius: var(--radius);
  transition: all .3s var(--ease);
  box-shadow: 0 2px 8px rgba(85, 142, 247, .3), inset 0 1px 0 rgba(255, 255, 255, .15)
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(85, 142, 247, .4), inset 0 1px 0 rgba(255, 255, 255, .15)
}

.btn-primary:active {
  transform: translateY(0)
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 30px;
  background: var(--surface);
  color: var(--text);
  font-weight: 600;
  font-size: .938rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all .3s var(--ease);
  box-shadow: var(--shadow-sm)
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--navy);
  box-shadow: var(--shadow)
}

/* ══ SECTION ELEMENTS ══ */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: var(--primary-50);
  border: 1px solid var(--primary-200);
  border-radius: 100px;
  color: var(--navy);
  font-size: .813rem;
  font-weight: 600;
  letter-spacing: .03em;
  text-transform: uppercase;
  margin-bottom: 20px
}

.section-title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  margin-bottom: 16px
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 600px;
  line-height: 1.7
}

/* ══ REVEAL ANIMATIONS ══ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s var(--ease-out), transform .7s var(--ease-out)
}

.reveal.visible {
  opacity: 1;
  transform: none
}

.reveal-d1 { transition-delay: .08s }
.reveal-d2 { transition-delay: .16s }
.reveal-d3 { transition-delay: .24s }
.reveal-d4 { transition-delay: .32s }
.reveal-d5 { transition-delay: .4s }

/* ══ NAVBAR ══ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 14px 0;
  transition: all .35s var(--ease)
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative
}

.nav-logo img {
  height: 30px;
  width: auto;
  transition: opacity .35s var(--ease);
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%)
}

.nav-logo .logo-light {
  position: relative;
  top: auto;
  transform: none
}

.nav-logo .logo-dark {
  opacity: 0
}

.nav-logo span {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -.02em
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none
}

.nav-links a {
  font-size: .875rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color .2s
}

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

.nav-right {
  display: flex;
  align-items: center;
  gap: 14px
}

.lang-switch {
  display: flex;
  gap: 2px;
  font-size: .75rem;
  font-weight: 600
}

.lang-switch a {
  padding: 4px 8px;
  border-radius: 6px;
  color: var(--text-tertiary);
  transition: all .2s
}

.lang-switch a.active {
  color: var(--navy);
  background: var(--primary-50)
}

.lang-switch span {
  color: var(--border);
  line-height: 2
}

.nav-cta {
  padding: 10px 22px !important;
  font-size: .813rem !important
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 22px;
  padding: 2px 0
}

.hamburger span {
  display: block;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all .3s
}

/* Scrolled navbar */
.navbar.scrolled {
  background: var(--surface-glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(226, 232, 240, .6);
  box-shadow: 0 1px 12px rgba(0, 0, 0, .04);
  padding: 10px 0
}

.navbar.scrolled .nav-logo .logo-light {
  opacity: 0;
  pointer-events: none
}

.navbar.scrolled .nav-logo .logo-dark {
  opacity: 1
}

/* Dark hero navbar overrides */
.navbar.hero-dark .nav-links a {
  color: rgba(255, 255, 255, 0.7)
}

.navbar.hero-dark .nav-links a:hover {
  color: #fff
}

.navbar.hero-dark .lang-switch a {
  color: rgba(255, 255, 255, 0.5)
}

.navbar.hero-dark .lang-switch a.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.12)
}

.navbar.hero-dark .lang-switch span {
  color: rgba(255, 255, 255, 0.25)
}

.navbar.hero-dark .hamburger span {
  background: #fff
}

/* When scrolled, override dark hero styles back to light */
.navbar.hero-dark.scrolled .nav-links a {
  color: var(--text-secondary)
}

.navbar.hero-dark.scrolled .nav-links a:hover {
  color: var(--text)
}

.navbar.hero-dark.scrolled .lang-switch a {
  color: var(--text-tertiary)
}

.navbar.hero-dark.scrolled .lang-switch a.active {
  color: var(--navy);
  background: var(--primary-50)
}

.navbar.hero-dark.scrolled .lang-switch span {
  color: var(--border)
}

.navbar.hero-dark.scrolled .hamburger span {
  background: var(--text)
}

/* Mobile menu */
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(248, 250, 252, .97);
  backdrop-filter: blur(20px);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s
}

.mobile-menu.open {
  opacity: 1;
  pointer-events: all
}

.mobile-menu a {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--text)
}

.mobile-close {
  position: absolute;
  top: 18px;
  right: 20px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--text)
}

@media(max-width:900px) {
  .nav-links {
    display: none
  }

  .hamburger {
    display: flex
  }

  .nav-cta {
    display: none !important
  }
}

/* ══ PAGE HERO (sub-pages) ══ */
.page-hero {
  padding: 140px 0 70px;
  text-align: center;
  position: relative;
  overflow: hidden
}

.page-hero::before {
  content: '';
  position: absolute;
  width: 800px;
  height: 800px;
  top: -300px;
  right: -200px;
  background: radial-gradient(circle, rgba(85, 142, 247, .08) 0%, transparent 70%);
  pointer-events: none
}

.page-hero h1 {
  font-size: clamp(2.2rem, 4.5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -.03em;
  margin-bottom: 16px
}

.page-hero h1 .hl {
  color: var(--accent)
}

.page-hero p {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.7
}

/* ══ FAQ ══ */
.faq {
  position: relative;
  z-index: 1;
  padding: 110px 0
}

.faq.alt-bg {
  background: var(--bg-warm)
}

.faq-header {
  text-align: center;
  margin-bottom: 56px
}

.faq-list {
  max-width: 700px;
  margin: 0 auto
}

.faq-item {
  border-bottom: 1px solid var(--border)
}

.faq-item.styled {
  background: var(--surface);
  margin-bottom: 8px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden
}

.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0;
  text-align: left;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  transition: color .2s
}

.faq-item.styled .faq-q {
  padding: 20px 24px
}

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

.faq-q svg {
  width: 18px;
  height: 18px;
  color: var(--text-tertiary);
  transition: transform .3s var(--ease-out), color .2s;
  flex-shrink: 0;
  margin-left: 16px
}

.faq-item.open .faq-q svg {
  transform: rotate(45deg);
  color: var(--accent)
}

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .4s var(--ease-out)
}

.faq-a-inner {
  padding: 0 0 22px;
  font-size: .938rem;
  color: var(--text-secondary);
  line-height: 1.7
}

.faq-item.styled .faq-a-inner {
  padding: 0 24px 20px
}

/* ══ FINAL CTA ══ */
.final-cta {
  position: relative;
  z-index: 1;
  padding: 110px 0;
  text-align: center
}

.final-cta-box {
  padding: 72px 40px;
  background: linear-gradient(135deg, var(--primary-50), var(--teal-light));
  border: 1px solid var(--primary-100);
  border-radius: var(--radius-xl);
  position: relative;
  overflow: hidden
}

.final-cta-box::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(85, 142, 247, .04) 1px, transparent 1px);
  background-size: 28px 28px
}

.final-cta h2 {
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 14px;
  position: relative
}

.final-cta p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 540px;
  margin: 0 auto 36px;
  position: relative
}

.final-cta-btns {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative
}

/* ══ FOOTER ══ */
.footer {
  padding: 72px 0 36px;
  border-top: 1px solid var(--border)
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 52px
}

.footer-brand {
  max-width: 260px
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px
}

.footer-logo img {
  height: 26px
}

.footer-logo span {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.063rem
}

.footer-tagline {
  font-size: .875rem;
  color: var(--text-tertiary);
  font-style: italic;
  margin-bottom: 18px
}

.footer-social {
  display: flex;
  gap: 10px
}

.footer-social a {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  transition: all .2s
}

.footer-social a:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-light)
}

.footer-col h4 {
  font-size: .75rem;
  font-weight: 600;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: 14px
}

.footer-col ul {
  list-style: none
}

.footer-col li {
  margin-bottom: 9px
}

.footer-col a {
  font-size: .875rem;
  color: var(--text-tertiary);
  transition: color .2s
}

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

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 28px;
  border-top: 1px solid var(--border);
  font-size: .75rem;
  color: var(--text-tertiary)
}

@media(max-width:900px) {
  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 28px
  }

  .footer-brand {
    grid-column: 1/-1
  }
}

@media(max-width:600px) {
  .footer-top {
    grid-template-columns: 1fr
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center
  }
}

/* ══ PROSE / LEGAL CONTENT ══ */
.prose {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 0 80px
}

.prose h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 48px 0 16px;
  color: var(--text)
}

.prose h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 32px 0 12px;
  color: var(--text)
}

.prose p {
  font-size: .938rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 16px
}

.prose ul,
.prose ol {
  padding-left: 24px;
  margin-bottom: 16px
}

.prose li {
  font-size: .938rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 6px
}

.prose a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px
}

.prose a:hover {
  color: var(--navy)
}

.prose strong {
  color: var(--text);
  font-weight: 600
}

.prose .info-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0 28px
}

.prose .info-table td {
  padding: 10px 16px;
  font-size: .938rem;
  border-bottom: 1px solid var(--border-light)
}

.prose .info-table td:first-child {
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  width: 200px
}

.prose .info-table td:last-child {
  color: var(--text-secondary)
}

.prose .last-updated {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: .813rem;
  color: var(--text-tertiary);
  font-style: italic
}

/* ══ DOC CONTENT ══ */
.doc-content {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 0 80px
}

.doc-nav {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 56px;
  justify-content: center
}

.doc-nav a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: .875rem;
  font-weight: 600;
  color: var(--text);
  transition: all .2s var(--ease)
}

.doc-nav a:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: var(--shadow)
}

.doc-section {
  margin-bottom: 64px
}

.doc-section h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 12px
}

.doc-section h2 .step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: .875rem;
  font-weight: 700;
  flex-shrink: 0
}

.doc-section p {
  font-size: .938rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 16px
}

.doc-section h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 28px 0 12px;
  color: var(--text)
}

.doc-section ul {
  padding-left: 24px;
  margin-bottom: 16px
}

.doc-section li {
  font-size: .938rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 6px
}

.code-block {
  position: relative;
  background: var(--navy-dark);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 16px 0 24px;
  overflow-x: auto
}

.code-block code {
  font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
  font-size: .813rem;
  line-height: 1.7;
  color: #e2e8f0;
  white-space: pre
}

.code-block .code-label {
  display: inline-block;
  position: absolute;
  top: 0;
  right: 0;
  padding: 4px 12px;
  background: rgba(255,255,255,.08);
  border-radius: 0 var(--radius) 0 var(--radius);
  font-family: var(--font);
  font-size: .688rem;
  font-weight: 600;
  color: var(--text-tertiary);
  letter-spacing: .04em;
  text-transform: uppercase
}

.code-block .hl-tag { color: #7dd3fc }
.code-block .hl-attr { color: #fbbf24 }
.code-block .hl-str { color: #86efac }
.code-block .hl-cmt { color: #64748b }

.doc-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 0
}

.doc-tab {
  padding: 10px 20px;
  font-size: .813rem;
  font-weight: 600;
  color: var(--text-tertiary);
  border: 1px solid var(--border);
  border-bottom: none;
  border-radius: var(--radius) var(--radius) 0 0;
  background: var(--bg-warm);
  cursor: pointer;
  transition: all .2s;
  margin-right: -1px
}

.doc-tab.active {
  color: var(--text);
  background: var(--navy-dark);
  border-color: var(--navy-dark)
}

.doc-tabs + .code-block {
  margin-top: 0;
  border-top-left-radius: 0
}

.doc-tab-content { display: none }
.doc-tab-content.active { display: block }

/* ══ CONTACT FORM ══ */
.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 48px;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 0 80px
}

.contact-form label {
  display: block;
  font-size: .813rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 12px 16px;
  font-family: var(--font);
  font-size: .938rem;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all .2s var(--ease);
  margin-bottom: 20px;
  outline: none
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(85, 142, 247, .12)
}

.contact-form textarea {
  min-height: 140px;
  resize: vertical
}

.contact-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%238896a8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px
}

.contact-form .btn-primary {
  width: 100%
}

.contact-info {
  padding: 36px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  align-self: start
}

.contact-info h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 24px;
  color: var(--text)
}

.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 24px
}

.contact-info-item:last-child {
  margin-bottom: 0
}

.contact-info-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--primary-50);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--accent)
}

.contact-info-text strong {
  display: block;
  font-size: .875rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 2px
}

.contact-info-text span,
.contact-info-text a {
  font-size: .875rem;
  color: var(--text-secondary)
}

.contact-info-text a:hover {
  color: var(--accent)
}

@media(max-width:768px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 32px
  }
}
