/* ============================================================================
   TEMPLATE: primextime-1
   ============================================================================
   Liegt unter templates/primextime-1/style.css. Enthält alle visuellen
   Styles EINES Templates - Schriften (fonts/ liegt daneben im selben
   Ordner), Farben, Layout. Das Logo wird als <img> in index.php eingebunden
   und liegt unter templates/primextime-1/img/.
   Ein anderes Template (z.B. "primextime-2") wäre ein eigener Ordner
   templates/primextime-2/ mit eigener style.css, eigenem img/- und fonts/-
   Unterordner, und wird später pro Umfrage im Admin-Bereich zuweisbar sein.
   ============================================================================ */

/* ===== AUTO-GENERATED: SEITENEINSTELLUNG START (nicht manuell bearbeiten - wird beim Speichern im Template-Editor überschrieben) ===== */
@font-face {
    font-family: 'Urbanist';
    src: url('fonts/urbanist-v18-latin-regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Urbanist';
    src: url('fonts/urbanist-v18-latin-700.woff2') format('woff2');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Urbanist';
    src: url('fonts/urbanist-v18-latin-900.woff2') format('woff2');
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'BN Dime Display';
    src: url('fonts/BNDimeDisplayRegular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

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

body {
    font-family: 'Urbanist', sans-serif;
    background-color: rgb(255, 255, 247);
    color: #111111;
    line-height: 1.4;
    font-size: 16px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container {
    width: 100%;
    padding: 0 24px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .container {
        max-width: 1200px;
    }
    body {
        font-size: 16px;
    }
}
/* ===== AUTO-GENERATED: SEITENEINSTELLUNG END ===== */

/* ===== AUTO-GENERATED: HEADER START (nicht manuell bearbeiten - wird beim Speichern im Template-Editor überschrieben) ===== */
.header {
    background-color: transparent;
    padding: 30px 0 2em 0;
}

.header-flex {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.logo-wrapper {
    display: inline-block;
    width: max-content;
    height: auto;
    margin: 0 auto;
    padding: 0;
    cursor: pointer;
}

.main-logo {
    width: 100%;
    max-width: 240px;
    height: 60px;
    display: block;
    transition: transform 0.2s ease;
}

.main-logo:hover {
    transform: scale(1.02);
}

@media (min-width: 768px) {
    .header {
        padding: 40px 0 4em 0;
    }
    .main-logo {
        max-width: 400px;
        height: 100px;
    }
}
/* ===== AUTO-GENERATED: HEADER END ===== */

/* 4. MAIN INHALT (Vollständig starr von oben aufgebaut, kein align-items: center mehr) */
.main-content {
    flex: 1;
    display: flex;
    justify-content: center;
    padding: 20px 0 40px 0;
}

.center-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 15px;
}

/* H1-Titel */
.page-main-title {
    font-family: "BN Dime Display", "Urbanist", serif;
    font-size: 44px;
    font-weight: normal;
    text-transform: uppercase;
    color: #111111;
    text-align: center;
    line-height: 1.0;
    letter-spacing: 0;
    margin-bottom: 10px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.title-line {
    display: block;
    text-align: center;
}

/* ===== AUTO-GENERATED: LANG_SELECTOR START (nicht manuell bearbeiten - wird beim Speichern im Template-Editor überschrieben) ===== */
.language-selector {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
    margin: 25px 0;
}

.selector-title {
    font-size: 13px;
    font-weight: 700;
    color: #111111;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out;
}

.selector-title.fade-out {
    opacity: 0;
}

.selector-title.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.flag-list {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

.flag-btn {
    background: none;
    border: 2px solid #111111;
    padding: 3px;
    cursor: pointer;
    border-radius: 0px;
    box-shadow: 0px 3px 0px #111111;
    background-color: #ffffff;
    transition: transform 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.flag-btn img {
    width: 44px;
    height: 28px;
    object-fit: cover;
    display: block;
    border-radius: 0px;
}

.flag-btn:hover {
    transform: translateY(-4px);
    box-shadow: 0px 7px 0px #111111;
}

.flag-btn.active {
    background-color: #ffffff;
    transform: translateY(2px);
    box-shadow: 0px 1px 0px #111111;
}

@media (min-width: 768px) {
    .language-selector {
        margin: 35px 0;
    }
    .flag-btn img {
        width: 54px;
        height: 34px;
    }
}
/* ===== AUTO-GENERATED: LANG_SELECTOR END ===== */

/* ===== AUTO-GENERATED: CONTENT START (nicht manuell bearbeiten - wird beim Speichern im Template-Editor überschrieben) ===== */
.content-box {
    border: 28px solid #E60012;
    border-radius: 0px;
    padding: 35px 20px;
    width: 100%;
    text-align: center;
    box-shadow: none;
    background-color: transparent;
    font-size: 1.3rem;
}

.content-box h2 {
    font-family: 'BN Dime Display', 'Urbanist', sans-serif;
    font-weight: 400;
    font-size: 1.6rem;
    line-height: 1.3;
    margin-bottom: 12px;
    color: #111111;
}

.content-box.poll-box {
    padding: 24px;
}

.subtitle {
    text-align: center;
    margin-bottom: 20px;
    font-weight: 400;
    font-size: 1.3rem;
    line-height: 1.1;
}

.announcement-text {
    font-family: 'BN Dime Display', 'Urbanist', sans-serif;
    font-size: 24px;
    font-weight: normal;
    text-transform: uppercase;
    color: #111111;
    margin-bottom: 24px;
    letter-spacing: 0px;
    line-height: 1.2;
    min-height: 58px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.announcement-text.text-error {
    color: #ef4444;
}

.announcement-text.poll-title {
    font-size: 1.5rem;
    margin-bottom: 8px;
    line-height: 1.3;
}

.countdown-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.countdown-item {
    background: rgb(255, 255, 247);
    border: 2px solid #111111;
    border-radius: 0px;
    padding: 12px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 2px 2px 0px #111111;
}

.countdown-value {
    font-family: 'BN Dime Display', 'Urbanist', sans-serif;
    font-size: 32px;
    font-weight: normal;
    color: #111111;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.countdown-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: #111111;
    margin-top: 6px;
    letter-spacing: 0.5px;
}

@media (min-width: 768px) {
    .content-box {
        max-width: 700px;
        padding: 50px 40px;
        border: 36px solid #E60012;
    }
    .announcement-text {
        font-size: 36px;
        min-height: 86px;
    }
    .countdown-value {
        font-size: 52px;
    }
    .countdown-label {
        font-size: 13px;
    }
}
/* ===== AUTO-GENERATED: CONTENT END ===== */

/* ===== AUTO-GENERATED: FOOTER START (nicht manuell bearbeiten - wird beim Speichern im Template-Editor überschrieben) ===== */
.footer {
    background-color: transparent;
    padding: 35px 0;
    margin-top: auto;
    margin-bottom: 0;
    text-align: center;
    font-size: 14px;
    font-weight: 700;
    color: #111111;
}

@media (min-width: 768px) {
    .footer {
        padding: 35px 0;
    }
}
/* ===== AUTO-GENERATED: FOOTER END ===== */

/* 6. MEDIA QUERIES (DESKTOP) */
/* Hinweis: .container/max-width, body/font-size, .header/.main-logo werden
   jetzt in den AUTO-GENERATED-Blöcken oben gesetzt, daher hier entfernt. */
@media (min-width: 768px) {
    .center-wrapper {
        gap: 20px;
    }

    .page-main-title {
        font-size: 88px; 
        letter-spacing: 0;
        margin-bottom: 15px;
    }
}
/* 7. RECHTECKIGER WORKAROUND ENTFERNT -> ORIGINAL MANGA ISSHO BUTTON STYLE */
.manga-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: "BN Dime Display", "Urbanist", serif;
    font-size: 18px;
    font-weight: normal;
    font-style: italic; /* Schräg gestellt wie im Original */
    color: #ffffff;
    text-transform: uppercase;
    text-decoration: none;
    background-color: #E60012; /* Roter Hintergrund */
    border: none;
    border-radius: 50px; /* Stark abgerundeter Button */
    padding: 14px 40px;
    margin-top: 25px;
    box-shadow: none; /* Kein fetter Blockschatten im Original an dieser Stelle */
    cursor: pointer;
    transition: background-color 0.2s ease-in-out, transform 0.1s ease;
}

/* Mouseover-Effekt: Wechselt zu komplett schwarzem Hintergrund */
.manga-action-btn:hover {
    background-color: #111111; 
    color: #ffffff;
}

/* Minimales haptisches Feedback beim Klicken */
.manga-action-btn:active {
    transform: scale(0.98);
}

@media (min-width: 768px) {
    .manga-action-btn {
        font-size: 24px;
        padding: 16px 54px;
        margin-top: 30px;
    }
}

/* ============================================================================
   TEIL 2: ABSTIMMUNGS-SPEZIFISCHE STYLES (vormals vote-style.css)
   Mobile-First CSS für die Online-Abstimmung
   ============================================================================ */

.poll-container { 
    background: #ffffff; 
    width: 100%; 
    max-width: 500px; 
    padding: 24px; 
    border-radius: 20px; 
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.05); 
}

/* Sprachwähler */
.lang-switch { 
    display: flex; 
    justify-content: flex-end; 
    gap: 8px; 
    margin-bottom: 16px; 
    font-size: 0.85rem; 
}

.lang-switch a { 
    text-decoration: none; 
    color: #64748b; 
    padding: 4px 8px; 
    border-radius: 4px; 
}

.lang-switch a.active { 
    font-weight: bold; 
    color: #0284c7; 
    background: #e0f2fe; 
}

h1 { 
    font-size: 1.4rem; 
    font-weight: 700; 
    margin-bottom: 6px; 
    text-align: center; 
}

/* Mobile-First Grid Layout (Einspaltig) */
.options-grid { 
    display: grid; 
    grid-template-columns: 1fr; 
    gap: 10px; 
    margin-bottom: 24px; 
}

.option-card { 
    position: relative; 
    border: 2px solid #e2e8f0; 
    border-radius: 14px; 
    overflow: hidden; 
    cursor: pointer; 
    transition: all 0.2s ease-in-out; 
    background: #fff; 
    display: flex; 
    flex-direction: column; 
}

.option-card img { 
    width: 100%; 
    aspect-ratio: 1 / 1; 
    object-fit: contain; 
    background-color: transparent;
    pointer-events: none; 
    padding: 8px;
}

.option-text { 
    padding: 12px; 
    font-weight: 600; 
    font-size: 0.95rem; 
    text-align: center; 
    pointer-events: none; 
}

/* Verstecktes Input-Element für natives Handling */
.option-card input[type="radio"] { 
    position: absolute; 
    top: 12px; 
    right: 12px; 
    width: 22px; 
    height: 22px; 
    accent-color: #0284c7; 
    cursor: pointer; 
}

.option-card.selected { 
    border-color: #0284c7; 
    background-color: #f0f9ff; 
}

.btn-submit { 
    display: block;
    margin: 24px auto 0 auto;    
    width: auto;
    min-width: 190px;
    max-width: 85%;
    padding: 16px 32px; 
    background-color: rgb(237, 28, 36); 
    color: #ffffff; 
    border: none; 
    border-radius: 8px; 
    font-size: 1.05rem; 
    font-weight: 700; 
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer; 
    transition: background-color 0.2s ease-in-out, transform 0.1s ease; 
}
.btn-submit:hover { 
    background-color: #000000; 
    color: #ffffff;
}
.btn-submit:active {
    transform: scale(0.98);
}
.btn-submit:disabled { 
    background-color: #cbd5e1; 
    color: #64748b;
    cursor: not-allowed; 
}

/* Infoboxen */
.alert { 
    padding: 14px; 
    border-radius: 10px; 
    text-align: center; 
    font-weight: 600; 
    margin-bottom: 20px; 
    font-size: 0.9rem; 
}

.alert-info { 
    background: #f1f5f9; 
    color: #475569; 
}

.alert-error { 
    background: #fef2f2; 
    color: #b91c1c; 
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-weight: bold;
}

/* Desktop-Ansicht ab 600px Breite (Zweispaltig) */
@media (min-width: 600px) {
    .options-grid { 
        grid-template-columns: 1fr 1fr; 
    }

    /* Varianten je nach Anzahl der Antwort-Optionen dieser Umfrage.
       index.php setzt die passende Klasse dynamisch anhand von count($options)
       (reine Logik, keine Style-Werte mehr im PHP-Code). */
    .options-grid.cols-3 { grid-template-columns: repeat(3, 1fr); gap: 16px; }
    .options-grid.cols-4plus { grid-template-columns: 1fr 1fr; gap: 16px; }
    .poll-container.cols-3 { max-width: 750px; }
    .poll-container.cols-4plus { max-width: 600px; }
}
/* --- 3. FLEXIBLE UND FORM-SCHÖNE TEXT-KACHELN --- */
.option-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 120px;
    background: #ffffff;
    transition: all 0.2s ease-in-out;
}

.option-card:not(:has(img)) .option-text {
    padding: 24px 16px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-grow: 1;
    width: 100%;
}
