/* ==========================================================================
   Ferndale Conservatory of Music & Audio — Official Design System & Framework
   Nashville Music Row, Tennessee | Est. 1974
   Color Scheme: Deep Burgundy (#6B1D2F), Brass Gold (#C5A059), Vinyl Black (#18181B)
   ========================================================================== */

/* --- Font Declarations --- */
@font-face {
  font-family: 'Cinzel';
  font-style: normal;
  font-weight: 600 700;
  font-display: swap;
  src: url('../fonts/cinzel.woff2') format('woff2');
}

@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400 500 600 700;
  font-display: swap;
  src: url('../fonts/plus-jakarta-sans.woff2') format('woff2');
}

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 500 600;
  font-display: swap;
  src: url('../fonts/inter.woff2') format('woff2');
}

/* --- Design Tokens --- */
:root {
  --primary: #6B1D2F;         /* Deep Vintage Burgundy / Maroon */
  --primary-dark: #4A1220;    /* Aged Cabernet */
  --primary-light: #8E2B42;   /* Rosewood Accent */
  --secondary: #C5A059;       /* Brass Gold / Console Accent */
  --secondary-light: #E2C382; /* Warm Gold Highlight */
  --dark: #18181B;            /* Vinyl Black / Acoustic Baffle */
  --dark-surface: #27272A;    /* Studio Control Desk Slate */
  --light: #FAF8F5;           /* Warm Parchment Score Sheet */
  --light-surface: #FFFFFF;   /* Clean White Panel */
  --border: #E4E4E7;          /* Hairline Zinc Border */
  --border-dark: #3F3F46;     /* Dark Mode / Studio Rack Border */
  --muted: #71717A;           /* Zinc Muted Copy */
  --on-air: #EF4444;          /* Live Studio Red Indicator */
  --live-green: #10B981;      /* Console Signal Green */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 3px rgba(24, 24, 27, 0.08);
  --shadow-md: 0 4px 12px rgba(24, 24, 27, 0.10);
  --shadow-lg: 0 12px 28px rgba(24, 24, 27, 0.16);
  --font-serif: 'Cinzel', Georgia, 'Times New Roman', serif;
  --font-sans: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

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

[hidden] {
  display: none !important;
}

html {
  font-size: 16px;
  line-height: 1.6;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  color: var(--dark);
  background-color: var(--light);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  position: relative;
}

/* Accessibility: Skip Links & Focus Ring */
.skip-link {
  position: absolute;
  top: -48px;
  left: 1rem;
  background: var(--secondary);
  color: var(--dark);
  font-weight: 700;
  padding: 0.6rem 1.2rem;
  z-index: 99999;
  border-radius: var(--radius-sm);
  transition: top 0.2s ease;
  text-decoration: none;
}
.skip-link:focus {
  top: 1rem;
  outline: 3px solid var(--primary);
}

a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid var(--secondary);
  outline-offset: 3px;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  color: var(--primary-dark);
  line-height: 1.25;
  margin-bottom: 0.8rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2rem, 4vw + 1rem, 3.25rem); }
h2 { font-size: clamp(1.6rem, 2.5vw + 0.8rem, 2.35rem); }
h3 { font-size: clamp(1.25rem, 1.8vw + 0.5rem, 1.65rem); }
h4 { font-size: 1.2rem; }

p {
  margin-bottom: 1.2rem;
  color: #27272A;
}

a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: var(--transition);
}
a:hover {
  color: var(--secondary);
}

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

/* --- Layout Containers --- */
.container {
  width: 100%;
  max-width: 1240px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.container-narrow {
  max-width: 860px;
}

/* --- Top Audio Dispatch & Studio Utility Bar --- */
.top-utility-bar {
  background-color: var(--dark);
  color: #D4D4D8;
  font-size: 0.82rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-dark);
}
.utility-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.studio-status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background-color: var(--on-air);
  box-shadow: 0 0 8px var(--on-air);
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}
.utility-links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}
.utility-links a {
  color: #A1A1AA;
  text-decoration: none;
  font-size: 0.8rem;
}
.utility-links a:hover {
  color: var(--secondary-light);
}

/* --- Main Header & Navigation --- */
.site-header {
  background-color: #FFFFFF;
  border-bottom: 2px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}
.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem 0;
}
.brand-link {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--primary-dark);
}
.brand-crest {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border: 2px solid var(--secondary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--secondary);
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.3rem;
  box-shadow: var(--shadow-sm);
}
.brand-text h1 {
  font-size: 1.18rem;
  margin: 0;
  line-height: 1.15;
  color: var(--primary-dark);
  font-family: var(--font-serif);
}
.brand-tagline {
  font-size: 0.73rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  display: block;
}

