:root {
  color-scheme: light;
  --paper: #faf3e6;
  --surface: #fff9ef;
  --ink: #2d1b27;
  --muted: #66535e;
  --line: #dbcbbd;
  --plum: #392334;
  --accent: #f69f92;
  --accent-strong: #e98576;
  --font-display: Georgia, 'Times New Roman', serif;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
  font-size: 100%;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
input, select, button { font: inherit; }
h1, h2, h3, p { margin: 0; }
p { color: var(--muted); }
h1, h2, h3 { color: var(--ink); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 3px solid #93406a;
  outline-offset: 4px;
}
main { min-height: 56vh; }
#content { scroll-margin-top: 20px; }
.shell { width: min(1200px, calc(100% - 80px)); margin-inline: auto; }

.skip-link {
  position: absolute;
  z-index: 9;
  top: .75rem;
  left: .75rem;
  transform: translateY(-200%);
  padding: .5rem 1rem;
  background: white;
}
.skip-link:focus { transform: none; }

.site-header { border-bottom: 1px solid var(--line); }
.masthead { display: flex; align-items: center; justify-content: space-between; gap: 1.55rem; min-height: 75px; }
.brand { display: inline-flex; gap: .64rem; align-items: center; flex: none; font-size: .98rem; line-height: 1.08; font-weight: 750; text-decoration: none; }
.brand-sub { display: block; font-size: .71rem; letter-spacing: .025em; font-weight: 650; margin-top: .2rem; }
.brand-mark {
  display: grid;
  grid-template: repeat(2, 5px) / repeat(2, 5px);
  place-content: center;
  gap: 3px;
  width: 33px;
  height: 33px;
  background: var(--plum);
  border-radius: 10px;
  rotate: -8deg;
}
.brand-mark i { background: #fcd7bc; border-radius: 1px; }
.brand-mark i:nth-child(2) { background: #f19182; }
.main-nav, .site-actions, .language { display: flex; align-items: center; }
.main-nav { gap: clamp(1rem, 3vw, 2.7rem); }
.main-nav a, .language a { text-decoration: none; font-weight: 650; font-size: .9rem; }
.main-nav a:hover, .main-nav a[aria-current] { text-decoration: underline; text-underline-offset: .32rem; }
.site-actions { gap: 1rem; }
.language { gap: .14rem; padding: .19rem; border: 1px solid var(--line); border-radius: 999px; }
.language a { display: grid; place-items: center; min-width: 34px; min-height: 35px; border-radius: 999px; font-size: .82rem; }
.language a[aria-current] { background: var(--plum); color: var(--surface); }
.language a:not([aria-current]):hover { background: #efe0d2; }
.actions { display: flex; gap: .7rem; flex-wrap: wrap; align-items: center; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: .75rem 1.15rem;
  min-height: 45px;
  text-align: center;
  font-weight: 700;
  line-height: 1.2;
  font-size: .91rem;
  text-decoration: none;
}
.button:focus-visible { outline-offset: 3px; }
.primary { background: var(--accent); color: var(--ink); }
.primary:hover { background: var(--accent-strong); }
.outline { border-color: #a68d99; background: transparent; }
.outline:hover { background: #f0e0d4; }
.mast-link { min-height: 40px; background: var(--plum); color: #fff7ee; font-size: .84rem; padding: .61rem .86rem; white-space: nowrap; }
.mast-link:hover { background: #59394e; }
.light { color: var(--plum); background: #fff3e4; }
.light:hover { background: #f1d8c6; }

.hero {
  display: grid;
  grid-template-columns: .93fr 1.07fr;
  min-height: clamp(385px, 43vw, 500px);
  margin-top: 29px;
  background: var(--plum);
  border-radius: 16px;
  overflow: hidden;
}
.hero-copy { padding: clamp(2rem, 4.15vw, 3.65rem); align-self: center; min-width: 0; }
.hero h1 {
  color: var(--surface);
  font-family: var(--font-display);
  font-weight: 400;
  line-height: .99;
  font-size: clamp(2.6rem, 5.45vw, 5.2rem);
  letter-spacing: -.065em;
  max-width: 11ch;
}
.hero h1 span {
  display: block;
  font: 700 .95rem/1.4 system-ui, sans-serif;
  color: #ffb7a8;
  margin-bottom: 1.15rem;
  letter-spacing: .025em;
}
.hero p { color: #fbede4; max-width: 45ch; margin-top: 1.5rem; font-size: 1rem; }
.hero .actions { margin-top: 1.55rem; }
.hero .outline { color: var(--surface); border-color: #a78b9e; }
.hero .outline:hover { background: #523449; }
.hero .button:focus-visible, .planner-panel .button:focus-visible { outline-color: #ffb7a8; }
.hero-image { min-width: 0; position: relative; }
.hero-image img { position: absolute; width: 100%; height: 100%; object-fit: cover; object-position: 54% 51%; }
html[lang="de"] .hero h1 { max-width: 14ch; font-size: clamp(2.5rem, 4.9vw, 4.8rem); }

.section { margin-top: clamp(42px, 6vw, 86px); margin-bottom: clamp(34px, 5.2vw, 72px); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem 1.5rem; margin-bottom: 1.45rem; }
h2 {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3.5vw, 3.05rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -.045em;
}
.section-heading p, .guides-home p { max-width: 65ch; margin-top: .55rem; }
.category-menu { position: relative; min-width: min(245px, 100%); }
.category-menu summary, .guide-controls select {
  position: relative;
  display: block;
  cursor: pointer;
  list-style: none;
  background: var(--surface);
  border: 1px solid #a98b9a;
  border-radius: 8px;
  padding: .6rem 2.5rem .6rem .85rem;
  line-height: 1.5;
  min-height: 44px;
  font-size: .93rem;
  color: var(--ink);
  font-weight: 650;
}
.category-menu summary::-webkit-details-marker { display: none; }
.category-menu summary::after {
  content: '';
  position: absolute;
  top: 46%;
  right: 1rem;
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  rotate: 45deg;
}
.category-menu[open] summary::after { rotate: 225deg; }
.category-menu ul {
  margin: .35rem 0 0;
  list-style: none;
  padding: .4rem;
  position: absolute;
  right: 0;
  z-index: 3;
  width: 100%;
  max-height: 305px;
  overflow: auto;
  background: var(--surface);
  border: 1px solid #a98b9a;
  border-radius: 8px;
  box-shadow: 0 8px 22px #39233424;
}
.category-menu a { display: block; border-radius: 4px; padding: .44rem .65rem; text-decoration: none; }
.category-menu a:hover, .category-menu a:focus-visible { background: #f0e0d4; }

.category-grid { display: grid; grid-template-columns: repeat(7,minmax(0,1fr)); gap: .7rem; }
.category-cell { min-width: 0; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); }
.category-button {
  overflow-wrap: anywhere;
  display: flex;
  align-items: center;
  flex: 1;
  padding: .7rem .72rem .4rem;
  min-height: 43px;
  text-decoration: none;
  font-size: .89rem;
  font-weight: 740;
  line-height: 1.25;
}
.category-button:hover { text-decoration: underline; text-underline-offset: .2em; color: #733451; }
.category-note { align-self: start; font-size: .78rem; color: #6c4b60; padding: .34rem .72rem .58rem; text-underline-offset: .12em; }

.planner-panel {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  align-items: center;
  gap: 1.5rem 3.4rem;
  padding: clamp(1.25rem, 4.1vw, 3rem);
  border-radius: 13px;
  color: #fff5ed;
  background: var(--plum);
}
.planner-panel h2, .planner-panel p { color: inherit; }
.planner-panel p { margin: .7rem 0 1.1rem; max-width: 36ch; }
.sample { background: #4c3246; padding: .65rem .72rem; border: 1px solid #77566e; border-radius: 9px; min-width: 0; }
.sample table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.sample th, .sample td { padding: .56rem .42rem; text-align: right; }
.sample th:first-child { text-align: left; }
.sample thead { color: #ffd0bf; }
.sample thead th, .sample tbody th { font-weight: 630; }
.sample tbody tr { border-top: 1px solid #816277; }
.sample tbody td { white-space: nowrap; font-variant-numeric: tabular-nums; }

.article-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1rem; }
.article-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  overflow: hidden;
}
.article-cover { display: block; overflow: hidden; }
.article-cover img { width: 100%; aspect-ratio: 16/10; object-fit: cover; }
.article-card:hover img { opacity: .92; }
.article-copy { padding: 1rem 1rem 1.25rem; }
.category-label { display: inline-block; margin-bottom: .42rem; color: #753d58; font-size: .82rem; font-weight: 700; text-underline-offset: .2rem; }
.article-copy h3 {
  font: 400 clamp(1.24rem, 2.05vw, 1.8rem)/1.14 var(--font-display);
  letter-spacing: -.026em;
}
.article-copy h3 a { text-decoration: none; }
.article-copy h3 a:hover { text-decoration: underline; text-underline-offset: .14em; }
.article-copy p { margin-top: .62rem; font-size: .94rem; }
.guides-home {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem 2rem;
  background: #f2e1d2;
  border-radius: 12px;
  padding: clamp(1.2rem, 3vw, 2.25rem);
}

.page-lead { padding-top: clamp(2.3rem, 5.4vw, 5.1rem); }
.page-lead h1, .story h1, .category-hero h1 {
  font: 400 clamp(2.55rem, 5.5vw, 5.25rem)/1.025 var(--font-display);
  letter-spacing: -.061em;
  max-width: 22ch;
  overflow-wrap: break-word;
  hyphens: auto;
}
.page-lead p, .standfirst { margin-top: 1rem; font-size: clamp(1rem, 2vw, 1.17rem); max-width: 63ch; }
.page-lead + .section { margin-top: 2rem; }
.about-copy, .worksheet-wrap { margin-top: 1.6rem; margin-bottom: 3.7rem; }

.breadcrumb { margin-top: 1.3rem; margin-bottom: 1.3rem; font-size: .88rem; color: #62495a; }
.breadcrumb ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .2rem .6rem; }
.breadcrumb li:not(:last-child)::after { content: '/'; margin-left: .6rem; color: #8e7184; }
.breadcrumb a { text-underline-offset: .19em; }
.category-hero, .with-image { display: grid; grid-template-columns: minmax(0,1.35fr) minmax(220px,.65fr); gap: clamp(1.65rem, 5vw, 4.7rem); align-items: center; }
.category-hero { border: 1px solid var(--line); border-radius: 13px; overflow: hidden; background: var(--surface); }
.category-hero-text { padding: clamp(1.2rem, 4.5vw, 3.5rem); }
.category-hero h2 { margin-top: 1rem; font-size: clamp(1.45rem, 2.6vw, 2.1rem); }
.category-hero p { margin: .6rem 0 1.15rem; max-width: 52ch; }
.category-hero img, .story-image { width: 100%; aspect-ratio: 1; object-fit: cover; }
.category-articles { margin-top: 1.45rem; }
.story-heading { padding: clamp(.95rem, 2.5vw, 2rem) 0; }
.story-image { border-radius: 11px; }
.byline { font-size: .9rem; margin-top: 1rem; }
.byline time { display: block; }
.prose { max-width: 66ch; }
.story .prose { margin-top: clamp(1rem, 3vw, 2.4rem); }
.prose section + section { margin-top: 1.9rem; }
.prose h2 { font-size: clamp(1.5rem, 2.6vw, 2.32rem); margin-bottom: .55rem; }
.prose p + p { margin-top: .7rem; }
.story-actions { margin-top: 1.6rem; }
.story-related { margin-top: 2.7rem; }
.guide-controls { display: grid; grid-template-columns: minmax(0,2fr) minmax(0,1fr); gap: .85rem; max-width: 700px; margin-bottom: 1.35rem; }
.guide-controls label { display: block; margin-bottom: .3rem; font-weight: 700; }
.guide-controls input, .guide-controls select {
  width: 100%;
  background-color: var(--surface);
  padding: .59rem .69rem;
  border: 1px solid #a98b9a;
  border-radius: 7px;
  min-height: 45px;
}
.guide-controls select {
  appearance: none;
  padding: .56rem 2rem .56rem .69rem;
  background-image: linear-gradient(45deg,transparent 50%,var(--ink) 50%),linear-gradient(135deg,var(--ink) 50%,transparent 50%);
  background-position: calc(100% - 17px) 50%,calc(100% - 12px) 50%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
}
.guide-list { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .74rem; margin: 1rem 0 0; padding: 0; list-style: none; }
.guide-list li { min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: .9rem 1rem; }
.guide-list a { font-weight: 720; text-underline-offset: .17em; }
.guide-list a:hover { color: #813958; }
.guide-list p { margin-top: .4rem; font-size: .92rem; }
.no-results { padding: .8rem 0; }

.site-footer { border-top: 1px solid var(--line); margin-top: 3rem; }
.footer-inner { min-height: 143px; padding-block: 2rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem 2rem; }
.footer-inner p { margin-top: .65rem; font-size: .91rem; }
.footer-inner nav { display: flex; flex-wrap: wrap; gap: .47rem 1.1rem; font-size: .9rem; font-weight: 650; }
.footer-inner nav a { text-underline-offset: .2rem; }

@media (max-width: 1080px) {
  .shell { width: min(1200px, calc(100% - 52px)); }
  .category-grid { grid-template-columns: repeat(4,minmax(0,1fr)); }
  .article-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .main-nav { gap: 1.05rem; }
}

@media (max-width: 800px) {
  .masthead { display: grid; grid-template-columns: 1fr auto; gap: 0 .9rem; padding-top: .65rem; }
  .main-nav { grid-row: 2; grid-column: 1 / -1; gap: .25rem 1.35rem; flex-wrap: wrap; padding-block: .52rem; }
  .main-nav a { padding-block: .25rem; }
  .hero { min-height: 0; grid-template-columns: 1fr; margin-top: 18px; }
  .hero-copy { padding: clamp(1.55rem, 5.5vw, 2.8rem); }
  .hero h1, html[lang="de"] .hero h1 { max-width: 16ch; font-size: clamp(2.75rem, 9vw, 4.67rem); }
  .hero-image { aspect-ratio: 2.04; }
  .hero-image img { object-position: center 53%; }
  .planner-panel { grid-template-columns: 1fr; }
  .planner-panel p { max-width: 53ch; }
  .guide-list { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 560px) {
  .shell { width: calc(100% - 28px); }
  .masthead { gap: .2rem .65rem; }
  .site-actions { gap: .45rem; }
  .mast-link { font-size: .73rem; min-height: 36px; padding: .45rem .56rem; white-space: normal; }
  .brand { gap: .44rem; font-size: .91rem; }
  .brand-mark { width: 29px; height: 29px; }
  .language a { min-width: 30px; min-height: 32px; }
  .section-heading, .guides-home, .footer-inner { align-items: start; flex-direction: column; }
  .article-grid, .category-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: .58rem; }
  .article-copy { padding: .7rem .67rem .8rem; }
  .article-copy p { font-size: .89rem; }
  .article-copy h3 { font-size: clamp(1.03rem, 5.1vw, 1.4rem); overflow-wrap: break-word; hyphens: auto; }
  .hero h1 span { margin-bottom: .8rem; }
  .hero p, .hero .actions { margin-top: 1rem; }
  .hero .button { padding: .55rem .67rem; }
  .sample { padding: .35rem .4rem; }
  .sample table { font-size: .8rem; }
  .sample th, .sample td { padding: .48rem .2rem; }
  .category-menu { width: 100%; }
  .category-hero, .with-image, .guide-list { grid-template-columns: 1fr; }
  .category-hero { gap: 0; }
  .category-hero img, .story-image { aspect-ratio: 1.55; }
}

@media (max-width: 355px) {
  .main-nav { gap: .25rem .85rem; }
  .site-actions .mast-link { display: none; }
  .hero h1, html[lang="de"] .hero h1 { font-size: 2.35rem; }
  .guide-controls { grid-template-columns: 1fr; }
}
