/* Reseteo general y base */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body {
  background-color: #f8f9fa;
  color: #1f1f1f;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Encabezado */
header {
  background-color: #ffffff;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  border-bottom: 1px solid #e0e0e0;
}

.header-left .logo {
  display: flex;
  align-items: center;
}

.header-title {
  font-size: 18px;
  font-weight: 500;
  color: #1f1f1f;
}

/* Contenido principal */
main {
  flex: 1;
  max-width: 800px;
  width: 100%;
  margin: 0 auto;
  padding: 60px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Estado de carrito vacío */
.empty-cart-section {
  text-align: center;
  margin-bottom: 60px;
}

.empty-cart-section h1 {
  font-size: 36px;
  font-weight: 400;
  letter-spacing: -0.5px;
  margin-bottom: 24px;
  color: #1f1f1f;
}

.btn-continue {
  background-color: transparent;
  color: #1f1f1f;
  border: 1.5px solid #1f1f1f;
  border-radius: 24px;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.btn-continue:hover {
  background-color: #f1f3f4;
}

/* Sección guardado para más tarde */
.saved-for-later-card {
  background-color: #ffffff;
  border-radius: 12px;
  width: 100%;
  padding: 32px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.saved-for-later-card h2 {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 20px;
  color: #1f1f1f;
}

.divider {
  height: 1px;
  background-color: #e0e0e0;
  margin-bottom: 24px;
}

.saved-info h3 {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 6px;
  color: #1f1f1f;
}

.saved-info p {
  font-size: 14px;
  color: #444746;
}

/* Alertas del carrito */
.cart-alert {
  width: 100%;
  padding: 14px 20px;
  border-radius: 10px;
  font-size: 14px;
  margin-bottom: 24px;
  text-align: center;
}

.cart-alert.exito {
  background-color: #e6f4ea;
  color: #137333;
  border: 1px solid rgba(19, 115, 51, 0.2);
}

.cart-alert.error {
  background-color: #fce8e6;
  color: #c5221f;
  border: 1px solid rgba(197, 34, 31, 0.2);
}

/* Cabecera del carrito con productos */
.cart-header-row {
  width: 100%;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 24px;
}

.cart-header-row h1 {
  font-size: 32px;
  font-weight: 400;
  letter-spacing: -0.5px;
}

.cart-header-row span {
  font-size: 14px;
  color: #444746;
}

/* Lista de ítems en el carrito */
.cart-items-card {
  background-color: #ffffff;
  border-radius: 12px;
  width: 100%;
  padding: 8px 32px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  margin-bottom: 24px;
}

.cart-item-row {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 24px 0;
  border-bottom: 1px solid #e0e0e0;
}

.cart-item-row:last-child {
  border-bottom: none;
}

.cart-item-img {
  width: 72px;
  height: 72px;
  border-radius: 10px;
  background-color: #f1f3f4;
  object-fit: contain;
  flex-shrink: 0;
  padding: 8px;
}

.cart-item-info {
  flex: 1;
  min-width: 0;
}

.cart-item-info h3 {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 4px;
}

.cart-item-info .cart-item-price {
  font-size: 14px;
  color: #444746;
}

.cart-item-qty-form {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cart-item-qty-form input[type="number"] {
  width: 56px;
  padding: 8px;
  border: 1px solid #dadce0;
  border-radius: 8px;
  font-size: 14px;
  text-align: center;
}

.btn-small {
  background-color: transparent;
  border: 1px solid #dadce0;
  border-radius: 100px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 500;
  color: #1f1f1f;
  cursor: pointer;
}

.btn-small:hover {
  background-color: #f1f3f4;
}

.cart-item-subtotal {
  width: 90px;
  text-align: right;
  font-size: 15px;
  font-weight: 500;
}

.btn-remove {
  background: none;
  border: none;
  color: #c5221f;
  font-size: 13px;
  cursor: pointer;
  text-decoration: underline;
  padding: 0;
}

/* Tarjeta de resumen de compra */
.cart-summary {
  background-color: #ffffff;
  border-radius: 12px;
  width: 100%;
  padding: 24px 32px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.cart-summary .cart-total-label {
  font-size: 14px;
  color: #444746;
}

.cart-summary .cart-total-amount {
  font-size: 24px;
  font-weight: 500;
}

.btn-checkout {
  background-color: #1a73e8;
  color: #ffffff;
  border: none;
  border-radius: 100px;
  padding: 12px 32px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.btn-checkout:hover {
  background-color: #1557b0;
}

/* Pie de página */
footer {
  background-color: #f8f9fa;
  padding: 24px;
  border-top: 1px solid #e0e0e0;
  margin-top: auto;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 12px;
  color: #444746;
  flex-wrap: wrap;
}

.flag-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.flag-icon {
  width: 20px;
  height: 14px;
}

.footer-links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.footer-links a {
  color: #444746;
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
}