/* === RESET & BASE === */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --sand: #f5f0e8;
  --cream: #faf8f4;
  --white: #ffffff;
  --ink: #1a1410;
  --ink-light: #4a3f35;
  --muted: #8a7e72;
  --border: #e2d9cc;
  --terracotta: #c0614a;
  --rust: #9e3d25;
  --sage: #4a7c5e;
  --gold: #b8860b;
  --sky: #2c6ea6;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: 'DM Sans', system-ui, sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.7;
  min-width: 320px;
}

/* === PROGRESS BAR === */
.progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  background: var(--terracotta);
  width: 0%;
  z-index: 999;
  transition: width 0.1s linear;
}

/* === HEADER === */
.site-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
  position: relative;
  overflow: hidden;
}

.header-inner {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 80px 64px;
  background: var(--sand);
  position: relative;
  z-index: 2;
}

.header-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--terracotta);
  border: 1.5px solid var(--terracotta);
  padding: 6px 14px;
  border-radius: 2px;
  width: fit-content;
  margin-bottom: 32px;
}

.site-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.15;
  color: var(--ink);
  margin-bottom: 24px;
}

.site-title em {
  font-style: italic;
  color: var(--terracotta);
}

.site-lead {
  font-size: 1.05rem;
  color: var(--ink-light);
  max-width: 440px;
  line-height: 1.7;
  margin-bottom: 48px;
}

.header-scroll {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--muted);
  font-size: 0.8rem;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.scroll-line {
  width: 40px;
  height: 1px;
  background: var(--muted);
}

.header-image {
  position: relative;
  overflow: hidden;
}

.header-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 8s ease;
}

.header-image:hover img {
  transform: scale(1.03);
}

.header-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(245,240,232,0.3) 0%, transparent 40%);
}

/* === STICKY NAV === */
.sticky-nav {
  position: sticky;
  top: 0;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  transition: box-shadow 0.2s;
}

.sticky-nav.scrolled {
  box-shadow: 0 2px 20px rgba(26,20,16,0.08);
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
}

.nav-link {
  display: block;
  padding: 18px 20px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-decoration: none;
  color: var(--muted);
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.nav-link:hover,
.nav-link.active {
  color: var(--terracotta);
  border-bottom-color: var(--terracotta);
}

/* === SECTIONS === */
.section {
  padding: 96px 0;
  border-bottom: 1px solid var(--border);
}

.section-alt {
  background: var(--sand);
}

.section-gold {
  background: var(--ink);
}

.section-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 32px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.section-inner.full-width {
  grid-template-columns: 1fr;
  gap: 0;
}

.section-inner.centered {
  text-align: center;
}

.section-meta {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 20px;
}

.section-meta.centered {
  justify-content: center;
}

.lesson-num {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--terracotta);
  line-height: 1;
}

.lesson-num.light { color: rgba(255,255,255,0.3); }

.lesson-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
}

.lesson-label.light { color: rgba(255,255,255,0.4); }

h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.2;
  color: var(--ink);
  margin-bottom: 24px;
}

h2.light { color: var(--white); }

.lead-text {
  font-size: 1.05rem;
  color: var(--ink-light);
  margin-bottom: 40px;
  max-width: 600px;
}

/* === STAT === */
.big-stat {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 32px;
  background: var(--white);
  border: 1px solid var(--border);
  border-left: 4px solid var(--terracotta);
  border-radius: 4px;
}

.stat-number {
  font-family: 'Playfair Display', serif;
  font-size: 4.5rem;
  font-weight: 900;
  color: var(--terracotta);
  line-height: 1;
  flex-shrink: 0;
}

.stat-pct {
  font-size: 2rem;
}

.big-stat p {
  font-size: 0.95rem;
  color: var(--ink-light);
  line-height: 1.6;
}

/* === SECTION IMAGE === */
.section-image img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  border-radius: 4px;
  display: block;
}

/* === CARDS === */
.cards-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 8px;
}

.info-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 3px solid var(--border);
  border-radius: 4px;
  padding: 32px 28px;
  transition: border-top-color 0.25s, transform 0.25s, box-shadow 0.25s;
}

.info-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(26,20,16,0.1);
}

.info-card[data-color="blue"]:hover,
.info-card[data-color="blue"].active {
  border-top-color: var(--sky);
}

.info-card[data-color="green"]:hover,
.info-card[data-color="green"].active {
  border-top-color: var(--sage);
}

.info-card[data-color="orange"]:hover,
.info-card[data-color="orange"].active {
  border-top-color: var(--terracotta);
}

.card-symbol {
  font-size: 2rem;
  margin-bottom: 16px;
  line-height: 1;
}

.info-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 12px;
}

.info-card p {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 20px;
}

.card-btn {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--terracotta);
  background: transparent;
  border: 1.5px solid var(--terracotta);
  border-radius: 2px;
  padding: 8px 16px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
style.cssstyle.cssstyle.css
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.filter-btn {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
  background: transparent;
  border: 1.5px solid var(--border);
  border-radius: 2px;
  padding: 8px 18px;
  cursor: pointer;
  transition: all 0.2s;
}

.filter-btn:hover {
  border-color: var(--terracotta);
  color: var(--terracotta);
}

.filter-btn.active {
  background: var(--terracotta);
  border-color: var(--terracotta);
  color: var(--white);
}

.licence-table {
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
}

.licence-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 0;
  transition: background 0.15s;
}

