/* Team page 3D identity layer - scoped to avoid collisions with global CSS */
.team-identity-page {
    --team-brand-1: #00a887;
    --team-brand-2: #5ed8c0;
    --team-brand-3: #1f2b3d;
    --team-bg-soft: #edf6f4;
    --team-card-border: rgba(15, 38, 47, 0.12);
    --team-card-shadow: 0 18px 46px rgba(7, 28, 32, 0.14);
    --team-card-shadow-hover: 0 28px 58px rgba(7, 28, 32, 0.22);
    --team-text-strong: #1f2b3d;
    --team-text-soft: #5c6b78;
    direction: rtl;
    background:
        radial-gradient(1200px 430px at 85% -80px, rgba(94, 216, 192, 0.24), transparent 60%),
        radial-gradient(850px 360px at 10% 30%, rgba(0, 168, 135, 0.14), transparent 65%),
        linear-gradient(180deg, #f2f8f7 0%, #ffffff 36%, #f5f8fb 100%);
    color: var(--team-text-strong);
    padding-bottom: 3.6rem;
}

.team-identity-page .container {
    max-width: 1320px;
    padding-inline: clamp(0.9rem, 2.2vw, 1.35rem);
}

/* Make team hero span viewport width like other top sections */
.team-vision-hero .container {
    max-width: 100%;
    width: 100%;
    padding-inline: clamp(0.9rem, 2.8vw, 2.4rem);
}

.team-vision-hero {
    position: relative;
    padding: clamp(2.1rem, 5vw, 4.2rem) 0 1.6rem;
    overflow: hidden;
}

.team-hero-aurora {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(360px 180px at 24% 16%, rgba(94, 216, 192, 0.22), transparent 72%),
        radial-gradient(460px 220px at 80% 18%, rgba(0, 168, 135, 0.18), transparent 72%);
    z-index: 0;
}

.team-hero-panel {
    position: relative;
    z-index: 1;
    display: grid;
    width: 100%;
    grid-template-columns: minmax(96px, 130px) minmax(0, 1fr);
    gap: clamp(1rem, 2.6vw, 1.6rem);
    align-items: center;
    padding: clamp(1.2rem, 3vw, 2.1rem);
    border-radius: 26px;
    border: 1px solid rgba(0, 168, 135, 0.18);
    background: linear-gradient(130deg, rgba(255, 255, 255, 0.97), rgba(243, 250, 248, 0.91));
    box-shadow: var(--team-card-shadow);
    backdrop-filter: blur(4px);
    border-top: 3px solid rgba(0, 168, 135, 0.55);
}

.team-crest {
    position: relative;
    width: 94px;
    aspect-ratio: 1;
    margin-inline: auto;
    display: grid;
    place-items: center;
    border-radius: 24px;
    border: 1px solid rgba(0, 168, 135, 0.2);
    background: linear-gradient(145deg, #ffffff, #eef8f5);
    box-shadow: 0 10px 22px rgba(0, 168, 135, 0.15);
}

.team-crest .team-crest-core {
    width: 70px;
    height: 70px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(140deg, var(--team-brand-1), var(--team-brand-2));
    box-shadow: 0 12px 26px rgba(0, 168, 135, 0.35);
    font-size: 1.25rem;
}

.team-kicker {
    margin: 0 0 0.45rem;
    color: #11715f;
    font-weight: 800;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    font-size: 0.83rem;
    text-align: center;
}

.team-hero-copy {
    width: min(100%, 980px);
    margin-inline: auto;
    text-align: center;
}

.team-identity-page .team-hero-title {
    margin: 0;
    font-size: clamp(1.6rem, 3.4vw, 2.7rem);
    line-height: 1.28;
    letter-spacing: -0.02em;
    font-weight: 900;
    color: var(--team-text-strong);
}

.team-identity-page .team-hero-desc {
    margin: 1rem auto 0;
    font-size: clamp(0.95rem, 1.45vw, 1.08rem);
    line-height: 1.95;
    color: var(--team-text-soft);
    max-width: 68ch;
}

.team-identity-page .team-stats {
    margin-top: 1.3rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(135px, 1fr));
    gap: 0.75rem;
}

.team-identity-page .team-stat {
    border-radius: 16px;
    padding: 0.85rem 0.7rem;
    text-align: center;
    border: 1px solid rgba(0, 168, 135, 0.12);
    background: linear-gradient(160deg, #ffffff 0%, #f4faf8 100%);
}

.team-identity-page .stat-number {
    font-size: clamp(1.15rem, 2.2vw, 1.58rem);
    line-height: 1;
    font-weight: 900;
    color: #0f6f5d;
}

.team-identity-page .stat-label {
    margin-top: 0.35rem;
    font-size: 0.79rem;
    color: #60717c;
    font-weight: 700;
}

.team-vision-pillars {
    margin-top: 1.2rem;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.8rem;
    align-items: stretch;
}

.vision-pillar {
    border-radius: 18px;
    padding: 1rem 0.95rem;
    border: 1px solid rgba(0, 168, 135, 0.14);
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(245, 250, 248, 0.95));
    box-shadow: 0 10px 20px rgba(10, 46, 58, 0.08);
    height: 100%;
}

.vision-pillar .vision-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: inline-grid;
    place-items: center;
    font-size: 1.1rem;
    color: #ffffff;
    background: linear-gradient(140deg, #00a887, #57c7b5);
}

.vision-pillar h2 {
    margin: 0.75rem 0 0.45rem;
    font-size: 1.06rem;
    font-weight: 800;
    color: #1f2b3d;
}

.vision-pillar p {
    margin: 0;
    color: #5e6c78;
    font-size: 0.91rem;
    line-height: 1.8;
}

.team-departments-shell {
    padding: 1rem 0 2.2rem;
}

.team-section-head {
    margin-bottom: 1.2rem;
}

.team-section-kicker {
    margin: 0;
    font-size: 0.8rem;
    font-weight: 800;
    color: #0f6f5d;
    letter-spacing: 0.06em;
}

.team-section-title {
    margin: 0.45rem 0 0.4rem;
    font-size: clamp(1.34rem, 2.4vw, 2rem);
    font-weight: 900;
    color: var(--team-text-strong);
}

.team-section-desc {
    margin: 0;
    color: #617380;
    font-size: 0.96rem;
}

.team-identity-page .department-tabs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(185px, 1fr));
    gap: 0.7rem;
    margin-bottom: 1.2rem;
}

