
/* TrueStory – seitenspezifisches Weltenschmiede-Design */
.truestory-page-wrapper {
    width: min(100% - 2rem, 92rem);
    margin: 0 auto;
    padding: 1.5rem 0 4rem;
}

.truestory-page-shell {
    width: 100%;
}

.truestory-page-shell > .container,
.truestory-page-shell .container {
    width: 100%;
    max-width: none;
    margin: 0;
}

.truestory-page #start {
    padding-top: 0;
}

.truestory-hero {
    --truestory-hero-image: none;
    position: relative;
    min-height: clamp(31rem, 56vw, 48rem);
    margin: 1.5rem 0 4rem;
    padding: clamp(2rem, 6vw, 5rem);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 4px;
    background-color: #151b20;
    background-image:
        linear-gradient(90deg, rgba(8,11,14,.93) 0%, rgba(8,11,14,.66) 48%, rgba(8,11,14,.22) 100%),
        var(--truestory-hero-image);
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    box-shadow: 0 1.5rem 4rem rgba(0,0,0,.28);
}

.truestory-hero::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 44%;
    background: linear-gradient(to top, rgba(8,11,14,.8), transparent);
    pointer-events: none;
}

.truestory-hero > * {
    position: relative;
    z-index: 1;
    max-width: 52rem;
}

.truestory-hero-eyebrow,
.story-deadline-badge,
.voting-closed-badge {
    color: var(--primary-gold);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .24rem;
    text-transform: uppercase;
}

.truestory-hero .hero-title {
    margin: .6rem 0 .5rem;
    color: #fff;
    font-size: clamp(3rem, 7vw, 6.6rem);
    line-height: .95;
    letter-spacing: .18rem;
    text-transform: uppercase;
    text-shadow: 0 .35rem 1.4rem rgba(0,0,0,.45);
}

.truestory-hero .hero-subtitle {
    margin: 0 0 .55rem;
    color: rgba(255,255,255,.88);
    font-size: clamp(1.05rem, 2vw, 1.55rem);
}

.truestory-hero > div:last-child {
    justify-content: flex-start !important;
    margin-top: 1.25rem;
}

.truestory-hero .action-btn,
.truestory-hero .secondary-btn {
    width: auto !important;
    min-width: 10rem;
    min-height: 3rem;
    border-radius: 3px !important;
    line-height: 1.2 !important;
    letter-spacing: .12rem;
    text-transform: uppercase;
}

.story-section-header,
.voting-header-box,
.chapter-poll-box,
.admin-dashboard-box {
    margin: 0 0 1.35rem;
    padding: clamp(1.25rem, 3vw, 2rem);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 4px;
    background: rgba(24,30,34,.88);
    box-shadow: 0 1rem 3rem rgba(0,0,0,.16);
}

.story-section-header,
.voting-header-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.story-main-heading {
    margin: 0;
    color: #fff;
    font-size: clamp(1.65rem, 3vw, 2.7rem);
    letter-spacing: .18rem;
    text-transform: uppercase;
}

.story-sub-heading {
    margin-top: .6rem;
    color: rgba(255,255,255,.65);
}

.voting-header-text { min-width: 0; }
.voting-header-actions { flex: 0 0 auto; }
.submit-idea-btn {
    min-height: 3.1rem;
    padding: 0 1.35rem;
    border: 1px solid var(--primary-gold);
    border-radius: 3px;
    background: var(--primary-gold);
    color: #181b1d;
    font-weight: 700;
    letter-spacing: .12rem;
    text-transform: uppercase;
    cursor: pointer;
}

.scroll-wrapper {
    position: relative;
}

.story-scroll-container {
    display: flex;
    gap: 1.15rem;
    overflow-x: auto;
    overflow-y: visible;
    padding: .25rem .15rem 1rem;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    scrollbar-color: rgba(216,184,93,.6) rgba(255,255,255,.06);
}

.story-scroll-container.show-all {
    display: grid;
    grid-template-columns: repeat(3, minmax(0,1fr));
    overflow: visible;
}

.scroll-wrapper.show-all .scroll-arrow { display: none; }

