/* =====================================================================
   Marians kleine Medienbude
   Look der ersten Version: Papier, alles in Marians Handschrift,
   Klebezettel, gezeichnete Rahmen – Lila als Akzentfarbe (wie das Logo).
   Schalter im Backend (Site-Einstellungen → Design → „Lesetexte auch in
   Handschrift“) setzt .page--hand – ist ab Werk an. Aus: Lesetexte in
   Space Grotesk.
   ===================================================================== */

@font-face {
    font-family: "Marian Hand";
    src: url("../Fonts/MarianHand-Regular.woff2") format("woff2"),
         url("../Fonts/MarianHand-Regular.woff") format("woff");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
/* Space Grotesk (SIL Open Font License, siehe Fonts/SpaceGrotesk-OFL.txt) – nur, wenn der Handschrift-Schalter aus ist */
@font-face {
    font-family: "Space Grotesk";
    src: url("../Fonts/SpaceGrotesk-latin-ext.woff2") format("woff2");
    font-weight: 300 700;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: "Space Grotesk";
    src: url("../Fonts/SpaceGrotesk-latin.woff2") format("woff2");
    font-weight: 300 700;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
    /* Papier + Tinte wie in der ersten Version */
    --paper: #f6f1e4;
    --paper-2: #eee6d2;
    --card: #fffdf6;
    --ink: #1f2a52;
    --ink-2: #45507a;
    --muted: #5c6385;
    --line: rgba(31, 42, 82, .22);
    --line-strong: rgba(31, 42, 82, .55);

    /* Lila: Akzentfarbe der Medienbude */
    --purple: #9b7fe8;
    --purple-d: #7c5fd4;
    --purple-dd: #6548c4;
    --purple-ink: #5a3dc0;
    --marker: rgba(155, 127, 232, .32);
    --marker-soft: rgba(155, 127, 232, .14);
    --note: #efe8ff;
    --note-2: #e4d9ff;
    --tape: rgba(155, 127, 232, .45);
    --sticker: #c4b3f3;

    --red: #b83a28;
    --red-tint: rgba(184, 58, 40, .08);
    --green: #2f6b3a;
    --green-tint: rgba(47, 107, 58, .1);

    --wobble: 255px 15px 225px 15px / 15px 225px 15px 255px;
    --wobble-2: 15px 255px 15px 225px / 225px 15px 255px 15px;
    --shadow: 0 14px 22px -16px rgba(31, 42, 82, .55);
    --shadow-lift: 0 20px 28px -18px rgba(31, 42, 82, .6);
    --border: 2.5px solid var(--ink);

    --hand: "Marian Hand", "Segoe Print", "Bradley Hand", cursive;
    --sans: "Space Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --font-body: var(--sans);
    --fs-body: clamp(1rem, .96rem + .22vw, 1.1rem);
    --fs-small: .92rem;
    --lh-body: 1.65;

    /* Höhe des Kopf-Streifens (Logo, Haus und Menü teilen sich diese Höhe = gleiche Grundlinie wie auf der Skizze) */
    --band-h: clamp(52px, 7vw, 74px);
    --gutter: clamp(16px, 4vw, 40px);
    --container: 1240px;
    --text-max: 46rem;
}

/* alles in Handschrift (Standard) */
.page--hand {
    --font-body: var(--hand);
    --fs-body: clamp(1.18rem, 1.02rem + .55vw, 1.42rem);
    --fs-small: clamp(1.02rem, .96rem + .25vw, 1.14rem);
    --lh-body: 1.55;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 110px; }

body {
    margin: 0;
    background: var(--paper) url("../Images/paper.png");
    color: var(--ink);
    font-family: var(--font-body);
    font-size: var(--fs-body);
    line-height: var(--lh-body);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; height: auto; }

::selection { background: var(--marker); color: var(--ink); }

.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    margin: -1px; padding: 0; border: 0;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

.skip-link {
    position: absolute; left: 12px; top: -80px; z-index: 60;
    padding: .35em 1em; background: var(--ink); color: var(--paper);
    font-family: var(--hand); font-size: 1.2rem;
    border-radius: var(--wobble); text-decoration: none;
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 3px dashed var(--purple-d); outline-offset: 4px; }

.page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: clip;
    font-family: var(--font-body);
    font-size: var(--fs-body);
    line-height: var(--lh-body);
}

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

/* --------------------------------------------------------------------- Kopf
   Logo, Haus und Menüpunkte sind Originalzeichnungen aus der Skizze (bzw. aus
   Marians Schrift gesetzt). Alle teilen sich dieselbe Höhe (--band-h) – dadurch
   stehen sie auf derselben Grundlinie wie auf dem Papier. */

.site-header { position: relative; z-index: 40; padding-top: clamp(8px, 1.6vw, 18px); }

.site-header__inner {
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0 calc(var(--band-h) * .3);
    padding-bottom: 12px;
}
/* Bleistiftstrich unter dem Kopf */
.site-header__inner::after {
    content: "";
    position: absolute;
    left: var(--gutter);
    right: var(--gutter);
    bottom: 0;
    height: 8px;
    background: var(--ink);
    opacity: .32;
    -webkit-mask: url("../Images/scribble-line.svg") no-repeat center / 100% 100%;
    mask: url("../Images/scribble-line.svg") no-repeat center / 100% 100%;
    pointer-events: none;
}

.brand {
    display: block;
    color: var(--ink);
    line-height: 0;
    transition: transform .25s ease;
}
.brand:hover { transform: rotate(-1deg); background: none; }
.brand .logo-svg { height: var(--band-h); width: auto; display: block; }
.logo-svg__accent { fill: var(--purple); }

.main-nav__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0 calc(var(--band-h) * .2);
}

.main-nav__item { position: relative; margin: 0; }
.main-nav__item::before { display: none; }

.main-nav__link {
    display: block;
    position: relative;
    color: var(--ink);
    text-decoration: none;
    line-height: 0;
    transition: transform .2s ease, color .2s ease;
}
.main-nav__link:hover { transform: rotate(-3deg) translateY(-2px); color: var(--purple-d); background: none; }
.main-nav__item.is-active > .main-nav__link { color: var(--ink); }

.nav-svg { display: block; height: var(--band-h); width: auto; }

.hand-svg {
    display: block;
    height: var(--band-h);
    aspect-ratio: var(--ratio, 2);
    background-color: currentColor;
    -webkit-mask: var(--src) center / contain no-repeat;
    mask: var(--src) center / contain no-repeat;
}

.hand-text {
    display: block;
    height: var(--band-h);
    padding-top: calc(var(--band-h) * .3);
    line-height: 1;
    font-family: var(--hand);
    font-size: calc(var(--band-h) * .36);
    white-space: nowrap;
}

/* aktive Seite: lila Kringel-Unterstrich */
.main-nav__item.is-active > .main-nav__link::after,
.main-nav__link[aria-current="page"]::after {
    content: "";
    position: absolute;
    left: 4%; right: 0;
    top: calc(var(--band-h) * .66);
    height: calc(var(--band-h) * .085);
    background: var(--purple-d);
    -webkit-mask: url("../Images/scribble-underline.svg") no-repeat center / 100% 100%;
    mask: url("../Images/scribble-underline.svg") no-repeat center / 100% 100%;
}
.main-nav__item--home.is-active > .main-nav__link::after { left: -10%; right: -10%; }

/* Knopf "Anfragen" (Originalstrich von der Karte) + Warenkorb: mittig auf der Schreibzeile der Menüwörter */
.main-nav__item--cta,
.main-nav__item--cart {
    align-self: flex-start;
    margin-top: calc(var(--band-h) * .18);
}
.main-nav__item--cta { margin-top: calc(var(--band-h) * .16); }
.nav-cta.btn {
    height: calc(var(--band-h) * .66);
    padding: 0 .8em;
    font-size: calc(var(--band-h) * .32);
    transform: rotate(-2deg);
}
.nav-cta.btn:hover { transform: rotate(0) scale(1.04); }
.nav-cta .hand-btn { display: block; height: calc(var(--band-h) * .66 - 9px); width: auto; }

