:root {
  --green-950: #001a16;
  --green-900: #002822;
  --green-800: #073f35;
  --green-700: #0d5b4b;
  --gold-600: #c9952e;
  --gold-300: #f4d27b;
  --cream: #fff8e8;
  --muted: #d7c8a8;
  --ink: #1d1608;
  --line: rgba(244, 210, 123, .28);
  --panel: rgba(5, 49, 42, .88);
  --panel-solid: #062f29;
  --danger: #ff8d8d;
  --shadow: 0 24px 70px rgba(0, 0, 0, .32);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: Tahoma, Arial, sans-serif;
  color: var(--cream);
  background:
    linear-gradient(180deg, rgba(0, 15, 13, .2), rgba(0, 15, 13, .86)),
    linear-gradient(135deg, #001814 0%, #073f35 48%, #00130f 100%);
}

a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .55; }
img { display: block; max-width: 100%; }
.container { width: min(1180px, calc(100% - 32px)); margin-inline: auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(0, 26, 22, .92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.nav-shell {
  min-height: 82px;
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand { margin-inline-end: auto; }
.brand img { width: 178px; height: 66px; object-fit: contain; }
.main-nav { display: flex; align-items: center; gap: 6px; }
.main-nav a {
  padding: 12px 14px;
  border-radius: 8px;
  color: #f8ecd3;
  font-weight: 800;
}
.main-nav a:hover,
.main-nav a.active {
  color: var(--ink);
  background: linear-gradient(135deg, var(--gold-600), var(--gold-300));
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--cream);
  background: rgba(255, 255, 255, .05);
}

.cart-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  color: var(--cream);
  background: rgba(255, 255, 255, .05);
  font-weight: 900;
}
.cart-chip b {
  min-width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--ink);
  background: var(--gold-300);
}

.app-shell { min-height: 62vh; outline: 0; }
.hero-section { padding: 58px 0 30px; }
.hero-grid {
  display: grid;
  grid-template-columns: 1fr .86fr;
  gap: 34px;
  align-items: center;
}
.hero-copy h1 {
  margin: 0 0 14px;
  font-size: clamp(3rem, 8vw, 6rem);
  line-height: 1.02;
  letter-spacing: 0;
  color: #fff7dc;
}
.hero-copy p {
  margin: 0;
  max-width: 680px;
  color: #f0e2c7;
  font-size: 1.2rem;
  line-height: 1.9;
}
.eyebrow,
.page-title span,
.section-heading span {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 12px;
  padding: 8px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--gold-300);
  font-weight: 900;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.hero-image {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
  box-shadow: var(--shadow);
}
.hero-image img { width: min(560px, 100%); margin-inline: auto; }

.gold-btn,
.ghost-btn,
.danger-btn {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  padding: 11px 18px;
  border: 0;
  font-weight: 900;
}
.gold-btn {
  color: var(--ink);
  background: linear-gradient(135deg, var(--gold-600), var(--gold-300));
  box-shadow: 0 16px 32px rgba(201, 149, 46, .18);
}
.ghost-btn {
  color: var(--gold-300);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .04);
}
.danger-btn {
  color: #2a0606;
  background: var(--danger);
  min-height: 36px;
  padding: 7px 12px;
}
.full { width: 100%; }

.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 12px;
}
.stats-row div,
.admin-stats div,
.summary-card,
.table-card,
.empty-panel,
.checkout-form,
.detail-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .18);
}
.stats-row div,
.admin-stats div {
  padding: 20px;
  display: grid;
  gap: 6px;
}
.stats-row strong,
.admin-stats strong {
  color: var(--gold-300);
  font-size: 2rem;
}
.stats-row span,
.admin-stats span { color: var(--muted); font-weight: 800; }

.page-section { padding: 42px 0; }
.page-title { margin-bottom: 24px; }
.page-title h1,
.section-heading h2 {
  margin: 0;
  color: #fff5d4;
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.16;
  letter-spacing: 0;
}
.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}
.section-heading a { color: var(--gold-300); font-weight: 900; }

.filters {
  display: grid;
  grid-template-columns: 1.4fr .8fr .8fr;
  gap: 12px;
  margin-bottom: 18px;
}
.filters label,
.checkout-form label {
  display: grid;
  gap: 8px;
  color: var(--gold-300);
  font-weight: 900;
}
.filters input,
.filters select,
.checkout-form input,
.checkout-form select {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  padding: 0 14px;
  color: var(--cream);
  background: rgba(255, 255, 255, .07);
  outline: 0;
}
.filters option,
.checkout-form option {
  color: #111;
}

