/* ===================================================
   skimmelfri.dk — Primær stylesheet
   Professionelt, neutralt skandinavisk design
   =================================================== */

/* --- CSS Custom Properties (Design Tokens) --- */
:root {
  /* Farver */
  --color-bg:            #ffffff;
  --color-bg-subtle:     #f4f7f5;
  --color-bg-muted:      #edf2ee;
  --color-surface:       #ffffff;
  --color-border:        #d8e2da;
  --color-border-light:  #eaf0eb;

  --color-text:          #1a2421;
  --color-text-muted:    #4a5e56;
  --color-text-subtle:   #7a9188;

  --color-primary:       #2d6a4f;   /* Muted forest green — tillid, natur */
  --color-primary-dark:  #1b4332;
  --color-primary-light: #40916c;
  --color-primary-bg:    #d8f3dc;

  --color-accent:        #52796f;
  --color-accent-light:  #84a98c;

  --color-link:          #1b5e3d;
  --color-link-hover:    #0d3d27;

  --color-warning:       #b5500a;
  --color-info:          #2c5f7a;

  /* Typografi */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
               Oxygen, Ubuntu, sans-serif;
  --font-serif: Georgia, 'Times New Roman', serif;

  --text-xs:   0.75rem;    /*  12px */
  --text-sm:   0.875rem;   /*  14px */
  --text-base: 1rem;       /*  16px */
  --text-md:   1.125rem;   /*  18px */
  --text-lg:   1.25rem;    /*  20px */
  --text-xl:   1.5rem;     /*  24px */
  --text-2xl:  1.875rem;   /*  30px */
  --text-3xl:  2.25rem;    /*  36px */
  --text-4xl:  2.75rem;    /*  44px */

  --leading-tight:   1.25;
  --leading-snug:    1.4;
  --leading-normal:  1.6;
  --leading-relaxed: 1.75;

  --font-weight-normal:  400;
  --font-weight-medium:  500;
  --font-weight-semi:    600;
  --font-weight-bold:    700;

  /* Spacing */
  --space-1:   0.25rem;
  --space-2:   0.5rem;
  --space-3:   0.75rem;
  --space-4:   1rem;
  --space-5:   1.25rem;
  --space-6:   1.5rem;
  --space-8:   2rem;
  --space-10:  2.5rem;
  --space-12:  3rem;
  --space-16:  4rem;
  --space-20:  5rem;
  --space-24:  6rem;

  /* Layout */
  --container-max:   1100px;
  --container-prose: 720px;
  --container-wide:  1280px;

  /* Borders */
  --radius-sm:  4px;
  --radius-md:  8px;
  --radius-lg:  12px;
  --radius-xl:  16px;

  /* Shadows */
  --shadow-sm:  0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md:  0 4px 12px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.04);
  --shadow-lg:  0 8px 24px rgba(0,0,0,0.08), 0 4px 8px rgba(0,0,0,0.04);

  /* Transitions */
  --transition-fast:   150ms ease;
  --transition-normal: 250ms ease;
}

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

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

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--color-link);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-link-hover);
}

a:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
  border-radius: 2px;
}

ul, ol {
  padding-left: var(--space-6);
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-weight: var(--font-weight-semi);
  line-height: var(--leading-tight);
  color: var(--color-text);
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }
h5 { font-size: var(--text-md); }
h6 { font-size: var(--text-base); }

@media (min-width: 768px) {
  h1 { font-size: var(--text-4xl); }
  h2 { font-size: var(--text-3xl); }
  h3 { font-size: var(--text-2xl); }
}

p {
  line-height: var(--leading-relaxed);
  color: var(--color-text);
}

.lead {
  font-size: var(--text-md);
  line-height: var(--leading-relaxed);
  color: var(--color-text-muted);
}

strong { font-weight: var(--font-weight-semi); }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-6);
}

.container--wide {
  max-width: var(--container-wide);
}

.container--prose {
  max-width: var(--container-prose);
}

