/* ==========================================================================
   Urna Eletrônica Simulador 2026 — Site Institucional
   Design System & Styles
   ========================================================================== */

/* ---------- Google Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

/* ---------- CSS Custom Properties (Design Tokens) ---------- */
:root {
  /* Brand Colors */
  --color-green: #009C3B;
  --color-green-dark: #007A2F;
  --color-green-light: #00B344;
  --color-gold: #FFD700;
  --color-gold-dark: #E6C200;
  --color-blue: #002776;
  --color-blue-light: #003DA5;

  /* Neutrals */
  --color-white: #FFFFFF;
  --color-off-white: #F8F9FA;
  --color-gray-50: #F1F3F5;
  --color-gray-100: #E9ECEF;
  --color-gray-200: #DEE2E6;
  --color-gray-400: #ADB5BD;
  --color-gray-600: #6C757D;
  --color-gray-800: #343A40;
  --color-gray-900: #212529;

  /* Semantic */
  --color-bg: var(--color-white);
  --color-bg-alt: var(--color-off-white);
  --color-text: var(--color-gray-900);
  --color-text-secondary: var(--color-gray-600);
  --color-accent: var(--color-green);

  /* Typography */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 2rem;
  --font-size-4xl: 2.5rem;
  --font-size-5xl: 3.25rem;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Borders & Shadows */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);
  --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.15);

  /* Layout */
  --max-width: 1120px;
  --header-height: 72px;

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

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

ul, ol {
  list-style: none;
}

/* ---------- Utility ---------- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

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

/* ==========================================================================
   HEADER
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-height);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-gray-100);
  transition: box-shadow var(--transition-base);
}

.site-header.scrolled {
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.header-logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-weight: 700;
  font-size: var(--font-size-lg);
  color: var(--color-green);
}

.header-logo img {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
}

.header-nav {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
}

.header-nav a {
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--color-gray-600);
  transition: color var(--transition-fast);
  position: relative;
}

.header-nav a:hover,
.header-nav a.active {
  color: var(--color-green);
}

.header-nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-green);
  border-radius: 1px;
  transition: width var(--transition-base);
}

.header-nav a:hover::after,
.header-nav a.active::after {
  width: 100%;
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-sm);
  color: var(--color-gray-800);
}

.menu-toggle svg {
  width: 24px;
  height: 24px;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero {
  padding-top: calc(var(--header-height) + var(--space-4xl));
  padding-bottom: var(--space-4xl);
  background: linear-gradient(165deg, var(--color-white) 0%, var(--color-gray-50) 50%, #e8f5e9 100%);
  overflow: hidden;
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0, 156, 59, 0.06) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3xl);
}

.hero-content {
  flex: 1;
  max-width: 540px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background-color: rgba(0, 156, 59, 0.08);
  color: var(--color-green);
  font-size: var(--font-size-sm);
  font-weight: 600;
  padding: var(--space-xs) var(--space-md);
  border-radius: 100px;
  margin-bottom: var(--space-lg);
}

.hero-badge::before {
  content: '🗳️';
}

.hero-title {
  font-size: var(--font-size-5xl);
  font-weight: 900;
  line-height: 1.1;
  color: var(--color-gray-900);
  margin-bottom: var(--space-lg);
  letter-spacing: -0.02em;
}

.hero-title .highlight {
  color: var(--color-green);
}

.hero-subtitle {
  font-size: var(--font-size-lg);
  color: var(--color-text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-2xl);
  max-width: 460px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.btn-playstore {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--color-gray-900);
  color: var(--color-white);
  padding: 14px 28px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: var(--font-size-base);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  border: none;
  cursor: pointer;
}

.btn-playstore:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  color: var(--color-white);
}

.btn-playstore svg {
  width: 22px;
  height: 22px;
}

.hero-image {
  flex: 1;
  max-width: 520px;
  position: relative;
}

.hero-image img {
  width: 100%;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
}

/* ==========================================================================
   FEATURES SECTION
   ========================================================================== */
.features {
  padding: var(--space-4xl) 0;
  background-color: var(--color-bg);
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-3xl);
}

.section-label {
  display: inline-block;
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--color-green);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-sm);
}

.section-title {
  font-size: var(--font-size-3xl);
  font-weight: 800;
  color: var(--color-gray-900);
  line-height: 1.2;
  margin-bottom: var(--space-md);
}

.section-subtitle {
  font-size: var(--font-size-lg);
  color: var(--color-text-secondary);
  max-width: 560px;
  margin: 0 auto;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-xl);
}

.feature-card {
  background: var(--color-white);
  border: 1px solid var(--color-gray-100);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl);
  transition: transform var(--transition-base), box-shadow var(--transition-base), border-color var(--transition-base);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--color-green), var(--color-gold));
  opacity: 0;
  transition: opacity var(--transition-base);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}

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

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin-bottom: var(--space-lg);
}

.feature-icon.green {
  background: rgba(0, 156, 59, 0.1);
}

.feature-icon.gold {
  background: rgba(255, 215, 0, 0.15);
}

.feature-icon.blue {
  background: rgba(0, 39, 118, 0.08);
}

.feature-icon.purple {
  background: rgba(142, 68, 173, 0.08);
}

.feature-card h3 {
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--color-gray-900);
  margin-bottom: var(--space-sm);
}

