/* =========================================================
   Audioguide Vienna – Stylesheet
   ========================================================= */

:root {
    --color-primary: #8a1f2d;
    --color-primary-dark: #6b1822;
    --color-accent: #c8a96a;
    --color-text: #1f2933;
    --color-text-soft: #52606d;
    --color-bg: #ffffff;
    --color-bg-alt: #f6f4ef;
    --color-border: #e3e0d8;
    --color-success: #1f7a4d;
    --color-error: #b3261e;

    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

    --radius: 6px;
    --shadow-sm: 0 1px 2px rgba(31, 41, 51, 0.06);
    --shadow-md: 0 6px 24px rgba(31, 41, 51, 0.08);

    --max-width: 1140px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font-sans);
    color: var(--color-text);
    line-height: 1.6;
    background: var(--color-bg);
    -webkit-font-smoothing: antialiased;
}

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

a {
    color: var(--color-primary);
    text-decoration: none;
}
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
    font-weight: 600;
    line-height: 1.25;
    color: var(--color-text);
    margin: 0 0 0.6em;
}
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); margin-top: 0; }
h3 { font-size: 1.15rem; }

p { margin: 0 0 1em; }

hr {
    border: 0;
    border-top: 1px solid var(--color-border);
    margin: 2.5rem 0;
}

/* Layout */
.container {
    width: 100%;
    max-width: var(--max-width);
    padding: 0 1.25rem;
    margin: 0 auto;
}
.container.narrow { max-width: 780px; }

.section { padding: 4rem 0; }
.section-alt { background: var(--color-bg-alt); }

.text-center { text-align: center; }
.subtle { color: var(--color-text-soft); }

/* Header */
.site-header {
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    z-index: 50;
    box-shadow: var(--shadow-sm);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}
.logo {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--color-text);
    font-weight: 600;
}
.logo:hover { text-decoration: none; }
.logo-mark {
    background: var(--color-primary);
    color: #fff;
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: var(--radius);
    font-weight: 700;
    letter-spacing: 0.5px;
    font-size: 0.95rem;
}
.logo-text { font-size: 1.05rem; }

.main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 1.75rem;
}
.main-nav a {
    color: var(--color-text);
    font-weight: 500;
    padding: 0.4rem 0;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
}
.main-nav a:hover { color: var(--color-primary); text-decoration: none; }
.main-nav a.active {
    color: var(--color-primary);
    border-bottom-color: var(--color-primary);
}

.nav-toggle {
    display: none;
    background: none;
    border: 0;
    width: 40px;
    height: 40px;
    cursor: pointer;
    padding: 8px;
}
.nav-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--color-text);
    margin: 5px 0;
}

/* Hero */
.hero {
    background:
        linear-gradient(135deg, rgba(138, 31, 45, 0.9) 0%, rgba(50, 14, 22, 0.85) 100%),
        url("https://images.unsplash.com/photo-1516550893923-42d28e5677af?auto=format&fit=crop&w=1600&q=70") center/cover;
    color: #fff;
    padding: 5.5rem 0;
}
.hero h1 { color: #fff; }
.hero-content { max-width: 720px; }
.eyebrow {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
    color: var(--color-accent);
    margin: 0 0 0.5rem;
    font-weight: 600;
}
.hero-lead {
    font-size: 1.15rem;
    color: rgba(255, 255, 255, 0.92);
    margin-bottom: 2rem;
}

.page-hero {
    background: var(--color-bg-alt);
    padding: 3rem 0;
    border-bottom: 1px solid var(--color-border);
}
.page-hero h1 { margin-bottom: 0.3rem; }
.page-hero p { color: var(--color-text-soft); margin: 0; }

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.85rem 1.6rem;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    border: 0;
    transition: background 0.15s, transform 0.1s;
    text-align: center;
}
.btn-primary {
    background: var(--color-primary);
    color: #fff;
}
.btn-primary:hover {
    background: var(--color-primary-dark);
    text-decoration: none;
    transform: translateY(-1px);
}
.btn-block { width: 100%; }

/* Cards */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}
.card {
    background: #fff;
    padding: 1.75rem 1.5rem;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-sm);
    transition: transform 0.15s, box-shadow 0.15s;
}
.card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.card-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}
.card h3 { margin-bottom: 0.5rem; }
.card p { color: var(--color-text-soft); margin: 0; font-size: 0.95rem; }

/* Vorteile */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem 2rem;
    margin-top: 2rem;
}
.benefit {
    padding: 1.25rem 0;
    border-top: 3px solid var(--color-primary);
}
.benefit h3 {
    margin-bottom: 0.4rem;
    font-size: 1.05rem;
}
.benefit p { color: var(--color-text-soft); margin: 0; font-size: 0.95rem; }