.story-card {
    position: relative;
    flex: 0 0 min(23rem, calc(100vw - 4rem));
    min-width: 0;
    min-height: 23rem;
    padding: 1.35rem !important;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border: 1px solid rgba(255,255,255,.12) !important;
    border-radius: 4px !important;
    background: rgba(25,31,35,.92) !important;
    color: #fff;
    scroll-snap-align: start;
    cursor: pointer;
    box-shadow: 0 1rem 2.8rem rgba(0,0,0,.16);
}

.story-card:hover {
    transform: translateY(-.18rem);
    border-color: rgba(216,184,93,.52) !important;
}

.story-card h2,
.story-card h4,
.story-card .story-card-title {
    color: #fff !important;
}

.story-card [style*="color:var(--primary-blue)"],
.story-card [style*="color: var(--primary-blue)"] {
    color: #fff !important;
}

.story-card [style*="color: #555"],
.story-card [style*="color:#555"],
.story-card [style*="color:#666"],
.story-card [style*="color: #666"],
.story-card [style*="color:#888"],
.story-card [style*="color: #888"] {
    color: rgba(255,255,255,.64) !important;
}

.story-card-snippet,
.story-card .justify-text {
    color: rgba(255,255,255,.72) !important;
    line-height: 1.65;
}

.story-card-avatar {
    width: 3.7rem;
    height: 3.7rem;
    object-fit: cover;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,.22);
}

.story-card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.vote-box {
    margin-top: auto;
    padding-top: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .8rem;
    border-top: 1px solid rgba(255,255,255,.1);
}

.show-all-card {
    align-items: center;
    justify-content: center;
    text-align: center;
    border-style: dashed !important;
}

.scroll-arrow {
    position: absolute;
    top: 50%;
    z-index: 4;
    width: 3rem;
    height: 3rem;
    padding: 0 !important;
    display: grid;
    place-items: center;
    transform: translateY(-50%);
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 50%;
    background: rgba(13,16,18,.92);
    color: #fff;
    cursor: pointer;
}
.left-arrow { left: -1.25rem; }
.right-arrow { right: -1.25rem; }

.chapter-poll-box {
    display: grid;
    grid-template-columns: minmax(0,1fr) minmax(18rem, 34rem);
    gap: 1.25rem;
    align-items: center;
}
.poll-bar-container {
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: .75rem;
}
.poll-btn {
    min-height: 3rem;
    border-radius: 3px !important;
}

.story-modal-overlay,
.js-close-custom-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 10020;
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding: max(1rem, 4vh) 1rem;
    overflow-y: auto;
    background: rgba(5,7,9,.82);
    backdrop-filter: blur(.45rem);
}

.story-modal-overlay[aria-hidden="false"] { display: flex; }

.story-modal-overlay .info-card,
.js-close-custom-modal-overlay .info-card {
    width: min(100%, 58rem);
    max-width: 58rem !important;
    max-height: none;
    margin: auto;
    padding: clamp(1.25rem, 3vw, 2.25rem) !important;
    overflow: visible;
    border: 1px solid rgba(255,255,255,.14) !important;
    border-radius: 4px !important;
    background: #1c2327 !important;
    color: #edf0f2;
}

.story-modal-overlay .close-modal,
.js-close-custom-modal-overlay .close-modal {
    position: sticky;
    top: 0;
    float: right;
    width: 3rem;
    height: 3rem;
    padding: 0 !important;
    border-radius: 3px !important;
    background: #20282d !important;
    color: #fff !important;
    z-index: 2;
}

.story-modal-overlay #modalTitle,
.js-close-custom-modal-overlay h2,
.js-close-custom-modal-overlay h3 {
    color: #fff !important;
    padding-right: 4rem;
}

.story-modal-overlay #modalContent,
.story-modal-overlay .justify-text,
.js-close-custom-modal-overlay .justify-text,
.js-close-custom-modal-overlay p,
.js-close-custom-modal-overlay li {
    color: rgba(255,255,255,.8) !important;
}

.modal-vote-section,
.modal-comments-section {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255,255,255,.12);
}

.comment-item {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255,255,255,.08);
}
.comment-reply { margin-left: 1.25rem; }
.comment-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: .8rem; }
.comment-action-btn {
    border: 0;
    background: none;
    color: var(--primary-gold);
    cursor: pointer;
}

