/* ==========================================================================
   Modern CSS for Muziekschool Janine
   Replaces Foundation framework with CSS Grid/Flexbox
   ========================================================================== */

/* --------------------------------------------------------------------------
   CSS Reset (minimal modern reset)
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  font-size: 100%;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

ul, ol {
  list-style: none;
}

a {
  text-decoration: none;
  color: inherit;
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

strong, b {
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   Grid System (Foundation replacement)
   -------------------------------------------------------------------------- */
:root {
  --row-gap: 1.5rem;
}

.row {
  display: flex;
  flex-wrap: wrap;
  max-width: 62.5rem; /* 1000px */
  width: 100%;
  margin: 0 auto;
  padding: 0 1rem;
  gap: var(--row-gap);
  text-align: left;
}

.row::before,
.row::after {
  display: none;
}

/* Base column styling */
.row > .columns,
.row > [class*="small-"],
.row > [class*="medium-"] {
  /*padding: 0 1rem;*/
  box-sizing: border-box;
}

/* Small screens (default - mobile first) */
/* Gap-adjusted widths: subtract (gaps / columns) from each column */
.row > .small-4 { flex: 0 0 calc(33.333% - var(--row-gap) * 2 / 3); max-width: calc(33.333% - var(--row-gap) * 2 / 3); }
.row > .small-8 { flex: 0 0 calc(66.667% - var(--row-gap) / 3); max-width: calc(66.667% - var(--row-gap) / 3); }
.row > .small-12 { flex: 0 0 100%; max-width: 100%; }

/* Medium screens (640px+) */
@media (min-width: 40em) {
  .row > .medium-4 { flex: 0 0 calc(33.333% - var(--row-gap) * 2 / 3); max-width: calc(33.333% - var(--row-gap) * 2 / 3); }
  .row > .medium-6 { flex: 0 0 calc(50% - var(--row-gap) / 2); max-width: calc(50% - var(--row-gap) / 2); }
  .row > .medium-8 { flex: 0 0 calc(66.667% - var(--row-gap) / 3); max-width: calc(66.667% - var(--row-gap) / 3); }

  .row > .medium-push-2 {
    margin-left: 16.667%;
  }
}

/* Utility classes */
.clearfix::after {
  content: "";
  display: table;
  clear: both;
}

.clear {
  clear: both;
}

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

/* --------------------------------------------------------------------------
   Base Typography
   -------------------------------------------------------------------------- */
body {
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  line-height: 1.5;
  text-align: center;
  text-rendering: optimizeLegibility;
  font-optical-sizing: auto;
  background: url("../img/background.png") center top no-repeat;
  color: #2d2d2d;
}

@media (max-width: 64rem) {
  body {
    background: none;
  }
}

h1, h2, h3, h4, h5, h6 {
  color: #222;
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 0.75rem;
}

h1 {
  font-size: 2rem;
  color: #b8a518;
  font-weight: normal;
}

h2 {
  font-size: 1.5rem;
}

h3 {
  font-size: 1.375rem;
}

h4 {
  font-size: 1.25rem;
  text-transform: uppercase;
}

p, ul, ol, dl, form, table {
  margin-bottom: 1.5rem;
}

abbr {
  font-size: 1.125em;
  font-family: "Goudy Old Style", Baskerville, Palatino, "Book Antiqua", serif;
  font-style: italic;
}

/* --------------------------------------------------------------------------
   Layout Sections
   -------------------------------------------------------------------------- */
.section {
  clear: both;
  width: 100%;
}

#content img {
  max-width: 100%;
  margin-bottom: 1.5em;
}

@media (min-width: 40em) {
  .side {
    margin-top: 140px;
  }
}

.side img,
#content img,
#footer-misc img {
  padding: 5px;
  background: #fff;
  border: 1px solid #eee;
  border-radius: 3px;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */
#header {
  background: #101010 url("../img/header_background.png") repeat-x;
}

#header .row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 60px;
  padding: 0 1rem;
}

#header h1#logo {
  color: #fff;
  font-weight: normal;
  margin: 0;
  text-transform: uppercase;
  font-size: 1.125em;
  letter-spacing: 0.04em;
}

@media (min-width: 40em) {
  #header h1#logo {
    font-size: 1.25em;
  }
}

#header h1#logo a {
  color: #fff;
  transition: all 0.3s ease-in-out;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 2px;
}

#header h1#logo a:hover {
  text-decoration-color: #fff;
}

#header nav ul {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0;
}

#header nav ul li a {
  display: block;
  background: #1d1d1d;
  color: #fff;
  border: 1px solid transparent;
  border-radius: 3px;
  padding: 0.5rem 0.75rem;
  transition: all 0.3s ease-in-out;
}

#header nav ul li a:hover {
  background: #272727;
  border-color: rgba(255, 255, 255, 0.15);
}

#header nav ul li.current_list_item a {
  font-weight: bold;
  background: #b8a518;
}

/* Hamburger button - hidden on desktop */
#menu-toggle {
  display: none;
}