.cart-preview { line-height: 0; }
.mini-cart {
    position: relative;
    display: grid;
    place-items: center;
    height: calc(var(--band-h) * .62);
    aspect-ratio: 1;
    color: var(--ink);
    text-decoration: none;
    transition: transform .2s ease, color .2s ease;
}
.mini-cart:hover { transform: rotate(-6deg); color: var(--purple-d); background: none; }
.mini-cart__icon { height: 100%; width: auto; display: block; }
.mini-cart__count {
    position: absolute;
    top: -6px;
    right: -12px;
    min-width: 1.6em;
    height: 1.6em;
    padding: 0 .3em;
    border-radius: 50% 45% 52% 48%;
    background: var(--purple-d);
    color: #fffdf6;
    font-family: var(--hand);
    font-size: 17px;
    line-height: 1.7em;
    text-align: center;
    transform: rotate(6deg);
}
.cart-preview:not(.has-items) .mini-cart__count { display: none; }
.cart-preview.is-bumped .mini-cart { animation: wiggle .6s ease; }

@keyframes wiggle {
    0%, 100% { transform: rotate(0); }
    25% { transform: rotate(-8deg) scale(1.08); }
    60% { transform: rotate(6deg) scale(1.04); }
}

/* --------------------------------------------------------------------- Leiste über dem Kopf
   Sprachumschalter DE/EN und Barrierefreiheit (Schrift, Kontrast, Links, Animationen). */

.utility-bar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 6px 18px;
    margin-bottom: clamp(4px, 1vw, 10px);
    font-family: var(--sans);
    font-size: .9rem;
    line-height: 1.2;
}
.lang-switch ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; }
.lang-switch li { margin: 0; }
.lang-switch li::before { display: none; }
.lang-switch__item {
    display: block;
    min-width: 2.6em;
    padding: .3em .55em;
    border-radius: var(--wobble);
    color: var(--ink);
    font-weight: 600;
    letter-spacing: .04em;
    text-align: center;
    text-decoration: none;
}
a.lang-switch__item:hover { background: var(--marker); }
.lang-switch__item.is-current { background: var(--ink); color: var(--paper); }
.lang-switch__item.is-unavailable { color: var(--muted); opacity: .6; }

