/* ============================================================
   CLIENT SLIDER - Tooltip Fix (tidak terpotong overflow hidden)
   ============================================================ */

/* Ganti tooltip di atas → pakai label DI BAWAH card, di luar mask */
/* Solusi: tooltip muncul di BAWAH card, masih dalam cl-slider-wrapper */

.our-clients * {
    box-sizing: border-box;
}

.our-clients {
    background-color: #f8f9fa;
    position: relative;
    margin-top: 0px;
    padding-top: 120px;
    overflow: visible;
}

.our-clients .section-heading {
    text-align: center;
    margin-bottom: 45px;
}

.our-clients .section-heading h6 {
    font-size: 12px;
    color: var(--secondary-color);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    margin-bottom: 15px;
}

.our-clients .section-heading h2 {
    font-size: 32px;
    text-transform: capitalize;
    color: #2a2a2a;
    font-weight: 700;
    letter-spacing: 0.25px;
    position: relative;
    z-index: 2;
    line-height: 1.3;
    margin-bottom: -5px;
}

.our-clients .section-heading h2 em {
    font-style: normal;
    color: var(--primary-color);
}

.our-clients .section-heading h2 span {
    color: var(--secondary-color);
    font-weight: 700;
    opacity: 1;
    text-transform: capitalize;
}

.our-clients .section-heading span {
    font-size: 32px;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--secondary-color);
    opacity: 0.15;
}

/* ============================================================
   SLIDER WRAPPER — overflow visible supaya tooltip tidak clip
   ============================================================ */

.our-clients .cl-slider-wrapper {
    overflow: visible;
    position: relative;
    /* Extra padding bawah untuk ruang label nama */
    padding: 30px 0 50px;
    margin-top: -50px;
}

/* MASK tetap hidden hanya secara horizontal (clip kiri-kanan) */
/* Tapi kita buat mask hanya clip X, bukan Y */
.our-clients .cl-slider-mask {
    overflow: hidden;
    width: 100%;
    position: relative;
    /* Tambahkan padding bawah agar nama label tidak ter-clip */
    padding-bottom: 50px;
    margin-bottom: -50px;
}

.our-clients .cl-slider-wrapper::before,
.our-clients .cl-slider-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 40px;
    z-index: 2;
    pointer-events: none;
}

.our-clients .cl-slider-wrapper::before {
    left: 0;
    background: linear-gradient(to right, #f8f9fa, rgba(248, 249, 250, 0));
}

.our-clients .cl-slider-wrapper::after {
    right: 0;
    background: linear-gradient(to left, #f8f9fa, rgba(255, 255, 255, 0));
}

/* ============================================================
   SLIDER TRACK
   ============================================================ */

.our-clients .cl-slider {
    display: flex;
    gap: 30px;
    width: max-content;
    will-change: transform;
    backface-visibility: hidden;
    -webkit-font-smoothing: antialiased;
    -webkit-transform: translate3d(0, 0, 0);
    transform: translate3d(0, 0, 0);
}

@keyframes scrollClients {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ============================================================
   CLIENT CARD
   ============================================================ */

.our-clients .cl-item {
    flex: 0 0 220px;
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0px 0px 15px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.35s ease, transform 0.35s ease;
    cursor: pointer;
    margin: 15px 15px 0 15px; /* margin bawah 0, space untuk label di bawah */
    user-select: none;
    -webkit-user-select: none;
    position: relative;
    overflow: visible; /* penting! */
}

.our-clients .cl-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.12);
}

/* ============================================================
   LOGO
   ============================================================ */

.our-clients .cl-logo {
    max-width: 100%;
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.35s ease, filter 0.35s ease;
    pointer-events: none;
    display: block;
    position: relative;
    z-index: 1;
}

.our-clients .cl-item:hover .cl-logo {
    transform: scale(1.06);
    filter: brightness(1.05);
}

/* ============================================================
   NAMA LABEL — MUNCUL DI BAWAH CARD, TIDAK MENUTUPI LOGO
   Posisi: di luar card, di bawahnya, centered
   ============================================================ */

.our-clients .client-name-overlay {
    position: absolute;
    /* Di bawah card, di luar batas card */
    top: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%) translateY(-4px);
    white-space: nowrap;
    z-index: 50;

    /* Tampilan pill label */
    background: var(--primary-color, #0d6efd);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    padding: 5px 14px;
    border-radius: 30px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);

    /* Tersembunyi by default */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.28s ease, transform 0.28s ease, visibility 0.28s ease;
    pointer-events: none;
}

/* Panah kecil mengarah ke atas (ke card) */
.our-clients .client-name-overlay::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-bottom-color: var(--primary-color, #0d6efd);
}