/* --- Site Header / Navigation --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--color-surface);
  border-bottom: 1px solid var(--color-border-light);
  box-shadow: var(--shadow-sm);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: var(--space-6);
}

.site-logo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  flex-shrink: 0;
}

.site-logo__icon {
  width: 36px;
  height: 36px;
  background-color: var(--color-primary);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.site-logo__icon svg {
  width: 20px;
  height: 20px;
  fill: white;
}

.site-logo__text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.site-logo__name {
  font-size: var(--text-md);
  font-weight: var(--font-weight-semi);
  color: var(--color-primary-dark);
  letter-spacing: -0.01em;
}

.site-logo__tagline {
  font-size: var(--text-xs);
  color: var(--color-text-subtle);
  font-weight: var(--font-weight-normal);
}

/* Primary Navigation */
.site-nav {
  display: none;
  flex: 1;
  align-items: center;
  justify-content: center;
}

@media (min-width: 900px) {
  .site-nav {
    display: flex;
  }
}

.site-nav__list {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
  gap: var(--space-1);
}

.site-nav__link {
  display: inline-flex;
  align-items: center;
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm);
  font-weight: var(--font-weight-medium);
  color: var(--color-text-muted);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast), background-color var(--transition-fast);
  white-space: nowrap;
}

.site-nav__link:hover {
  color: var(--color-primary);
  background-color: var(--color-bg-subtle);
}

.site-nav__link.is-active {
  color: var(--color-primary);
  background-color: var(--color-bg-muted);
  font-weight: var(--font-weight-semi);
}

/* Header Actions */
.site-header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-shrink: 0;
}

/* Search toggle */
.btn-search {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  background: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  color: var(--color-text-muted);
  transition: color var(--transition-fast), background-color var(--transition-fast);
}

.btn-search:hover {
  color: var(--color-primary);
  background-color: var(--color-bg-subtle);
}

.btn-search svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
}

/* Mobile menu toggle */
.btn-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  background: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  color: var(--color-text-muted);
  transition: color var(--transition-fast), background-color var(--transition-fast);
}

.btn-menu:hover {
  color: var(--color-primary);
  background-color: var(--color-bg-subtle);
}

.btn-menu svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
}

@media (min-width: 900px) {
  .btn-menu { display: none; }
}

/* Mobile Navigation Drawer */
.mobile-nav {
  display: none;
  flex-direction: column;
  background-color: var(--color-surface);
  border-top: 1px solid var(--color-border-light);
  padding: var(--space-4) var(--space-6) var(--space-6);
}

.mobile-nav.is-open {
  display: flex;
}

@media (min-width: 900px) {
  .mobile-nav { display: none !important; }
}

.mobile-nav__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.mobile-nav__link {
  display: block;
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-base);
  font-weight: var(--font-weight-medium);
  color: var(--color-text-muted);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast), background-color var(--transition-fast);
}

.mobile-nav__link:hover,
.mobile-nav__link.is-active {
  color: var(--color-primary);
  background-color: var(--color-bg-subtle);
}

/* Search Overlay */
.search-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background-color: rgba(0,0,0,0.4);
  align-items: flex-start;
  justify-content: center;
  padding-top: 80px;
}

.search-overlay.is-open {
  display: flex;
}

.search-box {
  background-color: var(--color-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 640px;
  margin-inline: var(--space-6);
  overflow: hidden;
}

.search-box__input-wrap {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--color-border-light);
}

.search-box__icon {
  flex-shrink: 0;
  color: var(--color-text-subtle);
}

.search-box__icon svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
}

.search-box__input {
  flex: 1;
  border: none;
  outline: none;
  font-family: var(--font-sans);
  font-size: var(--text-md);
  color: var(--color-text);
  background: transparent;
}

.search-box__input::placeholder {
  color: var(--color-text-subtle);
}

.search-box__close {
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-1);
  color: var(--color-text-subtle);
  transition: color var(--transition-fast);
}