.a11y { position: relative; }
.a11y button {
    font-family: var(--sans);
    font-size: .9rem;
    line-height: 1.2;
    transform: none;
}
.a11y__toggle {
    display: inline-flex;
    align-items: center;
    gap: .45em;
    padding: .3em .75em;
    background: transparent;
    color: var(--ink);
    border: 2px solid var(--ink);
    border-radius: var(--wobble);
    box-shadow: none;
    cursor: pointer;
}
.a11y__toggle:hover, .a11y__toggle[aria-expanded="true"] { background: var(--note); color: var(--ink); transform: none; }
.a11y__icon { width: 1.25em; height: 1.25em; flex: none; }
.a11y__panel {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    z-index: 70;
    width: min(19rem, calc(100vw - 2 * var(--gutter)));
    display: grid;
    gap: 6px;
    padding: 14px;
    background: var(--card);
    border: var(--border);
    border-radius: 6px;
    box-shadow: var(--shadow-lift);
}
.a11y__panel[hidden] { display: none; }
.a11y__panel button {
    width: 100%;
    margin: 0;
    padding: .55em .8em;
    background: var(--paper);
    color: var(--ink);
    border: 2px solid var(--line-strong);
    border-radius: 6px;
    box-shadow: none;
    text-align: left;
    font-weight: 500;
    cursor: pointer;
}
.a11y__panel button:hover { background: var(--note); color: var(--ink); transform: none; }
.a11y__panel button[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.a11y__panel button[aria-pressed="true"]::before { content: "✓ "; }
.a11y__size, .a11y__foot { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.a11y__size button { text-align: center; font-size: 1.05rem; font-weight: 700; }
.a11y__panel .a11y__reset { text-align: center; background: transparent; }
.a11y__hint { margin: 2px 0 0; font-size: .8rem; color: var(--muted); }

/* englischer Knopf "Get in touch" in Marians Schrift statt Originalstrich */
.nav-cta .hand-btn-text { display: block; font-family: var(--hand); line-height: 1; white-space: nowrap; }

/* Schrift größer/kleiner: skaliert alle rem-Größen */
html.a11y-size--1 { font-size: 90%; }
html.a11y-size-1 { font-size: 112.5%; }
html.a11y-size-2 { font-size: 125%; }
html.a11y-size-3 { font-size: 140%; }
html.a11y-size-4 { font-size: 160%; }

/* klare Schrift statt Handschrift (Originalstriche als Bild bleiben) */
html.a11y-plain {
    --hand: var(--sans);
}
html.a11y-plain .page,
html.a11y-plain .page--hand {
    --font-body: var(--sans);
    --fs-body: clamp(1rem, .96rem + .22vw, 1.1rem);
    --fs-small: .92rem;
    --lh-body: 1.65;
}

/* hoher Kontrast: weißes Papier, schwarze Tinte, dunkles Lila */
html.a11y-contrast {
    --paper: #ffffff;
    --paper-2: #f2f2f2;
    --card: #ffffff;
    --ink: #000000;
    --ink-2: #000000;
    --muted: #1a1a1a;
    --line: rgba(0, 0, 0, .6);
    --line-strong: #000000;
    --purple: #5a3dc0;
    --purple-d: #3f1fa6;
    --purple-dd: #2e1480;
    --purple-ink: #2e1480;
    --marker: rgba(90, 61, 192, .35);
    --note: #ece4ff;
    --note-2: #ddd0ff;
}
html.a11y-contrast body,
html.a11y-contrast .site-header { background-image: none !important; background-color: var(--paper); }

/* Links hervorheben */
html.a11y-links .page a:not(.btn):not(.brand):not(.main-nav__link):not(.site-footer__logo) {
    text-decoration: underline !important;
    text-decoration-thickness: 2px !important;
    text-underline-offset: 3px;
    background: #fff3a8 !important;
    color: #000 !important;
}
html.a11y-links .page a.btn, html.a11y-links .main-nav__link, html.a11y-links .stage .frame-type-text p:last-child > a {
    outline: 3px solid #000;
    outline-offset: 3px;
}

/* Animationen aus */
html.a11y-motion *, html.a11y-motion *::before, html.a11y-motion *::after {
    transition: none !important;
    animation: none !important;
    scroll-behavior: auto !important;
}
html.a11y-motion .page [style*="rotate"], html.a11y-motion .page .btn, html.a11y-motion .frame-note, html.a11y-motion .frame-cta { transform: none !important; }

@media (max-width: 480px) {
    .a11y__toggle span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
    .a11y__toggle { padding: .35em .5em; }
}

/* --------------------------------------------------------------------- Grundtypo */

.site-main { flex: 1; padding: clamp(28px, 5vw, 64px) 0 clamp(56px, 8vw, 110px); outline: none; }

h1, h2, h3, h4, .h1 {
    font-family: var(--hand);
    font-weight: 400;
    line-height: 1.12;
    margin: 0 0 .45em;
    letter-spacing: .01em;
    color: var(--ink);
}
h1 { font-size: clamp(2.6rem, 1.7rem + 3.4vw, 4.1rem); }
h2 { font-size: clamp(2rem, 1.5rem + 1.9vw, 2.8rem); }
h3 { font-size: clamp(1.55rem, 1.3rem + .9vw, 1.95rem); }
h4 { font-size: 1.4rem; }

h1 { width: fit-content; max-width: 100%; }
h1::after {
    content: "";
    display: block;
    width: 100%;
    max-width: 9em;
    height: 12px;
    margin-top: .1em;
    background: var(--purple-d);
    -webkit-mask: url("../Images/scribble-underline.svg") no-repeat left center / 100% 100%;
    mask: url("../Images/scribble-underline.svg") no-repeat left center / 100% 100%;
}

/* --------------------------------------------------------------------- Handschrift-Zeilen
   Überschriften, die genau wie eine Zeile von Marians Karteikarte lauten („Moin! Schön, dass du da bist!“,
   „Webseiten mit Handschrift“, „Was ich mache“, „Projekte“, „Über mich“ …), erscheinen als Originalstrich
   (Classes/EventListener/HandwritingHeaders.php). Ein SVG je Wort – bricht um wie Text.
   --hand-xh = x-Höhe der Zeichnung, --hand-w/-h/-d kommen aus den Maßen der Zeile. */
/* Wortabstand wie auf der Karte (~1,5 x-Höhen); .29em = Leerzeichen der Schrift */
.hand { --hand-xh: .4em; word-spacing: calc(var(--hand-xh) * 1.27 - .29em); }
.hand__svg {
    display: inline-block;
    width: calc(var(--hand-w) * var(--hand-xh));
    max-width: 100%;
    height: auto;
    aspect-ratio: var(--hand-w) / var(--hand-h);
    vertical-align: calc(var(--hand-d) * var(--hand-xh) * -1);
    overflow: visible;
}
h1 .hand { --hand-xh: .36em; }

.frame header { margin-bottom: .7em; }
.frame header > h1 + h2, .frame header > h2 + h3, .frame header > h3 + h4 {
    font-family: var(--font-body);
    font-size: clamp(1.2rem, 1.1rem + .4vw, 1.45rem);
    line-height: 1.4;
    color: var(--ink-2);
    margin-top: -.15em;
    letter-spacing: 0;
}

p { margin: 0 0 1em; }

a {
    color: var(--purple-ink);
    text-decoration-line: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: .22em;
    text-decoration-color: rgba(90, 61, 192, .4);
    transition: background-color .2s, text-decoration-color .2s, color .2s;
}
a:hover { text-decoration-color: currentColor; background-color: var(--marker); }

/* Textmarker */
strong, b {
    font-weight: 600;
    color: var(--ink);
    background: linear-gradient(transparent 55%, var(--marker) 55%, var(--marker) 90%, transparent 90%);
    padding: 0 .1em;
}
.page--hand strong, .page--hand b { font-weight: 400; }

em, i { font-style: italic; }

ul, ol { padding-left: 1.3em; margin: 0 0 1em; }
li { margin-bottom: .3em; }
/* gezeichnete Häkchen */
.frame ul { list-style: none; padding-left: 1.7em; }
.frame ul > li { position: relative; }
.frame ul > li::before {
    content: "";
    position: absolute;
    left: -1.6em;
    top: .32em;
    width: 1em;
    height: .85em;
    background: var(--purple-d);
    -webkit-mask: url("../Images/scribble-check.svg") no-repeat center / contain;
    mask: url("../Images/scribble-check.svg") no-repeat center / contain;
}

hr {
    border: 0;
    height: 8px;
    margin: 2.5em 0;
    background: var(--ink);
    opacity: .3;
    -webkit-mask: url("../Images/scribble-line.svg") no-repeat center / 100% 100%;
    mask: url("../Images/scribble-line.svg") no-repeat center / 100% 100%;
}

blockquote {
    margin: 1.5em 0;
    padding: .3em 1.2em;
    border-left: 3px solid var(--purple-d);
    font-family: var(--hand);
    font-size: 1.3em;
    line-height: 1.4;
}

table { width: 100%; border-collapse: collapse; margin: 0 0 1.4em; font-size: var(--fs-small); }
th, td { text-align: left; padding: .45em .55em; border-bottom: 2px dashed var(--line); vertical-align: top; }
th { font-weight: 400; color: var(--ink-2); }

.placeholder-hint {
    background: #ffe1d6;
    border-radius: var(--wobble);
    padding: .6em 1em;
    color: var(--red);
}
.placeholder-hint strong { color: var(--red); background: none; }

/* lila Notiz (z. B. Etiketten) */
.pill {
    display: inline-block;
    font-family: var(--hand);
    font-size: 1.25rem;
    line-height: 1.2;
    color: var(--purple-ink);
    background: linear-gradient(transparent 50%, var(--marker) 50%, var(--marker) 92%, transparent 92%);
    padding: 0 .15em;
    transform: rotate(-2deg);
}

/* --------------------------------------------------------------------- Inhaltsraster
   Inhaltselemente liegen in einem 12er-Raster. Rahmen "Karte", "Schritt" usw.
   legen fest, wie breit ein Element ist. */

.content-area,
.start {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: clamp(20px, 2.8vw, 36px);
    align-items: start;
}
.content-area > *,
.start > * { grid-column: 1 / -1; min-width: 0; }
.content-area > .frame-type-shortcut { display: contents; }
.content-area .frame { grid-column: 1 / -1; min-width: 0; }

.frame { margin-bottom: clamp(26px, 3.6vw, 46px); }
.frame-type-header { margin-bottom: clamp(14px, 2vw, 26px); }
.frame > h3:not(:first-child), .frame .ce-bodytext > h3:not(:first-child) { margin-top: 1.1em; margin-bottom: .3em; }

/* Lesebreite für reine Texte */
.content-area .frame-type-text:not([class*="frame-card"]):not(.frame-step):not(.frame-cta):not(.frame-trust):not(.frame-note) > :not(header),
.content-area .frame-type-header > header > :not(h1):not(h2),
.content-area .frame-type-textmedia:not([class*="frame-card"]) .ce-bodytext {
    max-width: var(--text-max);
}

.content-area .frame-card,
.content-area .frame-card-accent { grid-column: span 4; }
.content-area .frame-card-half { grid-column: span 6; }
.content-area .frame-card-wide { grid-column: 1 / -1; }
.content-area .frame-step { grid-column: span 3; }

@media (max-width: 1020px) {
    .content-area .frame-card,
    .content-area .frame-card-accent,
    .content-area .frame-step { grid-column: span 6; }
}
@media (max-width: 640px) {
    .content-area .frame-card,
    .content-area .frame-card-accent,
    .content-area .frame-card-half,
    .content-area .frame-step { grid-column: 1 / -1; }
}

/* Abschnitt: Untertitel wird zur lila Notiz über der Überschrift */
.frame-section { margin-top: clamp(18px, 3.4vw, 46px); margin-bottom: clamp(18px, 2.4vw, 28px); counter-reset: step; }
.frame-section > header { display: flex; flex-direction: column; margin-bottom: .4em; }
.frame-section > header > h1 + h2,
.frame-section > header > h2 + h3,
.frame-section > header > h3 + h4 {
    order: -1;
    align-self: flex-start;
    margin: 0 0 .35em;
    font-family: var(--hand);
    font-size: clamp(1.25rem, 1.15rem + .4vw, 1.5rem);
    line-height: 1.2;
    color: var(--purple-ink);
    background: linear-gradient(transparent 50%, var(--marker) 50%, var(--marker) 92%, transparent 92%);
    padding: 0 .2em;
    transform: rotate(-2deg);
    transform-origin: left center;
}
.frame-section .ce-bodytext, .frame-section > p, .frame-section .ce-bodytext p { color: var(--ink-2); }
.frame-section p:last-child { margin-bottom: 0; }

/* --------------------------------------------------------------------- Karten (Pakete, Projekte, Schritte)
   Gezeichneter Rahmen, leicht schief – wie Zettel auf dem Tisch. */

.frame-card, .frame-card-accent, .frame-card-half, .frame-card-wide, .frame-step,
.product-card, .news-list-view .article, .buy-box,
.frame-type-felogin_login fieldset, .card-box {
    position: relative;
    background: var(--card);
    border: var(--border);
    border-radius: var(--wobble);
    box-shadow: var(--shadow);
}

.frame-card, .frame-card-accent, .frame-card-half, .frame-card-wide, .frame-step,
.product-card, .news-list-view .article {
    transition: transform .25s ease, box-shadow .25s ease;
}
.content-area .frame-card:nth-child(3n+1), .content-area .frame-step:nth-child(odd),
.content-area .frame-card-half:nth-child(odd) { transform: rotate(-.7deg); }
.content-area .frame-card:nth-child(3n+2), .content-area .frame-step:nth-child(even),
.content-area .frame-card-half:nth-child(even) { transform: rotate(.6deg); border-radius: var(--wobble-2); }
.content-area .frame-card:nth-child(3n) { transform: rotate(-.3deg); }
.frame-card:hover, .frame-card-accent:hover, .frame-card-half:hover, .frame-card-wide:hover,
.product-card:hover, .news-list-view .article:hover,
.content-area .frame-card:hover, .content-area .frame-card-half:hover {
    transform: rotate(0) translateY(-4px);
    box-shadow: var(--shadow-lift);
}

.frame-card, .frame-card-accent, .frame-step { padding: clamp(22px, 2.6vw, 32px) clamp(20px, 2.4vw, 30px) clamp(18px, 2.2vw, 26px); }
.content-area .frame-card, .content-area .frame-card-accent, .content-area .frame-card-half, .content-area .frame-step {
    align-self: stretch;
    display: flex;
    flex-direction: column;
}
.frame-card > p:last-child, .frame-card-accent > p:last-child,
.frame-card-half > p:last-child, .frame-card-half .ce-bodytext > p:last-child { margin-top: auto; }
.frame-card-half.frame-type-textmedia .ce-bodytext { flex: 1; display: flex; flex-direction: column; }
.frame-card > header > h3, .frame-card-accent > header > h3,
.frame-card > header > h2, .frame-card-accent > header > h2 { font-size: clamp(1.8rem, 1.5rem + .9vw, 2.2rem); margin-bottom: .05em; }
.frame-card > header > h2::after, .frame-card-accent > header > h2::after { display: none; }

/* Preis im Untertitel einer Karte */
.frame-card > header > h2 + h3, .frame-card > header > h3 + h4,
.frame-card-accent > header > h2 + h3, .frame-card-accent > header > h3 + h4 {
    font-family: var(--hand);
    font-size: clamp(1.7rem, 1.45rem + .8vw, 2.1rem);
    color: var(--purple-ink);
    margin: .15em 0 0;
    line-height: 1.1;
}
.frame-card ul, .frame-card-accent ul { margin-bottom: .9em; }
.frame-card li, .frame-card-accent li { margin-bottom: .3em; }
.frame-card p:last-child, .frame-card-accent p:last-child { margin-bottom: 0; }
.frame-card p:last-child:not(:has(a)), .frame-card-accent p:last-child:not(:has(a)) { color: var(--muted); font-size: var(--fs-small); }

/* Empfehlung: lila Rahmen + lila Klebestreifen */
.content-area .frame-card-accent { border-color: var(--purple-d); transform: rotate(.4deg); }
.frame-card-accent::before {
    content: "Meine Empfehlung";
    position: absolute;
    top: -17px;
    right: 18px;
    font-family: var(--hand);
    font-size: 1.15rem;
    line-height: 1.2;
    color: var(--ink);
    background: var(--sticker);
    padding: .2em .8em .15em;
    transform: rotate(3deg);
    box-shadow: 0 2px 3px rgba(31, 42, 82, .12);
}

/* Links unten in Karten: Text-Link mit Pfeil */
.frame-card p:last-child > a:only-child,
.frame-card-accent p:last-child > a:only-child,
.frame-card-half p:last-child > a:only-child,
.frame-card-wide p:last-child > a:only-child,
.news .more {
    font-family: var(--hand);
    font-size: 1.3rem;
    color: var(--purple-ink);
    text-decoration: none;
    background: linear-gradient(transparent 60%, var(--marker-soft) 60%, var(--marker-soft) 92%, transparent 92%);
}
.frame-card p:last-child > a:only-child::after,
.frame-card-accent p:last-child > a:only-child::after,
.frame-card-half p:last-child > a:only-child::after,
.frame-card-wide p:last-child > a:only-child::after,
.news .more::after {
    content: " →";
    content: " →" / "";
    display: inline-block;
    transition: transform .2s ease;
}
.frame-card p:last-child > a:only-child:hover,
.frame-card-accent p:last-child > a:only-child:hover,
.frame-card-half p:last-child > a:only-child:hover,
.frame-card-wide p:last-child > a:only-child:hover,
.news .more:hover { background: linear-gradient(transparent 50%, var(--marker) 50%, var(--marker) 92%, transparent 92%); }
.frame-card p:last-child > a:only-child:hover::after,
.frame-card-accent p:last-child > a:only-child:hover::after,
.frame-card-half p:last-child > a:only-child:hover::after,
.frame-card-wide p:last-child > a:only-child:hover::after,
.news .more:hover::after { transform: translateX(4px); }

/* Karten mit Bild (Projekte): Bild oben */
.frame-card-half.frame-type-textmedia, .frame-card.frame-type-textmedia {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 0;
}
.frame-card-half.frame-type-textmedia .ce-textpic,
.frame-card.frame-type-textmedia .ce-textpic { display: contents; }
.frame-card-half.frame-type-textmedia .ce-gallery,
.frame-card.frame-type-textmedia .ce-gallery { order: -1; float: none; width: 100%; margin: 0 !important; }
.frame-card-half .ce-gallery .ce-row, .frame-card .ce-gallery .ce-row,
.frame-card-half .ce-gallery .ce-column, .frame-card .ce-gallery .ce-column { margin: 0 !important; }
.frame-card-half.frame-type-textmedia .ce-gallery figure.image,
.frame-card.frame-type-textmedia .ce-gallery figure.image {
    margin: 0; padding: 0; box-shadow: none; transform: none; background: var(--paper-2);
    border-bottom: var(--border);
}
.frame-card-half.frame-type-textmedia .ce-gallery figure.image::before,
.frame-card.frame-type-textmedia .ce-gallery figure.image::before { display: none; }
.frame-card-half.frame-type-textmedia .ce-gallery img,
.frame-card.frame-type-textmedia .ce-gallery img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top center; display: block; }
.frame-card-half.frame-type-textmedia > header,
.frame-card.frame-type-textmedia > header { padding: 22px clamp(20px, 2.4vw, 30px) 0; margin-bottom: .3em; }
.frame-card-half.frame-type-textmedia .ce-bodytext,
.frame-card.frame-type-textmedia .ce-bodytext { padding: 0 clamp(20px, 2.4vw, 30px) 22px; color: var(--ink-2); }
.frame-card-half > header > h2, .frame-card-half > header > h3 { font-size: clamp(1.8rem, 1.5rem + .9vw, 2.2rem); margin-bottom: .1em; }
.frame-card-half > header > h2::after { display: none; }
.frame-card-half.frame-type-text, .frame-card-wide.frame-type-text { padding: clamp(22px, 2.6vw, 32px) clamp(20px, 2.4vw, 30px); }

/* breite Karte mit Bild (Über mich) */
.frame-card-wide.frame-type-textmedia { padding: clamp(18px, 2.4vw, 28px); display: block; border-radius: var(--wobble-2); }
.frame-card-wide .ce-gallery figure.image { margin: 0; transform: rotate(-1deg); }
.frame-card-wide .ce-bodytext { color: var(--ink-2); }
.frame-card-wide > header > h2 { margin-bottom: .2em; }
.frame-card-wide > header > h2::after { display: none; }

/* Etiketten in Karten (Untertitel einer halben/breiten Karte, z. B. „Webdesign · TYPO3“) */
.frame-card-half header > h2 + h3, .frame-card-half header > h3 + h4,
.frame-card-wide.frame-type-textmedia header > h2 + h3 {
    display: inline-block;
    font-family: var(--hand);
    font-size: 1.15rem;
    line-height: 1.2;
    color: var(--purple-ink);
    background: linear-gradient(transparent 50%, var(--marker) 50%, var(--marker) 92%, transparent 92%);
    padding: 0 .15em;
    margin: .2em 0 .2em;
}
/* breite Text-Karte (Pflege-Abo): Untertitel = Preis */
.frame-card-wide.frame-type-text > header > h2 + h3 {
    font-family: var(--hand);
    font-size: clamp(1.7rem, 1.45rem + .8vw, 2.1rem);
    color: var(--purple-ink);
    margin: .2em 0 0;
    line-height: 1.1;
}

/* Schritte: Nummer im gezeichneten Kreis */
.frame-step { counter-increment: step; }
.frame-step > header { display: flex; align-items: center; gap: .45em; margin-bottom: .4em; }
.frame-step > header::before {
    content: counter(step);
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 2.1em;
    height: 1.65em;
    font-family: var(--hand);
    font-size: 1.7rem;
    line-height: 1;
    color: var(--purple-ink);
    background: url("../Images/scribble-circle.svg") no-repeat center / 100% 100%;
}
.frame-step > header > h2, .frame-step > header > h3 { font-size: clamp(1.55rem, 1.35rem + .6vw, 1.85rem); margin: 0; }
.frame-step p { color: var(--ink-2); font-size: var(--fs-small); margin-bottom: 0; }

/* Vertrauensleiste: vier Notizen mit gestrichelten Trennstrichen */
.frame-trust ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}
.frame-trust ul > li {
    margin: 0;
    padding: 4px clamp(14px, 2vw, 24px) 6px;
    border-left: 2px dashed var(--line-strong);
    color: var(--muted);
    font-size: var(--fs-small);
    line-height: 1.35;
}
.frame-trust ul > li:first-child { border-left: 0; padding-left: 0; }
.frame-trust ul > li::before { display: none; }
.frame-trust ul > li strong {
    display: block;
    font-family: var(--hand);
    font-weight: 400;
    font-size: clamp(1.45rem, 1.3rem + .5vw, 1.75rem);
    line-height: 1.15;
    color: var(--ink);
    background: none;
    padding: 0;
    margin-bottom: .2em;
}
@media (max-width: 900px) {
    .frame-trust ul { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 18px; }
    .frame-trust ul > li:nth-child(odd) { border-left: 0; padding-left: 0; }
}
@media (max-width: 480px) {
    .frame-trust ul { grid-template-columns: 1fr; row-gap: 12px; }
    .frame-trust ul > li { border-left: 0; padding-left: 0; }
}

