/**
 * Image with Text and Logos Block Styles
 * 
 * Colors:
 * - Primary Green: #006a3c
 * - Gold/Yellow: #f7b119
 * - Light Gray: #f5f6f6
 * - Text Dark: #252525
 * - Text Light: #b0cfc1
 * 
 * Fonts:
 * - Roboto Bold
 * - Roboto Regular
 */

/* ============================================
   Block Container
   ============================================ */
.image-text-logos-block {
    width: 100%;
    padding: 80px 0;
    padding-bottom: 0 !important;
    background-color: #ffffff;
}

.itl-container {
    max-width: var(--theme-normal-container-max-width, 1290px);
    width: var(--theme-container-width, 100%);
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================
   Content Wrapper (Two Columns)
   ============================================ */
.itl-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
}

/* Swapped Layout (when checkbox is checked)
   The DOM order is changed in the template, so the grid 
   automatically displays image on left, text on right */

/* ============================================
   Left Column: Content
   ============================================ */
.itl-content-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Heading */
.itl-heading {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    font-size: 48px;
    line-height: 1.3;
    color: #252525;
    margin: 0 0 10px 0;
    padding-top: 20px;
}

/* Text Content */
.itl-text-content {
    font-family: 'Roboto', sans-serif;
    font-weight: 400;
    font-size: 18px;
    line-height: 1.6;
    color: #252525;
}

.itl-text-content p {
    margin: 0 0 15px 0;
}

.itl-text-content p:last-child {
    margin-bottom: 0;
}

/* List Styles - Default */
.itl-text-content.list-style-default ul {
    list-style: disc;
    padding-left: 20px;
    margin: 15px 0;
}

.itl-text-content.list-style-default ul li {
    margin-bottom: 10px;
    padding-left: 5px;
}

/* List Styles - Green Dots */
.itl-text-content.list-style-dot ul {
    list-style: none;
    padding-left: 0;
    margin: 15px 0;
}

.itl-text-content.list-style-dot ul li {
    position: relative;
    padding-left: 40px;
    margin-bottom: 15px;
    line-height: 1.6;
}

.itl-text-content.list-style-dot ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 20px;
    height: 20px;
    background-color: #006a3c;
    border-radius: 50%;
}

/* List Styles - Green Ticks */
.itl-text-content.list-style-tick ul {
    list-style: none;
    padding-left: 0;
    margin: 15px 0;
}

.itl-text-content.list-style-tick ul li {
    position: relative;
    padding-left: 50px;
    margin-bottom: 20px;
    line-height: 1.6;
    font-weight: 700;
}

.itl-text-content.list-style-tick ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background-image: url('../images/Green-Tick.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

/* ============================================
   Logos Section
   ============================================ */
.itl-logos-wrapper {
    display: flex;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

.itl-logo-item {
    max-height: 240px;
    display: flex;
    align-items: center;
}

.itl-logo-item img {
    max-height: 240px;
    width: 200px;
    height: auto;
    object-fit: contain;
}

/* ============================================
   Button (Default and Hover States)
   ============================================ */
.itl-button-wrapper {
    margin-top: 10px;
}

.itl-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 14px;
    background-color: #f7b119;
    color: #ffffff;
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    font-size: 16px;
    text-decoration: none;
    border-radius: 0;
    cursor: pointer;
    transition: all 0.3s ease;
}

.itl-button-icon {
    width: 14px;
    height: 14px;
    fill: #ffffff;
    transition: fill 0.3s ease;
}

.itl-button-icon-img {
    width: 20px;
    height: 20px;
    fill: #ffffff;
    transition: fill 0.3s ease;
}

.itl-button-text {
    line-height: 1;
}

/* Button Hover State */
.itl-button:hover {
    background-color: #006a3c;
    color: #ffffff;
}

.itl-button:hover .itl-button-icon {
    fill: #ffffff;
}

.itl-button:hover .itl-button-icon-img {
    fill: #ffffff;
}

/* Alternative button style (outlined default) */
.itl-button.outlined {
    background-color: transparent;
    border-color: #f7b119;
    color: #f7b119;
}

.itl-button.outlined .itl-button-icon {
    fill: #f7b119;
}

.itl-button.outlined .itl-button-icon-img {
    fill: #f7b119;
}

.itl-button.outlined:hover {
    background-color: #f7b119;
    color: #ffffff;
}

.itl-button.outlined:hover .itl-button-icon {
    fill: #ffffff;
}

.itl-button.outlined:hover .itl-button-icon-img {
    fill: #ffffff;
}

/* Green button variant */
.itl-button.green {
    background-color: #006a3c;
    border-color: #006a3c;
}

.itl-button.green:hover {
    background-color: transparent;
    border-color: #006a3c;
    color: #006a3c;
}

.itl-button.green:hover .itl-button-icon {
    fill: #006a3c;
}

.itl-button.green:hover .itl-button-icon-img {
    fill: #006a3c;
}

/* ============================================
   Right Column: Image
   ============================================ */
.itl-image-column {
    position: relative;
}

.itl-image-wrapper {
    width: 100%;
    height: 100%;
    border-radius: 0;
    overflow: visible;
    position: relative;
}

.itl-image-wrapper img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* Triangle decoration - default (image on right, triangle on bottom left) */
.itl-image-wrapper::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 0;
    border-right: 100px solid transparent;
    border-bottom: 100px solid #ffffff;
    z-index: 2;
}