.search-box__close:hover { color: var(--color-text); }

.search-box__close svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
}

.search-box__results {
  padding: var(--space-4) var(--space-5);
  min-height: 80px;
}

.search-box__hint {
  font-size: var(--text-sm);
  color: var(--color-text-subtle);
  text-align: center;
  padding: var(--space-4) 0;
}

/* --- Site Footer --- */
.site-footer {
  background-color: var(--color-bg-subtle);
  border-top: 1px solid var(--color-border);
  padding-block: var(--space-12) var(--space-8);
  margin-top: var(--space-20);
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-10);
}

@media (min-width: 600px) {
  .site-footer__grid {
    grid-template-columns: 2fr 1fr 1fr;
    gap: var(--space-12);
  }
}

.site-footer__brand {}

.site-footer__brand .site-logo {
  margin-bottom: var(--space-4);
}

.site-footer__brand p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  max-width: 300px;
}

.site-footer__col {}

.site-footer__heading {
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-4);
}

.site-footer__nav {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.site-footer__nav a {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.site-footer__nav a:hover {
  color: var(--color-primary);
}

.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-border-light);
  margin-top: var(--space-10);
}

.site-footer__legal {
  font-size: var(--text-xs);
  color: var(--color-text-subtle);
}

.site-footer__legal a {
  color: var(--color-text-subtle);
  text-underline-offset: 2px;
}

.site-footer__legal a:hover {
  color: var(--color-primary);
}

.site-footer__cookie-link {
  font-size: var(--text-xs);
  color: var(--color-text-subtle);
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  font-family: var(--font-sans);
  transition: color var(--transition-fast);
}

.site-footer__cookie-link:hover {
  color: var(--color-primary);
}

/* --- Page Hero --- */
.page-hero {
  background-color: var(--color-bg-subtle);
  padding-block: var(--space-16) var(--space-12);
  border-bottom: 1px solid var(--color-border-light);
}

.page-hero--homepage {
  padding-block: var(--space-20) var(--space-16);
  background: linear-gradient(135deg, #f4f7f5 0%, #edf5ef 50%, #f4f7f5 100%);
}

.page-hero__label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semi);
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-4);
}

.page-hero__title {
  font-size: var(--text-3xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-text);
  line-height: var(--leading-tight);
  margin-bottom: var(--space-5);
  letter-spacing: -0.02em;
}

@media (min-width: 768px) {
  .page-hero__title {
    font-size: var(--text-4xl);
  }
}

.page-hero__description {
  font-size: var(--text-md);
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  max-width: 640px;
  margin-bottom: var(--space-8);
}

.page-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: var(--font-weight-medium);
  line-height: 1;
  border-radius: var(--radius-md);
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background-color var(--transition-fast),
              color var(--transition-fast),
              border-color var(--transition-fast),
              box-shadow var(--transition-fast);
  white-space: nowrap;
}

.btn:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

.btn--primary {
  background-color: var(--color-primary);
  color: #ffffff;
  border-color: var(--color-primary);
}

.btn--primary:hover {
  background-color: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
  color: #ffffff;
}

.btn--secondary {
  background-color: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.btn--secondary:hover {
  background-color: var(--color-bg-subtle);
  color: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
}

.btn--ghost {
  background-color: transparent;
  color: var(--color-text-muted);
  border-color: var(--color-border);
}

.btn--ghost:hover {
  background-color: var(--color-bg-subtle);
  color: var(--color-text);
}

.btn svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  flex-shrink: 0;
}

/* --- Cards --- */
.card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow var(--transition-normal), border-color var(--transition-normal);
}

.card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--color-border);
}

.card__body {
  padding: var(--space-6);
}

.card__icon {
  width: 48px;
  height: 48px;
  background-color: var(--color-bg-muted);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-4);
}

.card__icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--color-primary);
  fill: none;
}

.card__title {
  font-size: var(--text-lg);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-bottom: var(--space-2);
}

.card__description {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-4);
}

