/*
 Theme Name:   Bricks Child Theme
 Theme URI:    https://bricksbuilder.io/
 Description:  Use this child theme to extend Bricks.
 Author:       Bricks
 Author URI:   https://bricksbuilder.io/
 Template:     bricks
 Version:      1.1
 Text Domain:  bricks
*/

/* -------------------------------------------
   Checkout optimization
-------------------------------------------- */

#billing_phone,
.iti input {
    direction: ltr;
    text-align: left;
}
.woocommerce-account-fields .create-account {
	display: none;
}
/* -------------------------------------------------------
   GLOBAL FORM FIELD DESIGN SYSTEM
   Applies to all input, select, textarea, WC fields
   Brand Color: #3567fd
-------------------------------------------------------- */
.show-password-input {
	background-color: transparent;
}
/* Default form elements */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="password"],
input[type="number"],
input[type="search"],
input[type="url"],
input[type="date"],
input[type="time"],
input[type="week"],
input[type="month"],
select,
textarea {
    width: 100%;
	height: 48px;
    padding: 8px 12px;
    font-size: 15px;
    border: 1px solid #dcdcdc;
    border-radius: var(--radius-s);
    background: #fff;
    color: #222;
    transition: 0.2s ease;
    outline: none;
    appearance: none;
    box-sizing: border-box;
}

/* Hover */
input:not([type="checkbox"]):hover,
select:hover,
textarea:hover {
    border-color: var(--primary);
}

/* Focused */
input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgb(64 145 108 / 25%);
}

/* Placeholder styling */
input::placeholder,
textarea::placeholder {
    color: #999;
	font-size: var(--text-m);
}

/* Textarea */
textarea {
    min-height: 130px;
    resize: vertical;
    border-radius: var(--radius-s);
}

/* Disabled fields */
input:disabled,
select:disabled,
textarea:disabled {
    background: #f6f6f6;
    color: #999;
    cursor: not-allowed;
}

/* Select dropdown arrow */
select {
    background-image: url("data:image/svg+xml,%3Csvg width='16' height='16' fill='%233567fd' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
    background-position: calc(100% - 14px) center;
    background-repeat: no-repeat;
    background-size: 16px;
    padding-right: 40px;
}

/* -------------------------------------------------------
   SELECT2 (Global optimization using brand color)
-------------------------------------------------------- */

.select2-container .select2-selection--single {
    height: 48px;
    border: 1px solid #dcdcdc;
    border-radius: var(--radius-s);
    padding: 8px 12px;
    display: flex;
    align-items: center;
    transition: 0.2s ease;
}

.select2-selection__rendered {
    font-size: 15px;
    color: #222;
    line-height: 28px;
}

.select2-selection__arrow {
    top: 50%;
    transform: translateY(-50%);
}

/* Hover */
.select2-container--default .select2-selection--single:hover {
    border-color: var(--primary);
}

/* Focus */
.select2-container--default.select2-container--open .select2-selection--single {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgb(64 145 108 / 25%);
}

/* Dropdown menu */
.select2-dropdown {
    border: 1px solid #ddd;
    border-radius: var(--radius-s);
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}

/* Options */
.select2-results__option {
    padding: 10px 12px;
    font-size: 15px;
}

.select2-results__option--highlighted {
    background: rgba(53, 103, 253, 0.12);
    color: var(--primary);
}

.select2-results__option[aria-selected="true"] {
    background: rgb(64 145 108 / 15%);
    color: var(--primary);
}

/* -------------------------------------------------------
   WooCommerce specific form fields (Billing / Shipping)
-------------------------------------------------------- */

.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select {
    border-radius: var(--radius-s);
    padding: 12px 14px;
    border: 1px solid #dcdcdc;
}

.woocommerce form .form-row input:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgb(64 145 108 / 25%);
}


/* -------------------------------------------------------
   GLOBAL AJAX LOADER
-------------------------------------------------------- */
/* Remove default Woo gif loader */
.blockUI.blockOverlay::before {
    content: '' !important;
    background-image: none !important;
}

/* Smooth modern backdrop */
.blockUI.blockOverlay {
    background: rgba(255, 255, 255, 0.55) !important;
    backdrop-filter: blur(6px) saturate(140%);
    -webkit-backdrop-filter: blur(6px) saturate(140%);
}

/* Modern centered spinner */
.blockUI.blockOverlay::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 42px;
    height: 42px;
    margin: -21px 0 0 -21px;
    border-radius: 50%;
    border: 4px solid rgba(53, 103, 253, 0.20); /* light brand color */
    border-top-color: var(--primary);                   /* your brand color */
    animation: wc-modern-spin 0.75s ease-out infinite;
}

/* Clean, smooth spin */
@keyframes wc-modern-spin {
    0%   { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
/* -------------------------------------------------------
   END GLOBAL AJAX LOADER
-------------------------------------------------------- */
