/* ================================================
   Vestiges Shop CSS — inherits theme variables from theme.css
   ================================================ */

/* === NAVIGATION === */
.shop-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(15, 17, 24, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(201, 169, 110, 0.12);
}

.shop-nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.shop-nav-brand {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 900;
  color: var(--fg-primary);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.shop-nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.shop-nav-link {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--fg-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

.shop-nav-link:hover { color: var(--accent); }

.cart-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.cart-badge {
  background: var(--accent);
  color: var(--bg-primary);
  font-size: 0.65rem;
  font-weight: 700;
  border-radius: 999px;
  padding: 0 0.45rem;
  line-height: 1.6;
  min-width: 1.4rem;
  text-align: center;
}

/* === BUTTONS === */
.btn-primary {
  display: inline-block;
  background: var(--accent);
  color: var(--bg-primary);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-decoration: none;
  border: none;
  cursor: pointer;
  padding: 0.9rem 2.5rem;
  transition: background 0.2s, transform 0.1s;
}

.btn-primary:hover { background: #d4b87a; }
.btn-primary:active { transform: scale(0.98); }

/* === CATALOG === */
.catalog-page { min-height: 100vh; }

.catalog-header {
  text-align: center;
  padding: 6rem 2rem 4rem;
  background: radial-gradient(ellipse at 50% 0%, rgba(201,169,110,0.05) 0%, transparent 60%), var(--bg-primary);
}

.catalog-header-inner { max-width: 600px; margin: 0 auto; }

.catalog-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 900;
  line-height: 0.95;
  margin-bottom: 1rem;
}

.catalog-subtitle {
  color: var(--fg-secondary);
  font-size: 1rem;
}

.catalog-grid-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 2rem 6rem;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 2rem;
}

.product-card {
  text-decoration: none;
  display: block;
  background: var(--bg-card);
  border: 1px solid rgba(201, 169, 110, 0.1);
  transition: border-color 0.25s, transform 0.2s;
}

.product-card:hover {
  border-color: var(--accent-dim);
  transform: translateY(-2px);
}

.product-card-image {
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--bg-secondary);
}

.product-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

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

.product-card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
}

.placeholder-label {
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--fg-muted);
  font-weight: 600;
}

.product-card-info {
  padding: 1.25rem 1.5rem 1.5rem;
}

.product-card-name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--fg-primary);
  margin-bottom: 0.4rem;
}

.product-card-price {
  font-size: 0.95rem;
  color: var(--accent);
  font-weight: 600;
}

.catalog-empty {
  text-align: center;
  padding: 4rem 0;
  color: var(--fg-muted);
  font-style: italic;
}

/* === PRODUCT DETAIL === */
.product-page { min-height: 100vh; padding: 3rem 2rem 6rem; }

.product-detail {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.product-detail-image {
  aspect-ratio: 1;
  background: var(--bg-secondary);
  border: 1px solid rgba(201,169,110,0.12);
  overflow: hidden;
}

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

.product-detail-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-detail-category {
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.product-detail-name {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 900;
  color: var(--fg-primary);
  line-height: 1.1;
}

.product-detail-price {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--accent);
}

.product-detail-desc {
  color: var(--fg-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
  margin: 1.5rem 0;
}

.add-to-cart-form { margin-top: 1.5rem; }

.variant-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 0.5rem;
}

.variant-select-wrap { margin-bottom: 1.25rem; }

.variant-select {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid rgba(201,169,110,0.2);
  color: var(--fg-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.75rem 1rem;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23c9a96e' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
}

.qty-row { margin-bottom: 1.5rem; }

.qty-control {
  display: flex;
  align-items: center;
  gap: 0;
  width: fit-content;
}

.qty-btn {
  background: var(--bg-secondary);
  border: 1px solid rgba(201,169,110,0.2);
  color: var(--fg-primary);
  width: 2.5rem;
  height: 2.5rem;
  font-size: 1.2rem;
  cursor: pointer;
  transition: background 0.2s;
}
.qty-btn:hover { background: var(--bg-card); }

.qty-input {
  background: var(--bg-secondary);
  border-top: 1px solid rgba(201,169,110,0.2);
  border-bottom: 1px solid rgba(201,169,110,0.2);
  border-left: none;
  border-right: none;
  color: var(--fg-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  text-align: center;
  width: 3rem;
  height: 2.5rem;
}
.qty-input::-webkit-inner-spin-button { display: none; }

.add-to-cart-btn { width: 100%; text-align: center; margin-top: 0.5rem; }

.product-meta { margin-top: 2rem; }
.product-meta-item {
  font-size: 0.85rem;
  color: var(--fg-muted);
  margin-bottom: 0.4rem;
}

.back-to-shop { max-width: 1100px; margin: 3rem auto 0; padding: 0 2rem; }
.back-link { color: var(--fg-muted); font-size: 0.9rem; text-decoration: none; }
.back-link:hover { color: var(--accent); }

/* === CART === */
.cart-page { min-height: 100vh; padding: 3rem 2rem 6rem; }
.cart-inner { max-width: 1100px; margin: 0 auto; }

.cart-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 900;
}

.cart-empty { text-align: center; padding: 4rem 0; color: var(--fg-secondary); }

.cart-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 3rem;
  align-items: start;
}

.cart-item {
  display: grid;
  grid-template-columns: 100px 1fr auto;
  gap: 1.5rem;
  align-items: start;
  padding: 1.5rem 0;
  border-bottom: 1px solid rgba(201,169,110,0.08);
}

.cart-item-image {
  width: 100px;
  height: 100px;
  background: var(--bg-secondary);
  overflow: hidden;
  flex-shrink: 0;
}
.cart-item-image img { width: 100%; height: 100%; object-fit: cover; }
.cart-item-placeholder { width: 100%; height: 100%; background: var(--bg-secondary); }

.cart-item-name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--fg-primary);
  margin-bottom: 0.25rem;
}

