/* Ton e.V. Unna – Stylesheet (keine externen Abhängigkeiten) */

@font-face {
    font-family: "Roboto";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../fonts/roboto-latin-400.woff2") format("woff2");
}

@font-face {
    font-family: "Roboto";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("../fonts/roboto-latin-700.woff2") format("woff2");
}

:root {
    color-scheme: light;
    --bg: #fff;
    --surface: #f8f9fa;
    --text: #212529;
    --strong: #000;
    --muted: #5c636a;
    --border: #dee2e6;
    --accent: #8f0000;
    --on-accent: #fff;
    --button-bg: #212529;
    --button-text: #fff;
    --partner-bg: transparent;
    --radius: 6px;
    --container: 1140px;
    --content: 760px;
    --font: "Roboto", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        color-scheme: dark;
        --bg: #121416;
        --surface: #1c1f23;
        --text: #e3e5e8;
        --strong: #fff;
        --muted: #a0a7ae;
        --border: #343a40;
        --accent: #e35d5d;
        --on-accent: #121416;
        --button-bg: #e3e5e8;
        --button-text: #121416;
        --partner-bg: #e3e5e8;
    }
}

:root[data-theme="dark"] {
    color-scheme: dark;
    --bg: #121416;
    --surface: #1c1f23;
    --text: #e3e5e8;
    --strong: #fff;
    --muted: #a0a7ae;
    --border: #343a40;
    --accent: #e35d5d;
    --on-accent: #121416;
    --button-bg: #e3e5e8;
    --button-text: #121416;
    --partner-bg: #e3e5e8;
}

/* ---------- Basic ---------- */

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

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

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}

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

h1,
h2 {
    margin: 0 0 0.75rem;
    line-height: 1.2;
    font-weight: 700;
}

h1 {
    font-size: clamp(1.6rem, 1.2rem + 1.5vw, 2.25rem);
}

h2 {
    font-size: 1.35rem;
}

p {
    margin: 0 0 1rem;
}

a {
    color: var(--accent);
}

a:hover,
a:focus-visible {
    color: var(--strong);
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

address {
    font-style: normal;
}

.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: 1rem;
}

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

.skip-link {
    position: absolute;
    top: -100px;
    left: 1rem;
    z-index: 100;
    padding: 0.5rem 1rem;
    background: var(--bg);
    color: var(--strong);
}

.skip-link:focus {
    top: 0.5rem;
}

/* ---------- Header ---------- */

.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #2a2a2a;
    border-bottom: 3px solid #8f0000;
    color: #fff;
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 3.5rem;
}

.topbar-name {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #fff;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-decoration: none;
    text-transform: uppercase;
}

.topbar-name img {
    width: 2.5rem;
    height: 2.5rem;
}

.topbar-name:hover,
.topbar-name:focus-visible {
    color: #ff8a8a;
}

.theme-toggle {
    display: grid;
    place-items: center;
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 50%;
    background: transparent;
    color: #fff;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s, background-color 0.15s;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
    background: rgba(255, 255, 255, 0.12);
    border-color: #fff;
}

.topbar :focus-visible {
    outline-color: #fff;
}

.theme-toggle .icon {
    width: 1.25rem;
    height: 1.25rem;
}

.theme-toggle .icon-sun {
    display: none;
}

:root[data-theme="dark"] .theme-toggle .icon-sun {
    display: block;
}

:root[data-theme="dark"] .theme-toggle .icon-moon {
    display: none;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .theme-toggle .icon-sun {
        display: block;
    }

    :root:not([data-theme="light"]) .theme-toggle .icon-moon {
        display: none;
    }
}

/* ---------- Banner ---------- */

.hero {
    position: relative;
    height: clamp(260px, 45vw, 500px);
    background: #2a2a2a;
}

.hero::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 40%;
    background: linear-gradient(to bottom, rgba(42, 42, 42, 0), rgba(42, 42, 42, 0.6) 55%, #2a2a2a);
    pointer-events: none;
}

.hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 40% 50%;
}

/* ---------- Content ---------- */

.eyebrow {
    display: block;
    margin-bottom: 0.25rem;
    font-size: 1rem;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

main {
    padding-block: 2.5rem;
}

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

main > section + section {
    margin-top: 2.5rem;
    padding-top: 2.5rem;
    border-top: 1px solid var(--border);
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.button {
    display: inline-block;
    padding: 0.6rem 1.25rem;
    border: 2px solid var(--button-bg);
    border-radius: var(--radius);
    background: var(--button-bg);
    color: var(--button-text);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.button:hover,
.button:focus-visible {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--on-accent);
}

.button-outline {
    background: transparent;
    color: var(--button-bg);
}

.english {
    color: var(--muted);
}

.english h2 {
    color: var(--text);
}

.legal-page h2 {
    margin-top: 1.5rem;
    font-size: 1.1rem;
}

.legal-box {
    margin: 1.5rem 0;
    padding: 0.25rem 1.25rem;
    background: var(--surface);
    border-left: 4px solid var(--accent);
    border-radius: var(--radius);
}

.legal-box h2 {
    margin-top: 1rem;
}

.showcase {
    text-align: center;
}

.showcase h2 {
    font-size: 1.1rem;
    font-weight: 400;
}

.embed {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    height: 500px;
    padding: 1.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.embed p {
    max-width: 50ch;
    margin: 0;
    color: var(--muted);
}

.embed.is-loaded {
    padding: 0;
    border: 0;
}

.embed iframe {
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: var(--radius);
}

/* ---------- Footer ---------- */

.site-footer {
    padding-block: 1.5rem;
    background: var(--surface);
    border-top: 1px solid var(--border);
}

.social {
    display: flex;
    justify-content: space-between;
    margin: 0;
    padding: 0;
    list-style: none;
}

.social a {
    display: block;
    color: var(--strong);
    transition: color 0.15s;
}

.social a:hover,
.social a:focus-visible {
    color: var(--accent);
}

.icon {
    width: 2rem;
    height: 2rem;
    fill: currentColor;
}

.partner {
    max-width: 380px;
    margin: 3rem auto 0;
    text-align: center;
}

.partner img {
    width: 100%;
    height: auto;
    padding: 15px;
    background: var(--partner-bg);
    border-radius: var(--radius);
}

.partner p {
    margin: 0;
}

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    margin-top: 2rem;
    font-size: 0.875rem;
}

.copyright {
    margin: 0;
    color: var(--muted);
}

.legal {
    display: flex;
    gap: 1rem;
}
