/* 
  Consumer Rights Awareness Portal (CRAP)
  Global CSS - Civic Aesthetic Design System
*/

:root {
  /* Color Palette - Premium Civic Aesthetic */
  --primary-blue: #1e3a8a;
  --primary-gradient: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
  --secondary-teal: #0d9488;
  --secondary-gradient: linear-gradient(135deg, #0d9488 0%, #14b8a6 100%);
  --accent-amber: #d97706;
  --neutral-grey: #64748b;
  --bg-white: #ffffff;
  --bg-offwhite: #f8fafc;
  --text-dark: #0f172a;
  --text-muted: #475569;
  --error-red: #b91c1c;

  /* Typography */
  --font-family: 'Outfit', 'Inter', -apple-system, sans-serif;
  --line-height: 1.6;
  --font-size-base: 18px;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;

  /* Premium UI */
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Accessibility: Support for high-contrast/elderly users */
@media (prefers-contrast: more) {
  :root {
    --primary-blue: #000080;
    --text-dark: #000000;
    --text-muted: #1a1a1a;
  }
}

/* Base Styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

h1,
h2,
h3,
h4 {
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: var(--space-sm);
  color: var(--primary-blue);
  letter-spacing: -0.025em;
}

p {
  margin-bottom: var(--space-sm);
  color: var(--text-muted);
}

a {
  color: var(--primary-blue);
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition);
}

a:hover {
  color: var(--secondary-teal);
}

/* Layout Utilities */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.section {
  padding: var(--space-lg) 0;
}

.hero-bg {
  background: var(--primary-gradient);
  color: white;
  padding: calc(var(--space-lg) * 1.5) 0;
  position: relative;
  overflow: hidden;
}

.hero-bg h1,
.hero-bg p {
  color: white;
}

/* Components */
header {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  padding: var(--space-sm) 0;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: var(--transition);
}

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

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary-blue);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

nav ul {
  list-style: none;
  display: flex;
  gap: var(--space-md);
}

nav a {
  font-weight: 600;
  color: var(--text-muted);
  font-size: 0.95rem;
  padding: 0.5rem 0;
  border-bottom: 2px solid transparent;
}

nav a:hover,
nav a.active {
  color: var(--primary-blue);
  border-bottom-color: var(--primary-blue);
}

/* Cards & Interaction */
.card {
  background: var(--bg-white);
  padding: var(--space-md);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(226, 232, 240, 0.6);
  transition: var(--transition);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.btn {
  display: inline-block;
  padding: 0.85rem 2rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.btn-primary {
  background: var(--primary-gradient);
  color: white;
}

.btn-primary:hover {
  box-shadow: var(--shadow-lg);
  transform: scale(1.02);
  color: white;
}

.btn-secondary {
  background: var(--bg-white);
  color: var(--primary-blue);
  border: 2px solid var(--primary-blue);
}

.btn-secondary:hover {
  background: var(--primary-blue);
  color: white;
}

/* Interstitial Warning */
#interstitial-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  background: var(--bg-white);
  padding: var(--space-md);
  border-radius: var(--radius-md);
  max-width: 500px;
  text-align: center;
}

/* Footer Styles */
footer {
  background: var(--primary-blue);
  color: white;
  padding: var(--space-lg) 0;
  margin-top: var(--space-lg);
}

footer a {
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
}

footer a:hover {
  color: white;
  text-decoration: underline;
}

.footer-disclaimer {
  background: rgba(255, 255, 255, 0.05);
  padding: var(--space-md);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  margin-bottom: var(--space-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
  line-height: 1.6;
}

footer h4 {
  color: white;
  margin-bottom: var(--space-sm);
  font-size: 1.1rem;
}

/* Mobile Navigation & Hamburger */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--primary-blue);
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
}

@media (max-width: 768px) {
  .mobile-toggle {
    display: block;
  }

  nav ul {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: white;
    flex-direction: column;
    padding: var(--space-lg) var(--space-md);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
    z-index: 1000;
    display: flex;
    gap: var(--space-sm);
  }

  nav ul.active {
    right: 0;
  }

  nav a {
    font-size: 1.25rem;
    display: block;
    width: 100%;
    border-bottom: 1px solid var(--bg-offwhite);
    padding: var(--space-sm) 0;
  }

  .nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    backdrop-filter: blur(2px);
  }

  .nav-overlay.active {
    display: block;
  }
}

/* Form Styles */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  max-width: 600px;
  margin-top: var(--space-md);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-weight: 600;
  color: var(--text-dark);
  font-size: 0.9rem;
}

.form-control {
  width: 100%;
  padding: 0.85rem 1rem;
  font-family: var(--font-family);
  font-size: 1rem;
  border: 1px solid rgba(226, 232, 240, 1);
  border-radius: var(--radius-sm);
  background: white;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-blue);
  box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

textarea.form-control {
  min-height: 150px;
  resize: vertical;
}

.success-state {
  text-align: center;
  padding: var(--space-lg) var(--space-md);
  animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Print Friendly */
@media print {

  header,
  footer,
  nav,
  .btn,
  .modal {
    display: none !important;
  }

  body {
    font-size: 12pt;
    background: white;
  }

  .container {
    width: 100%;
    margin: 0;
    padding: 0;
  }
}