/* === GURU & STAFF PAGE STYLES - SUPER AGGRESSIVE === */

/* RESET TOTAL UNTUK SEMUA ELEMENT GURU */
.guru-photo {
    /* VISIBILITY */
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    
    /* SIZE & POSITION */
    width: 230px !important;
    height: 320px !important;
    max-width: 100% !important;
    position: relative !important;
    z-index: 1 !important;
    
    /* BORDER & STYLING */
    border-radius: 10% !important;
    border: 4px solid #2c5aa0 !important;
    object-fit: cover !important;
    
    /* NO EFFECTS */
    filter: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    transform: none !important;
    transition: none !important;
    
    /* MARGIN & PADDING */
    margin-bottom: 1rem !important;
    padding: 0 !important;
}

.photo-placeholder {
    /* VISIBILITY */
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    
    /* SIZE & POSITION */
    width: 120px !important;
    height: 120px !important;
    position: relative !important;
    z-index: 1 !important;
    
    /* BORDER & STYLING */
    border-radius: 50% !important;
    border: 4px solid #2c5aa0 !important;
    background: #f8fafc !important;
    
    /* CONTENT */
    align-items: center !important;
    justify-content: center !important;
    font-size: 2.5em !important;
    
    /* MARGIN & PADDING */
    margin-bottom: 1rem !important;
    padding: 0 !important;
}

.guru-card {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    z-index: 1 !important;
}

.guru-grid {
    display: grid !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Page Header */
.page-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
}

.page-title {
    font-size: 2.5em;
    color: #2c5aa0;
    margin-bottom: 0.5rem;
    font-weight: 800;
}

.page-subtitle {
    font-size: 1.2em;
    color: #64748b;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.stats-badges {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.stat-badge {
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    box-shadow: 0 4px 15px rgba(44, 90, 160, 0.3);
}

