/* History Page Styles */
.history-hero {
    background-image: linear-gradient(rgba(0, 51, 102, 0.7), rgba(0, 51, 102, 0.7)), url('../images/history/medical-history-doctor.webp');
    background-size: cover;
    background-position: center;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
    margin-top: 80px;
}

.history-hero-content {
    max-width: 800px;
    padding: 0 20px;
}

.history-hero-title {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.history-hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 0;
}

.timeline {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 50px 0;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 6px;
    background-color: var(--primary-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -3px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 25px;
    right: -12px;
    background-color: #fff;
    border: 4px solid var(--accent-color);
    top: 15px;
    border-radius: 50%;
    z-index: 1;
}

.timeline-item.left {
    left: 0;
}

.timeline-item.right {
    left: 50%;
}

.timeline-item.right::after {
    left: -12px;
}

.timeline-content {
    padding: 20px 30px;
    background-color: #fff;
    position: relative;
    border-radius: 6px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.timeline-date {
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.timeline-title {
    margin-top: 0;
    color: var(--primary-color);
    font-size: 1.5rem;
}

.timeline-text {
    margin-bottom: 0;
}

.history-image {
    width: 100%;
    height: auto;
    border-radius: 6px;
    margin-bottom: 15px;
}

.history-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin: 40px 0;
}

.gallery-item {
    background-color: #fff;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
}

.gallery-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.gallery-content {
    padding: 20px;
}

.gallery-title {
    margin-top: 0;
    color: var(--primary-color);
}

.gallery-text {
    margin-bottom: 0;
}

@media screen and (max-width: 768px) {
    .timeline::after {
        left: 31px;
    }
    
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }
    
    .timeline-item.right {
        left: 0;
    }
    
    .timeline-item::after {
        left: 19px;
        right: auto;
    }
    
    .timeline-item.right::after {
        left: 19px;
    }
    
    .history-hero-title {
        font-size: 2rem;
    }
}
