/* Font Face Declarations */
@font-face {
  font-family: 'Canela';
  src: url('Canela-Light.woff2') format('woff2'),
       url('Canela-Light.woff') format('woff'),
       url('Canela-Light-Trial.otf') format('opentype');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Founders Grotesk';
  src: url('FoundersGrotesk-Regular.woff2') format('woff2'),
       url('FoundersGrotesk-Regular.woff') format('woff'),
       url('FoundersGrotesk-Regular.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --primary: #2563eb;
  --success: #059669;
  --error: #dc2626;
  --bg: #f8fafc;
  --card: #fff;
  --border: #e5e7eb;
  --radius: 12px;
  --shadow: 0 2px 8px rgba(0,0,0,0.04);
  --font-body: 'Founders Grotesk', Arial, sans-serif;
  --font-heading: 'Canela', Georgia, serif;
}
html {
  width: 100%;
}

body {
  margin: 0; 
  font-family: var(--font-body); 
  background: var(--bg); 
  color: #222;
}

header {
  padding: 2rem 1rem 1rem 1rem; 
  text-align: center;
}

h1 { 
  color: var(--primary); 
  margin-bottom: 0.5rem; 
}

.logo {
  max-width: 200px;
  height: auto;
  margin-bottom: 1rem;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.desc { 
  color: #555; 
  margin-bottom: 2rem; 
}

.container {
  display: flex; 
  flex-wrap: wrap; 
  gap: 2rem; 
  justify-content: center; 
  max-width: 1200px; 
  margin: 0 auto;
}

.products {
  flex: 2 1 350px; 
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); 
  gap: 1.5rem;
}

.product-card {
  background: var(--card); 
  border-radius: var(--radius); 
  box-shadow: var(--shadow); 
  border: 1px solid var(--border);
  padding: 1.5rem; 
  display: flex; 
  flex-direction: column; 
  align-items: center; 
  transition: box-shadow 0.2s;
}

.product-card:hover { 
  box-shadow: 0 4px 16px rgba(37,99,235,0.08); 
}

.product-img { 
  font-size: 2.5rem; 
  margin-bottom: 1rem; 
}

.product-name { 
  font-weight: 600; 
  margin-bottom: 0.5rem; 
  text-align: center;
}

.product-desc { 
  color: #666; 
  font-size: 0.9rem; 
  text-align: center; 
  margin-bottom: 1rem;
  line-height: 1.4;
}

.product-price { 
  font-weight: 600; 
  color: var(--primary); 
  margin-bottom: 1rem;
}

.variant-group { 
  margin-bottom: 1rem; 
  width: 100%;
}

.variant-label { 
  display: block; 
  margin-bottom: 0.5rem; 
  font-weight: 500;
}

.variant-select { 
  width: 100%; 
  padding: 0.5rem; 
  border: 1px solid var(--border); 
  border-radius: 6px;
}

.qty-controls { 
  display: flex; 
  align-items: center; 
  gap: 0.5rem; 
  margin-bottom: 1rem;
}

.qty-btn {
  width: 32px; 
  height: 32px; 
  border: 1px solid var(--border); 
  background: var(--card); 
  border-radius: 6px; 
  cursor: pointer; 
  display: flex; 
  align-items: center; 
  justify-content: center;
  font-weight: 600;
}

.qty-btn:hover { 
  background: var(--bg); 
}

.qty-btn:active { 
  transform: scale(0.95); 
}

.add-cart-btn {
  background: var(--primary); 
  color: white; 
  border: none; 
  padding: 0.75rem 1.5rem; 
  border-radius: var(--radius); 
  cursor: pointer; 
  font-weight: 600; 
  transition: all 0.2s;
  width: 100%;
  font-size: 1rem;
}

.add-cart-btn:hover {
  background: #1d4ed8; 
  transform: translateY(-1px);
}

.add-cart-btn:active { 
  transform: translateY(0); 
}

.add-cart-btn.sold-out {
  background: #a3bffa; /* Lighter blue */
  color: #fff;
  cursor: not-allowed;
  font-size: 0.9rem;
  font-weight: 500;
}

.add-cart-btn.sold-out:hover {
  background: #a3bffa;
  transform: none;
}

.add-cart-btn.sold-out:active {
  background: #a3bffa;
  transform: none;
}

/* Disabled state for buttons when store is closed */
.store-closed .add-cart-btn:not(.sold-out) {
  background: #9ca3af !important;
  color: #6b7280 !important;
  cursor: not-allowed !important;
}

.store-closed .add-cart-btn:not(.sold-out):hover {
  background: #9ca3af !important;
  transform: none !important;
}

.store-closed .add-cart-btn:not(.sold-out):active {
  background: #9ca3af !important;
  transform: none !important;
}

.cart-sidebar {
  flex: 1 1 300px; 
  background: var(--card); 
  border-radius: var(--radius); 
  box-shadow: var(--shadow); 
  border: 1px solid var(--border);
  padding: 1.5rem; 
  height: fit-content;
  position: sticky;
  top: 2rem;
}

.cart-title { 
  font-weight: 600; 
  margin-bottom: 1rem; 
  font-size: 1.1rem;
}

.cart-items { 
  list-style: none; 
  padding: 0; 
  margin: 0 0 1rem 0;
}

.cart-item { 
  display: flex; 
  align-items: center; 
  gap: 0.5rem; 
  padding: 0.75rem 0; 
  border-bottom: 1px solid var(--border);
}

.cart-item-name { 
  flex: 1; 
  font-weight: 500;
}

.cart-item-options {
  font-size: 0.8rem;
  color: #666;
  margin-top: 0.25rem;
  font-style: italic;
}

.cart-item-qty { 
  color: #666; 
  min-width: 40px;
}

.cart-item-price {
  font-weight: 600; 
  min-width: 60px;
  text-align: right;
}

.cart-item-remove { 
  background: none; 
  border: none; 
  color: var(--error); 
  cursor: pointer; 
  font-size: 1.2rem; 
  padding: 0.25rem; 
  border-radius: 4px;
  transition: background 0.2s;
}

.cart-item-remove:hover {
  background: rgba(220, 38, 38, 0.1);
}

.cart-summary { 
  border-top: 1px solid var(--border); 
  padding-top: 1rem; 
  margin-bottom: 1.5rem;
}

.cart-total { 
  font-weight: 600; 
  font-size: 1.1rem;
}

.form-section { 
  border-top: 1px solid var(--border); 
  padding-top: 1.5rem;
}

.form-title { 
  font-weight: 600; 
  margin-bottom: 1rem;
}

.form-group { 
  margin-bottom: 1rem;
}

.form-label { 
  display: block; 
  margin-bottom: 0.5rem; 
  font-weight: 500;
}

.form-input {
  width: 100%; 
  padding: 0.75rem; 
  border: 1px solid var(--border); 
  border-radius: 6px; 
  font-size: 1rem;
}

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

.form-error { 
  color: var(--error); 
  font-size: 0.9rem; 
  margin-top: 0.25rem;
}

.checkout-btn {
  width: 100%; 
  background: var(--success); 
  color: white; 
  border: none; 
  padding: 1rem; 
  border-radius: var(--radius); 
  font-weight: 600; 
  cursor: pointer; 
  font-size: 1rem;
  transition: all 0.2s;
}

.checkout-btn:hover {
  background: #047857;
}

.checkout-btn:active { 
  transform: scale(0.98); 
}

.loading { 
  opacity: 0.7; 
  pointer-events: none;
}

.mobile-footer {
  display: none; 
  position: fixed; 
  bottom: 0; 
  left: 0; 
  right: 0; 
  background: var(--card); 
  border-top: 1px solid var(--border); 
  padding: 1rem; 
  z-index: 100;
}

.mobile-cart-summary {
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  margin-bottom: 1rem;
}

.mobile-cart-total {
  font-weight: 600;
}

.mobile-cart-count {
  color: #666;
}

.mobile-checkout-btn {
  width: 100%; 
  background: var(--success); 
  color: white; 
  border: none; 
  padding: 1rem; 
  border-radius: var(--radius); 
  font-weight: 600; 
  cursor: pointer;
  transition: all 0.2s;
}

.mobile-checkout-btn:hover {
  background: #047857;
}

.mobile-checkout-btn:active { 
  transform: scale(0.98); 
}

.mobile-checkout-btn:disabled {
  background: #ccc; 
  cursor: not-allowed;
}

/* Option Modal Styles */
.option-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
}