.team-identity-page .department-tab {
    border: 1px solid rgba(0, 168, 135, 0.16);
    border-radius: 14px;
    padding: 0.78rem 0.5rem;
    background: linear-gradient(130deg, #ffffff, #f1f7f6);
    color: #1f2b3d;
    font-weight: 800;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.team-identity-page .department-tab .tab-icon {
    font-size: 1rem;
}

.team-identity-page .department-tab .tab-title {
    font-size: 0.86rem;
    text-align: right;
}

.team-identity-page .department-tab .tab-count {
    min-width: 1.6rem;
    height: 1.6rem;
    border-radius: 999px;
    display: grid;
    place-items: center;
    font-size: 0.73rem;
    background: rgba(0, 168, 135, 0.1);
    color: #0d6f5b;
}

.team-identity-page .department-tab.active,
.team-identity-page .department-tab:hover {
    transform: translateY(-2px);
    border-color: rgba(0, 168, 135, 0.42);
    box-shadow: 0 12px 24px rgba(6, 33, 40, 0.14);
}

.team-identity-page .department-content {
    display: none;
    animation: teamFadeSlide 0.45s ease;
}

.team-identity-page .department-content.active {
    display: block;
}

.department-intro {
    border-radius: 16px;
    margin-bottom: 0.95rem;
    padding: 0.8rem 1rem;
    border: 1px solid rgba(0, 168, 135, 0.14);
    background: linear-gradient(145deg, #ffffff, #f5faf8);
}

.department-intro h3 {
    margin: 0;
    font-size: 1.02rem;
    font-weight: 800;
    color: #183148;
}

.department-intro p {
    margin: 0.38rem 0 0;
    font-size: 0.92rem;
    color: #5e717e;
}

.team-identity-page .team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1rem;
    align-items: stretch;
}

.team-identity-page .team-card {
    --tilt-rotate-x: 0deg;
    --tilt-rotate-y: 0deg;
    position: relative;
    border-radius: 20px;
    padding: 1.15rem 1rem 1rem;
    border: 1px solid var(--team-card-border);
    background: linear-gradient(155deg, #ffffff 0%, #f7fcfb 100%);
    box-shadow: var(--team-card-shadow);
    transform-style: preserve-3d;
    transform: perspective(1100px) rotateX(var(--tilt-rotate-x)) rotateY(var(--tilt-rotate-y));
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    overflow: hidden;
    isolation: isolate;
    width: min(100%, 380px);
    max-width: 100%;
    margin-inline: auto;
    min-height: 100%;
}

.team-identity-page .team-card::before {
    content: "";
    position: absolute;
    inset: -45% auto auto -32%;
    width: 72%;
    height: 75%;
    transform: rotate(-18deg);
    background: radial-gradient(circle at center, rgba(94, 216, 192, 0.24), transparent 72%);
    z-index: -1;
}

.team-identity-page .team-card:hover {
    box-shadow: var(--team-card-shadow-hover);
    border-color: rgba(0, 168, 135, 0.36);
}

.team-card-depth {
    position: absolute;
    inset: auto 16px 10px;
    height: 10px;
    border-radius: 999px;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.18), transparent 70%);
    filter: blur(4px);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.team-identity-page .team-card:hover .team-card-depth {
    opacity: 1;
}

.team-identity-page .leadership-badge {
    position: absolute;
    inset: 0.78rem 0.78rem auto auto;
    font-size: 0.68rem;
    font-weight: 800;
    color: #ffffff;
    border-radius: 999px;
    padding: 0.32rem 0.62rem;
    background: linear-gradient(135deg, #1e2d45, #385177);
    box-shadow: 0 6px 14px rgba(18, 30, 52, 0.22);
}

.team-identity-page .team-avatar {
    width: 90px;
    height: 90px;
    margin: 0 auto 0.75rem;
    border-radius: 22px;
    border: 1px solid rgba(0, 168, 135, 0.19);
    background: linear-gradient(150deg, #e5f4f1, #f8fcfb);
    display: grid;
    place-items: center;
    color: #00886f;
    font-size: 1.9rem;
    box-shadow: 0 9px 18px rgba(0, 168, 135, 0.14);
}

.team-identity-page .team-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
}

.team-department-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.5rem;
    padding: 0.25rem 0.6rem;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 800;
    background: rgba(0, 168, 135, 0.1);
    color: #0d6e5b;
}

.team-identity-page .team-name {
    margin: 0.15rem 0 0;
    text-align: center;
    font-size: 1.16rem;
    font-weight: 900;
    color: #1f2b3d;
}

.team-identity-page .team-name-link {
    color: inherit;
    text-decoration: none;
    text-decoration-color: rgba(0, 168, 135, 0.5);
}

.team-identity-page .team-name-link:hover,
.team-identity-page .team-name-link:focus {
    color: #007961;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.team-identity-page .team-role {
    margin: 0.45rem 0 0;
    text-align: center;
    color: #54636e;
    font-size: 0.88rem;
    font-weight: 700;
}

.team-identity-page .team-bio {
    margin: 0.7rem 0 0;
    padding-top: 0.62rem;
    border-top: 1px dashed rgba(31, 43, 61, 0.16);
    color: #63727f;
    font-size: 0.85rem;
    line-height: 1.75;
    text-align: center;
}

.team-empty-state {
    grid-column: 1 / -1;
    border-radius: 16px;
    padding: 1.6rem 1rem;
    text-align: center;
    border: 1px dashed rgba(0, 168, 135, 0.25);
    color: #5d6f7a;
    background: rgba(255, 255, 255, 0.75);
}

.team-empty-state i {
    font-size: 1.35rem;
    margin-bottom: 0.48rem;
    color: #0d7862;
}

.team-future-cta {
    margin-top: 0.9rem;
}

.team-future-panel {
    border-radius: 24px;
    padding: clamp(1.2rem, 3.2vw, 2rem);
    text-align: center;
    border: 1px solid rgba(0, 168, 135, 0.2);
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(236, 247, 245, 0.9));
    box-shadow: 0 16px 34px rgba(7, 35, 42, 0.14);
}

.team-future-panel h2 {
    margin: 0;
    color: #193149;
    font-weight: 900;
    font-size: clamp(1.2rem, 2.8vw, 2rem);
}

.team-future-panel p {
    max-width: 70ch;
    margin: 0.85rem auto 0;
    color: #5c6f7b;
    line-height: 1.92;
    font-size: 0.95rem;
}

.team-future-btn {
    margin-top: 1.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    padding: 0.68rem 1.2rem;
    border-radius: 999px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 800;
    color: #ffffff;
    border: 1px solid transparent;
    background: linear-gradient(135deg, #00a887, #44c5b1);
    box-shadow: 0 11px 22px rgba(0, 168, 135, 0.28);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.team-future-btn:hover,
.team-future-btn:focus {
    color: #ffffff;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(0, 168, 135, 0.34);
}

@keyframes orbitSpinA {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes orbitSpinB {
    from { transform: rotate(360deg); }
    to { transform: rotate(0deg); }
}

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

@media (max-width: 991px) {
    .team-hero-panel {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .team-crest {
        width: 88px;
        margin-bottom: 0.35rem;
    }

    .team-identity-page .team-hero-desc {
        margin-inline: auto;
    }

    .team-identity-page .team-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .team-vision-pillars {
        grid-template-columns: 1fr;
    }

    .team-identity-page .department-tabs {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }

    .team-identity-page .team-grid {
        grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    }
}

@media (max-width: 760px) {
    .team-identity-page .department-tabs {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .team-identity-page {
        padding-bottom: 2.6rem;
    }

    .team-vision-hero {
        padding-top: 1.8rem;
    }

    .team-hero-panel {
        border-radius: 18px;
        padding: 1rem 0.85rem;
    }

    .team-crest {
        width: 82px;
    }

    .team-crest .team-crest-core {
        width: 64px;
        height: 64px;
        border-radius: 16px;
        font-size: 1.1rem;
    }

    .team-identity-page .team-hero-title {
        font-size: 1.45rem;
    }

    .team-identity-page .team-hero-desc {
        font-size: 0.9rem;
        line-height: 1.82;
    }

    .team-identity-page .department-tabs {
        grid-template-columns: 1fr;
    }

    .team-identity-page .team-grid {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }

    .team-identity-page .team-card {
        border-radius: 16px;
        max-width: none;
    }

    .team-identity-page .team-avatar {
        width: 82px;
        height: 82px;
        border-radius: 18px;
    }

    .team-future-panel {
        border-radius: 18px;
        padding: 1.05rem 0.9rem;
    }
}
