/* Interactive Dot & Line Timeline Styles */

.interactive-timeline-section {
    width: 100%;
    padding: 60px 40px;
    background: white;
    border-radius: 12px;
}

.timeline-header {
    text-align: center;
    margin-bottom: 60px;
}

.timeline-header h2 {
    font-size: 2.5rem;
    color: #003087;
    margin-bottom: 10px;
    font-weight: 700;
}

.timeline-header p {
    font-size: 1.1rem;
    color: #666;
    font-weight: 400;
}

.timeline-container {
    display: flex;
    flex-direction: column;
    gap: 60px;
}

/* Content Area */
.timeline-content {
    width: 100%;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.content-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
    width: 100%;
    animation: fadeIn 0.6s ease-out;
}

.content-image {
    width: 100%;
    max-width: 500px;
    height: 350px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 48, 135, 0.15);
}

.content-text {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.content-year {
    font-size: 3.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #003087 0%, #0052cc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0;
}

.content-location {
    font-size: 2rem;
    color: #333;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
    display: flex;
    align-items: center;
    gap: 10px;
}

.content-location .flag-image {
    width: 40px;
    height: 40px;
    object-fit: cover;
    border-radius: 4px;
}

.content-tagline {
    font-size: 1.3rem;
    color: #0052cc;
    font-weight: 600;
    margin: 0;
}

.content-description {
    font-size: 1.1rem;
    color: #666;
    line-height: 1.6;
    margin-top: 10px;
}

/* Animation for content fade in/out */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.content-wrapper.fade-out {
    animation: fadeOut 0.4s ease-out;
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

/* Timeline Track and Dots */
.timeline-track-wrapper {
    position: relative;
    width: 100%;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.timeline-track {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 4px;
    background: #e0e0e0;
    border-radius: 2px;
    transform: translateY(-50%);
    z-index: 1;
}

.timeline-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: linear-gradient(90deg, #003087 0%, #0052cc 100%);
    border-radius: 2px;
    width: 0%;
    transition: width 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 2;
}

/* Dots Container */
.timeline-dots {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 3;
    padding: 0 20px;
}

/* Individual Dot */
.timeline-dot {
    width: 24px;
    height: 24px;
    background: white;
    border: 3px solid #e0e0e0;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.timeline-dot:hover {
    transform: scale(1.3);
    border-color: #003087;
    box-shadow: 0 0 0 4px rgba(0, 48, 135, 0.1);
}

.timeline-dot.active {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #003087 0%, #0052cc 100%);
    border-color: #003087;
    box-shadow: 0 4px 16px rgba(0, 48, 135, 0.3);
}

.timeline-dot.active::after {
    content: '';
    position: absolute;
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    animation: pulse 1.5s ease-in-out infinite;
}

.dot-flag-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

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

/* Tooltip for dot labels */
.dot-label {
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 10;
}

.timeline-dot:hover .dot-label,
.timeline-dot.active .dot-label {
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .interactive-timeline-section {
        padding: 40px 20px;
    }

    .timeline-header h2 {
        font-size: 1.8rem;
    }

    .timeline-header p {
        font-size: 1rem;
    }

    /* Hide timeline track wrapper on tablet and mobile */
    .timeline-track-wrapper {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        overflow: hidden !important;
    }

    .timeline-track {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        width: 0 !important;
    }

    .timeline-fill {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        width: 0 !important;
    }

    .timeline-dots {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
    }

    .timeline-dot {
        display: none !important;
        visibility: hidden !important;
        width: 0 !important;
        height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .content-wrapper {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .content-image {
        max-width: 100%;
        height: 300px;
    }

    .content-year {
        font-size: 2.5rem;
    }

    .content-location {
        font-size: 1.5rem;
    }

    .content-tagline {
        font-size: 1.1rem;
    }

    .timeline-container {
        gap: 40px;
    }
}

@media (max-width: 600px) {
    .interactive-timeline-section {
        padding: 30px 15px;
    }

    .timeline-header h2 {
        font-size: 1.5rem;
        margin-bottom: 8px;
    }

    .timeline-header p {
        font-size: 0.95rem;
    }

    /* Mobile: Hide entire timeline track, dots, and labels - show only content cards */
    .timeline-track-wrapper {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        overflow: hidden !important;
    }

    .timeline-track {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        width: 0 !important;
    }

    .timeline-fill {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        width: 0 !important;
    }

    .timeline-dots {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
    }

    .timeline-dot {
        display: none !important;
        visibility: hidden !important;
        width: 0 !important;
        height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .content-wrapper {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .content-image {
        height: 250px;
    }

    .content-year {
        font-size: 2rem;
    }

    .content-location {
        font-size: 1.3rem;
    }

    .content-tagline {
        font-size: 1rem;
    }

    .content-description {
        font-size: 1rem;
    }

    .timeline-container {
        gap: 30px;
    }
}

/* Extra Small Screens (320px and below) */
@media (max-width: 400px) {
    .interactive-timeline-section {
        padding: 20px 10px;
    }

    .timeline-header h2 {
        font-size: 1.2rem;
    }

    .timeline-header p {
        font-size: 0.9rem;
    }

    .timeline-track-wrapper {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        overflow: hidden !important;
    }

    .timeline-track {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        width: 0 !important;
    }

    .timeline-fill {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        width: 0 !important;
    }

    .timeline-dots {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
    }

    .timeline-dot {
        display: none !important;
        visibility: hidden !important;
        width: 0 !important;
        height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .content-year {
        font-size: 1.5rem;
    }

    .content-location {
        font-size: 1.1rem;
    }

    .content-tagline {
        font-size: 0.9rem;
    }

    .content-description {
        font-size: 0.95rem;
    }

    .content-image {
        height: 200px;
    }
}
