/**
 * Two Columns Franchising Veterans — scoped from franchising.html (.franchising-veterans).
 * Reviews carousel controls match NewsRoom (dots + arrows + infinite JS).
 */

/* Gutenberg wraps the section; without this, flex children can force page-wide overflow on small laptops */
.wp-block-acf-two-columns-franchising-veterans {
    max-width: 100%;
    box-sizing: border-box;
    min-width: 0;
}

.two-columns-franchising-veterans-block {
    position: relative;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 100px 80px;
    font-family: 'Inter', system-ui, sans-serif;
    min-width: 0;
    overflow-x: hidden;
}

.two-columns-franchising-veterans-block .franchising-veterans-inner {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 72px;
    width: 100%;
    min-width: 0;
}

/* ----- Header ----- */
.two-columns-franchising-veterans-block .franchising-veterans-header {
    text-align: center;
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
    box-sizing: border-box;
}

/* Long titles from ACF should wrap inside the header column */
.two-columns-franchising-veterans-block .franchising-veterans-header .es-section-title,
.two-columns-franchising-veterans-block .franchising-veterans-header .es-section-subtitle {
    max-width: 100%;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.two-columns-franchising-veterans-block .franchising-veterans-header .home-section-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Label crown: theme .es-icon-titles */

.two-columns-franchising-veterans-block .franchising-veterans-header .home-section-label span {
    color: #0097a7;
    font-weight: 700;
    font-size: 16px;
    line-height: 1.5;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Header: theme .es-section-title / .es-section-subtitle */

/* ----- Two columns ----- */
/* Match text-image-block__body / veterans-body: constrain flex row so copy column can shrink
   instead of forcing horizontal overflow (especially with long words or embedded media). */
.two-columns-franchising-veterans-block .franchising-veterans-body {
    display: flex;
    gap: 120px;
    align-items: center;
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
}

.two-columns-franchising-veterans-block .franchising-veterans-content {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    gap: 88px;
    min-width: 0;
    /* Explicit width cap: needed when stacked or inside WP layout wrappers */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.two-columns-franchising-veterans-block .franchising-veterans-text {
    display: flex;
    flex-direction: column;
    gap: 24px;
    min-width: 0;
    max-width: 100%;
}

/* WYSIWYG: break long URLs/strings; cap embedded media (ACF HTML) like other blocks */
.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg {
    max-width: 100%;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg img,
.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg video,
.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg iframe {
    max-width: 100%;
    height: auto;
}

/* WYSIWYG body: match franchising-veterans-text paragraph + list styles */
.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg p {
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 400;
    font-size: 18px;
    line-height: 1.5;
    color: var(--smith-grey, #404a50);
    margin: 0 0 1em;
}

.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg p:last-child {
    margin-bottom: 0;
}

.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg ul {
    margin: 0;
    padding-left: 24px;
}

.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg li {
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 400;
    font-size: 18px;
    line-height: 1.5;
    color: var(--smith-grey, #404a50);
    margin-bottom: 8px;
}

.two-columns-franchising-veterans-block .franchising-veterans-wysiwyg li small {
    font-size: 12px;
}

/* CTA link (from home-hero-card-link in design system) */
/* inline-block + max-width so long CTA strings wrap inside the column (see cta-two-columns pattern) */
.two-columns-franchising-veterans-block .home-hero-card-link {
    display: inline-block;
    max-width: 100%;
    margin-top: 8px;
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 700;
    font-size: 18px;
    line-height: 1.5;
    color: var(--orange, #e57440);
    text-decoration: none;
    vertical-align: top;
}

.two-columns-franchising-veterans-block .home-hero-card-link .link-label {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.two-columns-franchising-veterans-block .home-hero-card-link .link-arrow {
    display: inline-block;
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 700;
    font-size: 18px;
    line-height: 1.5;
    text-decoration: none;
    margin-left: 4px;
    transition: transform 0.2s ease;
}

.two-columns-franchising-veterans-block .home-hero-card-link:hover .link-arrow {
    transform: translateX(2px);
}

.two-columns-franchising-veterans-block .home-hero-card-link:hover {
    color: var(--link-light-hover, #f26828);
}

.two-columns-franchising-veterans-block .home-hero-card-link:active {
    color: var(--link-light-pressed, #c87400);
}

.two-columns-franchising-veterans-block .home-hero-card-link:focus-visible {
    outline: 2px solid var(--link-light-pressed, #c87400);
    outline-offset: 2px;
    border-radius: 2px;
}

/* ----- Reviews carousel (NewsRoom-style controls) ----- */
.two-columns-franchising-veterans-block .tcfv-reviews-wrap {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.two-columns-franchising-veterans-block .tcfv-reviews-carousel {
    width: 100%;
    overflow: hidden;
}

.two-columns-franchising-veterans-block .tcfv-reviews-carousel-track {
    display: flex;
    gap: 0;
    transition: transform 0.45s ease;
}

.two-columns-franchising-veterans-block .tcfv-review-slide {
    flex: 0 0 100%;
    min-width: 0;
    box-sizing: border-box;
}

/* Testimonial card */
.two-columns-franchising-veterans-block .franchising-veterans-testimonial {
    background: #f6fbfc;
    backdrop-filter: blur(21px);
    border-radius: 8px;
    padding: 32px 24px;
    box-shadow: 0px 4px 5px -1px rgba(0, 88, 95, 0.12);
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.two-columns-franchising-veterans-block .franchising-veterans-stars {
    width: 116px;
    height: 19px;
}

.two-columns-franchising-veterans-block .franchising-veterans-stars--dynamic {
    width: auto;
    height: auto;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 4px;
    flex-wrap: nowrap;
}

.two-columns-franchising-veterans-block .franchising-veterans-stars--dynamic svg {
    flex-shrink: 0;
    display: block;
}

.two-columns-franchising-veterans-block .franchising-veterans-quote {
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    color: var(--smith-grey, #404a50);
    margin: 0;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.two-columns-franchising-veterans-block .franchising-veterans-author {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-top: 16px;
    min-width: 0;
}

.two-columns-franchising-veterans-block .franchising-veterans-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
}

.two-columns-franchising-veterans-block .franchising-veterans-author-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.two-columns-franchising-veterans-block .franchising-veterans-name {
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 700;
    font-size: 22px;
    color: #0097a7;
    margin: 0;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.two-columns-franchising-veterans-block .franchising-veterans-role {
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 400;
    font-size: 16px;
    color: var(--smith-grey, #404a50);
    margin: 0;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

/* Controls — mirror .newsroom-controls */
.two-columns-franchising-veterans-block .tcfv-reviews-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-top: 24px;
}

.two-columns-franchising-veterans-block .tcfv-reviews-dots {
    display: flex;
    gap: 8px;
}

.two-columns-franchising-veterans-block .tcfv-reviews-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ccc;
    border: none;
    cursor: pointer;
    padding: 0;
    transition: background-color 0.2s ease;
}

.two-columns-franchising-veterans-block .tcfv-reviews-dot:hover {
    background: #999;
}

.two-columns-franchising-veterans-block .tcfv-reviews-dot.active {
    background: var(--orange, #e57440);
}

.two-columns-franchising-veterans-block .tcfv-reviews-dot:focus-visible {
    outline: 2px solid var(--orange, #e57440);
    outline-offset: 2px;
}

.two-columns-franchising-veterans-block .tcfv-reviews-arrows {
    display: flex;
    gap: 12px;
}

.two-columns-franchising-veterans-block .tcfv-reviews-arrow {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.two-columns-franchising-veterans-block .tcfv-reviews-arrow img {
    width: 15px;
    height: 11px;
}

/* Image column — must be allowed to shrink in the row; flex-shrink:0 caused horizontal overflow
   between ~1025px and ~1200px when copy + gap + fixed image width exceeded the inner width */
.two-columns-franchising-veterans-block .franchising-veterans-image {
    position: relative;
    /* flex-shrink 1 (via 0 1 auto) lets this column yield width so .franchising-veterans-content can stay in view */
    flex: 0 1 auto;
    min-width: 0;
    max-width: 100%;
    padding-right: 96px;
    box-sizing: border-box;
}

.two-columns-franchising-veterans-block .franchising-veterans-image img {
    width: 100%;
    max-width: 519px;
    height: auto;
    max-height: 633px;
    object-fit: cover;
    display: block;
}

/* Tighten row gap on smaller desktops so the text column keeps room before 1024px stack */
@media (max-width: 1200px) {
    .two-columns-franchising-veterans-block .franchising-veterans-body {
        gap: 48px;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-image {
        padding-right: 32px;
    }
}

/* ----- Tablet ----- */
@media (max-width: 1024px) {
    .two-columns-franchising-veterans-block {
        padding: 80px 40px;
    }

    /* Same idea as .franchising-building-text at 1024px in styles.css: full-width column when stacked */
    .two-columns-franchising-veterans-block .franchising-veterans-body {
        flex-direction: column;
        gap: 60px;
        align-items: stretch;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-content {
        gap: 48px;
        flex: none;
        width: 100%;
        max-width: 100%;
    }

    /* Theme defaults use nowrap on labels; allow wrap on tablet so long labels do not spill */
    .two-columns-franchising-veterans-block .franchising-veterans-header .home-section-label {
        flex-wrap: wrap;
        justify-content: center;
        row-gap: 4px;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-header .home-section-label span {
        white-space: normal;
        text-align: center;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-image {
        padding-right: 0;
        order: -1;
        width: 100%;
        max-width: 100%;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-image img {
        width: 100%;
        max-width: 519px;
        height: auto;
        margin: 0 auto;
    }
}

/* ----- Mobile ----- */
@media (max-width: 768px) {
    .two-columns-franchising-veterans-block {
        padding: 60px 24px;
        max-width: 100%;
        overflow-x: hidden;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-body {
        align-items: stretch;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-inner {
        width: 100%;
        max-width: 100%;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-content {
        align-self: stretch;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-header {
        gap: 12px;
        max-width: 100%;
    }

    .two-columns-franchising-veterans-block .franchising-veterans-wysiwyg p,
    .two-columns-franchising-veterans-block .franchising-veterans-wysiwyg li {
        font-size: 16px;
    }

    .two-columns-franchising-veterans-block .home-hero-card-link {
        font-size: 16px;
    }

    .two-columns-franchising-veterans-block .tcfv-reviews-controls {
        margin-top: 20px;
    }
}

/* ----- Small mobile ----- */
@media (max-width: 480px) {
    .two-columns-franchising-veterans-block .franchising-veterans-name {
        font-size: 18px;
    }
}
