/* Keystone BI - Website Styles
   Professional but different. Navy suit, off-color shirt, brown oxfords.
*/

/* ============================================
   CSS Variables - Color Palette
   ============================================ */
:root {
  /* Primary Colors */
  --navy: #1e3a5f;
  --navy-dark: #152a45;
  --navy-light: #2d4a6f;

  /* Accent Colors */
  --olive: #5c7c5c;
  --olive-light: #7a9a7a;
  --olive-dark: #4a644a;

  /* Neutrals */
  --background: #f5f5f3;
  --card-bg: #ffffff;
  --text-primary: #2d3748;
  --text-secondary: #5a6677;
  --text-light: #8492a6;
  --border: #e2e4e8;

  /* Warm Accent (the brown oxfords) */
  --warm-accent: #8b7355;
  --warm-accent-light: #a6896b;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-xxl: 6rem;

  /* Typography */
  --font-heading: 'Georgia', 'Times New Roman', serif;
  --font-body: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Borders & Shadows */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(30, 58, 95, 0.08);
  --shadow-md: 0 4px 12px rgba(30, 58, 95, 0.1);
  --shadow-lg: 0 8px 30px rgba(30, 58, 95, 0.12);
}

/* ============================================
   Reset & Base
   ============================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-primary);
  background-color: var(--background);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.3;
  color: var(--navy);
}

h1 {
  font-size: 2.75rem;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 2rem;
  margin-bottom: var(--space-md);
}

h3 {
  font-size: 1.5rem;
  margin-bottom: var(--space-sm);
}

p {
  margin-bottom: var(--space-sm);
  color: var(--text-secondary);
}

a {
  color: var(--navy);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--olive);
}

/* ============================================
   Layout
   ============================================ */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.section {
  padding: var(--space-xxl) 0;
}

/* ============================================
   Navigation
   ============================================ */
.nav {
  background: var(--card-bg);
  border-bottom: 1px solid var(--border);
  padding: var(--space-sm) 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.nav-logo {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--navy);
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.nav-logo-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--navy) 0%, var(--olive) 100%);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
  font-size: 0.9rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  list-style: none;
}

.nav-links a {
  font-size: 0.95rem;
  color: var(--text-secondary);
  padding: var(--space-xs) 0;
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
}

.nav-links a:hover {
  color: var(--navy);
  border-bottom-color: var(--olive);
}

.nav-cta {
  background: var(--navy);
  color: white !important;
  padding: var(--space-xs) var(--space-md) !important;
  border-radius: var(--radius-sm);
  font-weight: 500;
  border: none !important;
}

.nav-cta:hover {
  background: var(--navy-light) !important;
  color: white !important;
}

/* Mobile Navigation */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-xs);
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--navy);
  margin: 5px 0;
  transition: 0.3s;
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--card-bg);
    flex-direction: column;
    padding: var(--space-md);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links a {
    padding: var(--space-sm) 0;
  }
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
  padding: var(--space-xxl) 0;
  text-align: center;
}

.hero-content {
  max-width: 700px;
  margin: 0 auto;
}

.hero h1 {
  margin-bottom: var(--space-md);
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
  line-height: 1.8;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  background: var(--navy);
  color: white;
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius-md);
  font-size: 1.05rem;
  font-weight: 500;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-md);
}

.hero-cta:hover {
  background: var(--navy-light);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.hero-cta svg {
  width: 20px;
  height: 20px;
}

/* ============================================
   Features Section
   ============================================ */
.features {
  background: var(--card-bg);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.features-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.features-header p {
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}

@media (max-width: 768px) {
  .features-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }
}

.feature-card {
  padding: var(--space-lg);
  background: var(--background);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  transition: all 0.2s ease;
}

.feature-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--olive-light);
}

.feature-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--olive-light) 0%, var(--olive) 100%);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-md);
  color: white;
}

.feature-icon svg {
  width: 24px;
  height: 24px;
}

.feature-card h3 {
  color: var(--navy);
  margin-bottom: var(--space-xs);
}

.feature-card p {
  font-size: 0.95rem;
  margin-bottom: 0;
}

/* ============================================
   Benefits Section
   ============================================ */
.benefits {
  background: var(--background);
}

.benefits-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: center;
}

@media (max-width: 768px) {
  .benefits-content {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }
}

.benefits-text h2 {
  margin-bottom: var(--space-md);
}

.benefits-list {
  list-style: none;
  margin-top: var(--space-md);
}

.benefits-list li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
  color: var(--text-secondary);
}

.benefits-list li svg {
  width: 22px;
  height: 22px;
  color: var(--olive);
  flex-shrink: 0;
  margin-top: 2px;
}

.benefits-visual {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.benefits-visual-placeholder {
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, var(--navy) 0%, var(--olive) 100%);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-family: var(--font-heading);
  font-size: 1.5rem;
  text-align: center;
  padding: var(--space-md);
}

/* ============================================
   Footer
   ============================================ */
.footer {
  background: var(--navy-dark);
  color: rgba(255, 255, 255, 0.8);
  padding: var(--space-xl) 0 var(--space-lg);
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: var(--space-lg);
}

.footer-brand {
  max-width: 300px;
}

.footer-logo {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  color: white;
  margin-bottom: var(--space-sm);
}

.footer-brand p {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 0;
}

.footer-links {
  display: flex;
  gap: var(--space-xl);
}

.footer-links-column h4 {
  color: white;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-sm);
  font-family: var(--font-body);
}

.footer-links-column ul {
  list-style: none;
}

.footer-links-column li {
  margin-bottom: var(--space-xs);
}

.footer-links-column a {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.footer-links-column a:hover {
  color: white;
}

.footer-bottom {
  margin-top: var(--space-lg);
  padding-top: var(--space-md);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

@media (max-width: 768px) {
  .footer-content {
    flex-direction: column;
    text-align: center;
  }

  .footer-brand {
    max-width: 100%;
  }

  .footer-links {
    flex-direction: column;
    gap: var(--space-md);
  }
}

/* ============================================
   Legal Pages (Privacy Policy, Terms)
   ============================================ */
.legal-page {
  padding: var(--space-xl) 0 var(--space-xxl);
}

.legal-content {
  max-width: 800px;
  margin: 0 auto;
  background: var(--card-bg);
  padding: var(--space-xl);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

.legal-content h1 {
  margin-bottom: var(--space-xs);
}

.legal-updated {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: var(--space-lg);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid var(--border);
}

.legal-content h2 {
  font-size: 1.35rem;
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
  color: var(--navy);
}

.legal-content p {
  margin-bottom: var(--space-md);
}

.legal-content ul {
  margin-bottom: var(--space-md);
  padding-left: var(--space-md);
}

.legal-content li {
  margin-bottom: var(--space-xs);
  color: var(--text-secondary);
}

.legal-content strong {
  color: var(--text-primary);
}

/* ============================================
   404 Page
   ============================================ */
.error-page {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--space-xl) var(--space-md);
}

.error-content h1 {
  font-size: 8rem;
  color: var(--navy);
  line-height: 1;
  margin-bottom: var(--space-sm);
  opacity: 0.2;
}

.error-content h2 {
  font-size: 2rem;
  margin-bottom: var(--space-sm);
}

.error-content p {
  font-size: 1.1rem;
  margin-bottom: var(--space-lg);
}

.error-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  background: var(--navy);
  color: white;
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius-md);
  font-weight: 500;
  transition: all 0.2s ease;
}

.error-cta:hover {
  background: var(--navy-light);
  color: white;
}

/* ============================================
   Utilities
   ============================================ */
.text-center {
  text-align: center;
}

.mb-0 {
  margin-bottom: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
