/* RBBW 1.5.0 Premium DateRangePicker UI */

.rbbw-form,
.rbbw-form *,
.swal2-popup.rbbw-popup-custom,
.swal2-popup.rbbw-popup-custom * {
    box-sizing: border-box !important;
    font-family: inherit !important;
}

.swal2-popup.rbbw-popup-custom {
    padding: 20px !important;
    border-radius: 12px !important;
    max-width: 500px !important;
    background: #fff !important;
    color: #333 !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15) !important;
}

.swal2-styled.swal2-confirm {
    background-color: #1a8e46 !important;
}

@media (max-width: 1024px) {
    .swal2-popup.rbbw-popup-custom {
        width: 80% !important;
    }
}

@media (max-width: 768px) {
    .swal2-popup.rbbw-popup-custom {
        width: 95% !important;
    }
}

.swal2-popup.rbbw-popup-custom .swal2-title {
    font-size: 1.25em !important;
    margin-bottom: 20px !important;
    font-weight: 700 !important;
    color: #111 !important;
    line-height: 1.2 !important;
}

.rbbw-field-group {
    margin-top: 15px !important;
    text-align: left !important;
}

.rbbw-field-group label {
    display: block !important;
    margin-bottom: 8px !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    color: #333 !important;
}

.swal2-popup.rbbw-popup-custom .swal2-select,
.swal2-popup.rbbw-popup-custom .swal2-textarea,
.swal2-popup.rbbw-popup-custom .swal2-input {
    width: 100% !important;
    margin: 8px 0 0 0 !important;
    border: 1px solid #ddd !important;
    border-radius: 6px !important;
    font-size: 15px !important;
    box-shadow: none !important;
    transition: border-color 0.2s, box-shadow 0.2s !important;
    background: #fff !important;
    color: #333 !important;
}

.swal2-popup.rbbw-popup-custom .swal2-input,
.swal2-popup.rbbw-popup-custom .swal2-select {
    height: 48px !important;
    padding: 0 15px !important;
}

.swal2-popup.rbbw-popup-custom .swal2-textarea {
    min-height: 100px !important;
    padding: 12px 15px !important;
    line-height: 1.5 !important;
}

/* Focus states */
.swal2-popup.rbbw-popup-custom .swal2-input:focus,
.swal2-popup.rbbw-popup-custom .swal2-select:focus,
.swal2-popup.rbbw-popup-custom .swal2-textarea:focus {
    border-color: #1a8e46 !important;
    box-shadow: 0 0 0 3px rgba(26, 142, 70, 0.1) !important;
    outline: none !important;
}

.rbbw-field-group label input[type="checkbox"] {
    width: auto !important;
    margin-right: 10px !important;
    display: inline-block !important;
}

/* Wunschdaten Section */
.rbbw-wunschdaten {
    background: #fdfdfd;
    border: 1px solid #eee;
    padding: 12px;
    border-radius: 6px;
    text-align: left;
    margin-bottom: 15px;
}

.rbbw-wunsch-header label {
    font-weight: 700;
    font-size: 14px;
    color: #333;
}

.rbbw-styled-input {
    width: 100%;
    height: 44px;
    /* Slightly larger for the range string */
    border: 1px solid #1a8e46;
    border-radius: 4px;
    padding: 0 12px;
    font-size: 14px;
    color: #333;
    background: #fff;
    cursor: pointer;
    text-align: center;
}

.rbbw-styled-input:focus {
    outline: none;
    border-color: #d63031;
}

/* DateRangePicker Branding Override */
.daterangepicker {
    z-index: 9999 !important;
    /* Above swal2 */
    font-family: inherit;
    border: 1px solid #ddd;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.daterangepicker .calendar-table td.active,
.daterangepicker .calendar-table td.active:hover {
    background-color: #d63031 !important;
    border-color: transparent !important;
    color: #fff !important;
}

.daterangepicker .drp-buttons .btn-primary {
    background-color: #1a8e46 !important;
    border-color: #1a8e46 !important;
}

/* Customer Details Grid */
.rbbw-details-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 5px;
}

.rbbw-customer-details .swal2-input {
    height: 38px !important;
    margin: 5px 0 !important;
    border-radius: 4px !important;
    font-size: 13px !important;
    width: 100% !important;
}

@media (max-width: 480px) {
    .rbbw-details-grid {
        grid-template-columns: 1fr;
    }
}