.feature-card p {
  font-size: var(--font-size-sm);
  color: var(--color-text-secondary);
  line-height: 1.7;
}

/* ==========================================================================
   CTA SECTION (Download)
   ========================================================================== */
.cta {
  padding: var(--space-4xl) 0;
  background: linear-gradient(135deg, var(--color-green) 0%, var(--color-green-dark) 100%);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: '';
  position: absolute;
  top: -100px;
  right: -100px;
  width: 300px;
  height: 300px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 50%;
}

.cta::after {
  content: '';
  position: absolute;
  bottom: -80px;
  left: -60px;
  width: 200px;
  height: 200px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 50%;
}

.cta-title {
  font-size: var(--font-size-3xl);
  font-weight: 800;
  color: var(--color-white);
  margin-bottom: var(--space-md);
  position: relative;
  z-index: 1;
}

.cta-subtitle {
  font-size: var(--font-size-lg);
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: var(--space-2xl);
  position: relative;
  z-index: 1;
}

.btn-playstore-light {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--color-white);
  color: var(--color-green-dark);
  padding: 16px 32px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: var(--font-size-base);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  position: relative;
  z-index: 1;
}

.btn-playstore-light:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
  color: var(--color-green-dark);
}

.btn-playstore-light svg {
  width: 22px;
  height: 22px;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  padding: var(--space-3xl) 0 var(--space-xl);
  background-color: var(--color-gray-900);
  color: var(--color-gray-400);
}

.footer-inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}

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

.footer-logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-weight: 700;
  font-size: var(--font-size-lg);
  color: var(--color-white);
  margin-bottom: var(--space-md);
}

.footer-logo img {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
}

.footer-brand p {
  font-size: var(--font-size-sm);
  line-height: 1.7;
  color: var(--color-gray-400);
}

.footer-links h4 {
  font-size: var(--font-size-sm);
  font-weight: 700;
  color: var(--color-white);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--space-md);
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer-links a {
  font-size: var(--font-size-sm);
  color: var(--color-gray-400);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--color-white);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: var(--space-xl);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-md);
}

.footer-bottom p {
  font-size: var(--font-size-xs);
  color: var(--color-gray-600);
}

.footer-disclaimer {
  font-size: var(--font-size-xs);
  color: var(--color-gray-600);
  font-style: italic;
}

/* ==========================================================================
   LEGAL PAGES (Privacidade & Termos)
   ========================================================================== */
.legal-page {
  padding-top: calc(var(--header-height) + var(--space-3xl));
  padding-bottom: var(--space-4xl);
  min-height: 100vh;
}

.legal-content {
  max-width: 720px;
  margin: 0 auto;
}

.legal-content h1 {
  font-size: var(--font-size-3xl);
  font-weight: 800;
  color: var(--color-gray-900);
  margin-bottom: var(--space-sm);
}

.legal-meta {
  font-size: var(--font-size-sm);
  color: var(--color-text-secondary);
  margin-bottom: var(--space-2xl);
  padding-bottom: var(--space-xl);
  border-bottom: 1px solid var(--color-gray-200);
}

.legal-content h2 {
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--color-gray-900);
  margin-top: var(--space-2xl);
  margin-bottom: var(--space-md);
}

.legal-content h3 {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--color-gray-800);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.legal-content p {
  margin-bottom: var(--space-md);
  color: var(--color-gray-800);
  line-height: 1.8;
}

.legal-content ul {
  margin-bottom: var(--space-md);
  padding-left: var(--space-xl);
}

.legal-content li {
  list-style: disc;
  margin-bottom: var(--space-sm);
  color: var(--color-gray-800);
  line-height: 1.7;
}

.legal-content a {
  color: var(--color-green);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-content a:hover {
  color: var(--color-green-dark);
}

.legal-content strong {
  font-weight: 600;
  color: var(--color-gray-900);
}

.legal-content em {
  font-style: italic;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

/* Tablet */
@media (max-width: 768px) {
  :root {
    --font-size-5xl: 2.25rem;
    --font-size-4xl: 2rem;
    --font-size-3xl: 1.5rem;
  }

  .header-nav {
    display: none;
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--color-white);
    flex-direction: column;
    padding: var(--space-xl);
    gap: var(--space-lg);
    border-bottom: 1px solid var(--color-gray-100);
    box-shadow: var(--shadow-md);
  }

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

  .menu-toggle {
    display: block;
  }

  .hero-inner {
    flex-direction: column;
    text-align: center;
  }

  .hero-content {
    max-width: 100%;
  }

  .hero-subtitle {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-image {
    max-width: 400px;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

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

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

/* Mobile */
@media (max-width: 480px) {
  :root {
    --font-size-5xl: 1.875rem;
    --font-size-3xl: 1.375rem;
  }

  .hero {
    padding-top: calc(var(--header-height) + var(--space-2xl));
    padding-bottom: var(--space-2xl);
  }

  .hero-image {
    max-width: 300px;
  }

  .features {
    padding: var(--space-2xl) 0;
  }

  .cta {
    padding: var(--space-2xl) 0;
  }

  .feature-card {
    padding: var(--space-lg);
  }

  .btn-playstore,
  .btn-playstore-light {
    width: 100%;
    justify-content: center;
  }
}