/* Filter Section */
.filter-section {
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.tabs {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tab {
    padding: 0.8rem 1.5rem;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    color: #64748b;
    transition: all 0.3s ease;
    flex: 1;
    min-width: 120px;
    text-align: center;
}

.tab:hover {
    background: #e2e8f0;
    border-color: #cbd5e1;
}

.tab.active {
    background: #2c5aa0;
    color: white;
    border-color: #2c5aa0;
}

.mapel-filter {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}

.mapel-filter select {
    padding: 0.7rem 1rem;
    border-radius: 8px;
    border: 2px solid #e2e8f0;
    background: white;
    font-size: 0.95rem;
    color: #374151;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 250px;
}

.mapel-filter select:hover {
    border-color: #cbd5e1;
}

.mapel-filter select:focus {
    outline: none;
    border-color: #2c5aa0;
    box-shadow: 0 0 0 3px rgba(44, 90, 160, 0.1);
}

/* Jabatan Section */
.jabatan-khusus-section {
    margin-bottom: 3rem;
}

.jabatan-title {
    font-size: 1.4em;
    color: #2c5aa0;
    margin-bottom: 1.2rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #e2e8f0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.jabatan-icon {
    font-size: 1.2em;
}

.kategori-subtitle {
    color: #2c5aa0;
    margin: 2rem 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e2e8f0;
    font-size: 1.2em;
}

/* Guru Grid */
.guru-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.guru-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid #f1f5f9;
}

.guru-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

/* Photo Styles - KATEGORI WARNA */
.guru-photo.guru { border-color: #2c5aa0 !important; }
.guru-photo.staf { border-color: #10b981 !important; }
.guru-photo.karyawan { border-color: #f59e0b !important; }

.photo-placeholder.guru { 
    border-color: #2c5aa0 !important; 
    background: linear-gradient(135deg, #dbeafe, #eff6ff) !important;
}
.photo-placeholder.staf { 
    border-color: #10b981 !important; 
    background: linear-gradient(135deg, #d1fae5, #ecfdf5) !important;
}
.photo-placeholder.karyawan { 
    border-color: #f59e0b !important; 
    background: linear-gradient(135deg, #fef3c7, #fffbeb) !important;
}

/* Text Styles */
.guru-name {
    margin: 0 0 0.5rem 0;
    color: #2c5aa0;
    font-size: 1.1em;
    font-weight: 600;
    line-height: 1.3;
}

.guru-jabatan-khusus {
    margin: 0 0 0.5rem 0;
    color: #2c5aa0;
    font-size: 0.95em;
    font-weight: 600;
    line-height: 1.3;
}

.guru-jabatan {
    margin: 0 0 0.5rem 0;
    color: #666;
    font-weight: 500;
    font-size: 0.95em;
    line-height: 1.4;
}

.guru-deskripsi {
    margin: 0;
    color: #888;
    font-size: 0.9em;
    line-height: 1.4;
    flex-grow: 1;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: #64748b;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.empty-icon {
    font-size: 4em;
    margin-bottom: 1rem;
    opacity: 0.7;
}

.empty-state h3 {
    color: #374151;
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: #6b7280;
    max-width: 400px;
    margin: 0 auto;
}

/* === GURU MODAL GALLERY STYLES - FIXED POSITION === */
.guru-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    align-items: center;
    justify-content: center;
    padding: 100px 20px 20px 20px; /* Extra top padding untuk header */
}

.modal-content {
    position: relative;
    margin: auto;
    padding: 200px;
    width: 100%;
    max-width: 900px;
    max-height: calc(100vh - 140px); /* Account for header and padding */
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 25px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10001;
    background: rgba(0, 0, 0, 0.6);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
    border-color: rgba(255, 255, 255, 0.5);
}

.modal-image-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-height: 50vh;
    padding: 20px;
    min-height: 300px;
}

#modalImage {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 15px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
    transition: transform 0.3s ease;
    background: rgba(0, 0, 0, 0.3);
    padding: 10px;
}

.modal-nav {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    padding: 0 30px;
    transform: translateY(-50%);
    z-index: 1000;
}

.modal-prev,
.modal-next {
    background: rgba(255, 255, 255, 0.25);
    border: none;
    color: white;
    font-size: 28px;
    padding: 18px 22px;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.modal-prev:hover,
.modal-next:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: scale(1.15);
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.modal-info {
    text-align: center;
    color: white;
    padding: 30px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 15px;
    backdrop-filter: blur(15px);
    margin-top: 25px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-info h3 {
    margin: 0 0 20px 0;
    font-size: 2em;
    color: white;
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.modal-jabatan-khusus {
    margin: 15px 0;
    color: #fbbf24;
    font-weight: 700;
    font-size: 1.3em;
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.3), rgba(245, 158, 11, 0.3));
    padding: 12px 24px;
    border-radius: 25px;
    display: inline-block;
    border: 2px solid rgba(251, 191, 36, 0.5);
    backdrop-filter: blur(10px);
}

.modal-mapel {
    margin: 12px 0;
    color: #60a5fa;
    font-weight: 600;
    font-size: 1.2em;
    background: rgba(96, 165, 250, 0.2);
    padding: 10px 20px;
    border-radius: 20px;
    display: inline-block;
    border: 1px solid rgba(96, 165, 250, 0.4);
}

.modal-jabatan {
    margin: 12px 0;
    color: #34d399;
    font-weight: 600;
    font-size: 1.2em;
    background: rgba(52, 211, 153, 0.2);
    padding: 10px 20px;
    border-radius: 20px;
    display: inline-block;
    border: 1px solid rgba(52, 211, 153, 0.4);
}

.modal-deskripsi {
    margin: 20px 0 0 0;
    color: #e5e7eb;
    font-size: 1.1em;
    line-height: 1.6;
    font-style: italic;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    border-left: 4px solid #f59e0b;
}

/* Make guru photos clickable */
.guru-photo {
    cursor: pointer !important;
    transition: all 0.3s ease !important;
}

.guru-photo:hover {
    transform: scale(1.08) !important;
    box-shadow: 0 8px 25px rgba(44, 90, 160, 0.4) !important;
}

/* === MOBILE OVERRIDE === */
@media (max-width: 768px) {
    .guru-photo {
        width: 180px !important;
        height: 240px !important;
    }
    
    .photo-placeholder {
        width: 100px !important;
        height: 100px !important;
    }
    
    /* Modal Mobile Fixes */
    .guru-modal {
        padding: 80px 15px 15px 15px; /* Kurangi padding top untuk mobile */
    }
    
    .modal-content {
        padding: 20px;
        max-width: 95%;
        max-height: calc(100vh - 110px);
    }
    
    .modal-close {
        top: 15px;
        right: 20px;
        font-size: 35px;
        width: 45px;
        height: 45px;
    }
    
    .modal-nav {
        padding: 0 20px;
    }
    
    .modal-prev,
    .modal-next {
        width: 55px;
        height: 55px;
        font-size: 22px;
        padding: 15px 18px;
    }
    
    .modal-image-container {
        max-height: 120vh;
        padding: 15px;
        min-height: 250px;
    }
    
    .modal-info {
        padding: 20px;
        margin-top: 20px;
    }
    
    .modal-info h3 {
        font-size: 1.6em;
        margin-bottom: 15px;
    }
    
    .modal-jabatan-khusus {
        font-size: 1.1em;
        padding: 10px 18px;
    }
    
    .modal-mapel,
    .modal-jabatan {
        font-size: 1em;
        padding: 8px 16px;
    }
    
    .modal-deskripsi {
        font-size: 1em;
        padding: 15px;
    }
    
    .page-header {
        margin-bottom: -2rem;
        padding: 1.5rem 0;
    }
    
    .page-title {
        font-size: 1.8em;
    }
    
    .page-subtitle {
        font-size: 1.1em;
    }
    
    .stats-badges {
        gap: 0.8rem;
    }
    
    .stat-badge {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }
    
    .filter-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .tabs {
        flex-direction: row;
        gap: 0.2rem;
    }
    
    .tab {
        min-width: auto;
        padding: 0.8rem 1rem;
    }
    
    .mapel-filter {
        justify-content: stretch;
    }
    
    .mapel-filter select {
        min-width: auto;
        width: 100%;
    }
    
    .guru-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1rem;
    }
    
    .jabatan-title {
        font-size: 1.2em;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .kategori-subtitle {
        font-size: 1.1em;
        margin: 1.5rem 0 1rem 0;
    }
    
    .guru-name {
        font-size: 1em;
    }
    
    .guru-jabatan {
        font-size: 0.9em;
    }
}

/* SMALL MOBILE */
@media (max-width: 480px) {
    .guru-photo {
        width: 180px !important;
        height: 220px !important;
    }
    
    .photo-placeholder {
        width: 80px !important;
        height: 80px !important;
    }
    
    .guru-modal {
        padding: 70px 10px 10px 10px;
    }
    
    .modal-content {
        padding: 15px;
        max-width: 98%;
    }
    
    .modal-prev,
    .modal-next {
        width: 50px;
        height: 50px;
        font-size: 20px;
        padding: 12px 15px;
    }
    
    .modal-info h3 {
        font-size: 1.4em;
    }
    
    .modal-jabatan-khusus {
        font-size: 1em;
    }
    
    .page-title {
        font-size: 1.6em;
    }
    
    .stats-badges {
        flex-direction: row;
        align-items: center;
    }
    
    .stat-badge {
        width: auto;
    }
    
    .guru-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .guru-card {
        padding: 1rem;
    }
    
    .photo-placeholder {
        font-size: 2em;
    }
    
    .empty-state {
        padding: 2rem 1rem;
    }
    
    .empty-icon {
        font-size: 3em;
    }
}

/* Animation untuk smooth transitions */
.guru-card {
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}