/* WooCommerce Checkout Custom Styles for Farsisaz Theme */

/* Hide WooCommerce labels and use placeholders instead */
.woocommerce-checkout .form-row label {
    display: none !important;
}

/* Remove default WooCommerce input styling */
.woocommerce-checkout .form-row input.input-text,
.woocommerce-checkout .form-row select,
.woocommerce-checkout .form-row textarea {
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
}

/* Form row wrapper */
.woocommerce-checkout .form-row {
    margin: 0 !important;
    padding: 0 !important;
}

/* Required field asterisk */
.woocommerce-checkout .form-row .required {
    display: none !important;
}

/* Payment methods styling */
.woocommerce-checkout-payment {
    background: transparent !important;
    padding: 0 !important;
}

.woocommerce-checkout-payment ul.payment_methods {
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
}

.woocommerce-checkout-payment ul.payment_methods li {
    margin: 0 0 1rem 0 !important;
    padding: 1rem !important;
    border: 1px solid #F4F4F4 !important;
    border-radius: 14px !important;
    background: #ffffff !important;
}

html.dark .woocommerce-checkout-payment ul.payment_methods li {
    border-color: #2F2F2F !important;
    background: #191919 !important;
}

.woocommerce-checkout-payment ul.payment_methods li input[type="radio"] {
    margin-left: 10px !important;
}

.woocommerce-checkout-payment ul.payment_methods li label {
    display: inline-block !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    color: #000000 !important;
}

html.dark .woocommerce-checkout-payment ul.payment_methods li label {
    color: #ffffff !important;
}

.woocommerce-checkout-payment .payment_box {
    background: #F8F8F8 !important;
    border-radius: 10px !important;
    padding: 1rem !important;
    margin-top: 1rem !important;
    border: none !important;
}

html.dark .woocommerce-checkout-payment .payment_box {
    background: #000000 !important;
    color: #ffffff !important;
}

.woocommerce-checkout-payment .payment_box::before {
    display: none !important;
}

/* Cart totals in sidebar */
.cart-item-price .woocommerce-Price-amount {
    font-size: 24px !important;
    font-weight: 600 !important;
    color: #000000 !important;
}

html.dark .cart-item-price .woocommerce-Price-amount {
    color: #ffffff !important;
}

.cart-item-price .woocommerce-Price-currencySymbol {
    display: none;
}