/* Header responsive */
@media (max-width: 64rem) {
  #header .row {
    flex-wrap: nowrap;
    justify-content: space-between;
    align-items: center;
    height: 60px;
  }

  #header h1#logo {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    height: 60px;
  }

  /* Hamburger button */
  #menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    padding: 8px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
  }

  #menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: #fff;
    transition: all 0.3s ease;
  }

  #menu-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  #menu-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
  }

  #menu-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  /* Off-canvas nav */
  #main-nav {
    position: fixed;
    top: 0;
    right: -280px;
    width: 280px;
    height: 100vh;
    background: #101010;
    padding: 80px 0 2rem;
    transition: right 0.3s ease;
    z-index: 1000;
    overflow-y: auto;
  }

  #main-nav.is-open {
    right: 0;
  }

  #header nav ul {
    flex-direction: column;
    gap: 0;
    text-align: left;
  }

  #header nav ul li {
    border-bottom: 1px solid #272727;
  }

  #header nav ul li a {
    border-radius: 0;
    padding: 1rem 1.5rem;
  }

  /* Overlay */
  body.nav-open::before {
    content: "";
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
  }
}

/* --------------------------------------------------------------------------
   Title Banner
   -------------------------------------------------------------------------- */
#title {
  min-height: 200px;
  display: flex;
  align-items: center;
}

#title p {
  font-family: Georgia, serif;
  font-style: italic;
  font-weight: 300;
  font-size: 1.5rem;
  line-height: 1.4;
  color: #fff;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.5);
  margin: 0;
  max-width: 28rem;
  text-wrap: balance;
}

#title abbr {
  color: #fff;
}

@media (width < 64rem) {
  #title {
    background: #1a1a1a;
    min-height: auto;
    padding: 2rem 0;
  }

  #title p {
    margin-top: 0;
  }
}

/* --------------------------------------------------------------------------
   Content
   -------------------------------------------------------------------------- */
#content {
  margin-bottom: 30px;
}

.main h1 {
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
  max-width: 600px;
}

@media (width > 64rem) {
  .main h1 {
    display: grid;
    align-content: center;
    margin-top: .5rem;
    margin-bottom: 2rem;
    min-height: 6rem;
  }
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
#footer-misc {
  background: #0f0f0f url("../img/footer_background.png") no-repeat center center;
  background-size: cover;
  padding: 30px 0;
  margin-bottom: 30px;
  color: #fff;
}

#footer-misc .row {
  align-items: start;
}

#footer-misc h3 {
  font-size: 1.25em;
  line-height: 1.2em;
  margin-bottom: 0.5em;
  color: #fff;
}

#footer-misc a {
  color: #fff;
  transition: all 0.3s ease-in-out;
}

#footer-misc a:hover {
  text-decoration: underline;
}

#footer-misc .green {
  padding: 20px 30px;
  background: #c7b73d;
  margin-bottom: 30px;
  border-radius: 3px;
}

#footer .row {
  padding: 0 1rem 1.5rem;
}

#footer p {
  margin-bottom: 0.5rem;
}

/* --------------------------------------------------------------------------
   Tables
   -------------------------------------------------------------------------- */
.list-table {
  width: 100%;
  border-top: 1px solid #e3e7f0;
}

.list-table caption {
  background: #f7f8fb;
  height: 42px;
  font-size: 1.4em;
  line-height: 42px;
  text-align: center;
  color: #b8a518;
  font-weight: bold;
  border: 1px solid #e3e7f0;
  border-bottom: none;
}

.list-table thead td,
.list-table thead th {
  padding: 8px 12px;
  color: #2a4d9a;
  font-weight: normal;
  text-align: left;
  border-top: 1px solid #c7cfe1;
  border-bottom: 1px solid #c7cfe1;
  background: #f7f8fb;
}

.list-table tbody td,
.list-table tbody th {
  padding: 12px;
  text-align: left;
  font-weight: normal;
  border-bottom: 1px solid #e3e7f0;
}

.list-table tbody th {
  font-weight: bold;
}

.list-table tbody td {
  width: 190px;
  text-align: center;
  border-left: 1px solid #dbe0eb;
  border-right: 1px solid #dbe0eb;
}

.list-table tbody tr:nth-child(even) {
  background: #fff;
}

/* --------------------------------------------------------------------------
   Accessibility
   -------------------------------------------------------------------------- */
:focus {
  outline: 2px solid #b8a518;
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

:focus-visible {
  outline: 2px solid #b8a518;
  outline-offset: 2px;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: #b8a518;
  color: #fff;
  padding: 8px 16px;
  z-index: 1000;
}

.skip-link:focus {
  top: 0;
  outline: none;
}

/* --------------------------------------------------------------------------
   Print styles
   -------------------------------------------------------------------------- */
@media print {
  #header ul,
  #footer-misc img {
    display: none;
  }

  body {
    background: none;
    color: #000;
  }

  a {
    text-decoration: underline;
  }
}
