/*
Theme Name: 4S Polar
Theme URI: https://example.com
Author: Your Name
Author URI: https://example.com
Description: A lightweight custom theme from scratch
Version: 1.0
License: GNU General Public License v2 or later
Text Domain: 4spolar
*/

body {
  font-family: "Roboto", sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f6f6f6;
}

/* === Page Container === */
.site-container {
  max-width: 1200px; /* change as you like */
  margin: 0 auto; /* centers the content */
  padding: 0 20px; /* some breathing room on small screens */
  min-height: 60vh;
}

.site-header {
  position: sticky; /* or use fixed if you want it ALWAYS visible */
  top: 0;
  z-index: 1000;
  background: #fff; /* prevent content showing behind */
  border-bottom: 1px solid #eee;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

/* Base layout */
.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px 20px;
  height: 70px;
  position: relative;
}

/* Logo */
.header-logo {
  text-align: center;
}
.header-logo img {
  max-height: 40px;
  height: auto;
  width: auto;
}

/* Navigation (desktop) */
.header-nav .main-menu {
  display: flex;
  gap: 20px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.header-nav .main-menu a {
  text-decoration: none;
  font-weight: 500;
  color: #222;
}

/* Cart */
.header-utilities {
  font-size: 18px;
}

/* Burger hidden by default */
.menu-toggle {
  display: none;
  font-size: 24px;
  background: none;
  border: none;
  cursor: pointer;
}

/* === Desktop (≥769px) === */
@media (min-width: 769px) {
  .menu-toggle {
    display: none;
  }

  /* Desktop order: logo left → nav → cart */
  .header-logo {
    order: 1;
    margin-right: 20px;
  }
  .header-nav {
    order: 2;
    margin-right: auto;
  }
  .header-utilities {
    order: 3;
  }
}

/* === Mobile (≤768px) === */
@media (max-width: 768px) {
  .menu-toggle {
    display: block;
    order: 1;
  }

  .header-logo {
    order: 2;
    flex: 1;
    text-align: center; /* center logo */
  }

  .header-utilities {
    order: 3;
  }

  .header-nav {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    width: 100%;
    background: #fff;
    border-top: 1px solid #eee;
  }
  .header-nav.active {
    display: block;
  }

  .header-nav .main-menu {
    flex-direction: column;
    padding: 20px;
    gap: 10px;
  }
}

/* === POLAR CHECKOUT LAYOUT === */
.polar-checkout-columns {
  display: flex;
  gap: 40px;
  align-items: flex-start;
}

.polar-checkout-left {
  flex: 1 1 60%;
  min-width: 0;
}

.polar-checkout-right {
  flex: 1 1 35%;
  min-width: 280px;
  background: #fff;
  padding: 20px;
  border-radius: 15px;
}

/* Make right column sticky on large screens */
@media (min-width: 801px) {
  .polar-checkout-right {
    position: sticky;
    top: 90px; /* how far from the top of the viewport */
    align-self: flex-start;
    height: max-content; /* shrink-wrap to content so it doesn't stretch */
  }
}

/* Small screens: stack and reverse order */
@media (max-width: 800px) {
  .polar-checkout-columns {
    flex-direction: column-reverse;
    gap: 20px; /* smaller gap for mobile */
  }

  .polar-checkout-left,
  .polar-checkout-right {
    width: 100%;
    position: static; /* reset sticky */
  }
}

/* Mini-cart, coupon, summary boxes */
/* .polar-mini-cart,
.polar-coupon,
.polar-order-summary {
  border: 1px solid #eee;
  border-radius: 10px;
  background: #fff;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
} */

.polar-order-summary {
  border-top: 2px solid #eee;
  padding-top: 20px;
}

/* === HEADINGS === */
.woocommerce-checkout h2,
.woocommerce-checkout h3 {
  font-size: 18px;
  font-weight: 600;
  margin: 25px 0 15px;
  border-bottom: 1px solid #eee;
  padding-bottom: 8px;
  color: #111;
}

/* === MATERIAL DESIGN FORM FIELDS === */
.woocommerce-checkout .form-row {
  position: relative;
  margin-bottom: 26px;
}

.woocommerce-checkout .form-row label {
  position: absolute;
  top: 14px;
  left: 2px;
  font-size: 18px;
  color: #777;
  transition: all 0.2s ease;
  pointer-events: none;
}

/* Inputs, textareas, selects */
.woocommerce-checkout input.input-text,
.woocommerce-checkout textarea,
.woocommerce-checkout select,
.select2-container--default .select2-selection--single {
  border: none !important;
  border-bottom: 1px solid #ccc !important;
  border-radius: 0 !important;
  background: transparent !important;
  padding: 14px 2px 6px !important;
  width: 100%;
  font-size: 18px;
  line-height: 1.4;
  transition: border-color 0.2s ease;
}

/* Underline focus/invalid */
.woocommerce-checkout input:focus,
.woocommerce-checkout textarea:focus,
.woocommerce-checkout select:focus,
.select2-container--default.select2-container--focus .select2-selection--single {
  border-bottom: 2px solid #111 !important;
  outline: none !important;
}
.woocommerce-invalid input.input-text,
.woocommerce-invalid textarea,
.woocommerce-invalid select,
.woocommerce-invalid .select2-container--default .select2-selection--single {
  border-bottom: 2px solid #e51d34 !important;
}

/* Label floats when focused or row has value */
.woocommerce-checkout .form-row.has-value label,
.woocommerce-checkout .form-row input:focus ~ label,
.woocommerce-checkout .form-row textarea:focus ~ label,
.woocommerce-checkout .form-row select:focus ~ label {
  top: -8px;
  font-size: 12px;
  color: #111;
  background: #f6f6f6;
  padding: 0 4px;
}

/* Select2 label float fix */
.woocommerce-checkout .form-row.has-value label.float {
  top: -8px !important;
  font-size: 12px !important;
  color: #111 !important;
  background: #fff;
  padding: 0 4px;
}

/* Select2 tweaks */
.select2-container--default .select2-selection--single {
  height: auto !important;
  padding: 12px 2px 6px !important;
}
.select2-container--default .select2-selection--single .select2-selection__rendered {
  padding-left: 0 !important;
  color: #111;
}
.select2-container--default .select2-selection--single .select2-selection__arrow {
  top: 50%;
  right: 4px;
  transform: translateY(-50%);
}

/* === CART MINI === */
.polar-mini-cart .woocommerce-mini-cart-item {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  font-size: 14px;
}
.polar-mini-cart .woocommerce-mini-cart-item:last-child {
  border-bottom: none;
}
.woocommerce-mini-cart .remove_from_cart_button {
  color: #e51d34;
  font-size: 14px;
  text-decoration: none;
}
.woocommerce-mini-cart .remove_from_cart_button:hover {
  color: #c5001d;
}

/* === COUPON === */
.polar-coupon .checkout_coupon {
  display: flex;
  gap: 10px;
}
.polar-coupon .checkout_coupon input.input-text {
  flex: 1;
}
.polar-coupon .checkout_coupon button {
  background: #e51d34;
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
}
.polar-coupon .checkout_coupon button:hover {
  background: #c5001d;
}

/* === TOTALS TABLE === */
.woocommerce-checkout-review-order-table {
  width: 100%;
  font-size: 18px;
}
.woocommerce-checkout-review-order-table th,
.woocommerce-checkout-review-order-table td {
  padding: 10px 0;
  border-bottom: 1px solid #eee;
}
.woocommerce-checkout-review-order-table tfoot tr.order-total th,
.woocommerce-checkout-review-order-table tfoot tr.order-total td {
  font-size: 18px;
  font-weight: 700;
  border-top: 2px solid #111;
  border-bottom: none;
}

/* === PLACE ORDER BUTTON === */
#place_order {
  width: 100%;
  background: #e51d34;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  border: none;
  padding: 14px;
  border-radius: 50px;
  cursor: pointer;
  margin-top: 15px;
  text-transform: uppercase;
}
#place_order:hover {
  background: #c5001d;
}