/* Aufruf: großer lila Klebezettel, letzter Link = Knopf */
.frame-cta {
    position: relative;
    padding: clamp(30px, 4vw, 52px) clamp(24px, 4vw, 56px) clamp(24px, 3.4vw, 44px);
    background: linear-gradient(180deg, var(--note) 0%, var(--note-2) 100%);
    border-radius: 2px 2px 26px 2px;
    box-shadow: 0 18px 26px -18px rgba(31, 42, 82, .55);
    transform: rotate(-.5deg);
    margin-top: clamp(24px, 3.4vw, 44px);
}
.frame-cta::before {
    content: "";
    position: absolute;
    top: -15px;
    left: clamp(30px, 8%, 90px);
    width: 120px;
    height: 32px;
    background: var(--tape);
    transform: rotate(-4deg);
}
.frame-cta > header h2 { margin-bottom: .25em; }
.frame-cta > header h2::after { display: none; }
.frame-cta p { max-width: 40rem; color: var(--ink-2); }
.frame-cta p:last-child { margin: 1.2em 0 0; }

/* Text-Links als Knöpfe: Begrüßung + Aufruf */
.stage .frame-type-text p:last-child:has(> a),
.frame-cta p:last-child:has(> a) {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 18px;
    font-size: 0;
    max-width: none;
}
.stage .frame-type-text p:last-child > a,
.frame-cta p:last-child > a { font-size: 1.45rem; }

