/* shop.css */

/* Reset and base */
* {
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: #f7f9fc;
  margin: 0;
  padding: 0;
  color: #333;
}

/* Navbar */
.navbar {
  background-color: #2a2a72;
  display: flex;
  align-items: center;
  padding: 1rem 2rem;
  color: white;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.navbar .logo img {
  height: 40px;
}

.navbar nav {
  margin-left: auto;
  display: flex;
  gap: 1.5rem;
}

.navbar nav a {
  color: white;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.navbar nav a:hover {
  color: #f1c40f;
}

/* Search Bar */

/* .search container{

} */
.search {
  max-width: 500px;
  margin: 2rem auto 1rem;
  padding: 0 1rem;
}

.search input[type="search"] {
  width: 100%;
  padding: 0.7rem 1rem;
  font-size: 1rem;
  border-radius: 25px;
  border: 1.8px solid #b8b8b8;
  transition: border-color 0.3s ease;
}

.search input[type="search"]:focus {
  border-color: #2a2a72;
  outline: none;
}

/* Shop Main Container */
.shop-main {
  max-width: 1100px;
  margin: 0 auto 3rem;
  padding: 0 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
}

/* Each Section inside shop-main */
.shop-main .section {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
}

/* Product Card */
.card {
  background-color: white;
  border-radius: 12px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.15);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: default;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}

.card img.get-shop {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
}

.card-content {
  padding: 1rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.card-content h3 {
  margin: 0 0 0.5rem 0;
  font-weight: 700;
  font-size: 1.25rem;
  color: #2a2a72;
}

.card-content p {
  flex-grow: 1;
  font-size: 0.95rem;
  color: #555;
  margin-bottom: 1rem;
}

.card-content button {
  align-self: stretch;
  padding: 0.7rem 0;
  background-color: #2a2a72;
  border: none;
  color: white;
  font-weight: 700;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.3s ease;
  user-select: none;
}

.card-content button:hover {
  background-color: #3f3f91;
}

/* Breaker Section (Offers, Banners) */
.breaker {
  width: 100%;
  background: #f1c40f;
  color: #1b1b1b;
  font-weight: 700;
  font-size: 1.6rem;
  padding: 3rem 1rem;
  text-align: center;
  border-radius: 12px;
  margin: 2rem 0;
  
}

/* Theme variables (tweak to match brand) */
:root {
  --brand: #e3350d;           /* Pokémon red */
  --brand-dark: #c22b0b;
  --text: #222;
  --muted: #666;
  --bg-card: #fff;
  --bg-soft: #f7f7f8;
  --ring: rgba(227, 53, 13, 0.25);
  --radius: 12px;
  --shadow: 0 6px 18px rgba(0,0,0,0.08);
  --gap: 16px;
  --gap-lg: 24px;
}

/* Global helpers */
.container {
  width: min(1200px, 100%);
  margin-inline: auto;
  padding-inline: 16px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: 10px;
  padding: 10px 16px;
  font-weight: 600;
  cursor: pointer;
  transition: transform .1s ease, box-shadow .2s ease, background .2s ease;
}
.btn.primary {
  background: var(--brand);
  color: #fff;
}
.btn.primary:hover { background: var(--brand-dark); transform: translateY(-1px); }
.btn.secondary {
  background: #f1f1f1;
  color: var(--text);
}
.btn:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
}

/* SHOP: responsive grid */
.shop-main {
  width: min(1200px, 100%);
  margin: 20px auto 40px;
  padding-inline: 16px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); /* responsive without MQs */
  gap: var(--gap-lg);
}

.product-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .12s ease, box-shadow .2s ease;
}
.product-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0,0,0,0.1);
  background-color: aquamarine;
}

.product-image-wrap {
  aspect-ratio: 4/3; /* keeps image area consistent */
  background: var(--bg-soft);
  display: grid;
  place-items: center;
}
.product-image-wrap img {
  width: 85%;
  height: 85%;
  object-fit: contain;
}

.product-info {
  display: grid;
  gap: 8px;
  padding: 12px;
}
.product-title { margin: 0; color: var(--text); font-size: 1.05rem; }
.product-desc { margin: 0; color: var(--muted); font-size: .9rem; min-height: 38px; }
.price-row {
  margin-top: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.price { font-weight: 700; color: var(--text); }

/* PURCHASE: layout and components */
.purchase-container {
  width: min(1100px, 100%);
  margin: 24px auto;
  padding-inline: 16px;
  display: flex;
  grid-template-columns: 1.2fr .9fr; /* summary | form */
  gap: var(--gap-lg);
}
.purchase-container.single-col { grid-template-columns: 1fr; }

.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px;
}

.product-summary {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: var(--gap);
  align-items: start;
}
.product-summary img {
  width: 100%;
  height: auto;
  object-fit: contain;
  background: var(--bg-soft);
  border-radius: 10px;
}

.price-row, .totals div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 6px 0;
}
.totals {
  margin-top: 12px;
  border-top: 1px solid #eee;
  padding-top: 10px;
}
.totals div:last-child strong {
  color: var(--brand);
  font-size: 1.1rem;
}

.qty-row {
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.qty-row input[type="number"] {
  width: 98px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid #ccc;
}
.qty-row input[type="number"]:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--ring);
  outline: none;
}

.customer-info h2 { margin-top: 0; }
.customer-info form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap);
}
.customer-info form input,
.customer-info form textarea,
.customer-info form select {
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #ccc;
  width: 100%;
  font: inherit;
}
.customer-info form textarea { grid-column: 1 / -1; min-height: 96px; resize: vertical; }
.customer-info form input:focus,
.customer-info form textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--ring);
  outline: none;
}

.actions { display: flex; gap: 12px; margin-top: 12px; }

/* Sticky order summary on larger screens */
@media (min-width: 1000px) {
  .purchase-container > .card:first-child {
    position: sticky;
    top: 90px; /* below navbar */
    height: fit-content;
  }
}

/* Breakpoints for better stacking */
@media (max-width: 1000px) {
  .purchase-container { grid-template-columns: 1fr; }
  .product-summary { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .product-grid { gap: 16px; }
  .product-card { border-radius: 10px; }
  .customer-info form { grid-template-columns: 1fr; }
  .qty-row input[type="number"] { width: 86px; }
  .btn { padding: 10px 14px; }
}
