/* =============================================
   Testimonials Carousel Styles (tc- prefix)
   Section: آراء الطلاب عنا
   ============================================= */

/* ---- Section Container ---- */
.tc-section {
    padding: 70px 0 60px;
    background: var(--light-bg, #f8f9fa);
    overflow: hidden;
}

/* ---- Section Header ---- */
.tc-header {
    text-align: center;
    margin-bottom: 40px;
}

.tc-header .section-title {
    margin-bottom: 18px;
}

/* Decorative divider with chat icon */
.tc-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin: 0 auto 10px;
    max-width: 600px;
}

.tc-divider::before,
.tc-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color, #ddd);
}

.tc-divider-icon {
    width: 28px;
    height: 28px;
    margin: 0 16px;
    color: var(--text-gray, #777);
    flex-shrink: 0;
}

/* ---- Carousel Viewport ---- */
.tc-viewport {
    position: relative;
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 50px;
}

/* Track wrapper clips overflow */
.tc-track-wrapper {
    overflow: hidden;
    border-radius: var(--border-radius, 8px);
}

/* Track holds all cards in a row */
.tc-track {
    display: flex;
    gap: 20px;
    transition: transform 0.45s cubic-bezier(0.25, 0.8, 0.25, 1);
    cursor: grab;
    user-select: none;
}

.tc-track.tc-dragging {
    transition: none;
    cursor: grabbing;
}

/* ---- Individual Card ---- */
.tc-card {
    flex: 0 0 calc((100% - 40px) / 3);
    min-width: 0;
    background: #fff;
    border: 1px solid var(--border-color, #e8e8e8);
    border-radius: var(--border-radius-lg, 12px);
    box-shadow: var(--shadow-sm, 0 2px 8px rgba(0, 0, 0, 0.06));
    overflow: hidden;
    transition: box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.tc-card:hover {
    box-shadow: var(--shadow-md, 0 4px 16px rgba(0, 0, 0, 0.1));
}

/* ---- Card Header ---- */
.tc-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px;
    border-bottom: 1px solid var(--border-color, #eee);
}

/* Student info group: flag + name + university */
.tc-student-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Country flag emoji in a circle */
.tc-flag {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
    border: 2px solid #e8e8e8;
    overflow: hidden;
}

/* Name + university wrapper */
.tc-name-wrap {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.tc-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark, #222);
    line-height: 1.3;
}

.tc-university {
    font-size: 0.78rem;
    color: var(--text-gray, #888);
    line-height: 1.3;
}

/* Social media icon */
.tc-social {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tc-social svg {
    width: 24px;
    height: 24px;
}

/* ---- Card Body ---- */
.tc-card-body {
    padding: 18px 20px 22px;
    flex: 1;
}

.tc-text {
    font-size: 0.92rem;
    line-height: 1.75;
    color: var(--text-dark, #333);
    margin: 0;
    text-align: right;
}

/* ---- Navigation Arrows ---- */
.tc-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fff;
    border: 1px solid var(--border-color, #ddd);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
    transition: all 0.25s ease;
    padding: 0;
    color: var(--text-dark, #333);
}

.tc-arrow:hover {
    background: var(--primary-color, #112d53);
    color: #fff;
    border-color: var(--primary-color, #112d53);
}

.tc-arrow:disabled {
    opacity: 0.3;
    cursor: default;
    pointer-events: none;
}

.tc-arrow svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* RTL: prev arrow on the right, next on the left */
.tc-prev {
    right: 2px;
}

.tc-next {
    left: 2px;
}

/* ---- Pagination Dots ---- */
.tc-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 30px;
    padding: 0;
}

.tc-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: none;
    background: #d0d0d0;
    cursor: pointer;
    padding: 0;
    transition: all 0.3s ease;
}

.tc-dot:hover {
    background: #aaa;
}

.tc-dot.active {
    background: var(--primary-color, #112d53);
    width: 12px;
    height: 12px;
}

/* ===========================================
   Responsive Breakpoints
   =========================================== */

/* Tablet: 2 cards per view */
@media (max-width: 1024px) {
    .tc-card {
        flex: 0 0 calc((100% - 20px) / 2);
    }

    .tc-viewport {
        padding: 0 45px;
    }

    .tc-section {
        padding: 60px 0 50px;
    }
}

/* Mobile: 1 card per view */
@media (max-width: 640px) {
    .tc-card {
        flex: 0 0 100%;
    }

    .tc-viewport {
        padding: 0 40px;
    }

    .tc-section {
        padding: 50px 0 40px;
    }

    .tc-card-header {
        padding: 14px 16px;
    }

    .tc-card-body {
        padding: 14px 16px 18px;
    }

    .tc-flag {
        width: 36px;
        height: 36px;
        font-size: 20px;
    }

    .tc-name {
        font-size: 0.92rem;
    }

    .tc-text {
        font-size: 0.88rem;
    }

    .tc-arrow {
        width: 34px;
        height: 34px;
    }

    .tc-arrow svg {
        width: 17px;
        height: 17px;
    }

    .tc-prev {
        right: 2px;
    }

    .tc-next {
        left: 2px;
    }
}
