/**
 * File: chronik.css
 *
 * CHRONIK SNAKE TIMELINE
 * Styles for the Bendorf Carnival timeline exhibition.
 *
 * @package     KuK Bendorf Theme
 * @author      Oliver Ferber <admin@kuk-bendorf.de>
 * @copyright   2024-2026 KuK Bendorf e.V.
 * @license     Proprietary
 * @version     1.0.0
 */

/*
 * Chronik-Schriften (Playfair Display, Great Vibes) werden über PHP
 * consent-gesteuert eingebunden — siehe functions.php, is_page('chronik').
 * Ohne Einwilligung greift der Fallback: serif / cursive.
 */

:root {
    --c-primary: var(--kuk-red);
    /* KuK Genuine Red - references main.css */
    --c-gold: #D4AF37;
    --c-white: #ffffff;
    --c-parchment: #fffdf5;
    --c-text: #2c2c2c;
}

.chronik-page-snake {
    background-color: #f8f5f2;
    background-image:
        radial-gradient(var(--c-gold) 1px, transparent 1px),
        radial-gradient(var(--c-primary) 1px, transparent 1px);
    background-size: 50px 50px;
    background-position: 0 0, 25px 25px;
    font-family: 'Playfair Display', serif;
    overflow-x: hidden;
}

/* ---- Hero Section (Elegant & Traditional) ---- */
.snake-hero {
    position: relative;
    padding: 140px 20px 100px;
    text-align: center;
    background: linear-gradient(135deg, #a00000 0%, #d00000 100%);
    /* Deep Red Gradient */
    color: var(--c-white);
    overflow: hidden;
    border-bottom: 6px solid var(--c-gold);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.snake-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Subtle elegant pattern */
    background-image: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0.2) 100%);
}

@keyframes rotateBg {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.snake-hero-title {
    font-family: 'Great Vibes', cursive;
    /* Elegant Script */
    font-weight: 400;
    font-size: 6rem;
    /* Hero size but elegant */
    margin: 0;
    color: var(--c-white);
    text-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    /* Subtle shadow, no 3D */
    line-height: 1.1;
    position: relative;
    z-index: 2;
    letter-spacing: 1px;
    transform: rotate(-2deg);
    /* Slightly dynamic/handwritten feel */
}

.snake-hero-subtitle {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: var(--c-gold);
    margin: 10px 0 30px;
    font-weight: 400;
    position: relative;
    z-index: 2;
    text-transform: uppercase;
    letter-spacing: 3px;
    opacity: 0.9;
}

.snake-hero-divider {
    font-size: 2rem;
    color: var(--c-gold);
    display: inline-block;
    z-index: 2;
    opacity: 0.8;
}


/* ---- Timeline Section ---- */
.snake-timeline-section {
    position: relative;
    padding: 80px 0 120px;
    overflow: hidden;
}

.snake-container {
    position: relative;
    max-width: 1100px;
    margin: 0 auto;
}

/* 
   THE SNAKE PATH 
   "Luftschlange" (Streamer) Style - Ribbon-like
*/
.snake-track {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 240px;
    /* Wide swing */
    /* A ribbon-like curve using alternating colors/dashes isn't easy with single path.
       We'll use a double-stroked path to look like a thick ribbon. */
    background-image: url("data:image/svg+xml,%3Csvg width='240' height='400' viewBox='0 0 240 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M120 0 C 240 100, 240 100, 120 200 C 0 300, 0 300, 120 400' fill='none' stroke='%23F20F0F' stroke-width='4' stroke-opacity='0.3' /%3E%3Cpath d='M120 0 C 240 100, 240 100, 120 200 C 0 300, 0 300, 120 400' fill='none' stroke='%23d4af37' stroke-width='2' stroke-dasharray='10,15' stroke-opacity='0.6' /%3E%3C/svg%3E");
    background-repeat: repeat-y;
    z-index: 0;
}

/* No overlay for this style, cleaner */
.snake-track::after {
    display: none;
}


/* ---- Entry Layout ---- */
.snake-entry {
    position: relative;
    min-height: 220px;
    /* More space */
    margin-bottom: 0;
    /* Continuous flow */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px 0;
}

/* Markers - Carnival Medals */
.snake-marker {
    width: 60px;
    height: 60px;
    background: radial-gradient(circle at 30% 30%, #ffd700, #b8860b);
    border: 3px solid #fff;
    border-radius: 50%;
    /* Medal shape */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #8b0000;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    box-shadow:
        0 0 0 5px rgba(242, 15, 15, 0.2),
        0 4px 10px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.snake-entry:hover .snake-marker {
    transform: translateX(-50%) scale(1.2) rotate(15deg);
}

/* BIGGER YEARS - Elegant Style */
.snake-year {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: -35px;
    /* Transparent badge style */
    background: rgba(255, 255, 255, 0.9);
    color: var(--c-primary);
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    /* Extra Bold */
    font-size: 2.2rem;
    /* Big and Bold */
    padding: 0 15px;
    border-radius: 50px;
    z-index: 11;
    white-space: nowrap;
    border: 2px solid var(--c-gold);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    text-shadow: none;
    /* Clean */
}


/* ---- Card Layout ---- */
.snake-card {
    width: 40%;
    position: relative;
    z-index: 2;
}

/* 
   Card positioning to match the snake swing.
   We need to alternate proximity to center.
*/

.snake-left {
    justify-content: flex-start;
}

.snake-left .snake-card {
    margin-left: auto;
    margin-right: 60%;
    /* Push further left for wide track */
    text-align: left;
}

.snake-right {
    justify-content: flex-end;
}

.snake-right .snake-card {
    margin-right: auto;
    margin-left: 60%;
    /* Push further right */
    text-align: left;
}


/* ---- Parchment/Festschrift Card Style ---- */
.snake-card-inner {
    background: #fff;
    padding: 25px;
    border: 1px solid #eee;
    box-shadow:
        0 10px 30px rgba(0, 0, 0, 0.08),
        0 1px 3px rgba(0, 0, 0, 0.05);
    /* Modern clean shadow */
    position: relative;
    border-radius: 8px;
    /* Softer corners */
    border-top: 4px solid var(--c-primary);
    /* Red top border */
    transform: none;
    /* No rotation */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Straighten on hover */
.snake-card:hover .snake-card-inner {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.12);
}

.snake-right .snake-card-inner {
    transform: rotate(1deg);
}

/* Gold border inset */
.snake-card-inner::after {
    display: none;
}

/* Card Media */
.snake-card-media {
    margin: -25px -25px 20px -25px;
    overflow: hidden;
    position: relative;
    border-bottom: 2px solid var(--c-gold);
}

.snake-card-media img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: transform 0.6s ease;
    /* No sepia - vibrant carnival colors! */
}

.snake-card:hover .snake-card-media img {
    transform: scale(1.05);
}

/* Typography */
.snake-card h3 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--c-primary);
    /* KuK Red */
    margin: 0 0 10px;
    letter-spacing: 0.5px;
    line-height: 1.2;
    border: none;
    padding: 0;
}

