/* Reset & Variables */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
:root {
  --primary-blue: #1E5B9E;
  --primary-red: #D43F36;
  --accent-gold: #F2C94C;
  --accent-green: #27AE60;
  --bg-light: #F9F9F9;
  --bg-dark: #1A1A2E;
  --text-dark: #111;
  --text-light: #fff;
  --highlight: #FF6B35;
  --border-subtle: #E0E0E0;
  --font-heading: Impact, 'Arial Black', sans-serif;
  --font-body: 'Lucida Grande', 'Helvetica Neue', Arial, sans-serif;
  --max-width: 1200px;
  --header-h: 70px;
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;
}
body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-dark);
  background: var(--bg-light);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
a { color: var(--primary-blue); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible { outline: 3px solid var(--accent-gold); outline-offset: 2px; }
:focus-visible { outline: 3px solid var(--accent-gold); outline-offset: 2px; }

/* Skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--primary-red);
  color: var(--text-light);
  padding: var(--space-sm) var(--space-md);
  z-index: 1000;
  font-weight: bold;
}
.skip-link:focus { left: 0; }

/* Wrapper */
.wrapper { max-width: var(--max-width); margin: 0 auto; padding: 0 var(--space-sm); }

/* Header */
.site-header {
  background: var(--primary-blue);
  color: var(--text-light);
  position: relative;
  z-index: 900;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.header-bounds {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  gap: var(--space-sm);
}
.header-brand-group {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}
.site-logo {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  color: var(--text-light);
  font-family: var(--font-heading);
  font-size: 1.4rem;
}
.logo-icon { font-size: 1.8rem; }
.logo-text { letter-spacing: -0.02em; }
.header-tagline {
  font-size: 0.75rem;
  color: var(--accent-gold);
  border-left: 2px solid var(--accent-gold);
  padding-left: 0.5rem;
  display: none;
}
@media (min-width: 768px) {
  .header-tagline { display: inline; }
}
.header-nav { display: none; }
.header-nav[data-open] { display: block; }
.nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}
.nav-list a {
  display: block;
  padding: 0.5rem 1rem;
  color: var(--text-light);
  font-size: 1rem;
  font-weight: 600;
  transition: background 0.2s;
}
.nav-list a:hover,
.nav-list a:focus-visible { background: rgba(255,255,255,0.15); text-decoration: none; }
.nav-list a[aria-current="page"] {
  border-bottom: 3px solid var(--accent-gold);
  background: rgba(255,255,255,0.1);
}
.header-cta {
  display: none;
  white-space: nowrap;
}
@media (min-width: 768px) {
  .header-nav {
    display: flex;
    align-items: center;
  }
  .nav-list {
    flex-direction: row;
    gap: 0;
  }
  .nav-list a { padding: 0.5rem 0.75rem; }
  .header-cta { display: inline-block; }
  .nav-toggle { display: none; }
}
.nav-toggle {
  background: none;
  border: 2px solid var(--accent-gold);
  color: var(--accent-gold);
  font-size: 1.5rem;
  padding: 0.25rem 0.5rem;
  cursor: pointer;
  line-height: 1;
}
@media (max-width: 767px) {
  .header-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100%;
    background: var(--primary-blue);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    z-index: 999;
    padding: var(--space-md) var(--space-sm);
    box-shadow: 4px 0 12px rgba(0,0,0,0.2);
  }
  .header-nav[data-open] {
    transform: translateX(0);
    display: block;
  }
  .nav-list { flex-direction: column; gap: 0; }
  .nav-list a { padding: 1rem; font-size: 1.2rem; border-bottom: 1px solid rgba(255,255,255,0.1); }
  .header-cta { display: none; }
}

/* Footer */
.site-footer {
  background: var(--bg-dark);
  color: var(--text-light);
  padding: var(--space-lg) 0 var(--space-md);
}
.footer-bounds {
  display: grid;
  gap: var(--space-md);
}
.footer-brand { grid-area: footer-brand; }
.footer-logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--accent-gold);
}
.footer-tagline { margin-top: 0.5rem; opacity: 0.8; }
.footer-links { grid-area: footer-links; }
.footer-nav {
  list-style: none;
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}
.footer-nav a { color: var(--text-light); opacity: 0.8; font-size: 0.9rem; }
.footer-nav a:hover { opacity: 1; text-decoration: underline; }
.footer-info { grid-area: footer-info; font-size: 0.8rem; opacity: 0.6; }
.footer-contact { margin-top: 0.25rem; }
@media (min-width: 768px) {
  .footer-bounds {
    grid-template-areas:
      "footer-brand footer-links"
      "footer-info footer-info";
    grid-template-columns: 1fr auto;
  }
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.6rem 1.5rem;
  font-family: var(--font-body);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}
.btn-primary {
  background: var(--primary-red);
  color: var(--text-light);
  border-color: var(--primary-red);
}
.btn-primary:hover {
  background: #b8322c;
  border-color: #b8322c;
  text-decoration: none;
}
.btn-outline {
  background: transparent;
  color: var(--accent-gold);
  border-color: var(--accent-gold);
}
.btn-outline:hover {
  background: var(--accent-gold);
  color: var(--bg-dark);
  text-decoration: none;
}

/* Frame border component */
.frame-border {
  border: 3px solid var(--primary-blue);
  border-image: repeating-linear-gradient(90deg, var(--accent-gold) 0, var(--accent-gold) 8px, var(--primary-blue) 8px, var(--primary-blue) 16px) 30;
  padding: var(--space-md);
  position: relative;
  background: var(--bg-light);
}
.frame-border::before {
  content: "⏱︎";
  position: absolute;
  top: -12px;
  left: 20px;
  background: var(--primary-red);
  color: var(--text-light);
  font-size: 1.2rem;
  padding: 2px 8px;
  border-radius: 4px;
}

/* Misc */
img, svg { max-width: 100%; height: auto; display: block; }
ul, ol { padding-left: 1.5rem; }

/* Scroll progress bar (fixed top) */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: rgba(0,0,0,0.1);
  z-index: 1001;
  pointer-events: none;
}
.scroll-progress span {
  display: block;
  height: 100%;
  width: 0;
  background: var(--primary-red);
  transition: width 0.1s linear;
}
/* Back to top */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 48px;
  height: 48px;
  border: none;
  background: var(--primary-blue);
  color: var(--text-light);
  font-size: 1.5rem;
  cursor: pointer;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
  z-index: 998;
}
.back-to-top.visible { opacity: 1; visibility: visible; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

/* Responsive typography */
@media (max-width: 767px) {
  body { font-size: 15px; }
  h1 { font-size: 1.8rem; }
}
@media (min-width: 768px) {
  body { font-size: 16px; }
  h1 { font-size: 2.5rem; }
}
