/* FLR1 Clips - Frontend */

:root {
    --accent: #ffb020;
    --bg: #0b1017;
    --bg-panel: #131b25;
    --bg-raised: #1a2532;
    --line: rgba(255, 255, 255, 0.09);
    --text: #e9eef5;
    --text-muted: #90a0b2;
    --live: #ff3b30;
    --radius: 10px;
    --ticker-height: 46px;
}

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

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

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
}

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

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

.wrap {
    width: min(1180px, 100% - 2.5rem);
    margin-inline: auto;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--accent);
    color: #0b1017;
    padding: 0.6rem 1rem;
    z-index: 100;
    font-weight: 700;
}

.skip-link:focus {
    left: 1rem;
    top: 1rem;
}

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

/* ---------------------------------------------------------------- Kopfbereich */

.site-header {
    border-bottom: 1px solid var(--line);
    background: linear-gradient(180deg, #101823 0%, var(--bg) 100%);
    padding-block: 1.25rem;
}

.site-header__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.brand {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.brand__title {
    margin: 0;
    font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.1rem);
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    font-stretch: condensed;
}

.brand__title span {
    color: var(--accent);
}

.brand__subtitle {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--bg-panel);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.status-pill__dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--text-muted);
    flex: none;
}

.status-pill.is-live {
    border-color: rgba(255, 59, 48, 0.55);
    color: #fff;
}

.status-pill.is-live .status-pill__dot {
    background: var(--live);
    animation: pulse 1.8s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255, 59, 48, 0.6); }
    50% { box-shadow: 0 0 0 8px rgba(255, 59, 48, 0); }
}

/* ---------------------------------------------------------------- Player */

.stage {
    padding-block: 1.75rem 2.5rem;
}

.stage__grid {
    display: grid;
    gap: 1.25rem;
    grid-template-columns: minmax(0, 1fr);
}

.stage__grid.has-chat {
    grid-template-columns: minmax(0, 1fr) 340px;
}

@media (max-width: 980px) {
    .stage__grid.has-chat {
        grid-template-columns: minmax(0, 1fr);
    }
}

.player-card {
    background: var(--bg-panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
}

.player-tabs {
    display: flex;
    gap: 0.25rem;
    padding: 0.5rem 0.5rem 0;
    border-bottom: 1px solid var(--line);
    flex-wrap: wrap;
}

.player-tab {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--text-muted);
    font: inherit;
    font-weight: 700;
    font-size: 0.85rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.7rem 1.1rem;
    border-radius: var(--radius) var(--radius) 0 0;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.player-tab:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.04);
}

.player-tab[aria-selected="true"] {
    background: var(--bg-raised);
    color: var(--text);
    box-shadow: inset 0 -3px 0 var(--accent);
}

.player-tab__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: transparent;
    border: 1px solid var(--text-muted);
}

.player-tab.is-live .player-tab__dot {
    background: var(--live);
    border-color: var(--live);
}

.player-stage {
    position: relative;
    background: #000;
}

.player-frame {
    position: relative;
    aspect-ratio: 16 / 9;
    width: 100%;
}

.player-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.player-panel[hidden] {
    display: none;
}

.player-offline {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    text-align: center;
    padding: 2rem;
    background: radial-gradient(circle at 50% 40%, #1b2635 0%, #0a0f16 70%);
}

.player-offline__title {
    margin: 0;
    font-size: 1.1rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--accent);
}

.player-offline p {
    margin: 0;
    max-width: 46ch;
    color: var(--text-muted);
}

/* Logo-Overlay */

.player-logo {
    position: absolute;
    z-index: 3;
    line-height: 0;
    pointer-events: none;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.6));
}

.player-logo a {
    pointer-events: auto;
    display: inline-block;
}

.player-logo--top-right {
    top: 14px;
    right: 14px;
}

.player-logo--top-left {
    top: 14px;
    left: 14px;
}

.player-logo--bottom-right {
    right: 14px;
    bottom: calc(var(--ticker-height) + 14px);
}

.player-logo--bottom-left {
    left: 14px;
    bottom: calc(var(--ticker-height) + 14px);
}

.player-logo img {
    display: block;
    width: 100%;
    height: auto;
}

/* ---------------------------------------------------------------- Laufschrift */