/* --------------------------------------------------------------------- Knöpfe: gezeichnete Rahmen */

.btn, button, input[type="submit"], input[type="button"], .news-backlink-wrap a,
.stage .frame-type-text p:last-child > a,
.frame-cta p:last-child > a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .45em;
    font-family: var(--hand);
    font-size: 1.35rem;
    line-height: 1.15;
    letter-spacing: .01em;
    padding: .42em 1.2em .36em;
    color: var(--ink);
    background: transparent;
    border: var(--border);
    border-radius: var(--wobble);
    cursor: pointer;
    text-decoration: none;
    transition: transform .18s ease, background-color .18s, color .18s, border-color .18s;
}
.btn:hover, button:hover, input[type="submit"]:hover, input[type="button"]:hover, .news-backlink-wrap a:hover,
.stage .frame-type-text p:last-child > a:hover,
.frame-cta p:last-child > a:hover {
    transform: rotate(-1.5deg) scale(1.03);
    background: var(--marker);
    color: var(--ink);
}
.btn:active, button:active, input[type="submit"]:active,
.stage .frame-type-text p:last-child > a:active,
.frame-cta p:last-child > a:active { transform: rotate(0) scale(.98); }

.btn-primary, button[type="submit"], input[type="submit"],
.stage .frame-type-text p:last-child > a:first-child,
.frame-cta p:last-child > a:first-child {
    background: var(--purple-d);
    border-color: var(--purple-d);
    color: #fffdf6;
}
.btn-primary:hover, button[type="submit"]:hover, input[type="submit"]:hover,
.stage .frame-type-text p:last-child > a:first-child:hover,
.frame-cta p:last-child > a:first-child:hover {
    background: var(--purple-dd);
    border-color: var(--purple-dd);
    color: #fff;
}
.stage .frame-type-text p:last-child > a:first-child::after,
.frame-cta p:last-child > a:first-child::after { content: "→"; content: "→" / ""; margin-left: .1em; }
button:disabled, input:disabled { opacity: .5; cursor: not-allowed; transform: none; }

/* --------------------------------------------------------------------- Formulare: Schreiblinien */

label, .form-label {
    display: block;
    color: var(--ink-2);
    font-size: var(--fs-small);
    margin: .8em 0 .1em;
}
.required { color: var(--purple-ink); }

input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="tel"],
input[type="search"], input[type="url"], input:not([type]), select, textarea, .form-control {
    display: block;
    width: 100%;
    font: inherit;
    font-size: 1.25em;
    line-height: 1.35;
    color: var(--ink);
    background: transparent;
    border: 0;
    border-bottom: 2.5px solid var(--ink-2);
    border-radius: 0;
    padding: .25em .2em .15em;
    transition: background-color .2s, border-color .2s;
}
textarea, textarea.form-control {
    border: 2.5px solid var(--ink-2);
    border-radius: 6px 14px 8px 16px;
    min-height: 7em;
    padding: .4em .6em;
    resize: vertical;
}
input::placeholder, textarea::placeholder { color: #8d92aa; }
input:focus, select:focus, textarea:focus, .form-control:focus {
    outline: none;
    border-color: var(--purple-d);
    background: var(--marker-soft);
}
select {
    appearance: none;
    background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 12'%3E%3Cpath d='M2 2 L10 10 L18 2' fill='none' stroke='%237c5fd4' stroke-width='2.6' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right .3em center / .9em;
    padding-right: 1.8em;
}

input[type="checkbox"], input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    width: 1.15em; height: 1.15em;
    margin: .12em .5em 0 0;
    border: 2.5px solid var(--ink);
    border-radius: 4px 8px 5px 9px;
    background: transparent no-repeat center / 115%;
    vertical-align: -.15em;
    flex: 0 0 auto;
    cursor: pointer;
}
input[type="radio"] { border-radius: 50% 46% 52% 48%; }
input[type="checkbox"]:checked { background-image: url("../Images/scribble-check.svg"); border-color: var(--purple-d); }
input[type="radio"]:checked { border-color: var(--purple-d); background: radial-gradient(circle, var(--purple-d) 38%, transparent 42%); }

