/**
 * CMS: Eingebettete Seiteninhalte (Migrationen, Copy-Paste aus anderen Editoren).
 * Wird nach Layout- und Theme-CSS eingebunden (Views/Home/Index.cshtml).
 */
:root {
    --surface: color-mix(in srgb, var(--color-text) 7%, transparent);
}

html {
    overflow-x: clip;
}

main .hero,
.hero,
.hero > *,
main .page-body,
.page-body {
    min-width: 0;
    max-width: 100%;
}

.page-body {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.page-body [style*="width"] {
    max-width: 100% !important;
}

.page-body div[style*="display: flex"],
.page-body div[style*="display:flex"] {
    min-width: 0 !important;
}

.page-body table {
    max-width: 100%;
}

/* Zwei-Klick-Einbettungen (YouTube etc.): gleiches Erscheinungsbild wie im Editor.
   Öffentliche Seite lädt kein site.css — Regeln daher hier (nicht nur unter .page-section). */
.editor-embed {
    margin: 1.5rem 0;
    max-width: 100%;
}

.editor-embed-consent::after {
    content: "";
    display: table;
    clear: both;
}

.editor-embed-placeholder-inner {
    padding: 1.25rem 1rem;
    border: 2px dashed rgb(203 213 225);
    border-radius: 0.75rem;
    background: rgb(248 250 252);
    text-align: center;
}

.editor-embed-consent-text {
    margin: 0 0 1rem;
    font-size: 0.9375rem;
    color: #475569;
    line-height: 1.55;
}

.editor-embed-load-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    font-size: 0.9375rem;
    font-weight: 600;
    color: #fff;
    background: #0f172a;
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: background 0.15s ease;
}

.editor-embed-load-btn:hover {
    background: #1e293b;
}

.editor-embed-youtube .editor-embed-placeholder-inner {
    min-height: 10rem;
}

.editor-embed-youtube .editor-embed-inner {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 0.75rem;
    background: #000;
}

.editor-embed-youtube .editor-embed-inner iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.editor-embed-spotify iframe {
    display: block;
    max-width: 100%;
    border: 0;
    border-radius: 0.75rem;
}

.editor-embed-instagram iframe {
    display: block;
    width: 100%;
    max-width: 100%;
    min-height: 420px;
    border: 0;
    border-radius: 0.75rem;
}

/* =============================================================================
   Cookie-Richtlinie (HTML aus CookiePolicyHtmlFormatter)
   Footer-Modal, Onepage-#page, Custom Layout: stabile Optik ohne Abhängigkeit
   von Tailwind-Utility-Klassen im eingefügten HTML.
   ============================================================================= */

.cookie-policy.cookie-policy-content {
    --cookie-policy-font: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --cookie-policy-fs-body: 0.9375rem;
    --cookie-policy-fs-body-lg: 1rem;
    --cookie-policy-fs-small: 0.8125rem;
    --cookie-policy-fs-caption: 0.75rem;
    --cookie-policy-fs-h1: clamp(1.375rem, 2.2vw, 1.625rem);
    --cookie-policy-fs-h2: 1.125rem;
    --cookie-policy-fs-h3: 1.0625rem;
    --cookie-policy-fs-h4: 1rem;
    box-sizing: border-box;
    max-width: 48rem;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding: 0 0.25rem 1rem;
    color: #0f172a;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-body);
    line-height: 1.6;
}

@media (min-width: 640px) {
    .cookie-policy.cookie-policy-content {
        font-size: var(--cookie-policy-fs-body-lg);
    }
}

.cookie-policy-content .cookie-policy-header {
    border-bottom-color: #e2e8f0;
}

.cookie-policy-content .cookie-policy-header h1 {
    margin: 0 0 0.5rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-h1);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.25;
    color: #0f172a;
}

.cookie-policy-content .cookie-policy-header p {
    margin: 0;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-body);
    font-weight: 400;
    line-height: 1.65;
    color: #64748b;
}