.card__link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  font-weight: var(--font-weight-medium);
  color: var(--color-primary);
  text-decoration: none;
  transition: gap var(--transition-fast), color var(--transition-fast);
}

.card__link:hover {
  gap: var(--space-3);
  color: var(--color-primary-dark);
}

.card__link svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  transition: transform var(--transition-fast);
}

.card__link:hover svg {
  transform: translateX(2px);
}

/* Card as link */
a.card {
  display: block;
  text-decoration: none;
  color: inherit;
}

/* --- Section Layout --- */
.section {
  padding-block: var(--space-16);
}

.section--muted {
  background-color: var(--color-bg-subtle);
}

.section__header {
  margin-bottom: var(--space-10);
}

.section__label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semi);
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-3);
}

.section__title {
  font-size: var(--text-2xl);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-bottom: var(--space-3);
  letter-spacing: -0.01em;
}

@media (min-width: 768px) {
  .section__title { font-size: var(--text-3xl); }
}

.section__description {
  font-size: var(--text-md);
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  max-width: 600px;
}

/* --- Grid Systems --- */
.grid {
  display: grid;
  gap: var(--space-6);
}

.grid--2 {
  grid-template-columns: repeat(1, 1fr);
}

.grid--3 {
  grid-template-columns: repeat(1, 1fr);
}

.grid--4 {
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 600px) {
  .grid--2 { grid-template-columns: repeat(2, 1fr); }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 768px) {
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
}

/* --- Prose / Article Content --- */
.prose {
  max-width: var(--container-prose);
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  color: var(--color-text);
}

.prose > * + * {
  margin-top: var(--space-5);
}

.prose h2 {
  font-size: var(--text-2xl);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-top: var(--space-10);
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--color-border-light);
  letter-spacing: -0.01em;
}

.prose h3 {
  font-size: var(--text-xl);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}

.prose h4 {
  font-size: var(--text-lg);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-top: var(--space-6);
  margin-bottom: var(--space-2);
}

.prose p {
  margin-bottom: 0;
  color: var(--color-text);
}

.prose ul, .prose ol {
  padding-left: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.prose li {
  line-height: var(--leading-relaxed);
}

.prose a {
  color: var(--color-link);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.prose strong {
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
}

.prose blockquote {
  border-left: 3px solid var(--color-primary);
  padding-left: var(--space-5);
  margin-left: 0;
  color: var(--color-text-muted);
  font-style: italic;
}

/* --- Info Boxes / Callouts --- */
.callout {
  display: flex;
  gap: var(--space-4);
  padding: var(--space-5) var(--space-6);
  border-radius: var(--radius-md);
  border: 1px solid;
}

.callout--info {
  background-color: #f0f7ff;
  border-color: #c0d9f0;
  color: var(--color-info);
}

.callout--tip {
  background-color: #f0faf4;
  border-color: #b8e4ca;
  color: var(--color-primary-dark);
}

.callout--warning {
  background-color: #fff8f0;
  border-color: #f0d0aa;
  color: var(--color-warning);
}

.callout__icon {
  flex-shrink: 0;
  margin-top: 2px;
}

.callout__icon svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
}

.callout__content {
  flex: 1;
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
}

.callout__title {
  font-weight: var(--font-weight-semi);
  margin-bottom: var(--space-1);
}

/* --- Article Layout --- */
.article-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-10);
  padding-block: var(--space-12);
}

@media (min-width: 1024px) {
  .article-layout {
    grid-template-columns: 1fr 280px;
    align-items: start;
  }
}

.article-sidebar {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.sidebar-box {
  background-color: var(--color-bg-subtle);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}

.sidebar-box__title {
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-4);
}

.sidebar-box__nav {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.sidebar-box__nav a {
  display: block;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast), background-color var(--transition-fast);
}

.sidebar-box__nav a:hover {
  color: var(--color-primary);
  background-color: var(--color-bg-muted);
}