/* === TERMS === */
.woocommerce-terms-and-conditions-wrapper {
  margin: 20px 0;
}
.woocommerce-terms-and-conditions-wrapper label {
  display: flex;
  align-items: center;
  font-size: 14px;
}
.woocommerce-terms-and-conditions-wrapper a {
  color: #e51d34;
  text-decoration: none;
}
.woocommerce-terms-and-conditions-wrapper a:hover {
  text-decoration: underline;
}

.woocommerce-page form .form-row .select2-container .select2-selection--single .select2-selection__rendered {
  padding: 0 1.1rem;
}

/* Reset and style the "Ship to a different address?" checkbox */
#ship-to-different-address-checkbox {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid #aaa;
  border-radius: 3px;
  background: #fff;
  vertical-align: middle;
  cursor: pointer;
  position: relative;
}

#ship-to-different-address-checkbox:focus {
  border-bottom: 2px solid #aaa !important;
  outline: none !important;
}

/* Checked state */
#ship-to-different-address-checkbox:checked {
  background: #e51d34;
  border-color: #e51d34;
  border-bottom: 2px solid #e51d34 !important;
  outline: none !important;
}

/* Optional white checkmark when checked */
#ship-to-different-address-checkbox:checked::after {
  content: "✓";
  color: #fff;
  font-size: 14px;
  position: absolute;
  top: -2px;
  left: 3px;
}