@media (min-width: 640px) {
    .cookie-policy-content .cookie-policy-header p {
        font-size: var(--cookie-policy-fs-body-lg);
    }
}

/* Zwischenüberschriften (Consent, Kategorien): gleiche Stufe wie Hosting-Zusammenfassung */
.cookie-policy-consent h2,
.cookie-policy-categories-title {
    margin: 0 0 0.5rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-h2);
    font-weight: 600;
    line-height: 1.35;
    color: #0f172a;
}

.cookie-policy-consent > p {
    margin: 0 0 1rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-body);
    line-height: 1.65;
    color: #475569;
}

@media (min-width: 640px) {
    .cookie-policy-consent > p {
        font-size: var(--cookie-policy-fs-body-lg);
    }
}

.cookie-policy-hosting {
    border-radius: 1rem;
    border: 1px solid #e2e8f0;
    background: linear-gradient(to bottom, rgba(248, 250, 252, 0.95), #ffffff);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.cookie-policy-hosting[open] {
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
}

.cookie-policy-hosting-summary {
    list-style: none;
    cursor: pointer;
    user-select: none;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-h2);
    font-weight: 600;
    line-height: 1.35;
    color: #0f172a;
}

.cookie-policy-hosting-summary::-webkit-details-marker {
    display: none;
}

.cookie-policy-hosting-chevron {
    flex-shrink: 0;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-caption);
    font-weight: 700;
    line-height: 1;
    color: #475569;
    transition: transform 0.2s ease;
}

.cookie-policy-hosting[open] .cookie-policy-hosting-chevron {
    transform: rotate(90deg);
}

.cookie-policy-hosting-body {
    border-top: 1px solid #f1f5f9;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-body);
    line-height: 1.65;
    color: #475569;
}

.cookie-policy-hosting-body p,
.cookie-policy-hosting-body li {
    font-size: inherit;
    line-height: inherit;
}

.cookie-policy-hosting-body ul {
    margin: 0;
    padding-left: 1.25rem;
}

@media (min-width: 640px) {
    .cookie-policy-hosting-body {
        font-size: var(--cookie-policy-fs-body-lg);
    }
}

.cookie-policy-hosting-body > p:last-of-type {
    font-size: var(--cookie-policy-fs-caption);
    line-height: 1.5;
    color: #64748b;
}

.cookie-policy-lead {
    border-radius: 1rem;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.cookie-policy-lead-body {
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-body);
    line-height: 1.65;
    color: #334155;
}

@media (min-width: 640px) {
    .cookie-policy-lead-body {
        font-size: var(--cookie-policy-fs-body-lg);
    }
}

.cookie-policy-lead-body a {
    color: #0f172a;
    text-decoration: underline;
}

.cookie-policy-lead-body strong {
    color: #0f172a;
    font-weight: 600;
}

.cookie-policy-consent {
    border-radius: 1rem;
    border: 1px solid #e2e8f0;
    background: rgba(248, 250, 252, 0.88);
}

.cookie-policy-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-small);
    font-weight: 600;
    line-height: 1.25;
    color: #ffffff;
    background-color: #0f172a;
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.cookie-policy-btn-primary:hover,
.cookie-policy-btn-primary:focus-visible {
    background-color: #000000;
    color: #ffffff;
    outline: none;
}

.cookie-policy-btn-primary:focus-visible {
    box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px #0f172a;
}

.cookie-policy-legal {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2.5rem;
}

/* Aus PageLinkPublicTokenReplacer (ohne pill-Klasse); Optik wie zuvor «Pill»-Links */
.cookie-policy-legal a {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-small);
    font-weight: 500;
    line-height: 1.25;
    color: #1e293b;
    text-decoration: none;
    border-radius: 9999px;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
    transition: background-color 0.15s ease, border-color 0.15s ease;
}

.cookie-policy-legal a:hover,
.cookie-policy-legal a:focus-visible {
    background: #f8fafc;
    border-color: #94a3b8;
    outline: none;
}

