/*
Theme Name: Hadla Beauty Luxury Theme
Theme URI: https://hadlabeauty.com
Author: Hadla Beauty Team
Author URI: https://hadlabeauty.com
Description: Official Custom Luxury Theme for Hadla Beauty.
Version: 1.0.2
Template: astra
Text Domain: hadla-beauty
*/

/* ==========================================================================
   Hadla Beauty - Pure White & Full Width Sharp Rectangular Checkout
   ========================================================================== */

/* Fix checkout container width - Full Screen Width */
html, body, .woocommerce-checkout {
    background: #ffffff !important;
    background-color: #ffffff !important;
}

.woocommerce-checkout .entry-content,
.woocommerce-checkout .woocommerce,
.woocommerce-checkout form.checkout {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 auto !important;
    padding: 0 !important;
    background: #ffffff !important;
}

/* Ensure customer details section takes full width */
.woocommerce-checkout #customer_details,
.woocommerce-checkout #customer_details.col2-set {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    margin: 0 0 20px 0 !important;
    display: block !important;
    padding: 0 !important;
}

.woocommerce-checkout #customer_details.col2-set .col-1,
.woocommerce-checkout #customer_details.col2-set .col-2 {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    display: block !important;
    padding: 0 !important;
}

/* Card Styling for Billing Section - Pure White & Rectangular Sharp Right Angles */
.woocommerce-checkout .woocommerce-billing-fields {
    background: #ffffff !important;
    border: 1px solid #EBE2DF !important;
    border-radius: 0px !important;
    -webkit-border-radius: 0px !important;
    -moz-border-radius: 0px !important;
    padding: 20px 16px !important;
    box-shadow: none !important;
    margin-bottom: 20px !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.woocommerce-checkout .woocommerce-billing-fields h3,
.woocommerce-checkout #order_review_heading {
    font-size: 18px !important;
    font-weight: 800 !important;
    color: #2B2526 !important;
    margin-top: 0 !important;
    margin-bottom: 18px !important;
    padding-bottom: 10px !important;
    border-bottom: 1.5px solid #F4EDEA !important;
}

/* General Form Rows & Inputs - Strict 90-Degree Right Angles */
.woocommerce-checkout form.checkout .form-row {
    margin-bottom: 14px !important;
    width: 100% !important;
}

.woocommerce-checkout form.checkout label {
    display: block !important;
    font-size: 13.5px !important;
    font-weight: 700 !important;
    color: #2B2526 !important;
    margin-bottom: 6px !important;
    line-height: 1.4 !important;
}

.woocommerce-checkout form.checkout input.input-text,
.woocommerce-checkout form.checkout textarea,
.woocommerce-checkout form.checkout select,
.woocommerce-checkout .select2-container--default .select2-selection--single {
    width: 100% !important;
    min-height: 48px !important;
    height: 48px !important;
    border: 1px solid #E0D6D3 !important;
    border-radius: 0px !important;
    -webkit-border-radius: 0px !important;
    -moz-border-radius: 0px !important;
    padding: 10px 14px !important;
    font-size: 14.5px !important;
    color: #2B2526 !important;
    background-color: #ffffff !important;
    box-sizing: border-box !important;
    transition: all 0.2s ease !important;
    outline: none !important;
    box-shadow: none !important;
}

.woocommerce-checkout form.checkout input.input-text:focus,
.woocommerce-checkout form.checkout select:focus,
.woocommerce-checkout .select2-container--default.select2-container--open .select2-selection--single {
    border-color: #A45D68 !important;
    box-shadow: 0 0 0 2px rgba(164, 93, 104, 0.15) !important;
    outline: none !important;
}

.woocommerce-checkout .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 46px !important;
    padding-right: 12px !important;
    padding-left: 28px !important;
    color: #2B2526 !important;
}

.woocommerce-checkout .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 46px !important;
    left: 10px !important;
    right: auto !important;
}

