:root {
  --color-text-dark: #3b302b;
  --color-text-light: #ffffff;
  --color-text-muted: #7e6f67;
  --color-primary: #103970;
  --color-bg-light: #f7f6f3;
  --color-bg-gray: #f5f5f5;
  --color-border: #e5e2dc;
  --color-accent: #a70b0b;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background-color: #ffffff;
  color: var(--color-text-dark);
}

.page-wrapper {
    max-width: 1728px;
    margin: 0 auto;
    overflow-x: hidden;
}

.container {
  width: 100%;
  max-width: 1440px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 2rem;
  padding-right: 2rem;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  font-weight: 700;
}

p {
    margin: 0;
}


/* ============================
   CART FUNCTIONALITY STYLES
   ============================ */

/* Cart Badge */
.cart-icon {
  position: relative;
}

.cart-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #a70b0b;
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
}

/* Cart Notification */
.cart-notification {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #103970;
  color: #fff;
  padding: 16px 24px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 500;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.cart-notification.show {
  transform: translateY(0);
  opacity: 1;
}

/* Size/Color Selection Modal */
.product-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.product-modal-overlay.show {
  display: flex;
}

.product-modal {
  background: #fff;
  border-radius: 8px;
  max-width: 400px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--color-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text-dark);
  margin: 0;
}

.modal-close-btn {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--color-text-muted);
  line-height: 1;
}

.modal-body {
  padding: 24px;
}

.modal-product-info {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
}

.modal-product-image {
  width: 80px;
  height: 100px;
  background: #e9e7e2;
  flex-shrink: 0;
  overflow: hidden;
}

.modal-product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-product-details h4 {
  font-size: 16px;
  font-weight: 600;
  color: #103970;
  margin: 0 0 4px;
}

.modal-product-details .category {
  font-size: 12px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  margin: 0 0 8px;
}

.modal-product-details .price {
  font-size: 18px;
  font-weight: 600;
  color: var(--color-text-dark);
}

.option-section {
  margin-bottom: 20px;
}

.option-section label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text-dark);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.option-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.option-btn {
  padding: 10px 20px;
  border: 1px solid var(--color-border);
  background: var(--color-bg-light);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  border-radius: 4px;
}

.option-btn:hover {
  border-color: var(--color-primary);
}

.option-btn.selected {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

.color-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  padding: 0;
  position: relative;
}

.color-btn.selected::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #fff;
  font-size: 16px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.modal-footer {
  padding: 20px 24px;
  border-top: 1px solid var(--color-border);
}

.modal-add-btn {
  width: 100%;
  height: 48px;
  background: var(--color-primary);
  color: #fff;
  border: none;
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: background 0.2s;
  border-radius: 4px;
}

.modal-add-btn:hover {
  background: #0d2e5a;
}

.modal-add-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
}