.truestory-page .form-input,
.truestory-page .form-textarea,
.story-modal-overlay .form-input,
.story-modal-overlay .form-textarea,
.js-close-custom-modal-overlay .form-input,
.js-close-custom-modal-overlay .form-textarea {
    width: 100%;
    border: 1px solid rgba(255,255,255,.17) !important;
    border-radius: 3px !important;
    background: rgba(255,255,255,.06) !important;
    color: #fff !important;
}

.truestory-page .admin-dashboard-box label,
.truestory-page .admin-dashboard-box [style*="color:#333"] {
    color: rgba(255,255,255,.72) !important;
}

.truestory-page .toast-msg {
    position: fixed;
    top: 5.5rem;
    right: 1.25rem;
    z-index: 10100;
}

@media screen and (max-width: 980px) {
    .truestory-page-wrapper {
        width: min(100% - 1.25rem, 92rem);
    }
    .story-scroll-container.show-all {
        grid-template-columns: repeat(2, minmax(0,1fr));
    }
    .chapter-poll-box {
        grid-template-columns: 1fr;
    }
    .scroll-arrow { display: none; }
}

@media screen and (max-width: 736px) {
    .truestory-page-wrapper {
        width: calc(100% - .8rem);
        padding-top: .5rem;
    }
    .truestory-hero {
        min-height: 0;
        aspect-ratio: auto;
        margin: .7rem 0 2.5rem;
        padding: 0 1rem 1.15rem;
        justify-content: flex-start;
        background: #101518;
    }
    .truestory-hero::before {
        content: "";
        position: static;
        display: block;
        width: calc(100% + 2rem);
        aspect-ratio: 16 / 9;
        margin: 0 -1rem 1.35rem;
        flex: 0 0 auto;
        background-color: #101518;
        background-image: var(--truestory-hero-image);
        background-repeat: no-repeat;
        background-position: center;
        background-size: contain;
        border-bottom: 1px solid rgba(255,255,255,.08);
        pointer-events: none;
    }
    .truestory-hero::after { display: none; }
    .truestory-hero .hero-title {
        font-size: clamp(2.15rem, 12vw, 3.5rem);
        letter-spacing: .08rem;
    }
    .truestory-hero .hero-subtitle {
        font-size: 1rem !important;
    }
    .truestory-hero > div:last-child {
        display: grid !important;
        grid-template-columns: 1fr;
        width: 100%;
    }
    .truestory-hero .action-btn,
    .truestory-hero .secondary-btn {
        width: 100% !important;
    }
    .story-section-header,
    .voting-header-box {
        align-items: stretch;
        flex-direction: column;
    }
    .voting-header-actions,
    .submit-idea-btn { width: 100%; }
    .story-scroll-container,
    .story-scroll-container.show-all {
        display: flex;
        grid-template-columns: none;
        gap: .75rem;
        overflow-x: auto;
    }
    .story-card {
        flex-basis: min(86vw, 21rem);
        min-height: 21rem;
        padding: 1rem !important;
    }
    .poll-bar-container {
        grid-template-columns: 1fr;
    }
    .vote-box {
        align-items: stretch;
        flex-direction: column;
    }
    .story-modal-overlay,
    .js-close-custom-modal-overlay {
        padding: .4rem .4rem 5.5rem;
    }
    .story-modal-overlay .info-card,
    .js-close-custom-modal-overlay .info-card {
        width: 100%;
        padding: 1rem !important;
    }
    .comment-reply { margin-left: .5rem; }
}


/* TrueStory V3 – gezielte Korrekturen */
.story-modal-overlay .close-modal,
.js-close-custom-modal-overlay .close-modal,
.simple-modal-card > .js-close-any-modal {
    pointer-events: auto !important;
    z-index: 10020 !important;
    cursor: pointer !important;
}

@media screen and (max-width: 736px) {
    .truestory-hero > *:not(::before) {
        max-width: 100%;
    }
    .truestory-hero-eyebrow {
        margin-top: 0;
    }
    .story-modal-overlay .info-card,
    .js-close-custom-modal-overlay .info-card {
        min-height: 0;
    }
}