/* Reset default radio button look */
.woocommerce input[type="radio"].shipping_method {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid #aaa;
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
  position: relative;
  vertical-align: middle;
}

/* When selected → #e51d34 */
.woocommerce input[type="radio"].shipping_method:checked {
  border-color: #e51d34;
  background: #e51d34;
}

/* Optional: white dot in the middle when selected */
.woocommerce input[type="radio"].shipping_method:checked::after {
  content: "";
  width: 8px;
  height: 8px;
  background: #fff;
  border-radius: 50%;
  position: absolute;
  top: 3px;
  left: 3px;
}

.woocommerce input[type="radio"].shipping_method:focus {
  border-bottom: none !important;
  outline: none !important;
}

.woocommerce input[type="radio"]:focus {
  border-bottom: none !important;
  outline: none !important;
}

#add_payment_method #payment,
.woocommerce-cart #payment,
.woocommerce-checkout #payment {
  background: none;
}

/* Payment methods container */
.wc_payment_methods {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

/* Each card */
.wc_payment_method_card {
  list-style: none;
  flex: 1 1 150px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  position: relative;
}

/* Hide native radio button */
.wc_payment_method_card .payment-radio {
  display: none;
}

/* Label fills the card */
.payment-label {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  cursor: pointer;
  height: 100%;
}

/* Selected card = #e51d34 border */
.wc_payment_method_card .payment-radio:checked + .payment-label {
  border: 2px solid #e51d34;
  color: #e51d34;
  font-weight: bold;
}

.wc_payment_method_card .payment-radio + .payment-label {
  border: 2px solid #aaa;
}

/* Logo */
.payment-icon img {
  max-height: 40px;
}

/* Title (optional, smaller) */
.payment-title {
  margin-top: 8px;
  font-size: 14px;
}

.woocommerce-checkout #payment div.payment_box.payment_box_polar {
  background: #f6f6f6;
  padding: 0;
}

.woocommerce-checkout #payment div.payment_box.payment_box_polar::before {
  display: none;
}

.woocommerce ul.cart_list li img,
.woocommerce ul.product_list_widget li img {
  float: right;
  margin-left: 4px;
  width: 60px;
  height: auto;
  box-shadow: none;
}

.woocommerce-mini-cart .remove_from_cart_button {
  color: grey;
  font-size: 14px;
  text-decoration: none;
}

.polar-mini-cart .woocommerce ul.cart_list li a,
.woocommerce ul.product_list_widget li a {
  display: inline-block;
  font-weight: 400;
}

.mini-cart-qty-controls input:focus {
  border-bottom: none !important;
}

.woocommerce ul.cart_list li::after,
.woocommerce ul.cart_list li::before,
.woocommerce ul.product_list_widget li::after,
.woocommerce ul.product_list_widget li::before {
  content: "";
  display: table;
}

.woocommerce ul.cart_list li::after,
.woocommerce ul.cart_list li::before,
.woocommerce ul.product_list_widget li::after,
.woocommerce ul.product_list_widget li::before {
  content: none;
  display: table;
}

.woocommerce-page table.shop_table {
  width: 100%;
}

.woocommerce table.shop_table {
  border: none;
}

.woocommerce-page table.shop_table td,
.woocommerce-page table.shop_table th {
  padding: 10px 0;
}

.shop_table woocommerce-checkout-review-order-table {
  border: none;
}

.woocommerce ul.cart_list li,
.woocommerce ul.product_list_widget li {
  margin-top: 15px;
}

.cart-subtotal td,
.cart-shipping td,
.order-total td,
.fee td {
  text-align: right;
  border-top: 0 !important;
  border-bottom: 0 !important;
}

.cart-subtotal th,
.cart-shipping th,
.order-total th {
  border-top: 0 !important;
  border-bottom: 0 !important;
}

input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Hide arrows in Firefox */
input[type="number"] {
  -moz-appearance: textfield;
}

.not-found-page {
  text-align: center;
  padding: 80px 20px;
}

.not-found-page h1 {
  font-size: 48px;
  margin-bottom: 20px;
  color: #e51d34;
}

.not-found-page p {
  font-size: 18px;
  margin-bottom: 30px;
}