/* Steps */
.steps {
    list-style: none;
    counter-reset: step;
    padding: 0;
    margin: 2rem 0 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
}
.steps li {
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 1.5rem 1.25rem 1.25rem;
    counter-increment: step;
}
.steps li::before {
    content: counter(step);
    background: var(--color-primary);
    color: #fff;
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

/* ===========================================
   FORM - Erweitert mit Fieldsets, Select, Radio
   =========================================== */
.form {
    margin-top: 2rem;
    background: #fff;
    padding: 2rem;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-sm);
}

/* Fieldset / Sections */
.form-section {
    border: 0;
    padding: 0;
    margin: 0 0 2rem;
    border-top: 1px solid var(--color-border);
    padding-top: 1.5rem;
}
.form-section:first-of-type {
    border-top: 0;
    padding-top: 0;
}
.form-section legend {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding: 0;
    margin-bottom: 1.25rem;
    width: auto;
}

/* Form rows & fields */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}
.form-field {
    margin-bottom: 1.25rem;
}
.form-field:last-child {
    margin-bottom: 0;
}
.form-row .form-field {
    margin-bottom: 0;
}

.form-field label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.4rem;
    font-size: 0.95rem;
}

/* Inputs, Selects, Textareas */
.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    padding: 0.7rem 0.85rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font: inherit;
    background: #fff;
    color: var(--color-text);
    transition: border-color 0.15s, box-shadow 0.15s;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    outline: 0;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(138, 31, 45, 0.12);
}
.form-field input.invalid,
.form-field select.invalid,
.form-field textarea.invalid {
    border-color: var(--color-error);
    box-shadow: 0 0 0 3px rgba(179, 38, 30, 0.12);
}

/* Select Caret */
.form-field select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23666' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
    cursor: pointer;
}

.req { color: var(--color-primary); }

/* Radio Buttons */
.radio-group {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-top: 0.3rem;
}
.radio-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.95rem;
    padding: 0.5rem 0.85rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    background: var(--color-bg-alt);
    transition: border-color 0.15s, background 0.15s;
    flex: 1;
    min-width: 200px;
}
.radio-label:hover {
    border-color: var(--color-primary);
}
.radio-label input[type="radio"] {
    width: auto;
    margin: 0;
    accent-color: var(--color-primary);
}
.radio-label input[type="radio"]:checked + span {
    color: var(--color-primary);
    font-weight: 600;
}
.radio-label:has(input:checked) {
    background: rgba(138, 31, 45, 0.05);
    border-color: var(--color-primary);
}

/* Checkbox */
.checkbox-field {
    margin: 1.5rem 0;
    background: var(--color-bg-alt);
    padding: 1rem;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
}
.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.95rem;
    cursor: pointer;
    margin: 0;
    font-weight: normal;
}
.checkbox-label input[type="checkbox"] {
    width: auto;
    margin-top: 0.25rem;
    flex-shrink: 0;
    accent-color: var(--color-primary);
}

/* Honeypot */
.hp-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* Form Messages */
.form-message {
    margin-top: 1rem;
    padding: 1rem 1.25rem;
    border-radius: var(--radius);
    display: none;
    font-weight: 500;
    line-height: 1.5;
}
.form-message.show { display: block; }
.form-message.success {
    background: #e8f5ee;
    color: var(--color-success);
    border: 1px solid #b8e0c8;
}
.form-message.error {
    background: #fdecea;
    color: var(--color-error);
    border: 1px solid #f5c2bd;
}

/* Kontakt */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}
.contact-block {
    background: var(--color-bg-alt);
    padding: 1.5rem;
    border-radius: var(--radius);
    border-left: 3px solid var(--color-primary);
}
.contact-block h3 {
    margin-bottom: 0.5rem;
    font-size: 1rem;
    color: var(--color-primary);
}
.contact-block p { margin: 0; }

