/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  text-transform: uppercase;
  letter-spacing: 2px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-base);
  border: 1px solid transparent;
  line-height: 1;
}

.btn-primary {
  background-color: var(--color-accent);
  color: #fff;
}
.btn-primary:hover {
  background-color: var(--color-accent-hover);
}

.btn-secondary {
  background-color: var(--color-secondary);
  color: #fff;
}
.btn-secondary:hover {
  background-color: var(--color-secondary-hover);
}

.btn-outline {
  background-color: transparent;
  color: var(--color-text);
  border-color: currentColor;
}
.btn-outline:hover {
  background-color: var(--color-text);
  color: var(--color-bg);
}

.btn-ghost {
  padding: var(--space-sm) 0;
  color: var(--color-accent);
  background-color: transparent;
  border-radius: 0;
  border-bottom: 1px solid transparent;
}
.btn-ghost:hover {
  border-bottom-color: currentColor;
}

.btn-sm {
  padding: 10px 20px;
  font-size: 0.7rem;
}
.btn-lg {
  padding: 18px 40px;
  font-size: var(--fs-sm);
}

/* CARDS */
.card {
  background-color: var(--color-bg-card);
  border-radius: 0; /* Clean Shopify style */
  overflow: hidden;
  position: relative;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.card:hover {
  transform: translateY(-2px);
}

.card-image {
  position: relative;
  aspect-ratio: 3/4;
  overflow: hidden;
  background-color: var(--color-bg-alt);
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.card:hover .card-image img {
  transform: scale(1.05);
}

.card-content {
  padding: var(--space-lg);
  text-align: center;
}

.card-title {
  font-family: var(--font-heading);
  font-size: var(--fs-md);
  font-weight: var(--fw-regular);
  color: var(--color-text);
  margin-bottom: var(--space-xs);
}

.card-price {
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--color-text-muted);
}

.card-text {
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-bottom: var(--space-md);
}

/* BADGES */
.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 0.65rem;
  font-weight: var(--fw-bold);
  text-transform: uppercase;
  letter-spacing: 1px;
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  z-index: 10;
}

.badge-bestseller {
  background-color: var(--color-accent);
  color: #fff;
}
.badge-new {
  background-color: var(--color-secondary);
  color: #fff;
}
.badge-sale {
  background-color: hsl(0, 70%, 50%);
  color: #fff;
}
.badge-vegan {
  background-color: var(--color-success);
  color: #fff;
}

/* PRODUCT CARD SPECIFIC */
.product-card {
  display: flex;
  flex-direction: column;
}
.product-card .card-content {
  padding: var(--space-md) 0 0;
}

/* CATEGORY CARD */
.category-card {
  text-align: center;
  cursor: pointer;
}
.category-card .card-image {
  aspect-ratio: 1;
  border-radius: 50%;
  margin-bottom: var(--space-md);
}
.category-card:hover .card-image img {
  transform: scale(1.05);
}

/* FORMS */
.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: var(--fw-medium);
  margin-bottom: var(--space-xs);
  color: var(--color-text-muted);
}

.form-input {
  width: 100%;
  padding: 12px 0;
  background-color: transparent;
  border: none;
  border-bottom: 1px solid var(--color-border);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  color: var(--color-text);
  transition: border-color var(--transition-fast);
}

.form-input:focus {
  outline: none;
  border-bottom-color: var(--color-text);
}

*:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* TESTIMONIAL CARD */
.testimonial-card {
  background-color: var(--color-bg-card);
  padding: var(--space-xl);
  text-align: center;
  border: 1px solid var(--color-border);
}

.testimonial-quote {
  font-family: var(--font-heading);
  font-style: italic;
  font-size: var(--fs-lg);
  color: var(--color-text);
  margin-bottom: var(--space-md);
  line-height: 1.4;
}

.testimonial-author {
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ACCORDION */
.accordion {
  border-top: 1px solid var(--color-border);
}

.accordion-item {
  border-bottom: 1px solid var(--color-border);
}

.accordion-header {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md) 0;
  font-size: var(--fs-base);
  font-weight: var(--fw-medium);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-base);
}

.accordion-item.active .accordion-content {
  max-height: 500px;
  padding-bottom: var(--space-md);
}

/* CHAT PANEL */
.chat-panel {
  position: fixed;
  bottom: var(--space-xl);
  right: var(--space-xl);
  width: 350px;
  background-color: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-xl);
  display: flex;
  flex-direction: column;
  z-index: 1000;
  max-height: 600px;
}

.chat-header {
  background-color: var(--color-accent);
  color: #fff;
  padding: var(--space-md);
  font-weight: var(--fw-medium);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  display: flex;
  justify-content: space-between;
}

.chat-messages {
  flex: 1;
  padding: var(--space-md);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.chat-msg {
  max-width: 80%;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-lg);
  font-size: var(--fs-sm);
}

.chat-msg.bot {
  background-color: var(--color-bg-alt);
  align-self: flex-start;
  border-bottom-left-radius: 0;
}