/* --- Source Citation --- */
.source-citation {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  background-color: var(--color-bg-subtle);
  border-left: 3px solid var(--color-accent-light);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.source-citation__icon {
  flex-shrink: 0;
  color: var(--color-accent);
}

.source-citation__icon svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
}

/* --- Breadcrumb --- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--color-text-subtle);
  padding-block: var(--space-4);
  list-style: none;
  padding-left: 0;
  flex-wrap: wrap;
}

.breadcrumb__item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.breadcrumb__item + .breadcrumb__item::before {
  content: '/';
  color: var(--color-border);
}

.breadcrumb__link {
  color: var(--color-text-subtle);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.breadcrumb__link:hover {
  color: var(--color-primary);
}

.breadcrumb__current {
  color: var(--color-text-muted);
}

/* --- Steps / Numbered list --- */
.steps {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.step {
  display: flex;
  gap: var(--space-4);
  align-items: flex-start;
}

.step__number {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  background-color: var(--color-primary);
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-sm);
  font-weight: var(--font-weight-bold);
  margin-top: 2px;
}

.step__content {
  flex: 1;
}

.step__title {
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-bottom: var(--space-1);
}

.step__description {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
}

/* --- Resource List --- */
.resource-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.resource-item {
  display: flex;
  gap: var(--space-4);
  padding: var(--space-5);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  text-decoration: none;
  transition: border-color var(--transition-normal), box-shadow var(--transition-normal);
}

.resource-item:hover {
  border-color: var(--color-border);
  box-shadow: var(--shadow-sm);
}

.resource-item__icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background-color: var(--color-bg-muted);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
}

.resource-item__icon svg {
  width: 20px;
  height: 20px;
  stroke: var(--color-primary);
  fill: none;
}

.resource-item__content {
  flex: 1;
}

.resource-item__name {
  font-size: var(--text-base);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-bottom: var(--space-1);
}

.resource-item__description {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
}

.resource-item__badge {
  font-size: var(--text-xs);
  font-weight: var(--font-weight-medium);
  color: var(--color-primary);
  background-color: var(--color-bg-muted);
  padding: 2px var(--space-2);
  border-radius: var(--radius-sm);
  white-space: nowrap;
  align-self: flex-start;
  flex-shrink: 0;
}

/* --- Tag / Pill --- */
.tag {
  display: inline-flex;
  align-items: center;
  padding: var(--space-1) var(--space-3);
  font-size: var(--text-xs);
  font-weight: var(--font-weight-medium);
  border-radius: 100px;
  background-color: var(--color-bg-muted);
  color: var(--color-text-muted);
  text-decoration: none;
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

.tag:hover {
  background-color: var(--color-primary-bg);
  color: var(--color-primary-dark);
}

.tag--primary {
  background-color: var(--color-primary-bg);
  color: var(--color-primary-dark);
}

/* --- Utility Classes --- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border-width: 0;
}

.text-center { text-align: center; }
.text-muted   { color: var(--color-text-muted); }

.mt-auto { margin-top: auto; }
.mt-4    { margin-top: var(--space-4); }
.mt-6    { margin-top: var(--space-6); }
.mt-8    { margin-top: var(--space-8); }
.mb-4    { margin-bottom: var(--space-4); }
.mb-6    { margin-bottom: var(--space-6); }
.mb-8    { margin-bottom: var(--space-8); }

.flex       { display: flex; }
.flex-col   { flex-direction: column; }
.items-center { align-items: center; }
.gap-2      { gap: var(--space-2); }
.gap-4      { gap: var(--space-4); }
.gap-6      { gap: var(--space-6); }
.flex-wrap  { flex-wrap: wrap; }

.divider {
  border: none;
  border-top: 1px solid var(--color-border-light);
  margin-block: var(--space-8);
}

/* --- Skip to content --- */
.skip-to-content {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  z-index: 1000;
  padding: var(--space-3) var(--space-5);
  background-color: var(--color-primary);
  color: #ffffff;
  font-size: var(--text-sm);
  font-weight: var(--font-weight-medium);
  text-decoration: none;
  border-radius: var(--radius-md);
  transition: top var(--transition-fast);
}

.skip-to-content:focus {
  top: var(--space-4);
}

/* --- Info box and Warning box --- */
.info-box {
  background: var(--color-bg-subtle);
  border: 1px solid var(--color-border-light);
  border-left: 4px solid var(--color-primary);
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  margin-block: var(--space-6);
  font-size: var(--text-sm);
}

.info-box__title {
  font-weight: var(--font-weight-semi);
  margin-bottom: var(--space-2);
  color: var(--color-text);
}

.warning-box {
  background: #fffbeb;
  border: 1px solid #fcd34d;
  border-left: 4px solid #f59e0b;
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  margin-block: var(--space-6);
  font-size: var(--text-sm);
}

.warning-box__title {
  font-weight: var(--font-weight-semi);
  margin-bottom: var(--space-2);
  color: #92400e;
}

/* --- Sources section --- */
.sources-section {
  margin-top: var(--space-10);
  padding-top: var(--space-6);
  border-top: 1px solid var(--color-border-light);
}

.sources-section__title {
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semi);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.sources-section__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.sources-section__list a {
  font-size: var(--text-sm);
  color: var(--color-primary);
}

/* --- Card Image --- */
.card__image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

/* --- Page Hero with Photo Background --- */
.page-hero--homepage {
  position: relative;
  overflow: hidden;
}

.page-hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0.10;
  z-index: 0;
  pointer-events: none;
}

