/* ═══════════════════════════════════════════════════════════
   BMO Online Banking Design System — Premium Branded Theme
   ═══════════════════════════════════════════════════════════ */

:root {
  --bmo-blue: #003366;
  --bmo-blue-dark: #001F3F;
  --bmo-sky: #0079C1;
  --bmo-sky-light: #E1F1FB;
  --bmo-white: #FFFFFF;
  --bmo-gray-50: #F9F9F9;
  --bmo-gray-100: #F1F1F1;
  --bmo-gray-200: #E2E2E2;
  --bmo-gray-700: #4A4A4A;
  --bmo-gray-900: #1A1A1A;
  
  --bmo-text-primary: #1A1A1A;
  --bmo-text-secondary: #4A4A4A;
  --bmo-text-muted: #767676;
  
  --bmo-gradient: linear-gradient(135deg, #003366 0%, #001F3F 100%);
  --bmo-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  --bmo-shadow-blue: 0 4px 15px rgba(0, 51, 102, 0.2);
  
  --bmo-radius: 4px;
  --bmo-radius-md: 8px;
  --bmo-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --bmo-max-width: 1200px;
  --bmo-transition: 0.2s ease-in-out;
}

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

html { scroll-behavior: smooth; font-size: 16px; }

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

a { color: var(--bmo-blue); text-decoration: none; transition: var(--bmo-transition); }
a:hover { color: var(--bmo-blue-dark); text-decoration: underline; }

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

/* ─── Typography ─── */
h1, h2, h3, h4 { font-weight: 700; line-height: 1.2; color: var(--bmo-blue); }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); margin-bottom: 24px; }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); margin-bottom: 20px; }
h3 { font-size: 1.5rem; margin-bottom: 16px; }
p { margin-bottom: 16px; }

.lead { font-size: 1.25rem; color: var(--bmo-text-secondary); margin-bottom: 32px; }

/* ─── Layout ─── */
.container { max-width: var(--bmo-max-width); margin: 0 auto; padding: 0 24px; }

.section { padding: 80px 0; }
.section-alt { background: var(--bmo-gray-50); }
.section-branded { background: var(--bmo-blue); color: #fff; }
.section-branded h1, .section-branded h2, .section-branded h3 { color: #fff; }

.text-center { text-align: center; }

/* ─── Header ─── */
.site-header {
  background: var(--bmo-white);
  border-bottom: 4px solid var(--bmo-sky);
  position: sticky; top: 0; z-index: 1000;
  box-shadow: var(--bmo-shadow);
}
.header-inner {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--bmo-blue);
  text-transform: uppercase;
  letter-spacing: -1px;
}
.logo span { color: var(--bmo-sky); }

.main-nav { display: flex; gap: 32px; }
.main-nav a {
  color: var(--bmo-text-primary);
  font-weight: 600;
  font-size: 1rem;
  padding: 8px 0;
  position: relative;
}
.main-nav a:hover { color: var(--bmo-blue); text-decoration: none; }
.main-nav a.active::after {
  content: '';
  position: absolute; bottom: 0; left: 0; width: 100%; height: 2px;
  background: var(--bmo-blue);
}

.nav-cta {
  background: var(--bmo-blue);
  color: #fff !important;
  padding: 10px 24px !important;
  border-radius: var(--bmo-radius);
}
.nav-cta:hover { background: var(--bmo-blue-dark) !important; transform: translateY(-1px); }

/* ─── Tables ─── */
.table-container { overflow-x: auto; margin: 32px 0; border: 1px solid var(--bmo-gray-200); border-radius: var(--bmo-radius-md); }
.data-table { width: 100%; border-collapse: collapse; background: #fff; text-align: left; }
.data-table th, .data-table td { padding: 18px 24px; border-bottom: 1px solid var(--bmo-gray-200); }
.data-table th { background: var(--bmo-gray-50); color: var(--bmo-blue); font-weight: 700; text-transform: uppercase; font-size: 0.85rem; letter-spacing: 0.5px; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover { background: var(--bmo-gray-50); }

.feature-tag { 
    display: inline-block; padding: 4px 12px; background: rgba(0, 121, 193, 0.1); 
    color: var(--bmo-sky); border-radius: 20px; font-size: 0.75rem; font-weight: 700; 
    text-transform: uppercase; margin-bottom: 12px;
}

/* ─── Buttons ─── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  font-weight: 700;
  border-radius: var(--bmo-radius);
  cursor: pointer;
  transition: var(--bmo-transition);
  border: none;
}
.btn-primary { background: var(--bmo-blue); color: #fff; }
.btn-primary:hover { background: var(--bmo-blue-dark); box-shadow: var(--bmo-shadow-blue); }
.btn-sky { background: var(--bmo-sky); color: #fff; }
.btn-sky:hover { background: var(--bmo-blue); }

/* ─── Cards ─── */
.grid { display: grid; gap: 32px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: #fff;
  padding: 40px;
  border: 1px solid var(--bmo-gray-200);
  border-bottom: 4px solid var(--bmo-gray-200);
  transition: var(--bmo-transition);
}
.card:hover {
  transform: translateY(-5px);
  border-bottom-color: var(--bmo-sky);
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* ─── FAQ ─── */
.faq-item { border-bottom: 1px solid var(--bmo-gray-200); }
.faq-question {
  width: 100%; padding: 20px 0; background: none; border: none;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 1.1rem; font-weight: 700; color: var(--bmo-blue); cursor: pointer; text-align: left;
}
.faq-answer { display: none; padding-bottom: 20px; color: var(--bmo-text-secondary); }
.faq-item.active .faq-answer { display: block; }

/* ─── AI Chunks ─── */
.ai-chunk {
  font-style: italic;
  color: var(--bmo-blue-dark);
  border-left: 3px solid var(--bmo-sky);
  padding-left: 16px;
  margin: 24px 0;
  font-size: 1rem;
  line-height: 1.5;
  background: rgba(0, 121, 193, 0.05);
  padding-top: 12px;
  padding-bottom: 12px;
}

/* ─── Footer ─── */
.site-footer { background: var(--bmo-gray-900); color: #fff; padding: 60px 0 30px; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
.footer-logo { font-size: 1.5rem; font-weight: 900; margin-bottom: 20px; color: #fff; }
.footer-logo span { color: var(--bmo-sky); }
.footer-links h4 { color: var(--bmo-sky); margin-bottom: 20px; font-size: 1rem; }
.footer-links ul { list-style: none; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: #ccc; font-size: 0.9rem; }
.footer-links a:hover { color: #fff; }

.footer-bottom { border-top: 1px solid #333; margin-top: 40px; padding-top: 20px; display: flex; justify-content: space-between; font-size: 0.8rem; color: #888; }

/* Mobile */
@media (max-width: 768px) {
  .header-inner { flex-direction: column; height: auto; padding: 20px 0; gap: 20px; }
  .grid-3 { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
}