.cookie-policy-pill {
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-small);
    font-weight: 500;
    line-height: 1.25;
    text-decoration: none;
    border-radius: 9999px;
}

.cookie-policy-empty {
    border-radius: 0.75rem;
}

.cookie-policy-category-empty p {
    font-family: var(--cookie-policy-font);
    line-height: 1.65;
    color: #334155;
}

.cookie-policy-category-empty p:first-of-type {
    margin: 0 0 0.25rem;
    font-size: var(--cookie-policy-fs-h4);
    font-weight: 600;
    color: #0f172a;
}

.cookie-policy-category-empty p:last-of-type {
    margin: 0;
    font-size: var(--cookie-policy-fs-body);
    color: #475569;
}

@media (min-width: 640px) {
    .cookie-policy-category-empty p:last-of-type {
        font-size: var(--cookie-policy-fs-body-lg);
    }
}

.cookie-policy-categories-title {
    margin-top: 0.5rem;
    margin-bottom: 1rem;
}

.cookie-policy-category-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.cookie-policy-category > div:first-of-type {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

@media (min-width: 640px) {
    .cookie-policy-category > div:first-of-type {
        flex-direction: row;
        align-items: flex-start;
        justify-content: space-between;
    }
}

.cookie-policy-category > div:first-of-type > div:last-child {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.cookie-policy-category > div:first-of-type > div:last-child span {
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-caption);
    line-height: 1.25;
}

.cookie-policy-category h3 {
    margin: 0;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-h3);
    font-weight: 600;
    line-height: 1.35;
    color: #0f172a;
}

.cookie-policy-category h3 + p {
    margin: 0.25rem 0 0;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-body);
    line-height: 1.65;
    color: #475569;
}

@media (min-width: 640px) {
    .cookie-policy-category h3 + p {
        font-size: var(--cookie-policy-fs-body-lg);
    }
}

.cookie-policy-service-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cookie-policy-service {
    border-radius: 0.75rem;
    border: 1px solid #f1f5f9;
    background: rgba(248, 250, 252, 0.65);
}

.cookie-policy-service h4 {
    margin: 0;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-h4);
    font-weight: 600;
    line-height: 1.35;
    color: #0f172a;
}

.cookie-policy-service h4 + p {
    margin: 0.25rem 0 0;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-small);
    line-height: 1.6;
    color: #475569;
}

.cookie-policy-service dl {
    margin: 0.75rem 0 0;
    display: grid;
    gap: 0.5rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-small);
    line-height: 1.5;
}

.cookie-policy-service dt {
    font-weight: 500;
    color: #64748b;
}

.cookie-policy-service dd {
    margin: 0;
    color: #1e293b;
    word-break: break-word;
}

.cookie-policy-service-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.cookie-policy-service-links a {
    display: inline-flex;
    align-items: center;
    border-radius: 0.5rem;
    padding: 0.375rem 0.75rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-caption);
    font-weight: 500;
    color: #1e293b;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    text-decoration: none;
}

.cookie-policy-service-links a:hover {
    background: #f8fafc;
}

.cookie-policy-category-empty {
    border-radius: 0.75rem;
}

.cookie-policy-orphans {
    border-radius: 1rem;
}

.cookie-policy-orphans h3 {
    margin: 0 0 0.5rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-h2);
    font-weight: 600;
    line-height: 1.35;
    color: #422006;
}

.cookie-policy-orphans > p {
    margin: 0 0 1rem;
    font-family: var(--cookie-policy-font);
    font-size: var(--cookie-policy-fs-body);
    line-height: 1.65;
    color: rgba(69, 10, 10, 0.9);
}

@media (min-width: 640px) {
    .cookie-policy-orphans > p {
        font-size: var(--cookie-policy-fs-body-lg);
    }
}

.cookie-policy-orphans-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Footer-Modal: volle Breite nutzen, horizontales Scrollen vermeiden */
#footerModalContent .cookie-policy.cookie-policy-content {
    max-width: 100%;
    padding: 0;
}
