@import url("https://fonts.googleapis.com/css2?family=Cinzel:wght@600&family=Manrope:wght@400;600;700&display=swap");

:root {
  --bg: #071b15;
  --panel: #103126;
  --panel-border: #2a5440;
  --text: #e6cb8e;
  --muted: #bea367;
  --accent: #c9a24c;
  --accent-2: #9e7428;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 10% -20%, rgba(201, 162, 76, 0.2) 0%, transparent 45%),
    linear-gradient(180deg, #0b2a21 0%, var(--bg) 100%);
}

.wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px;
}

.hero {
  border: 1px solid var(--panel-border);
  border-radius: 16px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #143a2d 0%, #0a231c 100%);
}

h1, h2 {
  margin: 0;
  font-family: "Cinzel", serif;
}

.hero p {
  margin: 8px 0 0;
  color: var(--muted);
}

.hero-actions {
  margin-top: 12px;
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}

.filters {
  margin-top: 10px;
  display: grid;
  gap: 8px;
  grid-template-columns: 2fr 1fr 1fr 2fr auto;
}

#selected-line {
  color: var(--muted);
  font-weight: 700;
}

input[type="text"],
input[type="number"] {
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: #102d22;
  color: var(--text);
  padding: 8px 10px;
}

input[type="range"] {
  accent-color: var(--accent);
}

.hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.lang-switch {
  display: flex;
  gap: 6px;
}

.lang-btn {
  border: 1px solid #705b31;
  border-radius: 8px;
  padding: 6px 10px;
  background: #2f2919;
  color: #e7c97e;
  font-weight: 700;
  cursor: pointer;
}

.lang-btn.active {
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-2) 100%);
  color: #1e180b;
  box-shadow: 0 0 0 1px rgba(255, 222, 145, 0.4) inset;
}

.panel {
  margin-top: 12px;
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  padding: 12px;
  background: linear-gradient(180deg, #103528 0%, #0d2a20 100%);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.chip,
.tile-btn {
  border: 1px solid #705b31;
  background: #2f2919;
  color: #e7c97e;
  border-radius: 999px;
  padding: 8px 12px;
  cursor: pointer;
}

.chip.active {
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-2) 100%);
  color: #1e180b;
  border-color: #d0b16b;
  box-shadow: 0 0 0 1px rgba(255, 226, 150, 0.35) inset;
}

.tile-list {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}

.tile-btn {
  border-radius: 12px;
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-height: 118px;
}

.tile-btn img {
  width: 100%;
  height: 84px;
  object-fit: cover;
  border-bottom: 1px solid rgba(201, 162, 76, 0.35);
}

.tile-btn span {
  padding: 8px 10px;
  font-weight: 700;
  text-align: left;
}

.tile-btn.active {
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-2) 100%);
  color: #1e180b;
  border-color: #d0b16b;
  box-shadow: 0 0 0 1px rgba(255, 226, 150, 0.35) inset;
}

.grid {
  margin-top: 10px;
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.card {
  border: 1px solid #356a56;
  border-radius: 12px;
  padding: 10px;
  background: #153c31;
  display: flex;
  flex-direction: column;
  min-height: 264px;
}

.thumb {
  width: 100%;
  height: 176px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(201, 162, 76, 0.35);
  background: #0c2a20;
}

.title {
  margin: 8px 0 6px;
  font-weight: 700;
  min-height: 48px;
}

.row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.cta-row {
  justify-content: flex-end;
  gap: 8px;
}

.qty-control {
  justify-content: flex-end;
  gap: 6px;
}

.controls-inline {
  justify-content: flex-start;
  gap: 8px;
  margin-top: 8px;
}

.price {
  font-weight: 700;
}

.btn {
  border: 0;
  border-radius: 8px;
  text-decoration: none;
  padding: 9px 11px;
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-2) 100%);
  color: #20190b;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.12s ease, filter 0.12s ease, box-shadow 0.12s ease;
}

.btn:hover {
  filter: brightness(1.05);
  box-shadow: 0 4px 14px rgba(201, 162, 76, 0.25);
}

.btn:active {
  transform: translateY(1px);
}

.btn:focus-visible {
  outline: 2px solid #f2ce83;
  outline-offset: 2px;
}

.btn-muted {
  background: #2a4a3c;
  color: var(--text);
  border: 1px solid #3a715a;
}

.cart-panel {
  border-color: #4e8a6f;
  background: linear-gradient(180deg, #134434 0%, #0e3227 100%);
}

.cart-panel #selected-list .card {
  border-color: #5c987c;
  background: linear-gradient(180deg, #1a4a3a 0%, #143b2f 100%);
}

.cart-panel .title {
  color: #f0d697;
}

.cart-panel .price {
  color: #e9c978;
}

.helper-text {
  color: var(--muted);
  margin: 8px 0 0;
  font-size: 13px;
}

.empty-state {
  border: 1px dashed var(--panel-border);
  border-radius: 10px;
  padding: 14px;
  text-align: center;
  color: var(--muted);
}

.skeleton {
  position: relative;
  overflow: hidden;
}

.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
  animation: shimmer 1.2s infinite;
}

.skeleton .thumb {
  background: #1a4b3b;
}

.skeleton .title,
.skeleton .price {
  color: transparent;
  background: #1d4d3e;
  border-radius: 6px;
}

.sticky-summary {
  position: sticky;
  bottom: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  padding: 10px 14px;
  border-top: 1px solid #4a7f67;
  background: linear-gradient(180deg, rgba(13, 47, 36, 0.94), rgba(8, 30, 23, 0.98));
  backdrop-filter: blur(6px);
}

dialog {
  width: min(92vw, 520px);
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  background: #12362b;
  color: var(--text);
  padding: 14px;
}

dialog::backdrop {
  background: rgba(0, 0, 0, 0.45);
}

#web-order-form {
  display: grid;
  gap: 10px;
}

@keyframes shimmer {
  to {
    transform: translateX(100%);
  }
}

@media (max-width: 700px) {
  .hero-top {
    flex-direction: column;
    align-items: flex-start;
  }
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .filters {
    grid-template-columns: 1fr 1fr;
  }
  .tile-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .thumb {
    height: 150px;
  }
  .title {
    min-height: 40px;
  }
}