/* Add Toman symbol after price */
.cart-item-price .woocommerce-Price-amount::after {
    content: '';
    display: inline-block;
    width: 18px;
    height: 15px;
    margin-right: 4px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='15' viewBox='0 0 18 15' fill='none'%3E%3Cpath d='M3.49609 7.92394C3.91196 7.72104 4.22386 7.51814 4.53576 7.21379C4.74369 6.90944 4.95162 6.60509 5.15956 6.30074C5.26352 5.89494 5.36749 5.48913 5.36749 5.08333H15.2443C15.8681 5.08333 16.3879 4.88043 16.8038 4.57608C17.1157 4.17028 17.3236 3.66303 17.3236 2.95288V0.518066H15.9721V2.85142C15.9721 3.35868 15.6602 3.66303 15.1403 3.66303H5.36749V3.15578C5.36749 2.64852 5.26352 2.34417 5.15956 1.93837C5.15956 1.63402 4.95162 1.32967 4.74369 1.12677C4.53576 0.923868 4.32783 0.822417 4.11989 0.720967C3.80799 0.619517 3.49609 0.518066 3.28816 0.518066C2.8723 0.518066 2.5604 0.619517 2.2485 0.720967C2.04057 0.923868 1.72867 1.02532 1.6247 1.32967C1.41677 1.53257 1.20883 1.73547 1.20883 2.03982C1.10487 2.34417 1.0009 2.64852 1.0009 2.95288C1.0009 3.25723 1.0009 3.56158 1.10487 3.86593C1.20883 4.17028 1.3128 4.37318 1.41677 4.57608C1.6247 4.67753 1.83263 4.88043 2.14453 4.98188C2.45643 5.08333 2.76833 5.08333 3.28816 5.08333H4.11989C4.11989 5.28623 4.01593 5.48913 4.01593 5.69203C3.91196 5.89494 3.70403 6.09784 3.60006 6.30074C3.49609 6.40219 3.28816 6.50364 2.97626 6.60509C2.76833 6.70654 2.45643 6.80799 2.14453 6.80799H0.792969V8.22829H2.14453C2.66436 8.12684 3.08023 8.02539 3.49609 7.92394ZM3.28816 3.66303C2.8723 3.66303 2.66436 3.66303 2.45643 3.46013C2.35246 3.35868 2.2485 3.15578 2.2485 2.85142C2.2485 2.54707 2.35246 2.24272 2.45643 2.14127C2.66436 2.03982 2.8723 1.93837 3.1842 1.93837C3.49609 1.93837 3.70403 2.03982 3.91196 2.24272C4.11989 2.44562 4.11989 2.74997 4.11989 3.15578V3.76448H3.28816V3.66303Z' fill='black'/%3E%3Cpath d='M14.2007 0.518066H10.25V1.73547H14.2007V0.518066Z' fill='black'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

/* Cart total amount styling */
.cart-total-amount .woocommerce-Price-amount {
    font-size: 23px !important;
    font-weight: 700 !important;
    color: #000000 !important;
}

html.dark .cart-total-amount .woocommerce-Price-amount {
    color: #ffffff !important;
}

.cart-total-amount .woocommerce-Price-currencySymbol {
    display: none;
}

.cart-total-amount .woocommerce-Price-amount::after {
    content: '';
    display: inline-block;
    width: 18px;
    height: 15px;
    margin-right: 4px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='15' viewBox='0 0 18 15' fill='none'%3E%3Cpath d='M3.49609 7.92394C3.91196 7.72104 4.22386 7.51814 4.53576 7.21379C4.74369 6.90944 4.95162 6.60509 5.15956 6.30074C5.26352 5.89494 5.36749 5.48913 5.36749 5.08333H15.2443C15.8681 5.08333 16.3879 4.88043 16.8038 4.57608C17.1157 4.17028 17.3236 3.66303 17.3236 2.95288V0.518066H15.9721V2.85142C15.9721 3.35868 15.6602 3.66303 15.1403 3.66303H5.36749V3.15578C5.36749 2.64852 5.26352 2.34417 5.15956 1.93837C5.15956 1.63402 4.95162 1.32967 4.74369 1.12677C4.53576 0.923868 4.32783 0.822417 4.11989 0.720967C3.80799 0.619517 3.49609 0.518066 3.28816 0.518066C2.8723 0.518066 2.5604 0.619517 2.2485 0.720967C2.04057 0.923868 1.72867 1.02532 1.6247 1.32967C1.41677 1.53257 1.20883 1.73547 1.20883 2.03982C1.10487 2.34417 1.0009 2.64852 1.0009 2.95288C1.0009 3.25723 1.0009 3.56158 1.10487 3.86593C1.20883 4.17028 1.3128 4.37318 1.41677 4.57608C1.6247 4.67753 1.83263 4.88043 2.14453 4.98188C2.45643 5.08333 2.76833 5.08333 3.28816 5.08333H4.11989C4.11989 5.28623 4.01593 5.48913 4.01593 5.69203C3.91196 5.89494 3.70403 6.09784 3.60006 6.30074C3.49609 6.40219 3.28816 6.50364 2.97626 6.60509C2.76833 6.70654 2.45643 6.80799 2.14453 6.80799H0.792969V8.22829H2.14453C2.66436 8.12684 3.08023 8.02539 3.49609 7.92394ZM3.28816 3.66303C2.8723 3.66303 2.66436 3.66303 2.45643 3.46013C2.35246 3.35868 2.2485 3.15578 2.2485 2.85142C2.2485 2.54707 2.35246 2.24272 2.45643 2.14127C2.66436 2.03982 2.8723 1.93837 3.1842 1.93837C3.49609 1.93837 3.70403 2.03982 3.91196 2.24272C4.11989 2.44562 4.11989 2.74997 4.11989 3.15578V3.76448H3.28816V3.66303Z' fill='black'/%3E%3Cpath d='M14.2007 0.518066H10.25V1.73547H14.2007V0.518066Z' fill='black'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

/* Error messages */
.woocommerce-error,
.woocommerce-message,
.woocommerce-info {
    background: #fef2f2 !important;
    color: #991b1b !important;
    border: 1px solid #fca5a5 !important;
    border-radius: 10px !important;
    padding: 1rem !important;
    margin-bottom: 1rem !important;
    list-style: none !important;
}

.woocommerce-message {
    background: #f0fdf4 !important;
    color: #166534 !important;
    border-color: #86efac !important;
}

.woocommerce-info {
    background: #eff6ff !important;

}

html.dark .woocommerce-error {
    background: #2d1515 !important;
    color: #fca5a5 !important;
    border-color: #7f1d1d !important;
}

html.dark .woocommerce-message {
    background: #14291c !important;
    color: #86efac !important;
    border-color: #166534 !important;
}

html.dark .woocommerce-info {
    background: #1a2540 !important;
    color: #93c5fd !important;
    border-color: #1e40af !important;
}

/* Remove default WooCommerce notice icons */
.woocommerce-error::before,
.woocommerce-message::before,
.woocommerce-info::before {
    display: none !important;
}

/* Hide place order button default (we have custom button) */
.woocommerce-checkout #payment #place_order {
    display: none !important;
}

/* Cart shadows */
.cart-shadows-one {
    box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
}

html.dark .cart-shadows-one {
    box-shadow: none;
}

/* Hide all WooCommerce default wrappers */
.woocommerce-billing-fields,
.woocommerce-shipping-fields,
.woocommerce-account-fields {
    display: contents !important;
}

.woocommerce-billing-fields h3,
.woocommerce-shipping-fields h3 {
    display: none !important;
}

.woocommerce-billing-fields__field-wrapper {
    display: contents !important;
}

/* Custom billing input focus state */
#customer_details input:focus {
    border-color: #E1FF00 !important;
    box-shadow: 0 0 0 3px rgba(225, 255, 0, 0.2) !important;
}