label.check { display: flex; gap: .2em; align-items: flex-start; color: var(--ink); font-size: var(--fs-body); }
label.check .check__box { display: none; }

.validation-error, .alert-danger, .alert-warning, .typo3-messages .alert-danger, .help-block, .invalid-feedback {
    color: var(--red);
    background: var(--red-tint);
    border-radius: var(--wobble);
    padding: .35em .9em;
    margin: .3em 0 .6em;
    font-size: var(--fs-small);
}
.alert-success { color: var(--green); background: var(--green-tint); border-radius: var(--wobble); padding: .45em 1em; margin: .6em 0; }
.alert { list-style: none; }
.typo3-messages { padding: 0; list-style: none; }

/* Kontaktformular (EXT:form) */
.frame-type-form_formframework form { max-width: 46rem; }
.frame-type-form_formframework .row { display: flex; flex-wrap: wrap; margin: 0 -12px; }
.frame-type-form_formframework .row > [class*="col-"] { flex: 1 1 100%; padding: 0 12px; min-width: 0; }
@media (min-width: 700px) {
    .frame-type-form_formframework .row > .col-md-6 { flex-basis: 50%; max-width: 50%; }
}
.frame-type-form_formframework .form-group, .frame-type-form_formframework .mb-3 { margin-bottom: .5em; }
.frame-type-form_formframework .actions, .frame-type-form_formframework nav.form-navigation { margin-top: 1.5em; }
.frame-type-form_formframework .btn-toolbar, .frame-type-form_formframework .btn-group { display: flex; gap: 12px; }
.frame-type-form_formframework .form-check-label, .frame-type-form_formframework .form-check label { font-size: var(--fs-small); color: var(--ink-2); }
.frame-type-form_formframework .is-invalid, .frame-type-form_formframework .has-error .form-control { border-color: var(--red); }
/* Bestätigung nach dem Absenden: Klebezettel */
.frame-type-form_formframework div[id^="kontakt-"]:not(:has(form)):not(:has(input)) {
    position: relative;
    max-width: 40rem;
    font-family: var(--hand);
    font-size: clamp(1.45rem, 1.25rem + .8vw, 1.9rem);
    line-height: 1.4;
    color: var(--ink);
    background: linear-gradient(180deg, var(--note) 0%, var(--note-2) 100%);
    border-radius: 2px 2px 20px 2px;
    box-shadow: var(--shadow);
    padding: 30px 30px 24px;
    transform: rotate(-.8deg);
}

/* --------------------------------------------------------------------- Startseite: Begrüßung + Klebezettel */

.stage { position: relative; padding: clamp(6px, 2vw, 26px) 0 clamp(20px, 3vw, 40px); }
.stage .frame { margin-bottom: 0; }
.stage .frame > header { display: flex; flex-direction: column; }
.stage h1 { font-size: clamp(2.5rem, 1.4rem + 3.4vw, 4.2rem); line-height: 1.06; margin-bottom: .3em; }
.stage h1::after { max-width: 6.5em; height: 14px; margin-top: .14em; }
/* „Webseiten mit Handschrift“ als Originalstrich, „Handschrift“ in Lila wie „Medienbude“ im Logo;
   der Rest der Überschrift steht klein darunter */
.stage h1:has(.hand) { display: flex; flex-direction: column; }
.stage h1 .hand { --hand-xh: .335em; order: 1; line-height: 1.25; }
.stage h1 .hand--webseiten-mit-handschrift .hand__svg:last-of-type { color: var(--purple-d); }
.stage h1::after { order: 2; }
.stage h1 .hand-rest { order: 3; display: block; margin-top: .3em; font-size: .42em; line-height: 1.3; color: var(--ink-2); }
/* „Moin! Schön, dass du da bist.“ – handschriftlich über der Überschrift */
.stage .frame > header > h1 + h2 {
    order: -1;
    align-self: flex-start;
    margin: 0 0 .35em;
    font-family: var(--hand);
    font-size: clamp(1.5rem, 1.25rem + 1vw, 2.1rem);
    line-height: 1.2;
    color: var(--purple-ink);
    letter-spacing: .01em;
    transform: rotate(-2.5deg);
    transform-origin: left bottom;
}
.stage .frame > header > h1 + h2 .hand { --hand-xh: .44em; }
.stage p { font-size: clamp(1.06rem, .98rem + .4vw, 1.25rem); max-width: 34em; color: var(--ink-2); line-height: 1.7; }
.page--hand .stage p { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); line-height: 1.5; }
.stage p:last-child { margin: 1.4em 0 0; }

/* Klebezettel (Rahmen "note"): lila Zettel mit Klebestreifen */
.frame-note {
    position: relative;
    background: linear-gradient(180deg, var(--note) 0%, var(--note-2) 100%);
    padding: clamp(28px, 3vw, 40px) clamp(24px, 3vw, 38px) clamp(16px, 2vw, 24px);
    max-width: 640px;
    border-radius: 2px 2px 22px 2px;
    box-shadow: 0 16px 24px -16px rgba(31, 42, 82, .5);
    transform: rotate(-1.2deg);
    font-family: var(--hand);
    font-size: clamp(1.22rem, 1.1rem + .45vw, 1.48rem);
    line-height: 1.5;
}
.frame-note::before {
    content: "";
    position: absolute;
    top: -15px;
    left: 50%;
    width: 120px;
    height: 32px;
    margin-left: -60px;
    background: var(--tape);
    transform: rotate(-3deg);
}
.frame-note > header { margin: 0 0 .2em; }
.frame-note > header > h2, .frame-note > header > h3 { font-size: clamp(1.75rem, 1.45rem + .9vw, 2.2rem); margin: 0; }
.frame-note > header > h2::after { display: none; }
.frame-note > header .hand { --hand-xh: .44em; }
.frame-note ul { margin-top: .5em; margin-bottom: .6em; }
.frame-note p { margin-top: .4em; margin-bottom: .6em; }
.frame-note strong { font-weight: 400; color: var(--purple-ink); background: none; padding: 0; }
.content-area .frame-note:nth-child(even) { transform: rotate(1deg); }

.start { row-gap: 0; }
@media (min-width: 1000px) {
    .start > .stage { grid-column: 1 / span 7; grid-row: 1; align-self: center; }
    .start > .content-area { display: contents; }
    .start > .content-area > .frame-note:first-child { grid-column: 8 / -1; grid-row: 1; align-self: center; justify-self: end; width: 100%; margin: 24px 0 clamp(30px, 3.4vw, 46px); }
}
@media (max-width: 999px) {
    .start > .content-area > .frame-note:first-child { margin-top: 26px; }
}

/* --------------------------------------------------------------------- Bilder: eingeklebte Fotos */

.ce-gallery figure.image, .taped-photo, .news-img-wrap, .frame-tape .image {
    position: relative;
    background: #fff;
    padding: 10px 10px 14px;
    box-shadow: var(--shadow);
    margin: 0 0 1em;
}
.ce-gallery figure.image img, .taped-photo img { display: block; width: 100%; height: auto; }
.ce-gallery figure.image a { line-height: 0; display: block; }
.ce-gallery figure.image a:hover { background: none; }
.ce-gallery figcaption, .image-caption { font-size: var(--fs-small); color: var(--ink-2); padding: .4em .2em 0; line-height: 1.35; }

/* lila Klebestreifen */
.ce-gallery figure.image::before, .taped-photo::before, .frame-tape .image::before {
    content: "";
    position: absolute; top: -12px; left: 50%; width: 96px; height: 26px; margin-left: -48px;
    background: var(--tape);
    transform: rotate(2deg);
}
.ce-gallery .ce-column:nth-child(odd) figure.image { transform: rotate(-1.2deg); }
.ce-gallery .ce-column:nth-child(even) figure.image { transform: rotate(1deg); }