.option-modal-content {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

.option-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 1.5rem 0 1.5rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
}

.option-modal-header h3 {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 1.5rem;
}

.option-modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #666;
  padding: 0.25rem;
  border-radius: 4px;
  transition: background 0.2s;
}

.option-modal-close:hover {
  background: var(--bg);
}

.option-modal-body {
  padding: 1.5rem;
}

.product-info {
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.product-info p {
  margin: 0.5rem 0;
  color: #666;
}

.base-price {
  font-weight: 600;
  color: var(--primary) !important;
}

.option-group {
  margin-bottom: 1.5rem;
}

.option-label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: #333;
}

.option-choices {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.option-choice {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.option-choice:hover {
  background: var(--bg);
  border-color: var(--primary);
}

.option-choice input[type="radio"],
.option-choice input[type="checkbox"] {
  margin: 0;
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
}

.choice-text {
  flex: 1;
  font-weight: 500;
}

.option-modal-footer {
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
  margin-top: 1.5rem;
}

.total-price {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 1rem;
  text-align: center;
}

.add-to-cart-btn {
  width: 100%;
  background: var(--primary);
  color: white;
  border: none;
  padding: 1rem;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  font-size: 1rem;
  transition: all 0.2s;
}

.add-to-cart-btn:hover {
  background: #1d4ed8;
}

.add-to-cart-btn:active {
  transform: scale(0.98);
}

@media (max-width: 900px) {
  .container { 
    flex-direction: column; 
    align-items: stretch;
  }
  
  .cart-sidebar { 
    position: static; 
  }
  
  .mobile-footer { 
    display: block; 
  }
  
  body { 
    padding-bottom: 120px; 
  }
}

@media (max-width: 600px) {
  .products { 
    grid-template-columns: 1fr; 
  }
  
  .cart-sidebar { 
    margin: 0 1rem; 
  }
  
  .option-modal {
    padding: 0.5rem;
  }
  
  .option-modal-content {
    max-height: 95vh;
  }
  
  .option-modal-header,
  .option-modal-body {
    padding: 1rem;
  }
} 