/* Történelem oldal dedikált stílusok */

/* Timeline Section - Modern, reszponzív design */
.timeline-section {
    padding: 6rem 0;
    background: var(--timeline-bg-start);
    position: relative;
    overflow: hidden;
    transition: background 0.5s ease;
}

.timeline-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(244, 208, 63, 0.03) 0%, 
        rgba(243, 156, 18, 0.02) 100%);
    pointer-events: none;
    z-index: 1;
}

.timeline-section .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 2;
}

.timeline-section .section-header {
    text-align: center;
    margin-bottom: 5rem;
    position: relative;
}

.timeline-section .section-header h2 {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--timeline-title-color);
    margin-bottom: 1.5rem;
    font-family: 'Nunito', sans-serif;
    background: linear-gradient(135deg, var(--timeline-gradient-start), var(--timeline-gradient-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 4px 20px var(--timeline-title-shadow);
    transition: color 0.5s ease;
}

.timeline-section .section-header p {
    font-size: 1.3rem;
    color: var(--timeline-subtitle-color);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.7;
    font-family: 'Nunito', sans-serif;
    transition: color 0.5s ease;
}

/* Timeline konténer */
.timeline-container {
    position: relative;
    max-width: 100%;
    margin: 0 auto;
    padding: 2rem 0;
}

/* Központi vonal */
.timeline {
    position: relative;
    padding: 2rem 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, 
        var(--timeline-line-start) 0%, 
        var(--timeline-line-mid1) 25%, 
        var(--timeline-line-mid2) 50%, 
        var(--timeline-line-mid3) 75%, 
        var(--timeline-line-end) 100%);
    transform: translateX(-50%);
    border-radius: 2px;
    box-shadow: 
        0 0 20px var(--timeline-line-shadow),
        0 0 40px var(--timeline-line-shadow-light);
    z-index: 1;
    transition: background 0.5s ease;
}

/* Timeline elemek */
.timeline-item {
    position: relative;
    margin-bottom: 4rem;
    display: flex;
    align-items: center;
    min-height: 200px;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

/* Páratlan elemek - Bal oldal */
.timeline-item:nth-child(odd) {
    flex-direction: row;
    padding-right: 50%;
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-right: 3rem;
    text-align: right;
}

/* Páros elemek - Jobb oldal */
.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
    padding-left: 50%;
}

.timeline-item:nth-child(even) .timeline-content {
    margin-left: 3rem;
    text-align: left;
}

/* Timeline marker (pont és vonal) */
.timeline-marker {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timeline-dot {
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, var(--timeline-date-bg-start), var(--timeline-date-bg-end));
    border: 4px solid var(--timeline-date-border);
    border-radius: 50%;
    box-shadow: 
        0 4px 15px var(--timeline-date-shadow),
        0 8px 25px var(--timeline-date-shadow-light);
    transition: all 0.4s ease;
    z-index: 11;
}

.timeline-line {
    width: 2px;
    height: 60px;
    background: linear-gradient(180deg, 
        var(--timeline-line-start) 0%, 
        var(--timeline-line-mid1) 50%, 
        var(--timeline-line-end) 100%);
    margin-top: 10px;
    border-radius: 1px;
    transition: all 0.4s ease;
}

/* Timeline tartalom */
.timeline-content {
    flex: 1;
    max-width: 480px;
    position: relative;
}

.timeline-date {
    background: linear-gradient(135deg, var(--timeline-date-bg-start), var(--timeline-date-bg-end));
    color: var(--timeline-date-text);
    padding: 0.8rem 1.2rem;
    border-radius: 25px;
    font-weight: 700;
    font-size: 0.85rem;
    white-space: nowrap;
    box-shadow: 
        0 4px 15px var(--timeline-date-shadow),
        0 8px 25px var(--timeline-date-shadow-light);
    border: 3px solid var(--timeline-date-border);
    transition: all 0.4s ease;
    display: inline-block;
    margin-bottom: 1.5rem;
}

