/* House Merch Storefront Styles */
/* Matches the booking portal design system */

:root {
  --bg-main: #f8f3ee;
  --bg-card: #ffffff;
  --white: #ffffff;
  --primary: #c8652d;
  --primary-dark: #9f3e1f;
  --primary-light: #e2725b;
  --text-dark: #1a1a1a;
  --text-muted: #6f6f6f;
  --text-light: #999999;
  --border: rgba(0, 0, 0, 0.08);
  --border-strong: rgba(0, 0, 0, 0.12);
  --radius: 16px;
  --radius-sm: 8px;
  --radius-lg: 20px;
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
  --shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.12);
  --font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'Roboto Mono', monospace;
  --transition: 0.2s ease;
  --max-width: 1200px;
}

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

[hidden] {
  display: none !important;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text-dark);
  background: var(--bg-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

button {
  cursor: pointer;
  font-family: inherit;
}

/* ─── Header (inherited from /booking/styles.css) ─── */

/* ─── Buttons ─── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  text-decoration: none;
  transition: all var(--transition);
}

.btn-primary {
  background: var(--primary);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-hover);
}

.btn-secondary {
  background: var(--text-dark);
  color: var(--white);
}

.btn-secondary:hover {
  background: #333;
}

.btn-outline {
  background: transparent;
  color: var(--text-dark);
  border: 1.5px solid var(--border-strong);
}

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

.btn-lg {
  padding: 16px 32px;
  font-size: 13px;
}

.btn-full {
  width: 100%;
}

/* ─── Hero ─── */
.merch-hero {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 80px 24px;
  text-align: center;
}

.merch-hero__kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--primary);
  margin: 0 0 12px;
}

.merch-hero__title {
  font-family: var(--font-heading);
  font-size: clamp(36px, 6vw, 56px);
  font-weight: 700;
  line-height: 1.1;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
}

.text-accent {
  color: var(--primary);
}

.merch-hero__subtitle {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 500px;
  margin: 0 auto 32px;
}

/* ─── Section Title ─── */
.section-title {
  font-family: var(--font-heading);
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 600;
  margin: 0 0 24px;
  letter-spacing: -0.01em;
}

/* ─── Categories ─── */
.merch-categories {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px 64px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.category-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-align: left;
  padding: 0;
  transition: all var(--transition);
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary);
}

.category-card__image {
  width: 100%;
  height: 200px;
  overflow: hidden;
  background: #f0ebe5;
}

.category-card__image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
  transition: transform 0.4s ease;
}

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

.category-card__title {
  font-size: 16px;
  font-weight: 600;
  margin: 16px 16px 4px;
}

.category-card__desc {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0 16px 16px;
}

/* ─── Shop Section ─── */
.merch-shop {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px 64px;
}

.shop-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.shop-controls {
  display: flex;
  gap: 12px;
}

.shop-select {
  padding: 8px 32px 8px 12px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--text-dark);
  background: var(--white);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 5l3 3 3-3' stroke='%236f6f6f' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

.shop-select:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* ─── Product Grid ─── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition);
}

.product-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.product-card__image {
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  background: #f5f0eb;
}

.product-card__image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
  transition: transform 0.4s ease;
}

.product-card:hover .product-card__image img {
  transform: scale(1.04);
}

.product-card__body {
  padding: 16px;
}

.product-card__category {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  margin: 0 0 6px;
}

.product-card__name {
  font-size: 15px;
  font-weight: 600;
  margin: 0 0 8px;
  line-height: 1.3;
}

.product-card__price {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-dark);
}

.product-card__price .price-from {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-muted);
}

.product-card__badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  background: var(--primary);
  color: var(--white);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  border-radius: 4px;
}

.product-card__image {
  position: relative;
}

/* ─── Product Detail ─── */
.product-detail {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 24px 24px 64px;
}

.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 0;
  border: none;
  background: none;
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
  transition: color var(--transition);
}

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

.product-detail__layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

@media (max-width: 768px) {
  .product-detail__layout {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

.product-detail__gallery {
  display: grid;
  gap: 12px;
}

.gallery-main {
  width: 100%;
  aspect-ratio: 1;
  border-radius: var(--radius);
  overflow: hidden;
  background: #f5f0eb;
}

.gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 16px;
}

.gallery-thumbs {
  display: flex;
  gap: 8px;
}

.gallery-thumb {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color var(--transition);
}

.gallery-thumb.is-active,
.gallery-thumb:hover {
  border-color: var(--primary);
}

.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  margin: 0 0 8px;
}

.detail-title {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 700;
  margin: 0 0 12px;
  line-height: 1.2;
}

.detail-price {
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 20px;
}

.detail-description {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  margin: 0 0 24px;
}

/* Variant selectors */
.variant-group {
  margin-bottom: 20px;
}

.variant-label {
  font-size: 13px;
  font-weight: 600;
  margin: 0 0 8px;
  display: block;
}

.variant-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.variant-option {
  padding: 8px 16px;
  border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--white);
  font-size: 13px;
  font-weight: 500;
  transition: all var(--transition);
}

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