.page-hero .container,
.page-hero--homepage .container {
  position: relative;
  z-index: 1;
}

/* --- Section Image Banner --- */
.section-image {
  width: 100%;
  overflow: hidden;
  border-bottom: 1px solid var(--color-border-light);
}

.section-image__img {
  display: block;
  width: 100%;
  height: 280px;
  object-fit: cover;
  object-position: center;
}

@media (min-width: 768px) {
  .section-image__img {
    height: 360px;
  }
}

/* --- Article Banner Image --- */
.article-figure {
  margin: 0 0 var(--space-8) 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.article-figure__img {
  display: block;
  width: 100%;
  height: 260px;
  object-fit: cover;
  object-position: center;
}

.article-figure__caption {
  display: block;
  font-size: var(--text-xs);
  color: var(--color-text-subtle);
  padding: var(--space-2) var(--space-3);
  background-color: var(--color-bg-subtle);
  text-align: center;
}

/* --- Article Content Styles --- */
.article-content {
  min-width: 0;
}

.article-header {
  margin-bottom: var(--space-8);
  padding-bottom: var(--space-6);
  border-bottom: 2px solid var(--color-border-light);
}

.article-title {
  font-size: var(--text-3xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-text);
  line-height: var(--leading-tight);
  letter-spacing: -0.02em;
  margin-bottom: var(--space-4);
}

@media (min-width: 768px) {
  .article-title {
    font-size: var(--text-4xl);
  }
}

.article-intro {
  font-size: var(--text-md);
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  margin-bottom: 0;
}

/* Article body: section headings and text */
.article-content section > h2 {
  font-size: var(--text-xl);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-top: var(--space-10);
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--color-border-light);
}

.article-content h2:not(:first-child) {
  margin-top: var(--space-10);
}

.article-content h2 {
  font-size: var(--text-xl);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-top: var(--space-8);
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--color-border-light);
}

.article-content h3 {
  font-size: var(--text-lg);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  margin-top: var(--space-6);
  margin-bottom: var(--space-3);
}

.article-content p {
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-4);
}

.article-content ul,
.article-content ol {
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-4);
  padding-left: var(--space-6);
}

.article-content li {
  margin-bottom: var(--space-2);
}

/* Article nav (related articles) */
.article-nav {
  margin-top: var(--space-10);
  padding-top: var(--space-6);
  border-top: 2px solid var(--color-border-light);
}

