/* --- Front-end Inputs Layout --- */
.gd-frontend-option-wrap {
    margin-bottom: 20px;
    padding: 10px 0;
}
.gd-frontend-option-wrap label {
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}
.gd-option-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

/* Range Slider Layout */
.gd-field-type-range {
  display: flex;
  align-items: center;
  gap: 12px;
}
.gd-range-slider-row {
  display: flex;
  align-items: center;
}
.gd-range-slider-input {
  margin-right: 12px;
}

/* Color Chips Layout */
.gd-color-chips {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.gd-color-chip-label {
    cursor: pointer;
    position: relative;
}
.gd-color-chip-label input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}
.gd-color-swatch {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid #ddd;
    display: block;
    transition: transform 0.2s;
}
.gd-color-chip-label input:checked + .gd-color-swatch {
    border-color: #000;
    transform: scale(1.1);
}

/* Image Selection Layout */
.gd-image-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.gd-image-option-label {
    cursor: pointer;
    text-align: center;
    border: 2px solid #eee;
    padding: 6px;
    border-radius: 4px;
    transition: border-color 0.2s;
    container-type: inline-size;
}
.gd-image-option-label input {
    position: absolute;
    opacity: 0;
}
.gd-image-option-label img {
    width: 100%;
    height: auto;
    object-fit: cover;
    margin-bottom: 4px;
}
.gd-image-option-label span {
    font-size: 6cqw;
    display: block;
    padding: 15px;
}
.gd-image-option-label input:checked + div {
    border-color: #000;
}
.gd-image-option-card {
  width: 100%;
}

/* --- Button Swatches Selection Groups --- */
.gd-button-swatch-group {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 5px;
}
.gd-swatch-label-badge {
    position: relative;
    cursor: pointer;
    margin: 0 !important;
}
.gd-swatch-label-badge input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}
.gd-swatch-text-span {
    display: inline-block;
    padding: 8px 16px;
    background: #f4f4f4;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    font-weight: normal !important;
    transition: all 0.2s ease;
}
.gd-swatch-label-badge input:checked + .gd-swatch-text-span {
    background: #000;
    color: #fff;
    border-color: #000;
}
.gd-swatch-text-span:hover {
    border-color: #888;
}

/* --- Text Inputs & Textarea Styling --- */
.gd-wysiwyg-text-input {
  width: 100%;
  height: 136px;
  padding: 6px 8px;
}

/* --- Number Counter Styling --- */
.gd-number-spinner-field {
    width: 80px;
    padding: 6px;
    border: 1px solid #ccc;
    border-radius: 4px;
    text-align: center;
}

/* --- Force Swatch Badge Block Display Visibility --- */
.gd-field-type-button_swatch {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}
.gd-button-swatch-group {
    display: flex !important;
    gap: 10px !important;
    flex-wrap: wrap !important;
    margin-top: 8px;
    clear: both;
}
.gd-swatch-label-badge {
    display: inline-block !important;
    cursor: pointer;
    margin: 0 !important;
    padding: 0 !important;
}
.gd-swatch-label-badge input[type="radio"] {
    position: absolute !important;
    opacity: 0 !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden;
}
.gd-swatch-text-span {
    display: block !important;
    padding: 10px 20px !important;
    background: #f5f5f5 !important;
    border: 1px solid #ccc !important;
    border-radius: 4px !important;
    font-size: 14px;
    color: #333 !important;
    text-align: center;
}
.gd-swatch-label-badge input:checked + .gd-swatch-text-span {
    background: #000 !important;
    color: #fff !important;
    border-color: #000 !important;
}

/* --- Full-Screen Layout Architecture --- */
.gd-flyin-panel.gd-fullscreen-mode {
    position: fixed;
    top: 0;
    right: -100vw; /* Anchored off-screen left route hook */
    width: 100vw;
    max-width: 100vw;
    height: 100vh;
    background: #fff;
    z-index: 99999;
    transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.gd-flyin-panel.gd-fullscreen-mode.open {
    right: 0;
}

.gd-flyin-panel-columns-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Exact split 50/50 dual column alignment */
    width: 1600px;
    max-width: 100%; 
    height: 100%;
    margin: 0 auto; /* Center alignment matrix hook if using localized content boundaries */
}

/* Independent Column Containers Scroll Management without scrollbar visibility */
.gd-fullscreen-column {
    height: 100vh;
    overflow-y: scroll;
    scrollbar-width: none; /* Suppress scrollbars Firefox */
    -ms-overflow-style: none; /* Suppress scrollbars IE/Edge */
}
.gd-fullscreen-column::-webkit-scrollbar {
    display: none; /* Suppress scrollbars Safari/Chrome */
}
.gd-column-inner-scroll {
    padding: 60px; /* Spacious configuration deck formatting padding */
    box-sizing: border-box;
}