/* Timeline kártya */
.timeline-card {
    background: linear-gradient(135deg, var(--timeline-card-bg-start) 0%, var(--timeline-card-bg-end) 100%);
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 
        0 10px 40px var(--timeline-card-shadow),
        0 20px 80px var(--timeline-card-shadow-light);
    border: 2px solid transparent;
    transition: all 0.5s ease;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

/* Felső sáv a kártyákon */
.timeline-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--timeline-card-accent-start), var(--timeline-card-accent-end));
    transform: scaleX(0);
    transition: transform 0.5s ease;
}

/* Hover effekt a kártyákra */
.timeline-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 
        0 25px 80px var(--timeline-card-shadow-hover),
        0 40px 120px var(--timeline-card-shadow-hover-light);
    border-color: var(--timeline-card-border-hover);
}

.timeline-card:hover::before {
    transform: scaleX(1);
}

.timeline-card:hover .timeline-dot {
    transform: scale(1.2);
    box-shadow: 
        0 8px 25px var(--timeline-date-shadow-hover),
        0 12px 35px var(--timeline-date-shadow-hover-light);
}

.timeline-card:hover .timeline-line {
    height: 80px;
    background: linear-gradient(180deg, 
        var(--timeline-line-start) 0%, 
        var(--timeline-line-mid2) 50%, 
        var(--timeline-line-end) 100%);
}

/* Címek */
.timeline-text h3 {
    color: var(--timeline-card-title);
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    font-family: 'Nunito', sans-serif;
    line-height: 1.3;
    text-shadow: 0 2px 10px var(--timeline-card-title-shadow);
    transition: color 0.5s ease;
}

/* Szövegek */
.timeline-text p {
    color: var(--timeline-card-text);
    line-height: 1.7;
    margin: 0;
    font-size: 1rem;
    text-shadow: 0 1px 5px var(--timeline-card-text-shadow);
    transition: color 0.5s ease;
}

/* Timeline képek */
.timeline-image {
    width: 100%;
    height: 200px;
    margin-bottom: 1.5rem;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 
        0 8px 25px var(--timeline-image-shadow),
        0 15px 50px var(--timeline-image-shadow-light);
    border: 2px solid var(--timeline-image-border);
    transition: all 0.5s ease;
    position: relative;
}

/* Kép overlay effekt */
.timeline-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        var(--timeline-image-overlay-start) 0%, 
        var(--timeline-image-overlay-end) 100%);
    z-index: 1;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.timeline-card:hover .timeline-image::before {
    opacity: 1;
}

.timeline-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease, filter 0.5s ease;
    filter: var(--timeline-image-filter);
}

.timeline-card:hover .timeline-image img {
    transform: scale(1.08);
    filter: var(--timeline-image-filter-hover);
}

/* Animációk */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Alap animációk */
.timeline-item {
    animation: fadeInUp 1s ease forwards;
    opacity: 0;
}

.timeline-item:nth-child(odd) {
    animation: slideInLeft 1s ease forwards;
}

.timeline-item:nth-child(even) {
    animation: slideInRight 1s ease forwards;
}

/* Késleltetések az elemekhez */
.timeline-item:nth-child(1) { animation-delay: 0.1s; }
.timeline-item:nth-child(2) { animation-delay: 0.2s; }
.timeline-item:nth-child(3) { animation-delay: 0.3s; }
.timeline-item:nth-child(4) { animation-delay: 0.4s; }
.timeline-item:nth-child(5) { animation-delay: 0.5s; }
.timeline-item:nth-child(6) { animation-delay: 0.6s; }
.timeline-item:nth-child(7) { animation-delay: 0.7s; }
.timeline-item:nth-child(8) { animation-delay: 0.8s; }
.timeline-item:nth-child(9) { animation-delay: 0.9s; }
.timeline-item:nth-child(10) { animation-delay: 1.0s; }
.timeline-item:nth-child(11) { animation-delay: 1.1s; }
.timeline-item:nth-child(12) { animation-delay: 1.2s; }