/* Desktop Nav */
.main-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}
.nav-list {
  display: flex;
  list-style: none;
  gap: 0.25rem;
  align-items: center;
}
.nav-item {
  position: relative;
}
.nav-link {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 600;
  color: #27272A;
  text-decoration: none;
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.nav-link:hover, .nav-item:focus-within > .nav-link {
  color: var(--primary);
  background-color: rgba(107, 29, 47, 0.06);
}

/* Dropdown Menu */
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 260px;
  background: #FFFFFF;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-md);
  padding: 0.6rem 0;
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all 0.2s ease;
  z-index: 1050;
}
.nav-item:hover .dropdown-menu,
.nav-item:focus-within .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown-menu a {
  display: block;
  padding: 0.55rem 1.25rem;
  font-size: 0.88rem;
  font-weight: 500;
  color: #3F3F46;
  text-decoration: none;
}
.dropdown-menu a:hover {
  background-color: #FAF5F6;
  color: var(--primary);
  padding-left: 1.5rem;
}

/* Mobile Nav Toggle */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  padding: 0.5rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  color: var(--dark);
}

/* Mobile Drawer */
.mobile-drawer {
  position: fixed;
  top: 0;
  right: -320px;
  width: 300px;
  height: 100vh;
  background: #FFFFFF;
  box-shadow: var(--shadow-lg);
  z-index: 9999;
  transition: right 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
  padding: 1.5rem;
}
.mobile-drawer.open {
  right: 0;
}
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(24, 24, 27, 0.5);
  backdrop-filter: blur(2px);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}
.drawer-backdrop.active {
  opacity: 1;
  visibility: visible;
}

/* --- Hero Banner Styles --- */
.hero-section {
  position: relative;
  background-color: var(--dark);
  color: #FFFFFF;
  padding: 5rem 0 4.5rem;
  background-size: cover;
  background-position: center;
  overflow: hidden;
}
.hero-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(24, 24, 27, 0.88) 0%, rgba(107, 29, 47, 0.75) 60%, rgba(24, 24, 27, 0.92) 100%);
  z-index: 1;
}
.hero-content {
  position: relative;
  z-index: 2;
  max-width: 820px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  background: rgba(197, 160, 89, 0.2);
  border: 1px solid var(--secondary);
  border-radius: 999px;
  color: var(--secondary-light);
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.25rem;
}
.hero-section h1 {
  color: #FFFFFF;
  margin-bottom: 1.25rem;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}
.hero-lead {
  font-size: 1.22rem;
  color: #E4E4E7;
  margin-bottom: 2rem;
  line-height: 1.6;
}
.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* --- Buttons & CTAs --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.6rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
}
.btn-primary {
  background-color: var(--primary);
  color: #FFFFFF;
  box-shadow: 0 2px 8px rgba(107, 29, 47, 0.3);
}
.btn-primary:hover {
  background-color: var(--primary-light);
  color: #FFFFFF;
  transform: translateY(-1px);
}
.btn-secondary {
  background-color: var(--secondary);
  color: var(--dark);
  font-weight: 700;
}
.btn-secondary:hover {
  background-color: var(--secondary-light);
  color: var(--dark);
  transform: translateY(-1px);
}
.btn-outline-light {
  background-color: transparent;
  border-color: rgba(255, 255, 255, 0.4);
  color: #FFFFFF;
}
.btn-outline-light:hover {
  background-color: rgba(255, 255, 255, 0.1);
  border-color: #FFFFFF;
  color: #FFFFFF;
}
.btn-outline-dark {
  background-color: transparent;
  border-color: var(--primary);
  color: var(--primary);
}
.btn-outline-dark:hover {
  background-color: var(--primary);
  color: #FFFFFF;
}

/* --- Studio Badges & Tags --- */
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.pill-on-air {
  background: rgba(239, 68, 68, 0.15);
  color: #DC2626;
  border: 1px solid rgba(239, 68, 68, 0.3);
}
.pill-open {
  background: rgba(16, 185, 129, 0.15);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* --- Section Styling --- */
.section {
  padding: 4.5rem 0;
}
.section-alt {
  background-color: #F4F1EA;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.section-dark {
  background-color: var(--dark);
  color: #FFFFFF;
}
.section-dark h2, .section-dark h3 {
  color: #FFFFFF;
}
.section-dark p {
  color: #A1A1AA;
}
.section-header {
  margin-bottom: 2.8rem;
}
.section-header.text-center {
  text-align: center;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}
.section-kicker {
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--secondary);
  display: block;
  margin-bottom: 0.5rem;
}

/* --- Cards & Grids --- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(440px, 1fr));
  gap: 2rem;
}
.grid-4 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.5rem;
}

.card {
  background: #FFFFFF;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: rgba(107, 29, 47, 0.3);
}
.card-media {
  position: relative;
  aspect-ratio: 16 / 9;
  background-color: #27272A;
  overflow: hidden;
}
.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.card:hover .card-media img {
  transform: scale(1.04);
}
.card-body {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.card-body h3 {
  margin-bottom: 0.6rem;
  font-size: 1.25rem;
}
.card-body p {
  font-size: 0.92rem;
  color: var(--muted);
  flex: 1;
}
.card-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border);
  background: #FAFAFA;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* --- Tables & Academic Specs --- */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 1.5rem 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: #FFFFFF;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.92rem;
}
th {
  background-color: #F4F1EA;
  color: var(--primary-dark);
  font-family: var(--font-serif);
  font-weight: 700;
  padding: 0.9rem 1.2rem;
  border-bottom: 2px solid var(--border);
}
td {
  padding: 0.85rem 1.2rem;
  border-bottom: 1px solid var(--border);
  color: #3F3F46;
}
tr:last-child td {
  border-bottom: none;
}
tr:hover td {
  background-color: #FAF5F6;
}

