/* ==========================================================================
   NORA CART — Brand-Styled WooCommerce Cart Page CSS
   Applies to: Cart page (/cart/)
   Brand tokens: Cairo font | #C8758A pink | #C9A96E gold | #1E1216 dark
   ========================================================================== */

/* ---------- CRITICAL: HIDE BREADCRUMBS & HERO SECTION ---------------------- */
#base-breadcrumbs,
.base-breadcrumbs,
nav.base-breadcrumbs,
.entry-hero #base-breadcrumbs,
.entry-hero .base-breadcrumbs,
.entry-hero-container-inner {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
}

.entry-hero.page-hero-section {
  display: none !important;
}

/* ---------- Global Font & Typography ---------------------- */
body.woocommerce-cart,
.woocommerce-cart {
  font-family: "Cairo", sans-serif;
}

/* ==========================================================================
   CONTAINER & LAYOUT
   ========================================================================== */

.content-container.site-container {
  background: #fff8f9;
  border-radius: 20px;
  padding: 24px;
}

.content-area,
.site-content-area {
  background: transparent !important;
  margin-top: 2rem !important;
  margin-bottom: 2rem !important;
}

/* ==========================================================================
   CART TABLE
   ========================================================================== */

.wc-block-cart-items {
  width: 100%;
  border-collapse: collapse;
  font-family: "Cairo", sans-serif;
}

.wc-block-cart-items thead {
  background: #fff8f9;
  border-bottom: 2px solid #c9a96e;
}

.wc-block-cart-items__header {
  background: #fff8f9;
  border-bottom: 2px solid #c9a96e;
}

.wc-block-cart-items__header th {
  padding: 12px;
  color: #1e1216;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  font-weight: 700;
  text-align: right;
  direction: rtl;
}

.wc-block-cart-items__row {
  border-bottom: 1px solid #f0d9de;
}

.wc-block-cart-items__row:last-child {
  border-bottom: none;
}

.wc-block-cart-items__row td {
  padding: 16px 12px;
  vertical-align: middle;
}

/* Cart Item Image */
.wc-block-cart-item__image {
  width: 100px;
  text-align: center;
}

.wc-block-cart-item__image img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
}

.wc-block-cart-item__image a {
  text-decoration: none;
}

/* Cart Item Product Info */
.wc-block-cart-item__product {
  flex: 1;
}

.wc-block-components-product-name {
  color: #1e1216;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  display: block;
  margin-bottom: 8px;
  line-height: 1.4;
  transition: color 0.2s ease;
}

.wc-block-components-product-name:hover {
  color: #c8758a;
}

.wc-block-cart-item__prices {
  color: #c9a96e;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 8px;
}

.wc-block-components-product-metadata__description {
  color: #64748b;
  font-family: "Cairo", sans-serif;
  font-size: 13px;
  line-height: 1.5;
  margin: 0;
  direction: rtl;
  text-align: right;
}

.wc-block-components-product-metadata__description p {
  margin: 0;
}

/* Quantity Selector */
.wc-block-cart-item__quantity {
  text-align: center;
}

.wc-block-components-quantity-selector {
  display: inline-flex;
  align-items: center;
  border: 1px solid #f5e8eb;
  border-radius: 6px;
  overflow: hidden;
  background: #fff8f9;
}

.wc-block-components-quantity-selector__input {
  width: 50px;
  padding: 8px;
  border: none;
  text-align: center;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  color: #1e1216;
  background: #fff8f9;
}

.wc-block-components-quantity-selector__input:focus {
  outline: none;
  background: #fffbfc;
}

.wc-block-components-quantity-selector__button {
  padding: 8px 12px;
  background: white;
  border: none;
  color: #c8758a;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-weight: 600;
}

.wc-block-components-quantity-selector__button:hover:not(:disabled) {
  background: #fff8f9;
  color: #b5667a;
}

.wc-block-components-quantity-selector__button:disabled {
  color: #ccc;
  cursor: not-allowed;
}

/* Remove Button */
.wc-block-cart-item__remove-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: none;
  background: transparent;
  color: #c8758a;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-top: 8px;
}

.wc-block-cart-item__remove-link:hover {
  background: #fff3f5;
  color: #b5667a;
  border-radius: 4px;
}

.wc-block-cart-item__remove-link svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