.licence-row:not(.head) {
  border-top: 1px solid var(--border);
}

.licence-row:not(.head):hover {
  background: rgba(192,97,74,0.04);
}

.licence-row.hidden {
  display: none;
}

.licence-row.head {
  background: var(--ink);
}

.licence-row.head span {
  padding: 14px 20px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
}

.licence-row:not(.head) span {
  padding: 16px 20px;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
}

.licence-name {
  font-weight: 600;
  color: var(--ink);
}

.tag {
  font-size: 0.82rem !important;
  font-weight: 600;
  border-radius: 2px;
  padding: 4px 10px !important;
  width: fit-content;
  height: fit-content;
  align-self: center !important;
}

.tag.yes { background: #eaf5ee; color: var(--sage); }
.tag.no { background: #fdecea; color: #c0392b; }
.tag.warn { background: #fef9e7; color: var(--gold); }
.tag.muted { background: transparent; color: var(--muted); font-weight: 500 !important; padding: 0 !important; }

/* === ACCORDION === */
.accordion {
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
}

.acc-item + .acc-item {
  border-top: 1px solid var(--border);
}

.acc-head {
  width: 100%;
  text-align: left;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
  background: var(--white);
  border: none;
  padding: 20px 24px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background 0.15s, color 0.15s;
  border-radius: 0;
}

.acc-head::after {
  content: '+';
  font-size: 1.2rem;
  color: var(--muted);
  transition: transform 0.2s, color 0.2s;
  flex-shrink: 0;
  margin-left: 12px;
}

.acc-head.open {
  background: var(--sand);
  color: var(--terracotta);
}

.acc-head.open::after {
  content: '−';
  color: var(--terracotta);
}

.acc-body {
  display: none;
  padding: 0 24px 24px;
  font-size: 0.9rem;
  color: var(--ink-light);
  line-height: 1.7;
  background: var(--sand);
}

/* === TABS === */
.tabs {
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
}

.tab-nav {
  display: flex;
  border-bottom: 1px solid var(--border);
  background: var(--white);
}

.tab-btn {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--muted);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 18px 28px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  border-radius: 0;
  margin-bottom: -1px;
}

.tab-btn:hover {
  color: var(--ink);
}

.tab-btn.active {
  color: var(--terracotta);
  border-bottom-color: var(--terracotta);
}

.tab-content {
  display: none;
  padding: 36px;
  background: var(--cream);
}

.tab-content.active {
  display: block;
}

.tab-content h4 {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 16px;
}

.tab-content p {
  font-size: 0.95rem;
  color: var(--ink-light);
  line-height: 1.7;
}

/* === TASL === */
.tasl-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  margin-top: 8px;
}

.tasl-block {
  padding: 36px 28px;
  border-right: 1px solid var(--border);
  transition: background 0.2s;
}

.tasl-block:last-child {
  border-right: none;
}

.tasl-block:hover {
  background: rgba(192,97,74,0.04);
}

.tasl-letter {
  font-family: 'Playfair Display', serif;
  font-size: 3.5rem;
  font-weight: 900;
  color: var(--terracotta);
  line-height: 1;
  display: block;
  margin-bottom: 16px;
}

.tasl-block h4 {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 10px;
}

.tasl-block p {
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.6;
}

/* === GOLDEN RULE === */
.section-gold .section-inner {
  padding: 80px 32px;
}

.section-gold h2 {
  color: var(--white);
  margin-bottom: 48px;
}

.big-quote {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(1.3rem, 3vw, 2rem);
  font-style: italic;
  font-weight: 700;
  color: var(--white);
  line-height: 1.5;
  max-width: 760px;
  margin: 0 auto 32px;
  padding: 0 40px;
  position: relative;
}

.big-quote::before,
.big-quote::after {
  content: '"';
  font-size: 5rem;
  color: var(--terracotta);
  opacity: 0.5;
  position: absolute;
  line-height: 1;
  font-style: normal;
}

.big-quote::before { top: -16px; left: 0; }
.big-quote::after { content: '"'; bottom: -48px; right: 0; }

.section-gold cite {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  margin-top: 56px;
}

/* === FOOTER === */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.35);
  text-align: center;
  padding: 32px 20px;
  font-size: 0.8rem;
  letter-spacing: 0.5px;
}

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .site-header {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .header-inner {
    padding: 64px 32px;
  }

  .header-image {
    height: 300px;
  }

  .section-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .section-image { order: -1; }
  .section-image img { height: 260px; }

  .cards-row {
    grid-template-columns: 1fr;
  }

  .tasl-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .tasl-block:nth-child(2) { border-right: none; }
  .tasl-block:nth-child(1),
  .tasl-block:nth-child(2) { border-bottom: 1px solid var(--border); }

  .licence-row {
    grid-template-columns: 1fr 1fr;
  }

  .licence-row.head span:nth-child(n+3),
  .licence-row:not(.head) span:nth-child(n+3) {
    display: none;
  }

  .nav-inner {
    padding: 0 16px;
  }

  .nav-link {
    padding: 14px 12px;
    font-size: 0.72rem;
  }
}

@media (max-width: 560px) {
  .section { padding: 64px 0; }
  .section-inner { padding: 0 20px; }
  .tasl-row { grid-template-columns: 1fr; }
  .tasl-block { border-right: none; border-bottom: 1px solid var(--border); }
  .tasl-block:last-child { border-bottom: none; }
}