/* Triangle decoration - swapped layout (image on left, triangle on bottom right) */
.swapped-layout .itl-image-wrapper::after {
    left: auto;
    right: 0;
    border-right: none;
    border-left: 100px solid transparent;
    border-bottom: 100px solid #ffffff;
    z-index: 2;
}

/* ============================================
   Responsive Design
   ============================================ */

/* Tablet */
@media (max-width: 1152px) {
    .itl-content-wrapper {
        gap: 40px;
    }
    
    .itl-heading {
        font-size: 32px;
    }

    .itl-logo-item img {
        max-height: 240px;
        width: 170px;
    }
    
}

/* Mobile */
@media (max-width: 768px) {
    .image-text-logos-block {
        padding: 40px 0;
    }
    
    .itl-content-wrapper {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .itl-heading {
        font-size: 28px;
    }
    
    .itl-text-content {
        font-size: 15px;
    }
    
    .itl-logos-wrapper {
        gap: 10px;
        grid-template-columns: repeat(2, 1fr);
        justify-content: flex-start;
    }
    
    .itl-logo-item {
        max-height: 250px;
    }
    
    .itl-logo-item img {
        max-height: 180px;
        width: 150px;
    }
    
    /* Stack image on top for mobile */
    .itl-image-column {
        order: -1;
    }
    
    /* Smaller triangle on mobile */
    .itl-image-wrapper::after {
        border-right-width: 70px;
        border-bottom-width: 70px;
    }
    
    .swapped-layout .itl-image-wrapper::after {
        border-left-width: 70px;
        border-bottom-width: 70px;
    }
    
    /* Adjust list styles for mobile */
    .itl-text-content.list-style-dot ul li {
        padding-left: 35px;
        margin-bottom: 12px;
    }
    
    .itl-text-content.list-style-dot ul li::before {
        width: 16px;
        height: 16px;
        top: 5px;
    }
    
    .itl-text-content.list-style-tick ul li {
        padding-left: 40px;
        margin-bottom: 15px;
        font-size: 15px;
    }
    
    .itl-text-content.list-style-tick ul li::before {
        width: 20px;
        height: 20px;
    }
}

/* ============================================
   Gutenberg Editor Specific Styles
   ============================================ */
.block-editor-block-list__block[data-type="acf/image-text-logos"] {
    margin: 20px 0;
}

.block-editor-block-list__block[data-type="acf/image-text-logos"] .image-text-logos-block {
    padding: 30px 0;
}

/* ============================================
   Alignment Support
   ============================================ */
.image-text-logos-block.alignwide .itl-container {
    max-width: var(--theme-normal-container-max-width, 1290px);
    width: var(--theme-container-width, 100%);
}

.image-text-logos-block.alignfull {
    width: 100%;
    padding-left: 0;
    padding-right: 0;
}

.image-text-logos-block.alignfull .itl-container {
    max-width: var(--theme-normal-container-max-width, 1290px);
    padding: 0 20px;
}

@media (max-width: 768px) {
    .image-text-logos-block.alignfull .itl-container {
        padding: 0 0px;
    }
}

