﻿/* ================= SHARED BACKGROUND ================= */
.teachers-hero,
.teachers-showcase {
    background-color: #05060f;
    position: relative;
    overflow: hidden;
}

/* ================= AURORA (پس‌زمینه‌ی زنده) ================= */
.aurora-layer {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    filter: blur(0px);
}

.aurora-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
    opacity: .55;
    mix-blend-mode: screen;
    animation: auroraDrift 18s ease-in-out infinite;
}

.aurora-1 {
    width: 620px;
    height: 620px;
    background: radial-gradient(circle, #2547f4, transparent 70%);
    top: -220px;
    left: -120px;
    animation-duration: 20s;
}

.aurora-2 {
    width: 520px;
    height: 520px;
    background: radial-gradient(circle, #7c3aed, transparent 70%);
    top: -150px;
    right: -180px;
    animation-duration: 24s;
    animation-delay: -6s;
}

.aurora-3 {
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, #06b6d4, transparent 70%);
    bottom: -220px;
    left: 30%;
    animation-duration: 26s;
    animation-delay: -12s;
}

.aurora-4 {
    width: 550px;
    height: 550px;
    background: radial-gradient(circle, #2547f4, transparent 70%);
    top: 10%;
    left: -200px;
    animation-duration: 22s;
}

.aurora-5 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, #f5b400, transparent 70%);
    bottom: 5%;
    right: -150px;
    opacity: .3;
    animation-duration: 28s;
    animation-delay: -8s;
}

@keyframes auroraDrift {
    0%, 100% {
        transform: translate(0,0) scale(1);
    }

    33% {
        transform: translate(60px,-40px) scale(1.15);
    }

    66% {
        transform: translate(-50px,50px) scale(.9);
    }
}

/* ================= NOISE (بافت ظریف فیلمی) ================= */
.noise-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    opacity: .04;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ================= TEACHERS HERO ================= */
.teachers-hero {
    min-height: 75vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.teachers-grid-pattern {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
    background-size: 46px 46px;
    mask-image: radial-gradient(circle at 50% 30%, black, transparent 68%);
    z-index: 1;
}

.teachers-hero .hero-content {
    position: relative;
    z-index: 3;
}

.teachers-hero .hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 26px;
    border-radius: 50px;
    background: rgba(255,255,255,.06);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,.14);
    color: #ffffff;
    font-weight: 800;
    box-shadow: 0 10px 30px rgba(0,0,0,.3);
    font-size: 14px;
    opacity: 0;
}

    .teachers-hero .hero-badge i {
        color: #f5b400;
    }

.teachers-hero h1 {
    margin-top: 28px;
    font-size: clamp(40px, 5.5vw, 78px);
    font-weight: 900;
    letter-spacing: -1.5px;
    color: #ffffff;
}

    .teachers-hero h1 .word {
        display: inline-block;
        overflow: hidden;
        vertical-align: top;
    }

    .teachers-hero h1 .word-inner {
        display: inline-block;
        transform: translateY(110%);
        filter: blur(6px);
        opacity: 0;
    }

    .teachers-hero h1 .highlight .word-inner {
        background: linear-gradient(135deg, #6b8cff, #06b6d4, #7c3aed);
        background-size: 200% auto;
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
        animation: gradientFlow 6s linear infinite;
    }

@keyframes gradientFlow {
    to {
        background-position: 200% center;
    }
}

.teachers-hero p {
    margin-top: 22px;
    color: rgba(255,255,255,.6);
    line-height: 2;
    font-size: 18px;
    max-width: 600px;
    margin-inline: auto;
    opacity: 0;
}

/* ================= SHOWCASE / TRACK ================= */
.teachers-showcase {
    padding: 110px 0;
}

.teacher-track {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 36px;
    position: relative;
    z-index: 3;
    padding: 0 24px;
}

.teacher-card {
    width: 360px;
    height: 540px;
    border-radius: 32px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    isolation: isolate;
    box-shadow: 0 25px 70px rgba(0,0,0,.5);
    border: 1px solid rgba(255,255,255,.1);
    background: rgba(255,255,255,.03);
    backdrop-filter: blur(6px);
    opacity: 1;
    transform: none;
    transition: border-color .4s, box-shadow .4s;
}
/*.teacher-card {
    width: 360px;
    height: 540px;
    border-radius: 32px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    isolation: isolate;
    box-shadow: 0 25px 70px rgba(0,0,0,.5);
    border: 1px solid rgba(255,255,255,.1);
    background: rgba(255,255,255,.03);
    backdrop-filter: blur(6px);
    opacity: 0;
    transform: translateY(50px);
    transition: border-color .4s, box-shadow .4s;
}*/

    .teacher-card:hover {
        border-color: rgba(107,140,255,.5);
        box-shadow: 0 35px 90px rgba(37,71,244,.35);
    }

/* حلقه‌ی نور هولوگرافیک که دنبال ماوس می‌ره */
.card-spotlight {
    position: absolute;
    inset: 0;
    z-index: 3;
    pointer-events: none;
    opacity: 0;
    transition: opacity .4s;
    background: radial-gradient(circle 220px at var(--x,50%) var(--y,50%), rgba(107,140,255,.35), transparent 70%);
}

.teacher-card:hover .card-spotlight {
    opacity: 1;
}

.teacher-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: relative;
    z-index: 0;
    transition: transform .6s var(--ease, ease);
}

.teacher-card:hover img {
    transform: scale(1.06);
}

.teacher-card-glow {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #2547f4, #7c3aed);
    opacity: 0;
    mix-blend-mode: overlay;
    transition: opacity .4s;
    z-index: 1;
    pointer-events: none;
}

.teacher-card:hover .teacher-card-glow {
    opacity: .3;
}

.teacher-info {
    position: absolute;
    inset: 0;
    display: flex;
    justify-content: flex-end;
    flex-direction: column;
    padding: 34px;
    color: white;
    background: linear-gradient(transparent 30%, rgba(3,5,15,.96));
    text-align: right;
    z-index: 2;
}

    .teacher-info h3 {
        font-weight: 900;
        font-size: 22px;
    }

    .teacher-info span {
        color: #a9b4d0;
        font-size: 14.5px;
        margin-top: 4px;
        display: block;
    }

.profile-btn {
    margin-top: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 26px;
    border: none;
    border-radius: 50px;
    font-weight: 800;
    cursor: pointer;
    background: linear-gradient(135deg, #2547f4, #7c3aed);
    color: white;
    align-self: flex-start;
    transition: .3s;
    box-shadow: 0 12px 30px rgba(37,71,244,.5);
    position: relative;
}

    .profile-btn:hover {
        transform: translateY(-3px);
        box-shadow: 0 18px 40px rgba(37,71,244,.6);
    }

.teachers-empty {
    text-align: center;
    padding: 90px 20px;
    color: #cbd5e1;
    font-size: 18px;
    position: relative;
    z-index: 3;
}

    .teachers-empty i {
        font-size: 56px;
        color: #6b8cff;
        display: block;
        margin-bottom: 20px;
    }

/* ================= MODAL ================= */
.teacher-modal {
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity .35s, visibility .35s;
    z-index: 99999;
    padding: 20px;
}

    .teacher-modal.show {
        opacity: 1;
        visibility: visible;
    }

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(3,5,15,.7);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    z-index: 1;
}

.modal-content-custom {
    position: relative;
    isolation: isolate;
    z-index: 5;
    width: 640px;
    max-width: 100%;
    background: linear-gradient(160deg, #0d0f1e, #05060f);
    border: 1px solid rgba(107,140,255,.25);
    border-radius: 32px;
    padding: 50px;
    text-align: center;
    box-shadow: 0 40px 100px rgba(0,0,0,.6);
    transform: scale(.94);
    opacity: 0;
    transition: transform .35s, opacity .35s;
}

.teacher-modal.show .modal-content-custom {
    transform: scale(1);
    opacity: 1;
}

.modal-img-wrapper {
    position: relative;
    width: 170px;
    height: 170px;
    margin: 0 auto;
}

    .modal-img-wrapper::before {
        content: "";
        position: absolute;
        inset: -6px;
        border-radius: 50%;
        background: conic-gradient(from 0deg, #2547f4, #7c3aed, #06b6d4, #2547f4);
        animation: thRingRotate 5s linear infinite;
        z-index: 0;
    }

@keyframes thRingRotate {
    to {
        transform: rotate(360deg);
    }
}

.modal-content-custom img {
    position: relative;
    z-index: 1;
    width: 170px;
    height: 170px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid #05060f;
    display: block;
}

.modal-content-custom h2 {
    margin-top: 24px;
    font-weight: 900;
    font-size: 26px;
    color: #ffffff;
}

.modal-content-custom h5 {
    color: #6b8cff;
    font-weight: 700;
    margin-top: 8px;
}

.modal-experience-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 18px;
    padding: 10px 22px;
    border-radius: 50px;
    background: rgba(107,140,255,.1);
    border: 1px solid rgba(107,140,255,.2);
    color: #6b8cff;
    font-weight: 800;
    font-size: 14px;
}

    .modal-experience-badge i {
        color: #f5b400;
    }

    .modal-experience-badge.hidden {
        display: none;
    }

.modal-content-custom p {
    margin-top: 18px;
    color: #a9b4d0;
    line-height: 2;
}

.close-modal {
    position: absolute;
    left: 22px;
    top: 18px;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.1);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 23px;
    cursor: pointer;
    color: white;
    transition: .3s;
    z-index: 6;
}

    .close-modal:hover {
        background: linear-gradient(135deg, #2547f4, #7c3aed);
        border-color: transparent;
    }

@media (max-width: 576px) {
    .modal-content-custom {
        padding: 36px 24px;
    }

    .teacher-card {
        width: 100%;
        max-width: 340px;
        height: 460px;
    }
}