/* Cart Item Total */
.wc-block-cart-item__total {
  text-align: center;
  font-weight: 700;
}

.wc-block-cart-item__total-price {
  color: #c9a96e;
  font-family: "Cairo", sans-serif;
  font-size: 15px;
  font-weight: 700;
}

/* ==========================================================================
   CART TOTALS SIDEBAR
   ========================================================================== */

.wc-block-cart__sidebar {
  background: #fff8f9;
  border: 1px solid #f0d9de;
  border-radius: 12px;
  padding: 20px;
  font-family: "Cairo", sans-serif;
}

.wc-block-cart__totals-title {
  color: #1e1216;
  font-family: "Cairo", sans-serif;
  font-size: 18px;
  font-weight: 700;
  margin: 0 0 16px 0;
  padding-bottom: 12px;
  border-bottom: 2px solid #c9a96e;
  direction: rtl;
  text-align: right;
}

.wc-block-components-totals-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #f0d9de;
  color: #1e1216;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  direction: rtl;
  text-align: right;
}

.wc-block-components-totals-item:last-child {
  border-bottom: none;
}

.wc-block-components-totals-item__label {
  color: #1e1216;
  font-weight: 600;
}

.wc-block-components-totals-footer-item {
  border-top: 2px solid #c9a96e;
  padding-top: 16px;
  font-size: 16px;
  font-weight: 700;
}

.wc-block-components-totals-footer-item .wc-block-components-totals-item__label {
  font-size: 16px;
}