.ticker {
    display: flex;
    align-items: stretch;
    min-height: var(--ticker-height);
    background: var(--ticker-bg, #101820);
    color: var(--ticker-color, #ffffff);
    border-top: 1px solid var(--line);
    position: relative;
    z-index: 4;
}

.ticker--player {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    background: color-mix(in srgb, var(--ticker-bg, #101820) 88%, transparent);
    backdrop-filter: blur(2px);
}

.ticker--page {
    position: sticky;
    bottom: 0;
    border-radius: 0;
}

.ticker__label {
    flex: none;
    display: flex;
    align-items: center;
    padding-inline: 1rem;
    background: var(--accent);
    color: #0b1017;
    font-weight: 800;
    font-size: 0.78rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.ticker__viewport {
    position: relative;
    flex: 1 1 auto;
    overflow: hidden;
    display: flex;
    align-items: center;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 24px), transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 24px), transparent 100%);
}

.ticker__track {
    display: flex;
    width: max-content;
    will-change: transform;
    animation: ticker-scroll var(--ticker-duration, 40s) linear infinite;
}

.ticker.is-paused .ticker__track,
.ticker__viewport:hover .ticker__track,
.ticker__viewport:focus-within .ticker__track {
    animation-play-state: paused;
}

@keyframes ticker-scroll {
    from { transform: translate3d(0, 0, 0); }
    to { transform: translate3d(-50%, 0, 0); }
}

.ticker__group {
    display: flex;
    align-items: center;
    flex: none;
}

.ticker__item {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    padding-inline: 0.85rem;
    font-size: 0.98rem;
}

.ticker__item a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.ticker__sep {
    color: var(--accent);
    font-weight: 800;
    white-space: nowrap;
}

.ticker__pause {
    flex: none;
    appearance: none;
    border: 0;
    border-left: 1px solid var(--line);
    background: transparent;
    color: inherit;
    font: inherit;
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding-inline: 0.9rem;
    cursor: pointer;
}

.ticker__pause:hover {
    background: rgba(255, 255, 255, 0.08);
}

@media (prefers-reduced-motion: reduce) {
    .ticker__track {
        animation: none;
    }

    .ticker__viewport {
        overflow-x: auto;
    }

    .status-pill.is-live .status-pill__dot {
        animation: none;
    }
}

@media (max-width: 640px) {
    .ticker__pause {
        display: none;
    }

    .ticker__label {
        padding-inline: 0.7rem;
        font-size: 0.7rem;
    }
}

/* ---------------------------------------------------------------- Chat */

.chat-card {
    background: var(--bg-panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 420px;
}

.chat-card__head {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--line);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.chat-card iframe {
    flex: 1 1 auto;
    width: 100%;
    min-height: 420px;
    border: 0;
}

/* ---------------------------------------------------------------- Inhalte */

.section {
    padding-block: 2.5rem;
    border-top: 1px solid var(--line);
}

.section__title {
    margin: 0 0 1.25rem;
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--accent);
}

.columns {
    display: grid;
    gap: 2rem;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
}

@media (max-width: 860px) {
    .columns {
        grid-template-columns: minmax(0, 1fr);
    }
}

.prose p {
    margin: 0 0 1rem;
    color: #cfd8e3;
}

.prose p:last-child {
    margin-bottom: 0;
}

.schedule {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.75rem;
}

.schedule__item {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-panel);
    border: 1px solid var(--line);
    border-left: 3px solid var(--accent);
    border-radius: var(--radius);
}

@media (max-width: 520px) {
    .schedule__item {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.4rem;
    }
}

.schedule__date {
    font-weight: 800;
    letter-spacing: 0.04em;
    line-height: 1.3;
}

.schedule__date small {
    display: block;
    font-weight: 500;
    color: var(--text-muted);
}

.schedule__title {
    margin: 0 0 0.25rem;
    font-size: 1.05rem;
}

.schedule__meta {
    margin: 0;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.schedule__desc {
    margin: 0.5rem 0 0;
    color: #cfd8e3;
    font-size: 0.95rem;
}

.empty-note {
    margin: 0;
    padding: 1.25rem;
    border: 1px dashed var(--line);
    border-radius: var(--radius);
    color: var(--text-muted);
}

/* ---------------------------------------------------------------- Fuss */

.site-footer {
    border-top: 1px solid var(--line);
    padding-block: 1.5rem 3rem;
    color: var(--text-muted);
    font-size: 0.88rem;
}

.site-footer__inner {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
    align-items: center;
    justify-content: space-between;
}

.site-footer a {
    color: var(--text-muted);
}

.site-footer a:hover {
    color: var(--accent);
}

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

/* --------------------------------------------------------- Eigener Player */

.player-frame video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #05090e;
}

.player-notice {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    margin: 0;
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    background: rgba(5, 9, 14, 0.85);
    color: #fff;
    font-size: 0.9rem;
}

.player-sound {
    position: absolute;
    right: 0.85rem;
    bottom: 0.85rem;
    padding: 0.4rem 0.85rem;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    background: rgba(5, 9, 14, 0.75);
    color: #fff;
    font: inherit;
    font-size: 0.82rem;
    cursor: pointer;
}

.player-sound:hover {
    border-color: var(--accent);
    color: var(--accent);
}