.event-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.event-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 16px 42px rgba(0, 0, 0, .2);
}
.event-media {
  position: relative;
  min-height: 204px;
  background: var(--green-800);
  overflow: hidden;
}
.event-media img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  transition: transform .2s ease;
}
.event-card:hover .event-media img { transform: scale(1.03); }
.event-media span {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--gold-300);
  background: rgba(0, 0, 0, .48);
  border: 1px solid var(--line);
  font-weight: 900;
}
.event-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px;
}
.event-content small { color: var(--gold-300); font-weight: 900; }
.event-content h3 { margin: 0; font-size: 1.35rem; color: #fff8e6; }
.event-content p { margin: 0; color: #eadcc2; line-height: 1.7; }
.event-meta {
  display: grid;
  gap: 6px;
  color: var(--muted);
  line-height: 1.5;
  font-size: .94rem;
}
.event-actions {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.event-actions strong { color: var(--gold-300); font-size: 1.2rem; white-space: nowrap; }

.detail-layout {
  padding: 46px 0;
  display: grid;
  grid-template-columns: .9fr 1fr;
  gap: 22px;
  align-items: start;
}
.detail-media {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--green-800);
  box-shadow: var(--shadow);
}
.detail-media img { width: 100%; min-height: 420px; object-fit: cover; }
.detail-card { padding: 26px; }
.detail-card h1 { margin: 0 0 14px; color: #fff5d4; font-size: clamp(2rem, 4vw, 3.6rem); }
.detail-card p { color: #f0e2c7; line-height: 1.9; font-size: 1.08rem; }
.detail-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 22px 0;
}
.detail-list div {
  padding: 13px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 8px;
  background: rgba(255, 255, 255, .04);
}
.detail-list dt { color: var(--muted); font-size: .9rem; }
.detail-list dd { margin: 6px 0 0; color: var(--gold-300); font-weight: 900; }
.detail-buy { margin-top: 18px; }

.cart-layout,
.checkout-layout,
.admin-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 18px;
  align-items: start;
}
.cart-list { display: grid; gap: 12px; }
.cart-row {
  display: grid;
  grid-template-columns: 112px 1fr auto;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}
.cart-row img {
  width: 112px;
  height: 86px;
  object-fit: cover;
  border-radius: 8px;
  background: var(--green-800);
}
.cart-row h3 { margin: 0 0 5px; }
.cart-row p { margin: 0 0 8px; color: var(--muted); }
.cart-row strong { color: var(--gold-300); }
.qty-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: end;
}
.qty-tools button:not(.danger-btn) {
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--cream);
  background: rgba(255, 255, 255, .05);
}
.qty-tools span { min-width: 24px; text-align: center; font-weight: 900; }

.summary-card {
  padding: 20px;
  display: grid;
  gap: 15px;
}
.summary-card h2,
.table-card h2 { margin: 0; color: var(--gold-300); }
.summary-card div,
.checkout-summary div,
.total-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
}
.summary-card strong,
.checkout-summary strong,
.total-line strong { color: var(--gold-300); }
.total-line {
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 1.12rem;
  font-weight: 900;
}

.checkout-form {
  padding: 24px;
  display: grid;
  gap: 16px;
}
.checkout-form small { color: var(--muted); line-height: 1.7; }

.admin-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 18px;
}
.admin-grid { grid-template-columns: 1fr 1fr; }
.table-card { padding: 18px; min-width: 0; }
.table-wrap { overflow-x: auto; margin-top: 14px; }
table { width: 100%; border-collapse: collapse; min-width: 520px; }
th, td {
  padding: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
  text-align: right;
  color: #f6ead2;
}
th { color: var(--gold-300); font-size: .92rem; }

.empty-panel,
.success-panel {
  padding: 34px;
  text-align: center;
}
.empty-panel h1,
.empty-panel h2 { margin: 0 0 10px; color: var(--gold-300); }
.empty-panel p { margin: 0 0 18px; color: var(--muted); }
.success-panel {
  width: min(620px, calc(100% - 32px));
  margin: 46px auto;
  display: grid;
  justify-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}
.success-panel img { width: 210px; height: 82px; object-fit: contain; }
.success-panel span { color: var(--gold-300); font-weight: 900; }
.success-panel h1 { margin: 0; color: #fff5d4; }
.success-panel p { margin: 0; color: var(--muted); }
.qr-demo {
  width: 118px;
  height: 118px;
  border: 8px solid #fff;
  background: repeating-linear-gradient(45deg, #111 0 8px, #fff 8px 16px);
  box-shadow: 0 0 0 1px var(--gold-600);
}

.site-footer {
  margin-top: 34px;
  padding: 32px 0 18px;
  border-top: 1px solid var(--line);
  background: rgba(0, 18, 15, .78);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 28px;
}
.footer-grid img { width: 190px; height: 74px; object-fit: contain; }
.footer-grid h3 { margin: 0 0 8px; color: var(--gold-300); }
.footer-grid p { margin: 6px 0; color: var(--muted); line-height: 1.7; }
.copyright { margin: 24px 0 0; text-align: center; color: #ad9f82; }

.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 50;
  max-width: min(420px, calc(100% - 40px));
  padding: 14px 18px;
  border-radius: 8px;
  color: var(--ink);
  background: var(--gold-300);
  box-shadow: var(--shadow);
  font-weight: 900;
  opacity: 0;
  transform: translateY(18px);
  transition: .2s ease;
  pointer-events: none;
}
.toast.show { opacity: 1; transform: translateY(0); }

@media (max-width: 980px) {
  .menu-toggle { display: inline-grid; place-items: center; }
  .main-nav {
    display: none;
    position: absolute;
    inset-inline: 16px;
    top: 82px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--green-950);
    box-shadow: var(--shadow);
  }
  .main-nav.open { display: grid; }
  .main-nav a { padding: 13px; }
  .hero-grid,
  .detail-layout,
  .cart-layout,
  .checkout-layout,
  .admin-grid { grid-template-columns: 1fr; }
  .event-grid { grid-template-columns: repeat(2, 1fr); }
  .admin-stats { grid-template-columns: repeat(2, 1fr); }
  .filters { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .container { width: min(100% - 22px, 1180px); }
  .nav-shell { min-height: 72px; gap: 10px; }
  .brand img { width: 132px; height: 54px; }
  .cart-chip span { display: none; }
  .hero-section { padding-top: 34px; }
  .hero-copy h1 { font-size: 3.4rem; }
  .stats-row,
  .event-grid,
  .filters,
  .admin-stats,
  .footer-grid,
  .detail-list { grid-template-columns: 1fr; }
  .section-heading { align-items: start; flex-direction: column; }
  .cart-row { grid-template-columns: 1fr; }
  .cart-row img { width: 100%; height: 160px; }
  .qty-tools { justify-content: start; }
  .detail-media img { min-height: 260px; }
}