.rbbw-form .form-checkbox {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.rbbw-form .form-checkbox label {
    font-size: 12px;
    color: #636e72;
}

.price-estimate {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 1.1em;
    color: #2d3436;
    text-align: center;
    margin: 15px 0;
}

/* Selection Bar */
.rbbw-selection-bar {
    background: #2d3436;
    color: #fff;
    text-align: center;
    padding: 8px;
    font-size: 14px;
    z-index: 9999;
    position: relative;
}

.rbbw-selection-bar a {
    color: #1a8e46;
    text-decoration: underline;
    margin-left: 15px;
    font-weight: 700;
}

/* VAT Label */
.rbbw-vat-label {
    font-size: 0.8em;
    color: #636e72;
    margin-left: 5px;
}

.rbbw-required-asterisk {
    color: #d63031 !important;
    margin-left: 3px;
    font-weight: bold;
}

/* B2B Disclaimer */
.rbbw-product-cta {
    margin-top: 15px;
    margin-bottom: 20px;
}

.rbbw-b2b-disclaimer {
    font-size: 13px;
    color: #d63031;
    margin-top: 10px;
    font-weight: 600;
}

/* Hero Banner Refinement */
/* These targets depend on theme, but common WooCommerce banner classes are used here */
.woocommerce-products-header__title.page-title,
.page-title-section,
.banner-section {
    min-height: 200px !important;
    /* Reducing height by at least 50% */
    height: auto !important;
    padding: 40px 0 !important;
    background-color: #f5f5f5 !important;
    /* Neutral background */
    background-image: none !important;
    /* Remove default image if any */
}

/* Cart Icon Cleanup */
.cart-contents .amount,
.header-cart .amount,
.site-header-cart .amount {
    display: none !important;
}

/* Shop Grid Cleanup */
.woocommerce ul.products li.product .button {
    margin: 10px 0 0 !important;
    display: block !important;
    text-align: center !important;
}

/* Remove clutter buttons if theme adds multiple */
.woocommerce ul.products li.product .add_to_cart_button {
    display: none !important;
}

/* Hover Image Effect */
.woocommerce ul.products li.product .rbbw-hover-img {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.woocommerce ul.products li.product:hover .rbbw-hover-img {
    opacity: 1;
}

/* Gallery Thumbnails Alignment */
.woocommerce-product-gallery--columns-4 .flex-control-thumbs li {
    width: 20% !important;
    float: left !important;
    margin-right: 2% !important;
}

/* Inquiry List Table */
.rbbw-inquiry-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 30px;
}

.rbbw-inquiry-table th,
.rbbw-inquiry-table td {
    padding: 12px;
    border: 1px solid #eee;
    text-align: left;
}

.rbbw-inquiry-table th {
    background: #f8f9fa;
}

.rbbw-remove-item {
    color: #d63031 !important;
    text-decoration: none;
    font-size: 20px;
    font-weight: bold;
}

/* Multi-Submission Form */
.rbbw-form-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 15px;
}

.rbbw-field label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    font-size: 14px;
}

.rbbw-field input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

@media (max-width: 768px) {
    .rbbw-form-grid {
        grid-template-columns: 1fr;
    }
}

/* Inquiry Page 2-Column Layout */
.rbbw-inquiry-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 30px;
    margin-top: 30px;
}

.rbbw-side-form-card {
    background: #fdfdfd;
    border: 1px solid #eee;
    padding: 25px;
    border-radius: 8px;
    position: sticky;
    top: 20px;
}

.rbbw-form-group {
    margin-bottom: 15px;
}

.rbbw-form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    font-size: 14px;
}

.rbbw-form-group input,
.rbbw-form-group textarea {
    width: 100%;
    margin-top: 5px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 15px;
    transition: border-color 0.2s, box-shadow 0.2s;
    background: #fff;
    color: #333;
}

.rbbw-form-group input {
    height: 48px;
    padding: 0 15px;
}

.rbbw-form-group textarea {
    min-height: 120px;
    padding: 12px 15px;
    line-height: 1.5;
}

.rbbw-form-group input:focus,
.rbbw-form-group textarea:focus {
    border-color: #1a8e46;
    box-shadow: 0 0 0 3px rgba(26, 142, 70, 0.1);
    outline: none;
}

.rbbw-selection-summary {
    background: #fff;
    border: 1px dashed #bbb;
    padding: 15px;
    border-radius: 6px;
    margin: 20px 0;
}

.rbbw-sum-item {
    margin-bottom: 10px;
    font-size: 13px;
}

.rbbw-full-button {
    width: 100%;
    height: 55px;
    font-size: 18px !important;
    background: #1a8e46 !important;
}

.rbbw-b2b-notice {
    color: #d63031;
    font-weight: 600;
    font-size: 12px;
    text-align: center;
    margin-top: 15px;
}

@media (max-width: 900px) {
    .rbbw-inquiry-grid {
        grid-template-columns: 1fr;
    }

    .rbbw-side-form-card {
        position: static;
        margin-top: 30px;
    }
}

.rbbw-table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 20px;
    border-radius: 8px;
    border: 1px solid #eee;
}

@media (max-width: 768px) {
    .rbbw-inquiry-table {
        min-width: 600px;
        /* Ensure table doesn't cramp too much */
    }

    .rbbw-list-footer {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .rbbw-grand-total {
        font-size: 1.1em;
    }
}

/* Floating Toggle Group */
.rbbw-floating-group {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.rbbw-floating-toggle,
.rbbw-floating-list-btn {
    background: #2d3436;
    color: #fff;
    padding: 10px 15px;
    border-radius: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    transition: transform 0.2s, background 0.2s;
    text-decoration: none !important;
}

.rbbw-floating-list-btn {
    background: #1a8e46;
}

.rbbw-floating-toggle:hover,
.rbbw-floating-list-btn:hover {
    transform: scale(1.05);
    color: #fff;
}

.rbbw-toggle-icon {
    font-size: 16px;
}

/* Combined Product Info Layout */
.rbbw-product-combined {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 10px 0;
}

.rbbw-product-thumbnail-wrap img {
    max-width: 80px !important;
    height: auto !important;
    border-radius: 4px;
    display: block !important;
    border: 1px solid #eee;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.rbbw-product-name-wrap {
    font-size: 14px;
    text-align: center;
    line-height: 1.3;
}

/* SVG Icon Styling for Floating Buttons */
.rbbw-toggle-icon svg {
    display: block;
}

.rbbw-floating-list-btn .rbbw-toggle-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
}