/* Validation error state for inputs */
#customer_details input.woocommerce-invalid,
#customer_details input:invalid {
    border-color: #F04055 !important;
}

/* Hide default WooCommerce form elements */
.woocommerce form .form-row {
    padding: 0 !important;
    margin: 0 !important;
}

.woocommerce form .form-row label {
    display: none !important;
}

/* Terms and conditions styling */
.woocommerce-terms-and-conditions-wrapper {
    margin-top: 1rem;
}

.woocommerce-terms-and-conditions-wrapper .woocommerce-privacy-policy-text {
    font-size: 12px;
    color: #666;
}

html.dark .woocommerce-terms-and-conditions-wrapper .woocommerce-privacy-policy-text {
    color: #999;
}

.woocommerce-form__label-for-checkbox {
    font-size: 12px;
    color: #000;
    display: flex;
    align-items: center;
    gap: 8px;
}

html.dark .woocommerce-form__label-for-checkbox {
    color: #fff;
}

/* Hide default place order section */
.form-row.place-order {
    display: none !important;
}

/* WooCommerce notices container */
.woocommerce-notices-wrapper {
    margin-bottom: 1rem;
}

/* Loading overlay for checkout updates */
.blockUI.blockOverlay {
    background: rgba(255, 255, 255, 0.8) !important;
}

html.dark .blockUI.blockOverlay {
    background: rgba(0, 0, 0, 0.8) !important;
}

/* Hide WooCommerce default order review table */
.woocommerce-checkout-review-order-table {
    display: none !important;
}

/* Ensure checkout form takes full width */
.woocommerce-checkout form.checkout {
    width: 100%;
}

/* Fix for RTL layout */
[dir="rtl"] .woocommerce-checkout {
    direction: rtl;
}

/* Payment method images */
.payment-gateway-icon img {
    max-height: 24px;
    width: auto;
}