/* Tampil saat hover */
.our-clients .cl-item:hover .client-name-overlay {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* ============================================================
   SPEED CONTROL
   ============================================================ */

.our-clients .cl-speed-toggle {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    color: #ffffff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    z-index: 10;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.our-clients .cl-speed-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.our-clients .cl-speed-panel {
    position: absolute;
    top: 60px;
    right: 10px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    padding: 16px;
    z-index: 11;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.our-clients .cl-speed-panel.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.our-clients .cl-speed-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e0e0e0;
}

.our-clients .cl-speed-header span {
    font-size: 13px;
    font-weight: 600;
    color: #2a2a2a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 1;
}

.our-clients .cl-close-panel {
    background: none;
    border: none;
    font-size: 20px;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.our-clients .cl-close-panel:hover {
    color: #2a2a2a;
}

.our-clients .cl-speed-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.our-clients .cl-speed-option {
    padding: 8px 12px;
    border: 2px solid #e0e0e0;
    background: #ffffff;
    color: #2a2a2a;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.our-clients .cl-speed-option:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.our-clients .cl-speed-option.active {
    background: var(--primary-color);
    color: #ffffff;
    border-color: var(--primary-color);
}

.our-clients .cl-speed-option i {
    font-size: 10px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 992px) {
    .our-clients { padding-top: 80px; }

    .our-clients .section-heading h6 { font-size: 11px; margin-bottom: 12px; }
    .our-clients .section-heading h2 { margin: 0px 15px; font-size: 26px; }

    .our-clients .cl-slider-wrapper { margin-top: 20px; }
    .our-clients .cl-item { flex: 0 0 200px; height: 130px; padding: 25px; margin: 10px 10px 0; }
    .our-clients .cl-slider { gap: 25px; }
    .our-clients .cl-speed-toggle { width: 36px; height: 36px; font-size: 14px; }
    .our-clients .cl-speed-panel { min-width: 180px; }
}

@media (max-width: 768px) {
    .our-clients { padding: 60px 0; }
    .our-clients .section-heading { margin-bottom: 35px; }
    .our-clients .section-heading h6 { font-size: 10px; margin-bottom: 10px; }
    .our-clients .section-heading h2 { font-size: 20px; margin: 0px 10px; }
    .our-clients .section-heading span { font-size: 20px; margin-top: 10px; }

    .our-clients .cl-slider-wrapper { padding: 25px 0 45px; margin-top: -30px; }
    .our-clients .cl-item { flex: 0 0 180px; height: 110px; padding: 20px; margin: 8px 8px 0; }
    .our-clients .cl-slider { gap: 20px; }

    .our-clients .cl-slider-wrapper::before,
    .our-clients .cl-slider-wrapper::after { width: 60px; }

    .our-clients .cl-speed-toggle { width: 34px; height: 34px; font-size: 13px; top: 8px; right: 8px; }
    .our-clients .cl-speed-panel { top: 50px; right: 8px; min-width: 160px; padding: 12px; }
    .our-clients .cl-speed-header span { font-size: 11px; }
    .our-clients .cl-speed-option { padding: 6px 10px; font-size: 11px; }

    .our-clients .client-name-overlay { font-size: 10px; padding: 4px 11px; }
}

@media (max-width: 576px) {
    .our-clients { padding: 50px 0; }
    .our-clients .section-heading { margin-bottom: 30px; }
    .our-clients .section-heading h2 { font-size: 22px; }
    .our-clients .section-heading span { font-size: 20px; }

    .our-clients .cl-slider-wrapper { padding: 20px 0 40px; margin-top: -35px; }
    .our-clients .cl-item { flex: 0 0 160px; height: 100px; padding: 18px; margin: 6px 6px 0; border-radius: 15px; }
    .our-clients .cl-slider { gap: 15px; }

    .our-clients .cl-slider-wrapper::before,
    .our-clients .cl-slider-wrapper::after { width: 40px; }
}

@media (max-width: 480px) {
    .our-clients { padding: 40px 0; }
    .our-clients .section-heading h2 { font-size: 20px; }
    .our-clients .section-heading span { font-size: 18px; }
    .our-clients .cl-slider-wrapper { margin-top: -40px; }
    .our-clients .cl-item { flex: 0 0 140px; height: 90px; padding: 15px; margin: 5px 5px 0; }
    .our-clients .cl-slider { gap: 12px; }
    .our-clients .cl-slider-wrapper::before,
    .our-clients .cl-slider-wrapper::after { width: 30px; }
}

@media (max-width: 400px) {
    .our-clients .section-heading h2 { font-size: 18px; }
    .our-clients .cl-slider-wrapper { margin-top: -45px; }
    .our-clients .cl-item { flex: 0 0 130px; height: 85px; padding: 12px; }
}