:root {
    /* SECTION-SPECIFIC VARIABLES */

    /* Colors */
    --to-testimonials-primary: #383455;
    /* Heading Color */
    --to-testimonials-secondary: #FBC430;
    /* Yellow Accent/Lines */
    --to-testimonials-body-bg: #FFFFFF;
    --to-testimonials-text-main: #000000;
    --to-testimonials-text-gray: #6A6A6A;

    /* Typography */
    --to-testimonials-heading-font: 'Montserrat', sans-serif;
    --to-testimonials-quote-font: 'Poppins', sans-serif;
    --to-testimonials-detail-font: 'Inter', sans-serif;
}

/* Main Section Styling */
.to-testimonials-section {
    padding-top: 80px;
    padding-bottom: 80px;
    width: 100%;
}

.to-testimonials-layout {
    display: flex;
    flex-direction: column;
    gap: 60px;
}

/* Sidebar (Left Column) */
.to-testimonials-sidebar {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 285px;
    /* Matches design height */
    width: 100%;
    max-width: 340px;
}

.to-sidebar-header {
    display: flex;
    flex-direction: column;
    gap: 6px;
    /* Calculated from design positioning */
}

.to-testimonials-sidebar h2 {
    font-family: var(--to-testimonials-heading-font);
    font-weight: 600;
    font-size: 32px;
    line-height: 39px;
    color: var(--to-testimonials-primary);
    margin: 0;
    letter-spacing: 0;
}

.to-divider {
    width: 136px;
    height: 2px;
    background-color: var(--to-testimonials-secondary);
    margin-top: 6px;
}

/* Navigation Buttons */
.to-nav-controls {
    display: flex;
    gap: 15px;
}

.to-nav-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s ease;
}

.to-nav-btn:hover {
    opacity: 0.8;
}

.to-nav-btn img {
    width: 100%;
    height: 100%;
    display: block;
}

/* Right Column Grid */
.to-testimonials-grid {
    display: flex;
    flex-direction: column;
    gap: 30px;
    width: 100%;
}

/* Slider Viewport (Mask) */
.to-testimonials-viewport {
    width: 100%;
    overflow: hidden;
    /* Masks the sliding content */
}

/* Slider Grid (Moving Track) */
.to-testimonials-grid {
    display: flex;
    flex-direction: column;
    gap: 30px;
    width: 100%;
}

/* Testimonial Cards */
.to-testimonial-card {
    display: flex;
    flex-direction: column;
    min-height: 285px;
    border-top: 1px solid var(--to-testimonials-secondary);
    border-bottom: 1px solid var(--to-testimonials-secondary);
    width: 100%;
}

.to-card-content {
    padding: 20px 6px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex-grow: 1;
    height: 100%;
}

.to-quote-text p {
    font-family: var(--to-testimonials-quote-font);
    font-weight: 400;
    font-size: 20px;
    line-height: 27.2px;
    /* 136% */
    color: var(--to-testimonials-text-main);
    margin: 0;
}

.to-author-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 40px;
    /* Minimum spacing if content is short */
}

.to-author-info h3 {
    font-family: var(--to-testimonials-detail-font);
    font-weight: 500;
    font-size: 18px;
    line-height: 25.2px;
    /* 140% */
    color: var(--to-testimonials-text-main);
    margin: 0;
}

.to-author-info p {
    font-family: var(--to-testimonials-detail-font);
    font-weight: 400;
    font-size: 14px;
    line-height: 19.6px;
    /* 140% */
    color: var(--to-testimonials-text-gray);
    margin: 0;
}

/* Mobile Styles (default) */
@media (max-width: 991px) {
    .to-testimonials-section {
        padding-top: 45px;
        padding-bottom: 45px;
    }

    .to-testimonials-layout {
        gap: 25px;
    }

    .to-testimonials-sidebar {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-end;
        min-height: auto;
        max-width: 100%;
    }

    .to-testimonials-sidebar h2 {
        font-size: 22px;
        line-height: 28px;
    }

    .to-divider {
        width: 90px;
        margin-top: 5px;
    }

    .to-nav-controls {
        flex-shrink: 0;
        gap: 12px;
    }

    .to-nav-btn {
        width: 28px;
        height: 28px;
    }

    /* Horizontal scrollable cards on mobile */
    .to-testimonials-viewport {
        width: 100%;
        overflow: hidden;
    }

    .to-testimonials-grid {
        display: flex;
        flex-direction: row;
        gap: 15px;
        width: auto;
        transition: transform 0.5s ease-in-out;
    }

    .to-testimonial-card {
        min-width: calc(100vw - 50px);
        max-width: calc(100vw - 50px);
        min-height: auto;
        flex-shrink: 0;
    }

    .to-card-content {
        padding: 18px 15px 18px 30px;
    }

    .to-quote-text p {
        font-size: 15px;
        line-height: 22px;
    }

    .to-author-info {
        margin-top: 20px;
    }

    .to-author-info h3 {
        font-size: 15px;
        line-height: 20px;
    }

    .to-author-info p {
        font-size: 12px;
        line-height: 16px;
    }
}

@media (max-width: 576px) {
    .to-testimonials-section {
        padding-top: 35px;
        padding-bottom: 35px;
    }

    .to-testimonials-layout {
        gap: 20px;
    }

    .to-testimonials-sidebar h2 {
        font-size: 20px;
        line-height: 26px;
    }

    .to-divider {
        width: 80px;
    }

    .to-nav-btn {
        width: 26px;
        height: 26px;
    }

    .to-testimonial-card {
        min-width: calc(100vw - 40px);
        max-width: calc(100vw - 40px);
    }

    .to-card-content {
        padding: 15px 12px 15px 25px;
    }

    .to-quote-text p {
        font-size: 14px;
        line-height: 21px;
    }

    .to-author-info {
        margin-top: 18px;
    }

    .to-author-info h3 {
        font-size: 14px;
    }

    .to-author-info p {
        font-size: 11px;
    }
}

/* Desktop Breakpoint */
@media (min-width: 992px) {
    .to-testimonials-layout {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
        gap: 80px;
    }

    .to-testimonials-viewport {
        max-width: 694px;
        /* 2 cards (332px * 2) + 30px gap */
    }

    .to-testimonials-grid {
        flex-direction: row;
        width: auto;
        /* Width determined by content */
        transition: transform 0.5s ease-in-out;
        /* Smooth sliding */
    }

    .to-testimonial-card {
        min-width: 332px;
        /* Fixed width for desktop slider calculation */
        max-width: 332px;
        /* Ensure consistency */
    }
}