.article-nav__title {
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semi);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.article-nav__list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.article-nav__link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  font-weight: var(--font-weight-medium);
  color: var(--color-primary);
  text-decoration: none;
  padding: var(--space-1) 0;
  transition: gap var(--transition-fast), color var(--transition-fast);
}

.article-nav__link::before {
  content: '→';
  font-size: var(--text-xs);
  flex-shrink: 0;
}

.article-nav__link:hover {
  color: var(--color-primary-dark);
  gap: var(--space-3);
}

/* Article sources */
.article-sources {
  margin-top: var(--space-10);
  padding-top: var(--space-6);
  border-top: 1px solid var(--color-border-light);
}

.article-sources__title {
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semi);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.article-sources__list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.article-sources__link {
  font-size: var(--text-sm);
  color: var(--color-primary);
}

/* Article updated timestamp */
.article-updated {
  margin-top: var(--space-6);
  font-size: var(--text-xs);
  color: var(--color-text-subtle);
}

/* --- Sidebar Widget aliases (backward compat) --- */
.sidebar-widget {
  background-color: var(--color-bg-subtle);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}

.sidebar-widget__title {
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-4);
}

.sidebar-widget__list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.sidebar-widget__link {
  display: block;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast), background-color var(--transition-fast);
}

.sidebar-widget__link:hover {
  color: var(--color-primary);
  background-color: var(--color-bg-muted);
}

/* --- Sidebar Card aliases --- */
.sidebar-card {
  background-color: var(--color-bg-subtle);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}

.sidebar-card__title {
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semi);
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-4);
}

.sidebar-card__list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.sidebar-card__link {
  display: block;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast), background-color var(--transition-fast);
}

.sidebar-card__link:hover {
  color: var(--color-primary);
  background-color: var(--color-bg-muted);
}

/* --- Breadcrumb aliases --- */
.breadcrumb__list {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  margin: 0;
}

.breadcrumb__item--current {
  color: var(--color-text-muted);
}

.breadcrumb__separator {
  color: var(--color-border);
  font-size: var(--text-sm);
}

/* --- Prose styles --- */
.prose p {
  line-height: var(--leading-relaxed);
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.prose h2 {
  font-size: var(--text-xl);
  font-weight: var(--font-weight-semi);
  margin-top: var(--space-8);
  margin-bottom: var(--space-4);
}

.prose ul, .prose ol {
  color: var(--color-text-muted);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-4);
}

.prose li {
  margin-bottom: var(--space-2);
}

/* --- Article body layout  --- */
.content-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-10);
  padding-block: var(--space-12);
}

@media (min-width: 1024px) {
  .content-grid {
    grid-template-columns: 1fr 280px;
    align-items: start;
  }
}

.article-body {
  min-width: 0;
}

/* --- Info table (used in comparison tables) --- */
.info-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-sm);
  margin-block: var(--space-4);
}

.info-table th,
.info-table td {
  padding: var(--space-3) var(--space-4);
  text-align: left;
  border-bottom: 1px solid var(--color-border-light);
}

.info-table th {
  font-weight: var(--font-weight-semi);
  background-color: var(--color-bg-subtle);
  color: var(--color-text);
}

.info-table td {
  color: var(--color-text-muted);
}

.info-table tr:last-child td {
  border-bottom: none;
}

/* --- Skip link alias --- */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  z-index: 1000;
  padding: var(--space-3) var(--space-5);
  background-color: var(--color-primary);
  color: #ffffff;
  font-size: var(--text-sm);
  font-weight: var(--font-weight-medium);
  text-decoration: none;
  border-radius: var(--radius-md);
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: var(--space-4);
}

/* --- Print styles --- */
@media print {
  .site-header,
  .site-footer,
  .cookie-banner,
  .search-overlay,
  .btn-menu,
  .btn-search { display: none !important; }

  body { font-size: 12pt; color: #000; }
  a { color: #000; }
  .container { max-width: 100%; padding: 0; }
}