/* Galerien über/unter dem Text: volle Breite, flexible Spalten */
.ce-above .ce-gallery, .ce-below .ce-gallery { float: none; width: 100%; }
.ce-above .ce-gallery .ce-outer, .ce-above .ce-gallery .ce-inner,
.ce-below .ce-gallery .ce-outer, .ce-below .ce-gallery .ce-inner { float: none; right: auto; }
.ce-above .ce-gallery .ce-row, .ce-below .ce-gallery .ce-row { display: flex; gap: clamp(18px, 3vw, 34px); margin-bottom: clamp(18px, 3vw, 34px); }
.ce-above .ce-gallery .ce-column, .ce-below .ce-gallery .ce-column { flex: 1 1 0; min-width: 0; float: none; margin: 0; }
.ce-above .ce-gallery figure.image, .ce-below .ce-gallery figure.image { display: block; margin: 0; }
.ce-above .ce-gallery img, .ce-below .ce-gallery img { width: 100%; }
.ce-bodytext + .ce-gallery, .ce-below .ce-gallery { margin-top: 1.2em; }
@media (max-width: 640px) {
    .ce-above .ce-gallery .ce-row, .ce-below .ce-gallery .ce-row { flex-direction: column; }
    .ce-intext.ce-right .ce-gallery, .ce-intext.ce-left .ce-gallery { float: none; width: 100%; margin: 0 0 1em; }
}

/* --------------------------------------------------------------------- Shop */

.product-grid {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 0 1.5em;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr));
    gap: clamp(24px, 3.4vw, 44px);
}
.product-grid > li { margin: 0; }
.product-grid > li::before { display: none; }
.product-card { display: flex; flex-direction: column; padding: 14px 16px 18px; }
.product-card:nth-child(3n+1) { transform: rotate(-.8deg); }
.product-card:nth-child(3n+2) { transform: rotate(.6deg); border-radius: var(--wobble-2); }
.product-card:nth-child(3n+3) { transform: rotate(-.3deg); }
.product-card__link { display: block; text-decoration: none; color: var(--ink); }
.product-card__link:hover { background: none; }
.product-card__image { display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 6px 16px 8px 14px; margin-bottom: .55em; background: var(--paper-2); }
.product-card__image img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.product-card:hover .product-card__image img { transform: scale(1.04); }
.product-card__title { display: block; font-family: var(--hand); font-size: 1.6rem; line-height: 1.15; }
.product-card__teaser { font-size: var(--fs-small); color: var(--ink-2); margin: .35em 0 .4em; line-height: 1.4; }
.product-card__teaser p { margin: 0; }
.product-card__price { margin-top: auto; }
.product-card__price .price { font-size: 1.7rem; }

.price-box { display: flex; flex-wrap: wrap; align-items: baseline; gap: .1em .7em; margin: .2em 0 .5em; }
.price { font-family: var(--hand); font-size: 2.1rem; line-height: 1.1; color: var(--ink); }
.price--old { color: var(--muted); font-size: 1.35rem; }
.price--special { color: var(--red); }
.price-note { font-size: var(--fs-small); color: var(--muted); flex-basis: 100%; }
.price-note a { color: var(--muted); }
.stock { font-size: var(--fs-small); color: var(--green); }
.stock.not-in-stock { color: var(--red); }

.product-detail { display: grid; gap: clamp(28px, 5vw, 64px); grid-template-columns: 1fr; align-items: start; }
@media (min-width: 860px) { .product-detail { grid-template-columns: 1.05fr 1fr; } }
.product-detail__title::after { display: none; }
.product-detail__title { font-size: clamp(2.2rem, 1.6rem + 2.4vw, 3.2rem); }
.product-detail__teaser { font-size: 1.3em; color: var(--ink-2); }
.taped-photo { transform: rotate(-1.4deg); }
.product-detail__thumbs { display: flex; gap: 10px; margin-top: 1em; }
.product-detail__thumbs img { width: 90px; border: 2px solid var(--ink); border-radius: 6px; }
.back-link { margin-top: 1.4em; }

.buy-box { padding: 18px 22px 16px; margin: 1.2em 0 1.6em; border-radius: var(--wobble-2); border-color: var(--purple-d); }
.buy-box__row { display: flex; gap: 14px; align-items: flex-end; flex-wrap: wrap; margin-top: .4em; }
.qty { margin: 0; }
.qty label { margin-top: 0; }
.buy-box input.qty__input { width: 4.2em; text-align: center; font-size: 1.5rem; }
.buy-box button[type="submit"] { font-size: 1.45rem; }
.form-message .alert { margin-top: .8em; }

/* Warenkorb (EXT:cart) – Bootstrap-Raster nachgebaut */
.tx-cart .row { display: flex; flex-wrap: wrap; margin: 0 -14px; }
.tx-cart [class*="col-"] { flex: 1 1 100%; max-width: 100%; padding: 0 14px; }
@media (min-width: 760px) {
    .tx-cart .col-md-4 { flex-basis: 33.333%; max-width: 33.333%; }
    .tx-cart .col-md-6 { flex-basis: 50%; max-width: 50%; }
    .tx-cart .col-md-8 { flex-basis: 66.666%; max-width: 66.666%; }
    .tx-cart .col-md-12 { flex-basis: 100%; max-width: 100%; }
}
@media (min-width: 1040px) {
    .tx-cart .col-lg-4 { flex-basis: 33.333%; max-width: 33.333%; }
    .tx-cart .col-lg-6 { flex-basis: 50%; max-width: 50%; }
    .tx-cart .col-lg-8 { flex-basis: 66.666%; max-width: 66.666%; }
    .tx-cart .col-lg-12 { flex-basis: 100%; max-width: 100%; }
}
.tx-cart .top-buffer { margin-top: 1.5em; }
.tx-cart .text-right, .tx-cart .pull-right { text-align: right; }
.tx-cart fieldset { border: 0; padding: 0; margin: 0 0 1em; min-width: 0; }
.tx-cart legend, .checkout-step-title, .tx-cart h4, .tx-cart h5 { font-family: var(--hand); font-size: 1.75rem; font-weight: 400; margin: 1em 0 .3em; padding: 0; }
.tx-cart .checkout-step { margin-bottom: 1.5em; }
.tx-cart .field { margin-bottom: .5em; }
.tx-cart table { font-size: var(--fs-small); }
.tx-cart table .price { font-size: 1.3rem; }
.tx-cart table tr:last-child .price { font-size: 1.7rem; color: var(--purple-ink); }
.tx-cart table tr:last-child td { border-bottom: 0; }
.tx-cart table input.form-control { width: 4em; display: inline-block; text-align: center; }
.tx-cart .checkout-step-content-list { background: var(--card); border: var(--border); border-radius: var(--wobble); padding: 14px 18px; box-shadow: var(--shadow); }
.tx-cart #form-order input[type="submit"] { font-size: 1.55rem; margin-top: .6em; }
.tx-cart .privacy-hint { font-size: var(--fs-small); color: var(--muted); }
.tx-cart .tax-note { font-size: var(--fs-small); color: var(--muted); margin: .9rem 0 0; }
.tx-cart .consents .field { margin-bottom: .8em; }
.tx-cart #form-order { margin-top: 1.5em; }

.cart-empty, .note-card {
    position: relative;
    background: linear-gradient(180deg, var(--note) 0%, var(--note-2) 100%);
    padding: 28px 30px 20px;
    max-width: 640px;
    border-radius: 2px 2px 20px 2px;
    box-shadow: var(--shadow);
    transform: rotate(-.8deg);
}
.cart-empty::before, .note-card::before {
    content: "";
    position: absolute; top: -13px; left: 50%; width: 100px; height: 28px; margin-left: -50px;
    background: var(--tape);
    transform: rotate(-3deg);
}
.cart-empty__title { font-family: var(--hand); font-size: 2rem; line-height: 1.2; margin-bottom: .3em; }
.order-success { max-width: 760px; }
.order-success__title { font-size: clamp(2.2rem, 1.5rem + 3vw, 3.4rem); }
.payment-info { margin-top: 1.4em; }
.payment-info__bank { font-size: 1.15em; white-space: pre-line; }