.variant-option.is-selected {
  border-color: var(--primary);
  background: rgba(200, 101, 45, 0.08);
  color: var(--primary);
}

.variant-option.is-disabled {
  opacity: 0.4;
  cursor: not-allowed;
  text-decoration: line-through;
}

.quantity-control {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.quantity-control label {
  font-size: 13px;
  font-weight: 600;
}

.qty-btn {
  width: 32px;
  height: 32px;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background: var(--white);
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

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

.qty-value {
  font-size: 15px;
  font-weight: 600;
  min-width: 24px;
  text-align: center;
}

.detail-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.stock-status {
  font-size: 12px;
  margin: 12px 0 0;
}

.stock-status.in-stock {
  color: #2e7d32;
}

.stock-status.out-of-stock {
  color: #c62828;
}

/* ─── Search Overlay ─── */
.search-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.97);
  z-index: 2000;
  padding: 80px 24px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.search-overlay[hidden] {
  display: none !important;
}

.search-overlay__inner {
  width: 100%;
  max-width: 600px;
  display: flex;
  gap: 12px;
  align-items: center;
}

.search-overlay__inner input {
  flex: 1;
  padding: 14px 20px;
  border: 2px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-family: var(--font-body);
  outline: none;
  transition: border-color var(--transition);
}

.search-overlay__inner input:focus {
  border-color: var(--primary);
}

.search-close-btn {
  width: 40px;
  height: 40px;
  border: none;
  background: none;
  font-size: 20px;
  color: var(--text-muted);
  border-radius: 50%;
  transition: all var(--transition);
}

.search-close-btn:hover {
  background: rgba(0, 0, 0, 0.05);
  color: var(--text-dark);
}

.search-results {
  width: 100%;
  max-width: 600px;
  margin-top: 24px;
  overflow-y: auto;
}

/* ─── Cart Drawer ─── */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1500;
}

.cart-overlay[hidden] {
  display: none !important;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: min(400px, 90vw);
  height: 100vh;
  background: var(--white);
  z-index: 1600;
  display: flex;
  flex-direction: column;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.1);
  transform: translateX(100%);
  transition: transform 0.3s ease;
}

.cart-drawer[hidden] {
  display: none !important;
}

.cart-drawer.is-open {
  transform: translateX(0);
}

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

.cart-drawer__header h2 {
  font-size: 18px;
  font-weight: 600;
  margin: 0;
}

.cart-close-btn {
  width: 32px;
  height: 32px;
  border: none;
  background: none;
  font-size: 18px;
  color: var(--text-muted);
  border-radius: 50%;
}

.cart-close-btn:hover {
  background: rgba(0, 0, 0, 0.05);
}

.cart-drawer__items {
  flex: 1;
  overflow-y: auto;
  padding: 16px 24px;
}

.cart-item {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  align-items: center;
}

.cart-item__image {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: #f5f0eb;
}

.cart-item__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item__details {
  min-width: 0;
}

.cart-item__name {
  font-size: 13px;
  font-weight: 600;
  margin: 0 0 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cart-item__variant {
  font-size: 11px;
  color: var(--text-muted);
  margin: 0 0 4px;
}

.cart-item__price {
  font-size: 13px;
  font-weight: 600;
}

.cart-item__remove {
  border: none;
  background: none;
  color: var(--text-light);
  font-size: 16px;
  padding: 4px;
  cursor: pointer;
}

.cart-item__remove:hover {
  color: #c62828;
}

.cart-drawer__footer {
  padding: 20px 24px;
  border-top: 1px solid var(--border);
}

.cart-totals {
  margin-bottom: 16px;
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  font-size: 15px;
  font-weight: 600;
}

.cart-note {
  font-size: 12px;
  color: var(--text-muted);
  margin: 6px 0 0;
}

.cart-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
  text-align: center;
  color: var(--text-muted);
}

.cart-empty p {
  margin: 0 0 16px;
  font-size: 15px;
}

.product-empty {
  text-align: center;
  padding: 48px 24px;
  color: var(--text-muted);
}

/* ─── Footer ─── */
.merch-footer {
  background: var(--text-dark);
  color: var(--white);
  padding: 48px 24px 24px;
}

.merch-footer__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 48px;
}

@media (max-width: 768px) {
  .merch-footer__inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

.merch-footer__brand img {
  margin-bottom: 12px;
  filter: brightness(10);
}

.merch-footer__brand p {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
}

.merch-footer__links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

@media (max-width: 480px) {
  .merch-footer__links {
    grid-template-columns: 1fr 1fr;
  }
}

.footer-col h4 {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 0 0 12px;
}

.footer-col a {
  display: block;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  margin-bottom: 8px;
  transition: color var(--transition);
}

.footer-col a:hover {
  color: var(--white);
}

.merch-footer__bottom {
  max-width: var(--max-width);
  margin: 32px auto 0;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
}

.merch-footer__bottom p {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.4);
  margin: 0;
}
