/* Leadership Cards Container */
.leadership-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
    display: grid;
    gap: 3rem;
}

.leadership-container .principal-card:nth-child(1) {
    grid-column: 1 / -1;
}

@media (min-width: 768px) {
    .leadership-container {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .principal-image {
        width: 160px;
        height: 160px;
    }
    
    .principal-name {
        font-size: 2rem;
    }
    
    .principal-designation {
        font-size: 1rem;
    }
    
    .modal-content-wrapper {
        max-width: 800px;
    }
}

/* Principal Card Styles */
.principal-card {
    max-width: 900px;
    margin: 0 auto;
    background: #fff;
    border-radius: 16px;
    overflow: visible;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    position: relative;
}

.principal-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.12);
}

/* Card Header */
.card-header {
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.card-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.08'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    z-index: 0;
}

.director-bg {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.principal-bg {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
}

.headmaster-bg {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
}

.header-content {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    position: relative;
    z-index: 1;
    flex-wrap: wrap;
}

.header-left {
    flex-shrink: 0;
}

.header-right {
    flex: 1;
    color: white;
}

/* Principal Image */
.principal-image {
    width: 140px;
    height: 140px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0,0,0,0.2);
    border: 4px solid rgba(255,255,255,0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.principal-image:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 32px rgba(0,0,0,0.3);
}

.principal-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Image Modal */
.image-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

.image-modal.show {
    display: flex;
}

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

.modal-content-wrapper {
    position: relative;
    max-width: 90%;
    max-height: 90vh;
    animation: zoomIn 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: auto;
}

@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(5); opacity: 1; }
}

.modal-image {
    width: auto;
    height: auto;
    max-width: none;
    max-height: none;
    transform: scale(5);
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: rgba(255,255,255,0.2);
    color: white;
    border: 2px solid rgba(255,255,255,0.3);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.modal-close:hover {
    background: rgba(255,255,255,0.3);
    transform: rotate(90deg);
}

.modal-info {
    position: absolute;
    bottom: -60px;
    left: 0;
    right: 0;
    text-align: center;
    color: white;
    font-size: 1.2rem;
    font-weight: 600;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
}

/* Principal Info */
.principal-name {
    font-size: clamp(1.25rem, 3vw, 1.75rem);
    font-weight: 700;
    color: white;
    margin: 0 0 0.5rem;
    letter-spacing: -0.02em;
    text-shadow: 0 2px 8px rgba(0,0,0,0.1);
    word-break: break-word;
}

.principal-designation {
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.9);
}

.principal-qualification {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.95);
    font-weight: 600;
    margin: 0.5rem 0 0;
    padding: 0.35rem 0.85rem;
    background: rgba(255,255,255,0.2);
    border-radius: 20px;
    display: inline-block;
    border: 1px solid rgba(255,255,255,0.3);
    backdrop-filter: blur(10px);
}

/* Card Body */
.card-body {
    padding: 2rem;
}

/* Card Footer */
.card-footer {
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.social-icon:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.social-icon i {
    font-size: 1rem;
}

.phone-icon {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

/* .facebook-icon {
    background: linear-gradient(135deg, #1877f2 0%, #0c5ec7 100%);
}

.instagram-icon {
    background: linear-gradient(135deg, #e4405f 0%, #c13584 100%);
} */

.principal-message {
    font-size: clamp(0.9rem, 2.5vw, 1.05rem);
    line-height: 1.8;
    color: #334155;
    font-style: italic;
    margin: 0;
    padding: 1.5rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 12px;
    border-left: 4px solid;
    position: relative;
    word-wrap: break-word;
}

.principal-card:nth-child(1) .principal-message {
    border-left-color: #f59e0b;
}

.principal-card:nth-child(2) .principal-message {
    border-left-color: #2563eb;
}

.principal-card:nth-child(3) .principal-message {
    border-left-color: #059669;
}

.principal-message::before {
    content: '"';
    font-size: 4rem;
    position: absolute;
    left: 1rem;
    top: -0.5rem;
    font-family: Georgia, serif;
    opacity: 0.15;
    font-weight: 700;
}

.principal-card:nth-child(1) .principal-message::before {
    color: #f59e0b;
}

.principal-card:nth-child(2) .principal-message::before {
    color: #2563eb;
}

.principal-card:nth-child(3) .principal-message::before {
    color: #059669;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .leadership-container {
        padding: 1rem;
        gap: 1.5rem;
    }
    
    .principal-card {
        margin: 0;
        border-radius: 12px;
    }
    
    .card-header {
        padding: 1.25rem;
    }
    
    .header-content {
        gap: 0.85rem;
    }
    
    .principal-image {
        width: 130px;
        height: 130px;
        border: 3px solid rgba(255,255,255,0.3);
    }
    
    .principal-name {
        font-size: clamp(1.1rem, 4vw, 1.5rem);
        margin: 0 0 0.3rem;
    }
    
    .principal-designation {
        font-size: clamp(0.75rem, 2.5vw, 0.9rem);
        letter-spacing: 0.5px;
    }
    
    .principal-qualification {
        font-size: clamp(0.7rem, 2vw, 0.8rem);
        margin: 0.4rem 0 0;
        padding: 0.3rem 0.7rem;
    }
    
    .card-body {
        padding: 1.25rem;
    }
    
    .card-footer {
        padding: 0.85rem 1.25rem;
        gap: 0.85rem;
    }
    
    .social-icon {
        width: 36px;
        height: 36px;
    }
    
    .social-icon i {
        font-size: 0.9rem;
    }
    
    .principal-message {
        font-size: clamp(0.85rem, 2.5vw, 1rem);
        line-height: 1.7;
        padding: 1rem;
        border-left-width: 3px;
    }
    
    .principal-message::before {
        font-size: clamp(2rem, 8vw, 3rem);
        left: 0.5rem;
        top: -0.25rem;
    }
}

@media (max-width: 480px) {
    .leadership-container {
        padding: 0.75rem 0.5rem;
        gap: 1.25rem;
    }
    
    .card-header {
        padding: 1rem;
    }
    
    .header-content {
        gap: 0.65rem;
    }
    
    .principal-image {
        width: 115px;
        height: 115px;
        border-radius: 10px;
        border: 3px solid rgba(255,255,255,0.3);
    }
    
    .principal-name {
        font-size: clamp(1rem, 4.5vw, 1.2rem);
        line-height: 1.2;
    }
    
    .principal-designation {
        font-size: clamp(0.7rem, 2.8vw, 0.8rem);
    }
    
    .principal-qualification {
        font-size: clamp(0.65rem, 2.2vw, 0.75rem);
        padding: 0.25rem 0.6rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .principal-message {
        font-size: clamp(0.8rem, 3vw, 0.9rem);
        line-height: 1.65;
        padding: 0.85rem;
    }
    
    .principal-message::before {
        font-size: clamp(1.75rem, 7vw, 2.5rem);
        left: 0.4rem;
        top: -0.2rem;
    }
}

@media (max-width: 360px) {
    .leadership-container {
        padding: 0.5rem 0.25rem;
        gap: 1rem;
    }
    
    .card-header {
        padding: 0.85rem;
    }
    
    .principal-image {
        width: 100px;
        height: 100px;
    }
    
    .card-body {
        padding: 0.85rem;
    }
    
    .principal-message {
        padding: 0.75rem;
        font-size: 0.8rem;
    }
    
    .modal-close {
        top: 10px;
        right: 10px;
        width: 36px;
        height: 36px;
        font-size: 20px;
    }
    
    .modal-info {
        bottom: 10px;
        font-size: 1rem;
    }
}