.cta-box {
    margin-top: 3rem;
    padding: 2rem;
    background: var(--color-primary);
    color: #fff;
    border-radius: var(--radius);
    text-align: center;
}
.cta-box h3 { color: #fff; margin-bottom: 0.5rem; }
.cta-box p { color: rgba(255, 255, 255, 0.9); margin-bottom: 1.5rem; }
.cta-box .btn-primary {
    background: #fff;
    color: var(--color-primary);
}
.cta-box .btn-primary:hover { background: var(--color-bg-alt); }

/* Legal */
.legal-text h2 {
    margin-top: 2.5rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid var(--color-border);
}
.legal-text h3 { margin-top: 1.5rem; }

/* Footer */
.site-footer {
    background: #1f2933;
    color: #cbd2d9;
    padding: 3rem 0 1.5rem;
    margin-top: 2rem;
}
.site-footer h4 {
    color: #fff;
    margin-bottom: 0.75rem;
    font-size: 1rem;
}
.site-footer a { color: #e8b87a; }
.site-footer a:hover { color: #fff; }

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
}
.footer-links {
    list-style: none;
    margin: 0;
    padding: 0;
}
.footer-links li { margin-bottom: 0.4rem; }

.copyright {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #3e4c59;
    text-align: center;
    font-size: 0.85rem;
    color: #9aa5b1;
}

/* Time-Pair: Stunde + Minute Selects */
.time-pair {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.time-pair select {
    flex: 1;
    min-width: 0;
}
.time-pair .time-sep {
    font-weight: 600;
    color: var(--color-text-soft);
    font-size: 1.2rem;
}

/* Lieferadresse Box - öffnet sich animiert wenn "Lieferung" gewählt */
.lieferadresse-box {
    margin-top: 1.25rem;
    padding: 1.25rem;
    background: rgba(138, 31, 45, 0.04);
    border: 1px solid rgba(138, 31, 45, 0.2);
    border-radius: var(--radius);
    animation: slideDown 0.25s ease-out;
}
.lieferadresse-box.is-hidden,
.lieferadresse-box[hidden] {
    display: none !important;
}
.lieferadresse-title {
    margin: 0 0 1rem;
    font-size: 0.9rem;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}
.lieferadresse-hint {
    margin: 0.75rem 0 0;
    padding: 0.75rem 1rem;
    background: rgba(200, 169, 106, 0.15);
    border-left: 3px solid var(--color-accent);
    border-radius: 4px;
    font-size: 0.85rem;
    color: var(--color-text-soft);
    line-height: 1.5;
}
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .nav-toggle { display: block; }
    .main-nav ul {
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: #fff;
        flex-direction: column;
        gap: 0;
        padding: 0.5rem 0;
        border-bottom: 1px solid var(--color-border);
        box-shadow: var(--shadow-md);
        display: none;
    }
    .main-nav.open ul { display: flex; }
    .main-nav li { width: 100%; }
    .main-nav a {
        display: block;
        padding: 0.85rem 1.25rem;
        border-bottom: 1px solid var(--color-border);
    }
    .main-nav a.active { border-bottom-color: var(--color-border); }

    .hero { padding: 4rem 0; }
    .section { padding: 3rem 0; }

    .form { padding: 1.25rem; }
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
        margin-bottom: 0;
    }
    .form-row .form-field {
        margin-bottom: 1.25rem;
    }

    .radio-group {
        flex-direction: column;
        gap: 0.75rem;
    }
    .radio-label {
        min-width: 0;
    }
}

/* =====================================================
   COOKIE BANNER (DSGVO/AVG-konform)
   ===================================================== */
.cookie-banner {
    position: fixed;
    bottom: 1rem;
    left: 1rem;
    right: 1rem;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(31, 41, 51, 0.18);
    padding: 1.5rem;
    z-index: 9999;
    animation: cookieSlideUp 0.3s ease-out;
}
.cookie-banner[hidden] { display: none; }
.cookie-banner.is-hidden { display: none; }

@keyframes cookieSlideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.cookie-banner h3 {
    margin: 0 0 0.5rem;
    color: var(--color-primary);
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.cookie-banner p {
    margin: 0 0 1.2rem;
    font-size: 0.9rem;
    color: var(--color-text-soft);
    line-height: 1.5;
}
.cookie-banner p a {
    color: var(--color-primary);
    text-decoration: underline;
}
.cookie-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.cookie-actions .btn {
    flex: 1;
    min-width: 120px;
    padding: 0.65rem 1rem;
    font-size: 0.9rem;
}
.cookie-btn-secondary {
    background: #fff;
    color: var(--color-text);
    border: 1px solid var(--color-border);
}
.cookie-btn-secondary:hover {
    background: var(--color-bg-alt);
    border-color: var(--color-text-soft);
}

/* Settings Panel */
.cookie-settings {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
    display: none;
}
.cookie-settings.is-visible { display: block; }
.cookie-category {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
}
.cookie-category:last-child { border-bottom: 0; }
.cookie-category-info strong {
    display: block;
    font-size: 0.9rem;
    color: var(--color-text);
    margin-bottom: 0.2rem;
}
.cookie-category-info span {
    font-size: 0.82rem;
    color: var(--color-text-soft);
}
.cookie-toggle {
    flex-shrink: 0;
}
.cookie-toggle input { margin: 0; transform: scale(1.2); }
.cookie-toggle.disabled {
    opacity: 0.5;
    pointer-events: none;
}

@media (max-width: 480px) {
    .cookie-banner {
        bottom: 0;
        left: 0;
        right: 0;
        border-radius: 12px 12px 0 0;
        max-width: 100%;
    }
    .cookie-actions .btn {
        flex: 0 0 100%;
        min-width: 0;
    }
}