.wc-block-components-totals-footer-item__value,
.wc-block-components-totals-item__value {
  color: #c9a96e;
  font-weight: 700;
  font-size: 15px;
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */

.wc-block-components-button.wp-element-button,
.wc-block-cart__submit-button {
  background: linear-gradient(135deg, #c8758a 0%, #b5667a 100%);
  color: white !important;
  border: none;
  border-radius: 8px;
  padding: 12px 24px;
  font-family: "Cairo", sans-serif;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(200, 117, 138, 0.2);
  width: 100%;
  text-align: center;
}

.wc-block-components-button.wp-element-button:hover,
.wc-block-cart__submit-button:hover {
  background: linear-gradient(135deg, #b5667a 0%, #a05570 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(200, 117, 138, 0.3);
}

.wc-block-components-button.wp-element-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* ==========================================================================
   COUPON PANEL
   ========================================================================== */

.wc-block-components-panel__button {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  background: white;
  border: 1px solid #f0d9de;
  border-radius: 8px;
  color: #1e1216;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 12px;
}

.wc-block-components-panel__button:hover {
  border-color: #c8758a;
  background: #fff8f9;
}

.wc-block-components-panel__button[aria-expanded="true"] {
  border-color: #c8758a;
  background: #fff8f9;
}

.wc-block-components-panel__button-icon {
  width: 20px;
  height: 20px;
  fill: #c8758a;
  transition: transform 0.2s ease;
}

.wc-block-components-panel__button[aria-expanded="true"] .wc-block-components-panel__button-icon {
  transform: rotate(180deg);
}

/* Coupon Form */
.wc-block-components-form-coupon-input {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.wc-block-components-form-coupon-input input[type="text"] {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid #f5e8eb;
  border-radius: 6px;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  color: #1e1216;
  background: #fff8f9;
  transition: all 0.2s ease;
}

.wc-block-components-form-coupon-input input[type="text"]:focus {
  outline: none;
  border-color: #c9a96e;
  background: #fffbfc;
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.08);
}

.wc-block-components-form-coupon-input button {
  padding: 10px 16px;
  background: #c8758a;
  color: white;
  border: none;
  border-radius: 6px;
  font-family: "Cairo", sans-serif;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.wc-block-components-form-coupon-input button:hover {
  background: #b5667a;
}

/* ========== BROAD INPUT STYLING - Catch all form inputs ========== */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="password"],
textarea,
select {
  font-family: "Cairo", sans-serif;
  background: #fff8f9 !important;
  border: 1px solid #f5e8eb !important;
  border-radius: 8px !important;
  color: #1e1216 !important;
  padding: 12px 14px !important;
  transition: all 0.2s ease !important;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="number"]:focus,
input[type="password"]:focus,
textarea:focus,
select:focus {
  outline: none !important;
  border-color: #c9a96e !important;
  background: #fffbfc !important;
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.08) !important;
}

input[type="text"]:hover,
input[type="email"]:hover,
input[type="tel"]:hover,
input[type="number"]:hover,
input[type="password"]:hover,
textarea:hover,
select:hover {
  border-color: #efd4de !important;
}

/* ==========================================================================
   NOTICES & ALERTS
   ========================================================================== */

.wc-block-components-notice-banner {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  direction: rtl;
  text-align: right;
}

.wc-block-components-notice-banner.is-error {
  background: #fff3f5;
  border: 1px solid #f0d9de;
  color: #c8758a;
}

.wc-block-components-notice-banner.is-warning {
  background: #fff8f0;
  border: 1px solid #f0dcc8;
  color: #c9a96e;
}

.wc-block-components-notice-banner.is-success {
  background: #f0f8f5;
  border: 1px solid #c8d9d0;
  color: #1e1216;
}

.wc-block-components-notice-banner svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  fill: currentColor;
}

/* ==========================================================================
   EMPTY CART MESSAGE
   ========================================================================== */

.wc-block-components-empty-cart {
  text-align: center;
  padding: 40px 20px;
}

.wc-block-components-empty-cart p {
  color: #64748b;
  font-family: "Cairo", sans-serif;
  font-size: 16px;
  margin-bottom: 24px;
}

.wc-block-components-empty-cart a {
  display: inline-block;
  background: linear-gradient(135deg, #c8758a 0%, #b5667a 100%);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 12px 24px;
  font-family: "Cairo", sans-serif;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(200, 117, 138, 0.2);
}

.wc-block-components-empty-cart a:hover {
  background: linear-gradient(135deg, #b5667a 0%, #a05570 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(200, 117, 138, 0.3);
}

/* ==========================================================================
   RESPONSIVE DESIGN
   ========================================================================== */

@media (max-width: 1024px) {
  .wc-block-cart-item__image {
    width: 80px;
  }

  .wc-block-cart-item__image img {
    max-width: 100%;
  }
}

@media (max-width: 768px) {
  .content-container.site-container {
    padding: 16px;
  }

  .wc-block-cart-items thead {
    display: none;
  }

  .wc-block-cart-items__row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    border-bottom: 2px solid #f0d9de;
    padding: 12px 0;
  }

  .wc-block-cart-items__row:last-child {
    border-bottom: 1px solid #f0d9de;
  }

  .wc-block-cart-items__row td {
    display: block;
    width: 100%;
    padding: 8px 0;
  }

  .wc-block-cart-item__image {
    width: 100%;
  }

  .wc-block-cart-item__product {
    width: 100%;
  }

  .wc-block-cart-item__quantity {
    width: 100%;
  }

  .wc-block-cart-item__total {
    width: 100%;
  }

  .wc-block-cart__sidebar {
    margin-top: 24px;
    padding: 16px;
  }

  .wc-block-components-button.wp-element-button,
  .wc-block-cart__submit-button {
    padding: 10px 20px;
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .content-container.site-container {
    padding: 12px;
  }

  .wc-block-cart__totals-title {
    font-size: 16px;
  }

  .wc-block-components-totals-footer-item {
    font-size: 15px;
  }

  .wc-block-components-totals-footer-item .wc-block-components-totals-item__label {
    font-size: 15px;
  }

  .wc-block-components-button.wp-element-button,
  .wc-block-cart__submit-button {
    padding: 10px 16px;
    font-size: 13px;
  }

  .wc-block-cart__sidebar {
    padding: 12px;
  }

  .wc-block-components-quantity-selector__input {
    width: 40px;
    padding: 6px;
  }

  .wc-block-components-quantity-selector__button {
    padding: 6px 10px;
    font-size: 14px;
  }
}

/* ==========================================================================
   ACCESSIBILITY & ANIMATIONS
   ========================================================================== */

.wc-block-components-quantity-selector__input:focus,
.wc-block-components-panel__button:focus,
.wc-block-components-button:focus {
  outline: 2px solid #c8758a;
  outline-offset: 2px;
}

/* Smooth transitions */
.wc-block-components-quantity-selector__button,
.wc-block-cart-item__remove-link,
.wc-block-components-button,
.wc-block-components-panel__button {
  transition-property: background-color, border-color, color, box-shadow, transform;
  transition-duration: 0.2s;
  transition-timing-function: ease;
}