.cart-item-variant { font-size: 0.85rem; color: var(--fg-muted); margin-bottom: 0.5rem; }
.cart-item-price { font-size: 0.9rem; color: var(--fg-secondary); margin-bottom: 0.75rem; }
.cart-item-total { text-align: right; font-weight: 600; color: var(--fg-primary); font-size: 1rem; }

.cart-qty-form { display: inline-block; }
.remove-btn {
  background: none;
  border: none;
  font-size: 0.8rem;
  color: var(--fg-muted);
  cursor: pointer;
  text-decoration: underline;
  padding: 0;
  font-family: var(--font-body);
}
.remove-btn:hover { color: #e07070; }

.cart-summary-inner {
  background: var(--bg-card);
  border: 1px solid rgba(201,169,110,0.12);
  padding: 2rem;
  position: sticky;
  top: 80px;
}

.cart-summary-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--fg-secondary);
  margin-bottom: 0.75rem;
}

.cart-summary-total {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--fg-primary);
  padding-top: 1rem;
  margin-top: 0.5rem;
  border-top: 1px solid rgba(201,169,110,0.15);
  margin-bottom: 1.5rem;
}

.checkout-btn { width: 100%; text-align: center; }

.continue-shopping {
  display: block;
  text-align: center;
  margin-top: 1rem;
  font-size: 0.85rem;
  color: var(--fg-muted);
  text-decoration: none;
}
.continue-shopping:hover { color: var(--accent); }

/* === CHECKOUT === */
.checkout-page { min-height: 100vh; padding: 3rem 2rem 6rem; }
.checkout-inner { max-width: 1000px; margin: 0 auto; }

.checkout-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 900;
}

.checkout-alert {
  background: rgba(224, 112, 112, 0.12);
  border: 1px solid rgba(224, 112, 112, 0.3);
  color: #e07070;
  padding: 1rem 1.25rem;
  margin-bottom: 2rem;
  font-size: 0.9rem;
}

.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 4rem;
  align-items: start;
}

.checkout-section-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--fg-primary);
  margin-bottom: 1.5rem;
}

.checkout-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(201,169,110,0.06);
}

.checkout-item-info {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.checkout-item-name { font-size: 0.95rem; color: var(--fg-primary); }
.checkout-item-variant { font-size: 0.8rem; color: var(--fg-muted); }
.checkout-item-qty { font-size: 0.8rem; color: var(--fg-secondary); }
.checkout-item-total { font-size: 0.95rem; font-weight: 600; color: var(--fg-primary); }

.checkout-divider { height: 1px; background: rgba(201,169,110,0.12); margin: 1.25rem 0; }

.checkout-totals { margin-top: 0.5rem; }
.checkout-total-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--fg-secondary);
  margin-bottom: 0.5rem;
}

.checkout-grand-total {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--fg-primary);
  padding-top: 0.75rem;
  border-top: 1px solid rgba(201,169,110,0.15);
  margin-top: 0.5rem;
}

.checkout-pay {
  background: var(--bg-card);
  border: 1px solid rgba(201,169,110,0.12);
  padding: 2.5rem 2rem;
  position: sticky;
  top: 80px;
}

.checkout-pay-note {
  font-size: 0.9rem;
  color: var(--fg-secondary);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.checkout-pay-btn { width: 100%; text-align: center; font-size: 1rem; padding: 1.1rem 2rem; }
.checkout-secure-note { font-size: 0.8rem; color: var(--fg-muted); text-align: center; margin-top: 0.75rem; }

/* === CONFIRM === */
.confirm-page { min-height: 100vh; padding: 4rem 2rem 6rem; }
.confirm-inner { max-width: 640px; margin: 0 auto; text-align: center; }

.confirm-check {
  font-size: 3rem;
  color: var(--accent);
  margin-bottom: 1rem;
}

.confirm-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 900;
}

.confirm-subtitle {
  color: var(--fg-secondary);
  margin: 1.5rem 0 3rem;
  font-size: 1rem;
}

.confirm-order-details {
  background: var(--bg-card);
  border: 1px solid rgba(201,169,110,0.12);
  padding: 2rem;
  text-align: left;
  margin-bottom: 3rem;
}

.confirm-order-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.confirm-order-label {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  font-weight: 600;
  color: var(--fg-muted);
}

.confirm-order-status {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  font-weight: 600;
  color: var(--accent);
}

.confirm-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(201,169,110,0.06);
}

.confirm-next {
  color: var(--fg-secondary);
  font-size: 0.95rem;
  line-height: 1.8;
}

.confirm-next a { color: var(--accent); }

/* === FORM INPUTS === */
.form-input {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid rgba(201,169,110,0.2);
  color: var(--fg-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.75rem 1rem;
  display: block;
}

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

.form-textarea {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid rgba(201,169,110,0.2);
  color: var(--fg-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.75rem 1rem;
  resize: vertical;
}

/* === MOBILE === */
@media (max-width: 768px) {
  .product-detail {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .cart-layout {
    grid-template-columns: 1fr;
  }

  .checkout-layout {
    grid-template-columns: 1fr;
  }

  .checkout-pay { position: static; }
  .cart-summary-inner { position: static; }

  .cart-item {
    grid-template-columns: 80px 1fr;
    grid-template-rows: auto auto;
  }

  .cart-item-total {
    grid-column: 2;
    text-align: left;
  }

  .catalog-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1rem;
  }
}