.snake-date {
    display: block;
    font-family: 'Playfair Display', serif;
    font-size: 1rem;
    color: var(--c-gold);
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 5px;
    letter-spacing: 1px;
}

.snake-text {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.95rem;
    color: #444;
    line-height: 1.65;
}

/* Connectors */
.snake-card::before {
    content: '';
    position: absolute;
    top: 30px;
    /* Align with top part of card */
    height: 2px;
    width: 100px;
    background: repeating-linear-gradient(90deg, var(--c-primary) 0, var(--c-primary) 5px, transparent 5px, transparent 10px);
    /* Dotted line */
}

.snake-left .snake-card::before {
    left: 100%;
    margin-left: 10px;
}

.snake-right .snake-card::before {
    right: 100%;
    margin-right: 10px;
}


/* ---- Scroll Reveal ---- */
.snake-reveal {
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.snake-left.snake-reveal {
    transform: translateX(-50px) rotate(-2deg);
}

.snake-right.snake-reveal {
    transform: translateX(50px) rotate(2deg);
}

.snake-reveal.visible {
    opacity: 1;
    transform: translateX(0) rotate(0);
}


/* ---- Responsive ---- */
@media (max-width: 900px) {
    .snake-hero-title {
        font-size: 3rem;
    }

    .snake-track {
        left: 30px;
        width: 40px;
        background-image: url("data:image/svg+xml,%3Csvg width='40' height='200' viewBox='0 0 40 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 0 L20 200' fill='none' stroke='%23d4af37' stroke-width='3' /%3E%3C/svg%3E");
    }

    .snake-track::after {
        display: none;
    }

    .snake-entry {
        flex-direction: column !important;
        align-items: flex-start;
        padding-left: 60px;
        margin-bottom: 40px;
        min-height: auto;
    }

    .snake-marker {
        left: 30px;
        transform: translateX(-50%) !important;
        top: 0;
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .snake-year {
        left: 30px;
        top: 35px;
        bottom: auto;
        font-size: 1.1rem;
        padding: 4px 10px;
        position: absolute;
        transform: translateX(-50%);
        margin: 0;
        display: block;
    }

    .snake-card {
        width: 100%;
        margin: 30px 0 0 0 !important;
    }

    .snake-card-inner {
        padding: 15px;
    }

    .snake-card-media {
        margin: -15px -15px 15px -15px;
    }

    .snake-card-media img {
        height: 180px;
    }

    .snake-card h3 {
        font-size: 1.25rem;
    }

    .snake-card::before {
        display: none;
    }
}