/* ===========================================
   SOFTWARE MAIN PAGE – MEDIUM RESPONSIVE (601px–695px)
   =========================================== */

@media screen and (min-width: 601px) and (max-width: 695px) {

    /* ============================================
       SOFTWARE SHOWCASE WRAPPER
       ============================================ */

    .software-showcase-wrapper {
        width: calc(100% - 40px) !important;
        padding: 0 20px !important;
        gap: 50px !important;
    }

    .software-showcase-wrapper.software-showcase-top-layout {
        gap: 40px !important;
    }

    /* ============================================
       SECTION TITLE
       ============================================ */

    .software-section-title {
        font-size: 26px !important;
        margin: 0 0 -25px 0 !important;
        line-height: 1.3 !important;
    }

    /* ============================================
       SOFTWARE ITEMS GRID - 3 COLUMN MEDIUM LAYOUT
       ============================================ */

    .software-items-grid {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        grid-template-rows: auto !important;
        gap: 15px 12px !important;
        width: 100% !important;
        max-width: 100% !important;
        padding: 10px 0 !important;
    }

    /* Reset ALL negative margins */
    .software-items-grid .software-item {
        margin-top: 0 !important;
        margin-bottom: 0 !important;
    }

    .software-items-grid .software-item:nth-child(-n+4) {
        margin-top: 0 !important;
    }

    /* ============================================
       RESET EXPLICIT GRID POSITIONING
       All items flow naturally in 3-column grid
       ============================================ */

    .software-items-grid .software-item:nth-child(12) {
        grid-column: auto !important;
        grid-row: auto !important;
    }

    .software-items-grid .software-item:nth-child(13) {
        grid-column: auto !important;
        grid-row: auto !important;
    }

    /* ============================================
       SOFTWARE ITEM - EQUAL SIZING FOR ALL 13
       ============================================ */

    .software-item {
        position: relative !important;
        width: 100% !important;
        height: auto !important;
        aspect-ratio: auto !important;
        min-height: 85px !important;
        max-height: 110px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        opacity: 0.5 !important;
        overflow: visible !important;
    }

    .software-item.active {
        opacity: 1 !important;
    }

    /* ============================================
       IMG-MASK CONTAINER - CONSISTENT SIZE
       ============================================ */

    .software-items-grid .software-item .img-mask {
        position: relative !important;
        width: 100% !important;
        max-width: 180px !important;
        height: 80px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        overflow: visible !important;
        background-color: transparent !important;
    }

    /* ============================================
       IMAGES - UNIFORM SIZING FOR ALL LOGOS
       ============================================ */

    .software-items-grid .software-item img {
        width: 100% !important;
        height: auto !important;
        max-height: 75px !important;
        max-width: 160px !important;
        object-fit: contain !important;
        transform: scale(1) !important;
    }

    .software-items-grid .software-item.active img {
        transform: scale(1.02) !important;
    }

    .software-items-grid .software-item:hover img {
        transform: scale(1.05) !important;
    }

    /* ============================================
       DRIVE AI LOGO - Reset positioning
       ============================================ */

    .software-items-grid .software-item[data-software-id="7"] img {
        left: 0 !important;
        position: relative !important;
    }

    /* ============================================
       DIGIDINER SVG - Reset desktop overrides
       ============================================ */

    .software-items-grid .software-item[data-software-id="12"] img {
        width: 100% !important;
        height: auto !important;
        max-height: 45px !important;
        max-width: 160px !important;
        margin-left: 0 !important;
        transform: scale(1) !important;
    }

    .software-items-grid .software-item[data-software-id="12"]:hover img {
        transform: scale(1.05) !important;
    }

    .software-items-grid .software-item[data-software-id="12"].active img {
        transform: scale(1.02) !important;
    }

    /* ============================================
       ENSURE ALL 13 ITEMS VISIBLE
       ============================================ */

    .software-items-grid .software-item,
    .software-items-grid .software-item[data-software-id="0"],
    .software-items-grid .software-item[data-software-id="1"],
    .software-items-grid .software-item[data-software-id="2"],
    .software-items-grid .software-item[data-software-id="3"],
    .software-items-grid .software-item[data-software-id="4"],
    .software-items-grid .software-item[data-software-id="5"],
    .software-items-grid .software-item[data-software-id="6"],
    .software-items-grid .software-item[data-software-id="7"],
    .software-items-grid .software-item[data-software-id="8"],
    .software-items-grid .software-item[data-software-id="9"],
    .software-items-grid .software-item[data-software-id="10"],
    .software-items-grid .software-item[data-software-id="11"],
    .software-items-grid .software-item[data-software-id="12"] {
        display: flex !important;
        visibility: visible !important;
        opacity: 0.5 !important;
        position: relative !important;
    }

    .software-items-grid .software-item.active {
        opacity: 1 !important;
    }

    /* ============================================
       BOTTOM CONTENT AREA - SINGLE COLUMN
       ============================================ */

    .software-content-bottom {
        flex-direction: column !important;
        gap: 30px !important;
        padding: 0 !important;
        width: 100% !important;
    }

    .software-content-left-col {
        max-width: 100% !important;
        gap: 25px !important;
        order: 2 !important;
    }

    .software-content-right-col {
        width: 100% !important;
        justify-content: center !important;
        order: 1 !important;
    }

    /* ============================================
       TEXT CONTENT ADJUSTMENTS
       ============================================ */

    .showcase-paragraph {
        font-size: 16px !important;
        line-height: 26px !important;
    }

    .software-paragraph {
        min-height: auto !important;
    }

    .two-line-text {
        font-size: 20px !important;
        line-height: 28px !important;
    }

    .software-two-lines {
        min-height: auto !important;
        margin-top: 0 !important;
    }

    .two-words-text {
        font-size: 14px !important;
    }

    /* ============================================
       COMPLIANCE & OS ROW
       ============================================ */

    .software-compliance-os-row {
        flex-direction: row !important;
        gap: 30px !important;
    }

    .rect-img-wrapper,
    .os-img-wrapper {
        width: 200px !important;
        height: 65px !important;
    }

    /* ============================================
       SQUARE IMAGE
       ============================================ */

    .software-square-image {
        width: 100% !important;
        max-width: 100% !important;
    }

    .square-img-wrapper {
        width: 100% !important;
        max-width: 400px !important;
        height: auto !important;
        aspect-ratio: 1.08 !important;
        margin: 0 auto !important;
    }

    /* ============================================
       BENTO GRID - Custom 2-column layout
       ============================================ */

    .software-bento-grid {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        grid-template-rows: 220px 300px 370px !important;
        gap: 15px !important;
        padding: 0 20px !important;
        margin: 0 auto !important;
        max-width: calc(100vw - 40px) !important;
        box-sizing: border-box !important;
    }

    /* Card 1: 10M+ - Full width at top */
    .bento-card-tall {
        grid-column: 1 / -1 !important;
        grid-row: 1 !important;
        min-height: unset !important;
        height: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* 10M+ Card - 2-column layout for content */
    .bento-card-tall .bento-card-content {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        grid-template-rows: auto auto !important;
        gap: 10px 20px !important;
        align-items: center !important;
        height: 100% !important;
    }

    .bento-card-tall .bento-stat {
        grid-column: 1 !important;
        grid-row: 1 !important;
        text-align: left !important;
        margin: 0 !important;
    }

    .bento-card-tall .bento-title {
        grid-column: 1 !important;
        grid-row: 2 !important;
        margin: 0 !important;
        text-align: left !important;
        font-size: 16px !important;
    }

    .bento-card-tall .bento-text {
        grid-column: 2 !important;
        grid-row: 1 / 3 !important;
        align-self: center !important;
        font-size: 13px !important;
    }

    /* Card 2: Restaurants Powered - Right column, row 2 */
    .bento-card-small {
        grid-column: 2 !important;
        grid-row: 2 !important;
        min-height: unset !important;
        height: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        justify-content: flex-start !important;
        padding: 15px 20px !important;
    }

    /* Restaurants Powered - Reduced font sizes */
    .bento-card-small .bento-title-purple {
        font-size: 16px !important;
        margin-bottom: 5px !important;
    }

    .bento-card-small .bento-stat-purple {
        font-size: 54px !important;
        margin-bottom: 8px !important;
        text-align: center !important;
        width: 100% !important;
    }

    .bento-card-small .bento-text-dark {
        font-size: 11px !important;
        line-height: 1.4 !important;
    }

    .bento-card-small .bento-card-content {
        text-align: center !important;
    }

    /* Card 3: Multi-Location Control - Right column, row 3 */
    .bento-card-wide.bento-purple {
        grid-column: 2 !important;
        grid-row: 3 !important;
        min-height: unset !important;
        height: 100% !important;
        padding: 20px 15px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* Card 4: System Uptime - Left column, row 2 */
    .bento-card-wide-bottom.bento-uptime-card {
        grid-column: 1 !important;
        grid-row: 2 !important;
        min-height: unset !important;
        height: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding: 20px 15px !important;
    }

    /* Card 5: Peak-Hour Ready - Left column, row 3 */
    .bento-card-small-bottom {
        grid-column: 1 !important;
        grid-row: 3 !important;
        min-height: unset !important;
        height: 100% !important;
    }

    .bento-card-wide.bento-purple .bento-stats-row {
        flex-direction: column !important;
        align-items: center !important;
        gap: 10px !important;
    }

    .bento-card-wide.bento-purple .bento-stat-item {
        text-align: center !important;
    }

    .bento-card-wide.bento-purple .bento-stat-divider {
        width: 50px !important;
        height: 2px !important;
        margin: 5px auto !important;
    }

    .bento-card-wide.bento-purple .bento-stat-cyan {
        font-size: 60px !important;
    }

    .bento-card-wide.bento-purple .bento-title-white {
        font-size: 18px !important;
        margin-bottom: 10px !important;
        margin-top: 10px !important;
    }

    .bento-card-wide.bento-purple .bento-label {
        font-size: 11px !important;
    }

    .bento-card-wide.bento-purple .bento-text-white {
        margin-top: 15px !important;
        text-align: center !important;
        font-size: 11px !important;
    }

    .bento-uptime-card .bento-stat-huge {
        font-size: 72px !important;
    }

    .bento-uptime-card .bento-subtitle {
        font-size: 16px !important;
    }

    .bento-uptime-card .bento-text-white {
        font-size: 12px !important;
    }

    /* Peak-Hour Ready Performance - Fixed 2-column layout */
    .bento-card-small-bottom {
        min-height: 280px !important;
        padding: 20px 25px !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .bento-card-small-bottom .bento-card-content {
        display: grid !important;
        grid-template-columns: 55% 45% !important;
        grid-template-rows: auto 1fr !important;
        gap: 10px !important;
        height: 100% !important;
        position: relative !important;
    }

    .bento-card-small-bottom .bento-title-purple-large {
        grid-column: 1 / -1 !important;
        grid-row: 1 !important;
        margin-bottom: 5px !important;
    }

    .bento-card-small-bottom .bento-text-dark {
        grid-column: 1 !important;
        grid-row: 2 !important;
        max-width: 100% !important;
        align-self: start !important;
    }

    .bento-card-small-bottom .bento-icon {
        position: static !important;
        grid-column: 2 !important;
        grid-row: 2 !important;
        transform: none !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
    }

    .bento-card-small-bottom .bento-icon-img {
        width: 120px !important;
        height: auto !important;
        max-height: 170px !important;
    }

    /* ============================================
       FEATURE CARDS GRID
       ============================================ */

    .software-feature-cards,
    .software-kds-feature-cards,
    .software-kiosk-feature-cards {
        grid-template-columns: repeat(2, 1fr) !important;
        width: 100% !important;
        gap: 15px !important;
    }

    /* Reset centering transforms for kiosk cards */
    .software-kiosk-feature-cards .kiosk-feature-card:nth-last-child(2):nth-child(3n+1),
    .software-kiosk-feature-cards .kiosk-feature-card:nth-last-child(1):nth-child(3n+2) {
        transform: none !important;
    }

    .software-kiosk-feature-cards .kiosk-feature-card:nth-last-child(2):nth-child(3n+1):hover,
    .software-kiosk-feature-cards .kiosk-feature-card:nth-last-child(1):nth-child(3n+2):hover {
        transform: translateY(-5px) !important;
    }

    /* ============================================
       KDS BANNER
       ============================================ */

    .software-kds-banner {
        flex-direction: column !important;
        width: 100% !important;
        padding: 40px 25px !important;
        gap: 30px !important;
        margin-bottom: 0 !important;
    }

    .kds-banner-title {
        font-size: 26px !important;
    }

    .kds-banner-text {
        font-size: 16px !important;
    }

    .kds-banner-image {
        max-width: 100% !important;
    }

    .kds-banner-image img {
        width: 100% !important;
        max-width: 350px !important;
        margin: 0 auto !important;
        display: block !important;
    }

    /* ============================================
       FEATURES SHOWCASE
       ============================================ */

    .software-features-showcase {
        flex-direction: column !important;
        gap: 35px !important;
    }

    .features-menu-col {
        flex: none !important;
        width: 100% !important;
    }

    .features-menu-list {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 6px 10px !important;
        row-gap: 6px !important;
    }

    .features-menu-item {
        font-size: 13px !important;
        padding: 6px 10px !important;
        background: #f0f0f0 !important;
        border-radius: 4px !important;
        text-align: center !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .features-content-col {
        width: 100% !important;
    }

    .features-content-image {
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 16/10 !important;
    }

    .features-content-title {
        font-size: 26px !important;
    }

    /* ============================================
       UPGRADE HEADING
       ============================================ */

    .upgrade-heading-text {
        font-size: 34px !important;
        line-height: 1.3 !important;
    }

    /* ============================================
       FOOTER: Vertical Stack Layout
       Nav Links → Copyright → Arrow + Socials
       ============================================ */

    /* Override parent footer constraints */
    .clapat-footer {
        height: auto !important;
        min-height: auto !important;
        max-height: none !important;
        overflow: visible !important;
        pointer-events: auto !important;
        position: relative !important;
    }

    /* Flex-wrap row layout */
    .clapat-footer #footer-container {
        display: flex !important;
        flex-wrap: wrap !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 30px 20px !important;
        height: auto !important;
        min-height: auto !important;
        max-height: none !important;
        gap: 10px !important;
        position: relative !important;
        bottom: auto !important;
        left: auto !important;
        right: auto !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        opacity: 1 !important;
        visibility: visible !important;
        grid-template-columns: none !important;
        column-gap: 10px !important;
    }

    /* ROW 1: Nav Links (full width, vertical stack) */
    .clapat-footer #footer-container .footer-nav-links {
        order: 1 !important;
        flex: 1 1 100% !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 5px !important;
        transform: translateX(-90px) !important;
        -webkit-transform: translateX(-90px) !important;
        margin: 0 !important;
        padding: 0 !important;
        white-space: normal !important;
        grid-column: unset !important;
        position: relative !important;
        float: none !important;
        flex-wrap: nowrap !important;
    }

    .clapat-footer #footer-container .footer-nav-links a {
        font-size: 16px !important;
        margin-top: 0 !important;
        display: block !important;
        float: none !important;
        opacity: 1 !important;
        color: #fff !important;
    }

    /* ROW 2: Copyright (full width, centered) */
    .clapat-footer #footer-container .footer-copyright-text {
        order: 2 !important;
        flex: 1 1 100% !important;
        display: block !important;
        text-align: center !important;
        transform: none !important;
        -webkit-transform: none !important;
        top: auto !important;
        bottom: auto !important;
        left: auto !important;
        right: auto !important;
        position: relative !important;
        float: none !important;
        grid-column: unset !important;
        margin: 5px 0 !important;
        white-space: normal !important;
        font-size: inherit !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    /* Hide "| Terms of Use | Privacy Policy" */
    .clapat-footer #footer-container .footer-copyright-text span {
        font-size: 0 !important;
        visibility: hidden !important;
        line-height: 0 !important;
    }

    .clapat-footer #footer-container .footer-copyright-text span::before {
        content: "Copyright \00A9 2026. All Rights Reserved" !important;
        font-size: 16px !important;
        visibility: visible !important;
        color: #fff !important;
        display: block !important;
        line-height: 1.4 !important;
    }

    .clapat-footer #footer-container .footer-copyright-text span a {
        display: none !important;
    }

    /* Hide "Back to Top" Text */
    .clapat-footer #footer-container #backtotop.button-wrap .button-text,
    .clapat-footer #footer-container #backtotop.button-wrap.left .button-text,
    .clapat-footer #footer-container #backtotop .button-text.sticky,
    .clapat-footer #footer-container #backtotop .button-text.sticky.left {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        width: 0 !important;
        height: 0 !important;
        overflow: hidden !important;
    }

    /* Kill ::after clearing pseudo-element */
    .clapat-footer #footer-container #backtotop.button-wrap::after {
        display: none !important;
    }

    /* ROW 3: Arrow + Social Icons */

    /* Back to Top button — left side */
    .clapat-footer #footer-container #backtotop.button-wrap.left {
        order: 3 !important;
        flex: 0 0 auto !important;
        position: relative !important;
        float: none !important;
        left: auto !important;
        right: auto !important;
        top: auto !important;
        bottom: auto !important;
        margin: 15px 0px 0 -540px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        pointer-events: auto !important;
        cursor: pointer !important;
        grid-column: unset !important;
        width: auto !important;
        height: auto !important;
        margin-bottom: 0 !important;
    }

    /* Arrow icon wrapper */
    .clapat-footer #footer-container #backtotop .icon-wrap {
        float: none !important;
        position: relative !important;
        left: auto !important;
        right: auto !important;
        top: auto !important;
        margin: 0 !important;
        opacity: 1 !important;
        width: 36px !important;
        height: 36px !important;
    }

    .clapat-footer #footer-container #backtotop .button-icon {
        width: 36px !important;
        height: 36px !important;
        line-height: 36px !important;
    }

    /* Arrow icon color */
    .clapat-footer #footer-container #backtotop .button-icon i {
        color: #4814ac !important;
        font-size: 16px !important;
        line-height: 36px !important;
    }

    /* Social Icons — right of arrow */
    .clapat-footer #footer-container .socials-wrap {
        order: 4 !important;
        flex: 0 0 auto !important;
        position: relative !important;
        float: none !important;
        width: auto !important;
        height: auto !important;
        min-width: 0 !important;
        min-height: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        margin: 0 !important;
        margin-top: -51px !important;
        margin-right: 60px !important;
        padding: 0 !important;
        grid-column: unset !important;
        transform: none !important;
        -webkit-transform: none !important;
        transition: none !important;
        line-height: normal !important;
        top: auto !important;
        right: auto !important;
        left: auto !important;
        bottom: auto !important;
    }

    /* Prevent hover transform on socials-wrap */
    .clapat-footer #footer-container .socials-wrap:hover {
        transform: none !important;
        -webkit-transform: none !important;
    }

    /* Hide "Follow Us" text and share icon */
    .clapat-footer #footer-container .socials-wrap .socials-text,
    .clapat-footer #footer-container .socials-wrap .socials-icon {
        display: none !important;
    }

    /* Social icons: horizontal row */
    .clapat-footer #footer-container .socials-wrap .socials {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        gap: 6px !important;
        margin: 0 !important;
        transform: none !important;
        -webkit-transform: none !important;
        text-align: center !important;
        width: auto !important;
        height: auto !important;
        line-height: normal !important;
        float: none !important;
        position: relative !important;
    }

    /* Each social icon */
    .clapat-footer #footer-container .socials-wrap .socials li {
        float: none !important;
        opacity: 1 !important;
        transform: none !important;
        -webkit-transform: none !important;
        margin: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 28px !important;
        height: 28px !important;
        line-height: 28px !important;
        transition: none !important;
        position: relative !important;
    }

    /* Prevent hover re-transforms */
    .clapat-footer #footer-container .socials-wrap:hover .socials li {
        opacity: 1 !important;
        transform: none !important;
        -webkit-transform: none !important;
    }

    .clapat-footer #footer-container .socials-wrap .socials li a {
        width: 28px !important;
        height: 28px !important;
        line-height: 28px !important;
        font-size: 16px !important;
        color: #fff !important;
    }

}