.not-found-actions .button {
  display: inline-block;
  margin: 10px;
  padding: 12px 24px;
  background: #e51d34;
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.2s ease;
}

.not-found-actions .button:hover {
  background: #e51d34;
}

.woocommerce form .form-row {
  padding: 3px;
  margin: 0 0 20px;
}

.woocommerce-error a {
  color: #e51d34;
}

#add_payment_method #payment ul.payment_methods,
.woocommerce-cart #payment ul.payment_methods,
.woocommerce-checkout #payment ul.payment_methods {
  border-bottom: none;
  padding: 0;
}

#add_payment_method #payment div.form-row,
.woocommerce-cart #payment div.form-row,
.woocommerce-checkout #payment div.form-row {
  padding: 0;
}

.site-footer {
  background: #000;
  color: #fff;
  padding: 40px 20px;
  font-size: 14px;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto 30px;
}

.footer-logo img {
  max-height: 40px;
}

.footer-menus {
  display: flex;
  gap: 60px;
}

.footer-nav {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-nav li {
  margin-bottom: 8px;
}
.footer-nav a {
  color: #fff;
  text-decoration: none;
}
.footer-nav a:hover {
  text-decoration: underline;
}

.footer-contact a {
  color: #fff;
  text-decoration: none;
}
.footer-socials a {
  margin-right: 10px;
  color: #fff;
  font-size: 18px;
}

.footer-bottom {
  border-top: 1px solid #333;
  padding-top: 15px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
  gap: 20px;
}
.footer-links a {
  margin-right: 15px;
  color: #aaa;
  text-decoration: none;
}
.footer-links a:hover {
  color: #fff;
}

.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) #respond input#submit.alt,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) a.button.alt,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) button.button.alt,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) input.button.alt,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce #respond input#submit.alt,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce a.button.alt,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce button.button.alt,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce input.button.alt {
  background-color: #e51d34;
  border-radius: 50px;
}

.woocommerce table.shop_table tbody th,
.woocommerce table.shop_table tfoot td,
.woocommerce table.shop_table tfoot th {
  border: none;
}

.woocommerce .cart-collaterals .cart_totals,
.woocommerce-page .cart-collaterals .cart_totals {
  width: 100%;
}

#add_payment_method .wc-proceed-to-checkout a.checkout-button,
.woocommerce-cart .wc-proceed-to-checkout a.checkout-button,
.woocommerce-checkout .wc-proceed-to-checkout a.checkout-button {
  display: block;
  text-align: center;
  margin-bottom: 1em;
  font-size: 16px;
  padding: 14px;
}

.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) #respond input#submit.alt:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) a.button.alt:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) button.button.alt:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) input.button.alt:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor))
  .woocommerce
  #respond
  input#submit.alt:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce a.button.alt:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce button.button.alt:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce input.button.alt:hover {
  background-color: #c5001d;
}

.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) #respond input#submit:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) a.button:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) button.button:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) input.button:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce #respond input#submit:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce a.button:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce button.button:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce input.button:hover {
  background-color: #838383;
  text-decoration: none;
  background-image: none;
  color: white;
  border-radius: 50px;
}

.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) #respond input#submit,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) a.button,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) button.button,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) input.button,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce #respond input#submit,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce a.button,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce button.button,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce input.button {
  background-color: #a3a3a3;
  color: white;
  border-radius: 50px;
}

/* .polar-coupon {
  display: flex;
  border: 1px solid #e8e8e8;
  align-items: center;
  border-radius: 50px;
  padding: 10px;
  margin: 30px 0;
}

.polar-coupon .form-row-first {
  flex: 1;
}

.polar-coupon .form-row-first, .polar-coupon .form-row-last 
{
  width: auto !important;
  margin: 0 !important;
}

.woocommerce-checkout .polar-coupon input.input-text {
  border: none !important;
  border-bottom: none !important;
  border-radius: 0 !important;
  background: transparent !important;
  padding: 0 !important;
  width: 100%;
  font-size: 18px;
  line-height: 1.4;
  transition: border-color 0.2s ease;
} */

tr.cart-discount td {
  text-align: right;
}

tr.cart-discount td a {
  color: #e51d34;
}

.woocommerce #content table.cart td.actions .input-text, .woocommerce table.cart td.actions .input-text, .woocommerce-page #content table.cart td.actions .input-text, .woocommerce-page table.cart td.actions .input-text {
    width: 200px;
}

.shop_table .coupon {
  display: flex;
  align-items: center;
}

.nexixpay-loghi-container .internal-container {
  display: flex;
  align-items: center;
  gap: 10px;
}