/* --------------------------------------------------------------------- Neuigkeiten: Zettel nebeneinander */

.news-list-view { display: grid; gap: clamp(26px, 4vw, 44px); grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.news-list-view .article {
    display: flex;
    flex-direction: column;
    padding: 16px 18px 16px;
    border-radius: var(--wobble-2);
}
.news-list-view .article:nth-child(odd) { transform: rotate(-.5deg); }
.news-list-view .article:nth-child(even) { transform: rotate(.5deg); border-radius: var(--wobble); }
.news-list-view .article .header h3 { font-size: 1.75rem; margin: .1em 0 .3em; }
.news-list-view .article .header h3 a { text-decoration: none; color: var(--ink); }
.news-list-view .article .header h3 a:hover { background: none; color: var(--purple-ink); }
.news-list-view .news-img-wrap { order: -1; padding: 0; box-shadow: none; background: var(--paper-2); margin: 0 0 .6em; aspect-ratio: 3 / 2; overflow: hidden; border-radius: 6px 14px 8px 12px; }
.news-list-view .news-img-wrap::before { display: none; }
.news-list-view .news-img-wrap img { width: 100%; height: 100%; object-fit: cover; object-position: left top; display: block; }
.news-list-view .news-img-wrap a { display: block; height: 100%; }
.news-list-view .teaser-text { font-size: var(--fs-small); line-height: 1.45; color: var(--ink-2); }
.news-list-view .teaser-text p { margin-bottom: .5em; }
.news-list-view .footer, .news-single .footer { font-size: var(--fs-small); color: var(--ink-2); }
.news-list-view .footer p, .news-single .footer p { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; }
.news-list-date { background: linear-gradient(transparent 50%, var(--marker) 50%, var(--marker) 92%, transparent 92%); padding: 0 .2em; }
.news-list-category, .news-list-author { color: var(--muted); }
.news .more { display: inline-block; margin-top: .3em; padding: 0; border: 0; }
.page-navigation { margin-top: 2em; font-size: 1.2rem; }
.page-navigation ul { list-style: none; display: flex; gap: .6em; padding: 0; }
.page-navigation ul li::before { display: none; }
.page-navigation .current { background: var(--marker); padding: 0 .4em; }

.news-single { max-width: 860px; }
.news-single .article .header h3, .news-single .article .header h1 { font-size: clamp(2.2rem, 1.5rem + 2.8vw, 3.4rem); margin-bottom: .3em; }
.news-single .news-img-wrap { max-width: 720px; transform: rotate(-1deg); margin: 1.6em 0 1.8em; }
.news-single .news-img-caption { font-size: var(--fs-small); color: var(--ink-2); margin: .4em 0 0; }
.news-single .footer { margin-bottom: .8em; }
.news-single .news-img-wrap .outer, .news-single .news-img-wrap .mediaelement { margin: 0; }
.news-single .news-img-wrap img { display: block; width: 100%; height: auto; }
.news-single .teaser-text { font-size: 1.2em; color: var(--ink-2); }
.news-single .news-backlink-wrap { margin-top: 2em; }

/* --------------------------------------------------------------------- Login */

.frame-type-felogin_login form, .frame-type-felogin_login fieldset { max-width: 480px; }
.frame-type-felogin_login fieldset { padding: 18px 24px 24px; margin: 0; }
.frame-type-felogin_login legend { font-family: var(--hand); font-size: 1.7rem; padding: 0 .3em; color: var(--ink); }
.frame-type-felogin_login input[type="submit"] { margin-top: 1em; }

/* --------------------------------------------------------------------- Fuß */

.site-footer {
    position: relative;
    padding: 0 0 28px;
    font-size: var(--fs-small);
    color: var(--ink-2);
}
.site-footer .container { position: relative; padding-top: 34px; }
/* Bleistiftstrich über dem Fuß */
.site-footer .container::before {
    content: "";
    position: absolute;
    left: var(--gutter);
    right: var(--gutter);
    top: 0;
    height: 8px;
    background: var(--ink);
    opacity: .32;
    -webkit-mask: url("../Images/scribble-line.svg") no-repeat center / 100% 100%;
    mask: url("../Images/scribble-line.svg") no-repeat center / 100% 100%;
}
.site-footer__grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr 1fr;
    gap: 28px 40px;
    margin-bottom: 30px;
}
.site-footer__logo { display: inline-block; line-height: 0; }
.site-footer__logo:hover { background: none; }
.site-footer__logo img { width: 300px; max-width: 100%; height: auto; }
.site-footer__claim { margin: 14px 0 8px; max-width: 22rem; color: var(--ink-2); line-height: 1.45; }
.footer-col__title {
    font-family: var(--hand);
    font-size: 1.5rem;
    line-height: 1.2;
    color: var(--purple-ink);
    margin: 2px 0 .45em;
}
.footer-col__title::after { display: none; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin: 0 0 .35em; }
.footer-col a { color: var(--ink); text-decoration: none; }
.footer-col a:hover { background: var(--marker); }
.footer-col a[aria-current="page"] { background: linear-gradient(transparent 55%, var(--marker) 55%, var(--marker) 92%, transparent 92%); }
.site-footer__bottom {
    border-top: 2px dashed var(--line);
    padding-top: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px 24px;
    color: var(--muted);
}
.site-footer__bottom p { margin: 0; }
@media (max-width: 900px) {
    .site-footer__grid { grid-template-columns: 1fr 1fr; }
    .site-footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 480px) {
    .site-footer__grid { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------- Lightbox */

.lightbox-dialog { border: 0; padding: 12px 12px 16px; background: #fff; max-width: min(94vw, 1200px); box-shadow: 0 20px 60px rgba(0, 0, 0, .35); }
.lightbox-dialog::backdrop { background: rgba(31, 42, 82, .72); }
.lightbox-dialog img { display: block; max-height: 82vh; width: auto; margin: 0 auto; }
.lightbox-dialog button { position: absolute; top: 8px; right: 8px; background: #fff; font-size: 1.1rem; padding: .1em .7em; }

/* --------------------------------------------------------------------- Bildschirmgrößen */

@media (min-width: 1100px) {
    /* Kopf in einer Zeile: Höhe so, dass Logo + Menü + Knöpfe in die Breite passen */
    :root { --band-h: min(74px, calc((min(100vw, var(--container)) - 2 * var(--gutter)) * .065)); }
    .site-header__inner { flex-wrap: nowrap; }
    /* Kopf bleibt beim Scrollen stehen – mit demselben Papier dahinter */
    body { background-attachment: fixed; }
    .site-header { position: sticky; top: 0; background: var(--paper) url("../Images/paper.png") fixed; }
}
@media (max-width: 760px) {
    :root { --band-h: clamp(44px, 12.6vw, 56px); }
    /* „Anfragen“ steht hier in einer eigenen Zeile – größer, gut zu treffen */
    .nav-cta.btn { height: calc(var(--band-h) * .9); padding: 0 1em; }
    .nav-cta .hand-btn { height: calc(var(--band-h) * .9 - 10px); }
    .stage h1 .hand { --hand-xh: .42em; }
    .stage h1 .hand-rest { font-size: .5em; }
    .main-nav__list { gap: 0 calc(var(--band-h) * .16); }
    .frame-note, .content-area .frame-note:nth-child(even), .frame-cta { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

@media print {
    .main-nav, .site-footer, .skip-link, .utility-bar { display: none; }
    body { background: #fff; }
    .site-header { position: static; }
}
