/* SP POS Setup Widget - V2 Design (Connection Style) */

.sp-pos-setup--v2 {
    padding: 0;
    background-color: var(--nexros-bg);
    /* Break out of Elementor Boxed limits */
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    width: 100vw;
    max-width: 100vw;
    overflow-x: hidden;
}

.sp-pos-setup--v2 .sp-container-fluid {
    max-width: 1440px !important;
    margin: 0 auto;
    padding: 0 40px !important;
}

.sp-pos-setup__wrapper {
    display: flex;
    flex-wrap: wrap;
    align-items: center; /* Prevent items from stretching to match height */
    gap: 40px; /* Space between columns */
}

.sp-pos-setup__wrapper.reverse {
    flex-direction: row-reverse;
}

/* Left Column: Video Background */
.sp-pos-setup__video-col {
    flex: 0 0 45%; /* Slightly smaller than 50% to account for gap */
    max-width: 550px; /* Optional cap */
    position: relative;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    aspect-ratio: 1 / 1 !important; /* Perfect square */
    border-radius: 2rem;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sp-pos-setup__video-col .video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
}

.sp-pos-setup__video-col .video-popup-btn {
    position: relative;
    z-index: 2;
}

.sp-pos-setup__video-col .play-btn {
    width: 100px;
    height: 100px;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primaryColor);
    text-decoration: none;
    transition: transform 0.3s ease, background-color 0.3s ease;
    box-shadow: 0 0 0 10px rgba(255, 255, 255, 0.2);
    animation: pulse-white 2.5s infinite;
}

@keyframes pulse-white {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 0, 0, 0.6);
    }

    70% {
        box-shadow: 0 0 0 25px rgba(255, 255, 255, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0);
    }
}

.sp-pos-setup__video-col .play-btn:hover {
    transform: scale(1.1);
    background-color: var(--primaryColor);
    color: #111827;
    animation-play-state: paused;
}

.sp-pos-setup__video-col .play-icon svg {
    width: 30px;
    height: 30px;
    margin-left: 5px;
}

/* Right Column: Content */
.sp-pos-setup__content-col {
    flex: 1; /* Take remaining space */
    padding: 40px 0; /* Reduced padding */
    display: flex;
    align-items: center;
}

.sp-pos-setup__content-col .content-inner {
    width: 100%;
}

.sp-pos-setup__content-col .main-title {
    font-size: 38px;
    font-weight: 700;
    color: #111827;
    line-height: 1.1;
    margin-bottom: 50px;
    font-family: var(--primaryFont);
    letter-spacing: -0.01em;
}

/* Icon Grid */
.icon-grid {
    display: grid;
    grid-template-columns: 1fr; /* Full width items */
    gap: 30px;
}

.icon-box-item {
    display: flex;
    flex-direction: row;
    /* Horizontal for side-by-side icon and content */
    gap: 15px;
    align-items: flex-start;
}

.icon-box-item .item-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
    /* Slightly tighter gap between title and description */
}

.icon-box-item .item-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    color: var(--primaryColor);
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-box-item .item-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #111827;
    margin: 0;
    font-family: var(--primaryFont);
}

.icon-box-item .item-desc {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--greyColor600);
    margin: 0;
    max-width: 600px; /* Limit for better readability */
}

/* If the title is empty (common in mission sections), make the description feel more like an intro paragraph */
.icon-box-item .item-title:empty {
    display: none;
}

.icon-box-item:only-child,
.icon-box-item .item-title:empty + .item-desc {
    font-size: 1.125rem;
    color: #4b5563;
    max-width: 100%;
}

/* --- Updated Responsive Section --- */

@media (max-width: 1199px) {
    .sp-pos-setup__wrapper {
        min-height: auto;
    }

    .sp-pos-setup__content-col {
        padding: 40px 0;
    }

    /* Slightly smaller title for small desktops/large tablets */
    .sp-pos-setup__content-col .main-title {
        font-size: 32px;
        margin-bottom: 40px;
    }
}

/* TABLET OPTIMIZATION */
@media (max-width: 991px) {
    .sp-pos-setup__video-col,
    .sp-pos-setup__content-col {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .sp-pos-setup__video-col {
        height: 450px;
        border-radius: 1.5rem;
    }

    /* Tablet Typography */
    .sp-pos-setup__content-col .main-title {
        font-size: 28px; /* Optimized for Tablet */
        text-align: left;
        margin-bottom: 35px;
    }

    .icon-grid {
        grid-template-columns: 1fr; /* Keep it single column for better text flow */
        gap: 25px;
    }

    .icon-box-item .item-title {
        font-size: 1.15rem;
    }

    .icon-box-item .item-desc {
        font-size: 1rem;
        line-height: 1.6;
    }
}

/* MOBILE OPTIMIZATION */
@media (max-width: 575px) {
    .sp-pos-setup--v2 .sp-container-fluid {
        padding: 0 20px !important; /* Tighter padding for mobile */
    }

    .sp-pos-setup__video-col {
        height: 300px;
        border-radius: 1rem;
    }

    .sp-pos-setup__video-col .play-btn {
        width: 65px;
        height: 65px;
    }

    .sp-pos-setup__video-col .play-icon svg {
        width: 18px;
        height: 18px;
    }

    /* Mobile Typography */
    .sp-pos-setup__content-col {
        padding: 30px 0;
    }

    .sp-pos-setup__content-col .main-title {
        font-size: 24px; /* Scaled down for mobile screens */
        line-height: 1.2;
        margin-bottom: 25px;
    }

    .icon-grid {
        gap: 20px;
    }

    .icon-box-item {
        gap: 12px;
    }

    .icon-box-item .item-title {
        font-size: 1.1rem;
    }

    .icon-box-item .item-desc {
        font-size: 0.95rem; /* Slightly smaller for readability */
        line-height: 1.5;
    }

    .icon-box-item .item-icon {
        width: 20px;
        height: 20px;
    }
}