/* صفحه مدیران دفتر مرکزی — کاروسل team-card-two */
.hrhs-cm {
    overflow: hidden;
}

.hrhs-cm::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image: radial-gradient(rgba(68, 68, 68, 0.05) 1px, transparent 1px);
    background-size: 22px 22px;
    mask-image: linear-gradient(180deg, #000 0%, transparent 80%);
    -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 80%);
    pointer-events: none;
}

.hrhs-cm__orb {
    position: absolute;
    z-index: -1;
    border-radius: 50%;
    filter: blur(70px);
    pointer-events: none;
    animation: hrhs-cm-float 16s ease-in-out infinite;
}

.hrhs-cm__orb--one {
    width: 440px;
    height: 440px;
    top: -140px;
    right: -160px;
    background: rgba(var(--brand-primary-rgb, 251, 82, 13), 0.16);
}

.hrhs-cm__orb--two {
    width: 380px;
    height: 380px;
    bottom: -160px;
    left: -140px;
    background: rgba(255, 154, 92, 0.18);
    animation-delay: -8s;
    animation-direction: reverse;
}

@keyframes hrhs-cm-float {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    33% { transform: translate3d(-40px, 30px, 0) scale(1.08); }
    66% { transform: translate3d(30px, -20px, 0) scale(0.95); }
}

/* عنوان بخش */
.hrhs-cm .sec-title {
    margin-bottom: 48px;
}

.hrhs-cm .sec-title__tagline-rtl {
    gap: 8px;
    font-size: 17px;
    font-weight: 700;
}

.hrhs-cm .sec-title__tagline-rtl i {
    font-size: 15px;
}

.hrhs-cm .sec-title__title {
    color: #2f2f2f;
    font-weight: 800;
}

.hrhs-cm__intro {
    max-width: 720px;
    margin: 16px auto 0;
    font-size: 17px;
    line-height: 2;
    color: #5a5a5a;
}

.hrhs-cm__grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 18px;
    margin: 0;
    align-items: stretch;
}

.hrhs-cm__col {
    display: flex;
    min-width: 0;
    height: 100%;
}

.hrhs-cm__col > .team-card-two {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
}

.hrhs-cm__col > .team-card-two .team-card-two__image {
    flex: 1 1 auto;
}

