/* --- PRICING FORM WRAPPER SCOPE --- */

#custom-pricing-form-wrapper {
    --fs-font-stack: "degular-variable", sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue";
    font-family: var(--fs-font-stack);
}

#custom-pricing-form-wrapper h1,
#custom-pricing-form-wrapper h2,
#custom-pricing-form-wrapper h3,
#custom-pricing-form-wrapper h4,
#custom-pricing-form-wrapper h5,
#custom-pricing-form-wrapper h6,
#custom-pricing-form-wrapper p,
#custom-pricing-form-wrapper a,
#custom-pricing-form-wrapper span,
#custom-pricing-form-wrapper label,
#custom-pricing-form-wrapper input,
#custom-pricing-form-wrapper select,
#custom-pricing-form-wrapper textarea,
#custom-pricing-form-wrapper button {
    font-family: var(--fs-font-stack);
}

/* Scoped Input & Select styling */
#custom-pricing-form-wrapper input[type="text"],
#custom-pricing-form-wrapper input[type="email"],
#custom-pricing-form-wrapper input[type="number"],
#custom-pricing-form-wrapper input[type="search"],
#custom-pricing-form-wrapper input[type="tel"],
#custom-pricing-form-wrapper input[type="url"],
#custom-pricing-form-wrapper input[type="password"],
#custom-pricing-form-wrapper textarea,
#custom-pricing-form-wrapper select {
    width: 100%;
    padding: 10px !important;
    border: 1px solid #ccc !important;
    border-radius: 3px !important;
    background: #fff;
    color: #666;
    font-size: 1rem;
    font-family: var(--fs-font-stack) !important;
}

#custom-pricing-form-wrapper input:focus,
#custom-pricing-form-wrapper select:focus,
#custom-pricing-form-wrapper textarea:focus {
    color: #111;
    outline: none;
    border-color: #000 !important;
}

/* Scoped Button styling */
#custom-pricing-form-wrapper .button,
#custom-pricing-form-wrapper button[type="submit"],
#custom-pricing-form-wrapper input[type="submit"],
#custom-pricing-form-wrapper .btn-outline-primary {
    display: inline-block !important;
    background-color: transparent !important;
    color: #000 !important;
    padding: 15px 50px !important;
    border: none !important;
    border-radius: 0 !important;
    cursor: pointer;
    font-family: var(--fs-font-stack) !important;
    font-style: normal;
    font-size: 20px !important;
    text-decoration: underline !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    transition: all 0.3s ease;
}

#custom-pricing-form-wrapper .button:hover,
#custom-pricing-form-wrapper button[type="submit"]:hover,
#custom-pricing-form-wrapper input[type="submit"]:hover,
#custom-pricing-form-wrapper .btn-outline-primary:hover {
    background-color: transparent !important;
    color: #000 !important;
    text-decoration: none !important;
    opacity: 0.8;
}

/* --- PRICING FORM SPECIFIC (Existing) --- */

/* 1. Hide the default Storefront price and quantity (Global as it affects the product page) */
.single-product div.product form.cart .quantity,
.single-product div.product .single_add_to_cart_button:not(.btn-outline-primary) {
    display: none !important;
}

/* 2. Format your custom pricing option rows */
.custom-pricing-option {
    display: flex;
    flex-direction: column;
    margin-bottom: 28px;
}

.custom-pricing-option label {
    text-align: left;
    font-weight: 700;
    font-size: 16px;
    line-height: 21px;
    letter-spacing: 0px;
    color: #000000;
    text-transform: uppercase;
    opacity: 1;
    margin-bottom: 8px;
    display: block;
}

/* 3. Make the selects look like the theme inputs */
.custom-pricing-option select,
.custom-pricing-option input[type="number"],
.versions-stepper input#tharstern-versions {
    width: 100%;
    color: #666;
    font-size: 1rem;
}

.custom-pricing-option select:focus,
.custom-pricing-option input:focus {
    color: #111;
    outline: none;
}


/* 4. The Price Display Box */
#custom-price-display {
    background: #f1f1f1;
    padding: 15px;
    border-radius: 3px;
    margin: 20px 0;
    font-size: 1.2em;
    border-left: 5px solid #000000;
}

/**
 * 1. THEME HIDES (Global as they affect the product page)
 */
.single-product div.product p.price,
.single-product .summary .price,
.single-product .quantity,
.single-product .product .price,
.wp-block-woocommerce-product-price {
    display: none !important;
}

.single-product .product .single_add_to_cart_button,
.single-product .cart .single_add_to_cart_button {
    display: none !important;
}

/**
 * 2. CUSTOM FORM STYLING
 */
#custom-pricing-form-wrapper {
    margin-bottom: 20px;
    padding: 15px;
    background: #FFFFFF 0% 0% no-repeat padding-box;
    opacity: 1;
    border: 1px solid #eeeeee;
    border-radius: 3px;
}

/**
 * 3. SWATCHES & CAROUSEL
 */
.colorplan-carousel {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 10px 0;
    scrollbar-width: thin;
}

.colorplan-swatch {
    flex: 0 0 auto;
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 3px;
    transition: transform 0.15s, border-color 0.15s;
}

.colorplan-swatch img {
    width: 50px;
    height: 50px;
    border-radius: 3px;
    display: block;
}

.colorplan-swatch.selected {
    border-color: #000000;
    transform: scale(1.1);
}

/* Foil Swatch specific */
.swatch-container {
    display: flex;
    gap: 10px;
    margin-top: 5px;
}

.swatch {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid #ddd;
    cursor: pointer;
}

.swatch.selected {
    border-color: #000000;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
}

/* Corner Grid Layout */
.corner-grid {
    display: grid;
    grid-template-columns: 50px 50px;
    gap: 10px;
    margin: 10px 0;
    width: 110px;
}

.corner-option {
    width: 50px;
    height: 50px;
    border: 2px solid #ccc;
    background: #f9f9f9;
    cursor: pointer;
    transition: all 0.2s;
}

/* Make them look like corners */
.corner-option[data-corner="tl"] {
    border-top-left-radius: 15px;
}

.corner-option[data-corner="tr"] {
    border-top-right-radius: 15px;
}

.corner-option[data-corner="bl"] {
    border-bottom-left-radius: 15px;
}

.corner-option[data-corner="br"] {
    border-bottom-right-radius: 15px;
}

.corner-option.selected {
    background: #333333;
    border-color: #000000;
}

/* Versions Stepper Styling */
.versions-stepper {
    display: flex;
    align-items: center;
    max-width: 150px;
    margin-top: 5px;
}

.versions-stepper .stepper-btn {
    background: #000000;
    color: #fff;
    border: none;
    width: 40px;
    height: 40px;
    font-size: 1.2em;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    border-radius: 3px;
}

.versions-stepper .stepper-btn:hover {
    background: #333333;
}

.versions-stepper .stepper-btn:active {
    transform: scale(0.95);
}

.versions-stepper input#tharstern-versions {
    width: 60px;
    height: 40px;
    text-align: center;
    border-left: none !important;
    border-right: none !important;
    margin: 0 !important;
    padding: 0 !important;
    -moz-appearance: textfield;
    appearance: textfield;
}

.versions-stepper input#tharstern-versions::-webkit-outer-spin-button,
.versions-stepper input#tharstern-versions::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}