/* Reszponzív design */
@media (max-width: 1200px) {
    .timeline-item {
        padding-left: 2rem;
        padding-right: 2rem;
    }
    
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        padding-left: 2rem;
        padding-right: 2rem;
    }
    
    .timeline-item:nth-child(odd) .timeline-content,
    .timeline-item:nth-child(even) .timeline-content {
        margin: 0 0 0 4rem;
        text-align: left;
        max-width: 100%;
    }
    
    /* Tablet módban a vonal bal oldalon */
    .timeline::before {
        left: 2rem;
        transform: none;
    }
    
    .timeline-marker {
        left: 2rem;
        transform: translateX(-50%);
    }
}

@media (max-width: 768px) {
    .timeline-section {
        padding: 4rem 0;
    }
    
    .timeline-section .section-header h2 {
        font-size: 2.8rem;
    }
    
    .timeline-section .section-header p {
        font-size: 1.1rem;
    }
    
    .timeline {
        padding: 2rem 0;
    }
    
    .timeline-item {
        flex-direction: column !important;
        text-align: center;
        min-height: auto;
        padding: 0 1rem;
        margin-bottom: 3rem;
    }
    
    .timeline-item:nth-child(odd) .timeline-content,
    .timeline-item:nth-child(even) .timeline-content {
        margin: 1rem 0 0 0;
        max-width: 100%;
        text-align: center;
        padding: 2rem;
    }
    
    .timeline-marker {
        position: relative;
        left: auto;
        top: auto;
        transform: none;
        margin: 0 auto 1rem auto;
    }
    
    .timeline::before {
        display: none;
    }
    
    .timeline-line {
        display: none;
    }
}

@media (max-width: 480px) {
    .timeline-section .section-header h2 {
        font-size: 2.2rem;
    }
    
    .timeline-section .section-header p {
        font-size: 1rem;
    }
    
    .timeline-card {
        padding: 1.5rem;
    }
    
    .timeline-text h3 {
        font-size: 1.2rem;
    }
    
    .timeline-text p {
        font-size: 0.9rem;
    }
    
    .timeline-image {
        height: 150px;
    }
    
    .timeline-date {
        font-size: 0.8rem;
        padding: 0.6rem 1rem;
    }
}

/* Téma váltás animációk */
.timeline-section.theme-transitioning {
    animation: timelineThemeTransition 0.8s ease;
}

@keyframes timelineThemeTransition {
    0% {
        opacity: 0.8;
        transform: scale(0.98);
    }
    50% {
        opacity: 0.9;
        transform: scale(0.99);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Téma váltás után finom hover effektek */
.timeline-content.theme-transitioned {
    transition: all 0.4s ease;
}

.timeline-marker.theme-transitioned {
    transition: all 0.4s ease;
}

.timeline-image.theme-transitioned {
    transition: all 0.4s ease;
}

/* Téma váltás után a timeline elemek finom megjelenése */
.timeline-item.theme-transitioned {
    animation: timelineItemThemeTransition 0.6s ease forwards;
}

@keyframes timelineItemThemeTransition {
    0% {
        opacity: 0.7;
        transform: translateY(10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Téma váltás jelző a timeline szekcióban */
.timeline-theme-indicator {
    position: absolute;
    top: 1rem;
    right: 2rem;
    background: var(--timeline-card-bg-start);
    border: 2px solid var(--timeline-card-accent-start);
    border-radius: 20px;
    padding: 0.8rem 1.2rem;
    opacity: 0;
    transition: all 0.5s ease;
    z-index: 10;
    box-shadow: 0 8px 25px var(--timeline-card-shadow);
    backdrop-filter: blur(10px);
    transform: translateY(-20px) scale(0.9);
}

.timeline-theme-indicator.active {
    opacity: 1;
    transform: translateY(0) scale(1);
    animation: themeIndicatorSlideIn 0.6s ease;
}

.timeline-theme-indicator .theme-indicator-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--timeline-gradient-start);
    margin-right: 0.5rem;
    animation: pulse 2s infinite;
}

.timeline-theme-indicator .theme-indicator-text {
    color: var(--timeline-card-title);
    font-size: 0.85rem;
    font-weight: 600;
    font-family: 'Nunito', sans-serif;
}

@keyframes themeIndicatorSlideIn {
    0% {
        opacity: 0;
        transform: translateY(-20px) scale(0.9);
    }
    50% {
        opacity: 0.8;
        transform: translateY(-5px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.7;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