/* Review Order Section */
.woocommerce-checkout #order_review {
    background: #ffffff !important;
    border: 1px solid #EBE2DF !important;
    border-radius: 0px !important;
    -webkit-border-radius: 0px !important;
    -moz-border-radius: 0px !important;
    padding: 20px 16px !important;
    box-shadow: none !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* Mobile Specific Full Width across Screen */
@media (max-width: 768px) {
    .woocommerce-checkout #content,
    .woocommerce-checkout .site-content {
        padding: 0 !important;
        margin: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    .woocommerce-checkout #primary,
    .woocommerce-checkout #main,
    .woocommerce-checkout article,
    .woocommerce-checkout .ast-article-single,
    .woocommerce-checkout .entry-content {
        padding: 0 !important;
        margin: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    .woocommerce-checkout .ast-container {
        padding-left: 12px !important;
        padding-right: 12px !important;
        padding-top: 10px !important;
        padding-bottom: 30px !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        margin: 0 auto !important;
    }

    .woocommerce-checkout .woocommerce-billing-fields,
    .woocommerce-checkout #order_review,
    .woocommerce-checkout .woocommerce-additional-fields {
        padding: 18px 14px !important;
        border-radius: 0px !important;
        -webkit-border-radius: 0px !important;
        width: 100% !important;
        box-sizing: border-box !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    /* Force full-width on mobile to avoid broken split inputs */
    .woocommerce-checkout form.checkout .form-row-first,
    .woocommerce-checkout form.checkout .form-row-last,
    .woocommerce-page.woocommerce-checkout form .form-row-first,
    .woocommerce-page.woocommerce-checkout form .form-row-last {
        float: none !important;
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        clear: both !important;
        display: block !important;
    }

    .woocommerce-checkout #payment #place_order {
        width: 100% !important;
        min-height: 52px !important;
        font-size: 16px !important;
        font-weight: 800 !important;
        border-radius: 0px !important;
        -webkit-border-radius: 0px !important;
    }
}

/* Desktop 2-column nicely spaced for Name */
@media (min-width: 769px) {
    .woocommerce-checkout form.checkout .form-row-first {
        float: right !important;
        width: 48.5% !important;
        clear: right !important;
    }
    .woocommerce-checkout form.checkout .form-row-last {
        float: left !important;
        width: 48.5% !important;
        clear: left !important;
    }
}
/* ==========================================================================
   HADLA LUXURY SELECT2 (COUNTRY & STATE) - NO BLUE & NO KEYBOARD POPUP
   ========================================================================== */
html body .select2-dropdown,
html body .select2-container--default .select2-dropdown,
.select2-dropdown,
.select2-container--default .select2-dropdown {
    border: 1.5px solid #2B2526 !important;
    border-radius: 0px !important;
    -webkit-border-radius: 0px !important;
    -moz-border-radius: 0px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12) !important;
    background: #FFFFFF !important;
    z-index: 999999 !important;
    overflow: hidden !important;
}

/* Completely remove search box so mobile phone keyboard never pops up */
html body .select2-search--dropdown,
html body .select2-search,
html body .select2-container .select2-search--dropdown,
html body .select2-container--default .select2-search--dropdown,
.select2-search--dropdown,
.select2-search,
.select2-container .select2-search--dropdown,
.select2-container--default .select2-search--dropdown,
input.select2-search__field {
    display: none !important;
    height: 0 !important;
    width: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    visibility: hidden !important;
    opacity: 0 !important;
    border: none !important;
    pointer-events: none !important;
}

/* Dropdown list */
html body .select2-results__options,
.select2-results__options {
    padding: 0 !important;
    margin: 0 !important;
    max-height: 280px !important;
    background: #FFFFFF !important;
}

/* Individual options */
html body .select2-results__option,
html body .select2-container--default .select2-results__option,
.select2-results__option,
.select2-container--default .select2-results__option {
    padding: 13px 16px !important;
    font-size: 14.5px !important;
    font-weight: 600 !important;
    color: #2B2526 !important;
    line-height: 1.4 !important;
    cursor: pointer !important;
    border-bottom: 1px solid #FAF7F6 !important;
    transition: all 0.15s ease !important;
    text-align: right !important;
    direction: rtl !important;
    box-sizing: border-box !important;
    background-color: #FFFFFF !important;
}

html body .select2-results__option:last-child,
.select2-results__option:last-child {
    border-bottom: none !important;
}

/* ELIMINATE BLUE - Replace with Hadla Brand Rose #A45D68 */
html body .select2-container--default .select2-results__option--highlighted[aria-selected],
html body .select2-container--default .select2-results__option--highlighted,
html body .select2-results__option--highlighted[aria-selected],
html body .select2-results__option--highlighted,
.select2-container--default .select2-results__option--highlighted[aria-selected],
.select2-container--default .select2-results__option--highlighted,
.select2-results__option--highlighted[aria-selected],
.select2-results__option--highlighted {
    background-color: #A45D68 !important;
    background: #A45D68 !important;
    color: #FFFFFF !important;
    font-weight: 700 !important;
}

/* Selected option */
html body .select2-container--default .select2-results__option[aria-selected="true"],
html body .select2-results__option[aria-selected="true"],
.select2-container--default .select2-results__option[aria-selected="true"],
.select2-results__option[aria-selected="true"] {
    background-color: #F8F2F2 !important;
    color: #A45D68 !important;
    font-weight: 800 !important;
}

html body .select2-container--default .select2-results__option[aria-selected="true"].select2-results__option--highlighted,
html body .select2-results__option[aria-selected="true"].select2-results__option--highlighted,
.select2-container--default .select2-results__option[aria-selected="true"].select2-results__option--highlighted,
.select2-results__option[aria-selected="true"].select2-results__option--highlighted {
    background-color: #A45D68 !important;
    background: #A45D68 !important;
    color: #FFFFFF !important;
}
/* ==========================================================================
   HADLA MINIMAL LUXURY CHECKOUT HEADER & FOOTER
   ========================================================================== */
/* Hide announcement bar on checkout - Pure Clean Logo Only */
body.woocommerce-checkout .hadla-announcement-bar {
    display: none !important;
    height: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    visibility: hidden !important;
}

/* Center Checkout Page Title "إتمام الدفع" */
body.woocommerce-checkout .entry-header,
body.woocommerce-checkout header.entry-header,
body.woocommerce-checkout h1.entry-title {
    text-align: center !important;
    display: block !important;
    margin-left: auto !important;
    margin-right: auto !important;
    width: 100% !important;
}

/* 1. Header: Pure White with Enlarged Centered Logo Only */
body.woocommerce-checkout .hadla-pure-header-wrap {
    top: 0px !important;
    position: relative !important;
    min-height: auto !important;
    background: #FFFFFF !important;
    border-bottom: 1px solid #EBE2DF !important;
    box-shadow: none !important;
    z-index: 1000 !important;
    padding: 16px 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin-top: 0 !important;
}

/* Eliminate all inner borders/lines under logo */
body.woocommerce-checkout .hadla-mobile-header-row,
body.woocommerce-checkout .hadla-pure-header-row1,
body.woocommerce-checkout .hadla-pure-header-row2,
body.woocommerce-checkout .hadla-mobile-logo,
body.woocommerce-checkout .hadla-pure-header-logo {
    border: none !important;
    border-top: none !important;
    border-bottom: none !important;
    box-shadow: none !important;
}

/* Mobile & Tablet (< 992px) */
@media (max-width: 991px) {
    body.woocommerce-checkout .hadla-pure-header-wrap {
        top: 0px !important;
        position: relative !important;
        margin-top: 0 !important;
    }

    body.woocommerce-checkout .hadla-pure-header-row1,
    body.woocommerce-checkout .hadla-pure-header-row2 {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        padding: 0 !important;
        margin: 0 !important;
        overflow: hidden !important;
    }

    body.woocommerce-checkout .hadla-mobile-header-row {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        position: static !important;
        padding: 0 !important;
        margin: 0 !important;
        height: auto !important;
        min-height: auto !important;
        background: transparent !important;
        width: 100% !important;
    }

    body.woocommerce-checkout .hadla-mobile-logo img {
        height: 54px !important;
        max-height: 54px !important;
        width: auto !important;
        display: block !important;
        margin: 0 auto !important;
    }
}

/* Desktop (>= 992px) */
@media (min-width: 992px) {
    body.woocommerce-checkout .hadla-mobile-header-row {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        overflow: hidden !important;
    }

    body.woocommerce-checkout .hadla-pure-header-row1 {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0 !important;
        margin: 0 auto !important;
        position: static !important;
        max-width: 1200px !important;
        height: auto !important;
        min-height: auto !important;
        width: 100% !important;
    }

    body.woocommerce-checkout .hadla-pure-header-row2 {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        overflow: hidden !important;
    }

    body.woocommerce-checkout .hadla-pure-header-logo img {
        height: 60px !important;
        max-height: 60px !important;
        width: auto !important;
        display: block !important;
        margin: 0 auto !important;
    }
}

/* Completely hide all distractions, menus, search, wishlist, cart and badges */
body.woocommerce-checkout .hadla-mobile-icons-right,
body.woocommerce-checkout .hadla-mobile-icons-left,
body.woocommerce-checkout #hadla-mobile-drawer,
body.woocommerce-checkout .hadla-pure-header-right,
body.woocommerce-checkout .hadla-pure-header-actions,
body.woocommerce-checkout .hadla-header-search-wrap,
body.woocommerce-checkout .hadla-pure-search-box,
body.woocommerce-checkout .hadla-desktop-nav-wrap,
body.woocommerce-checkout .hadla-pure-header-row1 input,
body.woocommerce-checkout .hadla-pure-header-row1 button,
body.woocommerce-checkout .hadla-pure-header-row1 svg,
body.woocommerce-checkout .hadla-checkout-header-secure-badge,
body.woocommerce-checkout .hadla-bottom-nav,
body.woocommerce-checkout #hadla-mobile-bottom-nav {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

/* Centered Logos */
body.woocommerce-checkout .hadla-mobile-logo,
body.woocommerce-checkout .hadla-pure-header-logo {
    position: static !important;
    transform: none !important;
    margin: 0 auto !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* 2. Hide ALL bulky site footers on checkout */
body.woocommerce-checkout footer.hadla-custom-footer,
body.woocommerce-checkout footer.site-footer,
body.woocommerce-checkout footer#colophon,
body.woocommerce-checkout .hadla-footer-container,
body.woocommerce-checkout .hfe-before-footer-wrap,
body.woocommerce-checkout .footer-width-fixer,
body.woocommerce-checkout .site-above-footer-wrap,
body.woocommerce-checkout .site-below-footer-wrap,
body.woocommerce-checkout .site-primary-footer-wrap {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* 3. Clean Policies & Shipping Links Footer */
.hadla-checkout-clean-footer {
    background: #FFFFFF !important;
    border-top: 1px solid #EBE2DF !important;
    padding: 30px 18px 32px 18px !important;
    margin-top: 36px !important;
    text-align: center !important;
    width: 100% !important;
    box-sizing: border-box !important;
    direction: rtl !important;
    clear: both !important;
}

.hadla-clean-footer-links {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 16px !important;
    margin-bottom: 12px !important;
    font-size: 13.5px !important;
    font-weight: 700 !important;
}

.hadla-footer-policy-link {
    color: #555555 !important;
    text-decoration: none !important;
    transition: color 0.2s ease !important;
    cursor: pointer !important;
}

.hadla-footer-policy-link:hover {
    color: #A45D68 !important;
    text-decoration: underline !important;
}

.hadla-footer-sep {
    color: #CCCCCC !important;
    font-size: 11px !important;
}

.hadla-clean-footer-copy {
    font-size: 12px !important;
    color: #888888 !important;
    margin-top: 8px !important;
}