.chat-msg.user {
  background-color: var(--color-accent);
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 0;
}

.chat-input-area {
  display: flex;
  padding: var(--space-md);
  border-top: 1px solid var(--color-border);
}

.chat-input {
  flex: 1;
  border: 1px solid var(--color-border);
  padding: 10px;
  border-radius: var(--radius-full);
  font-size: var(--fs-sm);
}

.chat-input:focus {
  outline: none;
  border-color: var(--color-accent);
}

.chat-send-btn {
  margin-left: var(--space-sm);
  color: var(--color-accent);
}

.chat-suggestion-btn {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  padding: 6px 12px;
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
  transition: all var(--transition-fast);
}

.chat-suggestion-btn:hover {
  background-color: var(--color-bg-alt);
  color: var(--color-text);
}

/* BANNER WARNING */
.banner-warning {
  background-color: var(--color-accent-light);
  border-left: 4px solid var(--color-accent);
  padding: var(--space-md);
  color: var(--color-text);
  font-size: var(--fs-sm);
}

/* MODAL */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-overlay);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-base);
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background-color: var(--color-bg-card);
  padding: var(--space-2xl);
  max-width: 600px;
  width: 90%;
  position: relative;
  transform: translateY(20px);
  transition: transform var(--transition-base);
}

.modal-overlay.active .modal-content {
  transform: translateY(0);
}

/* WIZARD CONSTRUCTOR */
.constructor-panel {
  background-color: var(--color-bg-card);
  border: 1px solid var(--color-border);
  padding: var(--space-2xl);
  border-radius: var(--radius-sm);
}

.step-indicator {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-2xl);
  position: relative;
}

.step-number {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--color-bg-alt);
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: var(--fw-bold);
  font-size: var(--fs-sm);
  z-index: 2;
  position: relative;
}

.step-number.active {
  background-color: var(--color-accent);
  color: #fff;
}

.step-line {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  height: 2px;
  background-color: var(--color-bg-alt);
  width: 100%;
  z-index: 1;
}

/* SUCURSAL LAYOUT */
.sucursal-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-2xl);
}
@media (min-width: 992px) {
  .sucursal-layout {
    grid-template-columns: 1fr 1fr;
  }
}

/* Cart Drawer */
.cart-overlay { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background: var(--color-overlay); z-index: 2000; opacity: 0; visibility: hidden; transition: opacity var(--transition-base); }
.cart-overlay.is-open { opacity: 1; visibility: visible; }
.cart-drawer { position: fixed; top: 0; right: -400px; width: 100%; max-width: 400px; height: 100vh; background: var(--color-bg); z-index: 2001; display: flex; flex-direction: column; transition: right var(--transition-base); box-shadow: var(--shadow-xl); }
.cart-drawer.is-open { right: 0; }
.cart-header { padding: var(--space-lg) var(--space-xl); display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--color-border); }
.cart-header h2 { font-size: var(--fs-lg); margin: 0; font-family: var(--font-heading); font-weight: var(--fw-medium); }
.cart-close { background: none; border: none; font-size: var(--fs-xl); cursor: pointer; color: var(--color-text); }
.cart-body { flex: 1; overflow-y: auto; padding: var(--space-xl); display: flex; flex-direction: column; gap: var(--space-lg); }
.cart-empty-msg { text-align: center; color: var(--color-text-muted); margin-top: var(--space-2xl); }
.cart-item { display: flex; gap: var(--space-md); border-bottom: 1px solid var(--color-border); padding-bottom: var(--space-md); }
.cart-item-img { width: 70px; height: 90px; background: var(--color-bg-alt); object-fit: contain; }
.cart-item-details { flex: 1; display: flex; flex-direction: column; justify-content: center; }
.cart-item-title { font-size: var(--fs-sm); font-weight: var(--fw-medium); margin-bottom: 4px; }
.cart-item-price { font-size: var(--fs-xs); color: var(--color-text-muted); }
.cart-item-remove { font-size: var(--fs-xs); color: var(--color-accent); cursor: pointer; text-decoration: underline; margin-top: auto; border:none; background:none; text-align:left; padding:0; }
.cart-footer { padding: var(--space-xl); border-top: 1px solid var(--color-border); background: var(--color-bg-alt); }
.cart-subtotal { display: flex; justify-content: space-between; margin-bottom: var(--space-md); font-weight: var(--fw-bold); font-size: var(--fs-md); }
.cart-shipping-msg { font-size: var(--fs-xs); text-align: center; margin-bottom: var(--space-md); color: var(--color-accent); }
.btn-checkout { width: 100%; padding: var(--space-md); }
.cart-badge { position: absolute; top: -5px; right: -5px; background: var(--color-accent); color: #fff; font-size: 10px; font-weight: bold; width: 18px; height: 18px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.cart-toggle { position: relative; }
.btn-add-cart { width: 100%; margin-top: var(--space-md); padding: 8px; font-size: var(--fs-xs); }