/* --- Studio Gear & Rack Specifications --- */
.gear-spec-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}
.gear-item {
  background: #FFFFFF;
  border: 1px solid var(--border);
  padding: 1rem 1.2rem;
  border-radius: var(--radius-sm);
  border-left: 4px solid var(--secondary);
}
.gear-item strong {
  display: block;
  color: var(--primary-dark);
  font-size: 0.95rem;
}
.gear-item span {
  font-size: 0.85rem;
  color: var(--muted);
}

/* --- Interactive Budget & Studio Calculator Widget --- */
.calculator-box {
  background: #FFFFFF;
  border: 2px solid var(--secondary);
  border-radius: var(--radius-lg);
  padding: 2.2rem;
  box-shadow: var(--shadow-lg);
}
.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.form-group {
  margin-bottom: 1.25rem;
}
.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  color: var(--dark);
}
.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  background: #FFFFFF;
}
.form-control:focus {
  border-color: var(--secondary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(197, 160, 89, 0.25);
}
.calc-summary {
  background: #F4F1EA;
  padding: 1.8rem;
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.calc-total {
  font-size: 2.4rem;
  font-family: var(--font-serif);
  color: var(--primary-dark);
  font-weight: 700;
  margin: 0.5rem 0;
}

/* --- Breadcrumb --- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  padding: 1rem 0;
  list-style: none;
  color: var(--muted);
}
.breadcrumb a {
  color: var(--muted);
  text-decoration: none;
}
.breadcrumb a:hover {
  color: var(--primary);
}
.breadcrumb-separator {
  color: #A1A1AA;
}

/* --- Search & Filter Bar --- */
.search-container {
  position: relative;
  max-width: 540px;
  margin: 1.5rem auto;
}
.search-input {
  width: 100%;
  padding: 0.85rem 1.25rem 0.85rem 2.8rem;
  border: 2px solid var(--border);
  border-radius: 999px;
  font-size: 1rem;
  background: #FFFFFF;
}
.search-input:focus {
  border-color: var(--secondary);
  outline: none;
}
.search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
}

/* --- Downloads List --- */
.download-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 1.5rem;
  background: #FFFFFF;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 0.85rem;
  transition: var(--transition);
}
.download-card:hover {
  border-color: var(--secondary);
  box-shadow: var(--shadow-sm);
}
.download-info {
  display: flex;
  align-items: center;
  gap: 1.2rem;
}
.download-badge {
  padding: 0.3rem 0.6rem;
  background: #F4F1EA;
  color: var(--primary);
  font-weight: 700;
  font-size: 0.75rem;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
}

/* --- Footer --- */
.site-footer {
  background-color: var(--dark);
  color: #A1A1AA;
  border-top: 4px solid var(--secondary);
  padding: 4.5rem 0 2rem;
  margin-top: auto;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 3rem;
  margin-bottom: 3.5rem;
}
.footer-brand h2 {
  color: #FFFFFF;
  font-size: 1.35rem;
  margin-bottom: 0.5rem;
}
.footer-brand p {
  color: #A1A1AA;
  font-size: 0.9rem;
  line-height: 1.6;
}
.footer-column h3 {
  color: var(--secondary-light);
  font-size: 1rem;
  font-family: var(--font-sans);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.2rem;
}
.footer-links {
  list-style: none;
}
.footer-links li {
  margin-bottom: 0.65rem;
}
.footer-links a {
  color: #D4D4D8;
  text-decoration: none;
  font-size: 0.88rem;
}
.footer-links a:hover {
  color: var(--secondary);
}
.footer-bottom {
  border-top: 1px solid var(--border-dark);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.82rem;
}
.footer-legal-links {
  display: flex;
  gap: 1.5rem;
}
.footer-legal-links a {
  color: #71717A;
  text-decoration: none;
}
.footer-legal-links a:hover {
  color: #A1A1AA;
}

/* --- Responsive Media Queries --- */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }
}

@media (max-width: 820px) {
  .main-nav {
    display: none;
  }
  .mobile-nav-toggle {
    display: block;
  }
  .grid-2 {
    grid-template-columns: 1fr;
  }
  .calc-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .utility-flex {
    flex-direction: column;
    align-items: flex-start;
  }
  .hero-actions {
    flex-direction: column;
    width: 100%;
  }
  .hero-actions .btn {
    width: 100%;
  }
  .grid-3 {
    grid-template-columns: 1fr;
  }
}