/* Structural Color Splits */
.gd-column-left {
    background: #ffffff;
    border-right: 1px solid #eaeaea;
}
.gd-column-right {
    background: #f9f9f9;
}

/* Navigation & Elements UI Styling */
.gd-back-to-product-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    font-weight: bold;
    color: #000;
    text-decoration: none;
    margin-bottom: 40px;
}
.gd-back-to-product-link:hover {
    text-decoration: underline;
}
.gd-summary-product-title {
    font-size: 32px;
    margin: 0 0 30px 0;
    font-weight: 800;
}

/* Clean Receipt Layout Matrix */
.gd-live-summary-receipt-wrap {
    background: #fff;
    padding: 30px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    margin-bottom: 30px;
}
.gd-live-summary-receipt-wrap h3 {
    margin-top: 0;
    font-size: 18px;
    border-bottom: 2px solid #000;
    padding-bottom: 10px;
}
.gd-live-summary-table {
    width: 100%;
    border-collapse: collapse;
}
.gd-live-summary-table th {
    text-align: left;
    font-size: 12px;
    text-transform: uppercase;
    color: #888;
    padding-bottom: 10px;
}
.gd-live-summary-table th:last-child {
    text-align: right;
}
.gd-live-summary-table td {
    padding: 12px 0;
    border-bottom: 1px solid #eee;
    font-size: 14px;
}
.gd-live-summary-table tr:last-child td {
    border-bottom: none;
}
.gd-live-summary-table td:last-child {
    font-weight: bold;
    text-align: right;
}

/* Action Summary Deck */
.gd-summary-actions-deck {
    background: #fff;
    padding: 30px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
}
.gd-summary-quantity-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}
.gd-summary-quantity-row label {
    font-weight: bold;
}
.gd-summary-native-qty {
    width: 70px;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    text-align: center;
}
.gd-summary-total-wrap {
    display: flex;
    justify-content: space-between;
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 25px;
}
.gd-summary-actions-deck .gd-flyin-submit-add-to-cart {
    width: 100%;
    padding: 15px !important;
    font-size: 16px !important;
    text-transform: uppercase;
    font-weight: bold;
}

/* --- Active Selected Options Theme Styles --- */

/* 1. Color Swatches Outline - Target the exact input sibling depth for maximum specificity */
.gd-color-chip-label.gd-selected input + .gd-color-swatch,
.gd-color-chip-label.gd-selected .gd-color-swatch {
    border-color: #000000 !important;
    box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px #000000 !important;
    transform: scale(1.05) !important;
}

/* 2. Image Selection Border Card - Enforce high specificity rules on checked siblings and selected labels */
.gd-image-option-label.gd-selected .gd-image-option-card,
.gd-image-option-label input:checked + .gd-image-option-card,
.gd-image-option-label input:checked + div {
    border-color: #000000 !important;
    background-color: #fcfcfc !important;
    box-shadow: 0 0 0 1px #000000 !important;
}

/* 3. Button Selection Badge Group Swatch */
.gd-swatch-label-badge.gd-selected .gd-swatch-text-span,
.gd-swatch-label-badge input:checked + .gd-swatch-text-span {
    background: #000000 !important;
    color: #ffffff !important;
    border-color: #000000 !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15) !important;
}

/* --- NEW: Responsive Mobile Breakdown Matrix --- */
@media screen and (max-width: 767px) {
    /* Allow the root panel container to handle total viewport scroll natively */
    .gd-flyin-panel.gd-fullscreen-mode {
        overflow-y: scroll !important;
        -webkit-overflow-scrolling: touch;
    }
    
    /* Collapse grid columns down into a continuous vertical stack block */
    .gd-flyin-panel-columns-wrapper {
        grid-template-columns: 1fr !important;
        height: auto !important;
    }
    
    /* Disable desktop locked heights; scale seamlessly with content volume size */
    .gd-fullscreen-column {
        height: auto !important;
        overflow-y: visible !important;
    }
    
    /* Smooth out paddings for narrower mobile widths */
    .gd-column-inner-scroll {
        padding: 35px 20px !important;
    }
    
    /* Remove vertical divider borders on small viewports */
    .gd-column-left {
        border-right: none !important;
        border-bottom: 1px solid #eaeaea;
    }
}