@media (max-width: 1199px) {
    .hrhs-cm__grid {
        gap: 12px;
    }

    .hrhs-cm .team-card-two__content {
        padding: 14px 10px;
        gap: 8px;
    }

    .hrhs-cm-card__icon {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
}

@media (max-width: 767px) {
    .hrhs-cm__grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* کارت */
.hrhs-cm .team-card-two {
    --cm-rx: 0deg;
    --cm-ry: 0deg;
    --cm-lift: 0px;
    --cm-mx: 50%;
    --cm-my: 30%;
    border-radius: 24px;
    overflow: hidden;
    isolation: isolate;
    background-color: #222222;
    box-shadow: 0 24px 40px -18px rgba(34, 34, 34, 0.35);
    transform: perspective(1100px) rotateX(var(--cm-rx)) rotateY(var(--cm-ry)) translateY(var(--cm-lift));
    transition:
        transform 0.55s cubic-bezier(0.22, 1, 0.36, 1),
        background-color 0.45s ease,
        box-shadow 0.5s ease;
    will-change: transform;
}

.hrhs-cm .team-card-two.is-tilting {
    transition:
        transform 0.15s linear,
        background-color 0.45s ease,
        box-shadow 0.5s ease;
}

.hrhs-cm .team-card-two:hover {
    --cm-lift: -10px;
    background-color: var(--brand-primary, #fb520d);
    box-shadow: 0 36px 50px -20px rgba(var(--brand-primary-rgb, 251, 82, 13), 0.55);
}

.hrhs-cm .team-card-two__image {
    padding: 14px 14px 0;
    border-radius: 24px 24px 0 0;
}

.hrhs-cm .team-card-two__image::before {
    height: 100%;
    background: linear-gradient(180deg, var(--brand-primary, #fb520d) 0%, #ff8a4c 100%);
    transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

/* پرتره (جایگزین عکس) */
.hrhs-cm-card__portrait {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    aspect-ratio: 3 / 3.2;
    overflow: hidden;
    border-radius: 16px 16px 0 0;
    background:
        radial-gradient(circle at 50% 42%, rgba(var(--brand-primary-rgb, 251, 82, 13), 0.3), transparent 60%),
        linear-gradient(165deg, #5c5c60 0%, #3d3d41 55%, #2c2c30 100%);
    filter: grayscale(0.85);
    transition: filter 0.6s ease;
}

.hrhs-cm-card__portrait::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 45%;
    background: linear-gradient(0deg, rgba(20, 20, 22, 0.55), transparent);
    pointer-events: none;
}

.hrhs-cm .team-card-two:hover .hrhs-cm-card__portrait {
    filter: grayscale(0);
}

.hrhs-cm-card__silhouette {
    position: relative;
    z-index: 1;
    margin-bottom: -6px;
    font-size: clamp(72px, 7.5vw, 120px);
    line-height: 1;
    color: rgba(255, 255, 255, 0.86);
    transform-origin: 50% 100%;
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), color 0.5s ease;
}

.hrhs-cm .team-card-two:hover .hrhs-cm-card__silhouette {
    color: #ffffff;
    transform: scale(1.07) translateY(-4px);
}

.hrhs-cm-card__orbit {
    position: absolute;
    top: 14%;
    left: 50%;
    width: 62%;
    aspect-ratio: 1;
    margin-left: -31%;
    border: 2px dashed rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    animation: hrhs-cm-spin 22s linear infinite;
    transition: border-color 0.5s ease;
}

.hrhs-cm-card__orbit::before {
    content: "";
    position: absolute;
    top: -7px;
    left: 50%;
    width: 12px;
    height: 12px;
    margin-left: -6px;
    border-radius: 50%;
    background: var(--brand-primary, #fb520d);
    box-shadow: 0 0 0 5px rgba(var(--brand-primary-rgb, 251, 82, 13), 0.25), 0 0 18px rgba(var(--brand-primary-rgb, 251, 82, 13), 0.8);
}

.hrhs-cm-card__orbit::after {
    content: "";
    position: absolute;
    inset: 14%;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.14);
    animation: hrhs-cm-pulse 3.2s ease-out infinite;
}

.hrhs-cm .team-card-two:hover .hrhs-cm-card__orbit {
    border-color: rgba(255, 255, 255, 0.4);
    animation-duration: 8s;
}

@keyframes hrhs-cm-spin {
    to { transform: rotate(360deg); }
}

@keyframes hrhs-cm-pulse {
    0% { transform: scale(0.85); opacity: 0.9; }
    100% { transform: scale(1.45); opacity: 0; }
}

/* بخش متنی */
.hrhs-cm .team-card-two__content {
    flex: 0 0 auto;
    align-items: center;
    height: 104px;
    min-height: 104px;
    max-height: 104px;
    padding: 16px 12px;
    gap: 10px;
}

.hrhs-cm .team-card-two__content::after {
    width: 36px;
}

.hrhs-cm .team-card-two__info {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
}

.hrhs-cm .team-card-two__name {
    margin: 0 0 6px;
    font-size: clamp(12px, 0.95vw, 15px);
    font-weight: 800;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hrhs-cm .team-card-two__designation {
    margin: 0;
    font-size: clamp(11px, 0.85vw, 13px);
    line-height: 1.45;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: rgba(255, 255, 255, 0.82);
    transition: color 0.4s ease;
}

.hrhs-cm .team-card-two:hover .team-card-two__designation {
    color: #ffffff;
}

.hrhs-cm-card__icon {
    position: relative;
    z-index: 1;
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 16px;
    color: var(--brand-primary, #fb520d);
    background-color: #ffffff;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), color 0.4s ease;
}

.hrhs-cm .team-card-two:hover .hrhs-cm-card__icon {
    color: #222222;
    transform: rotate(360deg) scale(1.08);
}

/* نور دنبال‌کننده نشانگر و برق عبوری */
.hrhs-cm-card__glow,
.hrhs-cm-card__shine {
    position: absolute;
    inset: 0;
    z-index: 3;
    pointer-events: none;
}

.hrhs-cm-card__glow {
    background: radial-gradient(circle at var(--cm-mx) var(--cm-my), rgba(255, 255, 255, 0.22), transparent 45%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.hrhs-cm .team-card-two:hover .hrhs-cm-card__glow {
    opacity: 1;
}

.hrhs-cm-card__shine {
    background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.32) 48%, transparent 66%);
    transform: translateX(110%);
}

.hrhs-cm .team-card-two:hover .hrhs-cm-card__shine {
    transform: translateX(-110%);
    transition: transform 1s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ورود پلکانی کارت‌ها */
.hrhs-cm__grid.is-animated .hrhs-cm__col:not(.is-revealed) {
    opacity: 0;
}

.hrhs-cm__grid .hrhs-cm__col.is-revealed {
    animation: hrhs-cm-rise 1s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: calc(var(--cm-i, 0) * 140ms);
}

@keyframes hrhs-cm-rise {
    0% {
        opacity: 0;
        transform: translateY(60px) scale(0.94);
        filter: blur(6px);
    }
    100% {
        opacity: 1;
        transform: none;
        filter: none;
    }
}

@media (max-width: 767px) {
    .hrhs-cm .sec-title {
        margin-bottom: 36px;
    }

    .hrhs-cm__intro {
        font-size: 15.5px;
    }

    .hrhs-cm-card__portrait {
        aspect-ratio: 370 / 340;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hrhs-cm__orb,
    .hrhs-cm-card__orbit,
    .hrhs-cm-card__orbit::after {
        animation: none;
    }

    .hrhs-cm .team-card-two,
    .hrhs-cm-card__shine {
        transition: none;
    }
}
