:root {
  color-scheme: dark;
  --bg: #090d13;
  --panel: #111821;
  --line: #26303c;
  --muted: #8997a7;
  --red: #e53935;
  --text: #f0f3f6;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font:
    14px "DM Sans",
    sans-serif;
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  border: 1px solid var(--line);
  background: #1b2532;
  color: var(--text);
  border-radius: 7px;
  padding: 10px 15px;
  font-weight: 600;
  transition:
    background 0.15s,
    transform 0.15s;
}
button:hover {
  background: #2a3545;
}
button:active {
  transform: translateY(1px);
}
button:disabled {
  opacity: 0.45;
  cursor: wait;
}
button:focus-visible,
a:focus-visible {
  outline: 2px solid #ff7773;
  outline-offset: 4px;
}
.primary {
  background: var(--red);
  border-color: var(--red);
}
.primary:hover {
  background: #c82c29;
}
.danger {
  color: #fb8a87;
  background: #351c22;
  border-color: #643039;
}
.small {
  padding: 7px 11px;
  font-size: 12px;
}
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 22px 4%;
  background: #101620;
  border-bottom: 1px solid var(--line);
  gap: 15px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: inherit;
}
.mark {
  display: grid;
  place-content: center;
  width: 51px;
  height: 52px;
  background: var(--red);
  font: 800 italic 43px "Barlow Condensed";
  position: relative;
  overflow: hidden;
  border-radius: 6px;
}
.mark span {
  position: absolute;
  right: 1px;
  color: #101620;
  font-size: 62px;
  top: -12px;
}
.brand strong {
  font: 800 30px "Barlow Condensed";
  letter-spacing: 2px;
}
.brand small {
  font: 600 10px "DM Sans";
  letter-spacing: 1px;
  color: #ff8682;
  border: 1px solid #643039;
  padding: 4px 7px;
  vertical-align: middle;
  margin-left: 7px;
}
.brand p {
  font-size: 10px;
  letter-spacing: 2px;
  margin: 2px 0;
  color: #c8d0d8;
}
.brand p span {
  color: var(--muted);
}
.header-right {
  display: flex;
  align-items: center;
  gap: 22px;
}
.status {
  font-size: 12px;
  color: #b8c5d1;
}
.status i,
.live i {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4bd7a0;
  margin-right: 7px;
}
nav {
  display: flex;
  gap: 5px;
  overflow-x: auto;
  padding: 12px 4%;
  background: #101620;
  border-bottom: 1px solid var(--line);
}
nav button {
  white-space: nowrap;
  background: transparent;
  border-color: transparent;
  font-size: 12px;
  color: #9ca9b9;
  padding: 12px 17px;
}
nav button.active {
  background: #de3432;
  color: white;
}
nav button span {
  opacity: 0.6;
  margin-right: 9px;
}
main {
  max-width: 1460px;
  margin: auto;
  padding: 32px 4% 65px;
  min-height: 77vh;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font: 700 38px "Barlow Condensed";
  letter-spacing: 0.3px;
  margin-bottom: 6px;
}
h2 {
  font-size: 16px;
  margin-bottom: 7px;
}
h3 {
  font-size: 16px;
}
p {
  color: var(--muted);
  line-height: 1.6;
  font-size: 12px;
}
.eyebrow {
  font-size: 10px;
  color: var(--red);
  font-weight: 700;
  letter-spacing: 2px;
  margin-bottom: 9px;
}
.title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
}
.title-row p {
  margin-bottom: 0;
}
.live {
  font-size: 10px;
  letter-spacing: 1px;
  border: 1px solid var(--line);
  padding: 9px 12px;
  border-radius: 5px;
}
.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 25px;
}
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 24px;
}
.kpi {
  position: relative;
  overflow: hidden;
}
.kpi label {
  font-size: 10px;
  letter-spacing: 1.2px;
  color: #9caabb;
  text-transform: uppercase;
}
.kpi strong {
  font: 700 40px "Barlow Condensed";
  display: block;
  margin: 12px 0;
}
.kpi strong small {
  font: 12px "DM Sans";
  color: var(--muted);
}
.kpi p {
  margin: 0;
  font-size: 11px;
}
.kpi .corner {
  position: absolute;
  right: 19px;
  top: 22px;
  font-size: 21px;
  color: #617080;
}
.green {
  color: #5cdbac;
}
.amber {
  color: #efb85d;
}
.progress {
  height: 4px;
  background: #26303c;
  margin-top: 17px;
  border-radius: 5px;
  overflow: hidden;
}
.progress span {
  display: block;
  height: 100%;
  background: var(--red);
}
.split {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 22px;
}
.panel-top {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 12px;
  margin-bottom: 20px;
}
.panel-top p {
  margin-bottom: 0;
}
.table-wrap {
  overflow: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  text-align: left;
  white-space: nowrap;
}
th {
  text-transform: uppercase;
  font-size: 9px;
  letter-spacing: 1px;
  color: #8e9daf;
  background: #0d131b;
  padding: 14px 12px;
  font-weight: 600;
}
td {
  padding: 17px 12px;
  border-bottom: 1px solid #222d39;
  font-size: 12px;
}
td p {
  margin: 3px 0 0;
  font-size: 10px;
}
.avatar {
  display: inline-grid;
  place-items: center;
  width: 33px;
  height: 33px;
  background: #352127;
  color: #fa8c87;
  border: 1px solid #5b3036;
  border-radius: 9px;
  margin-right: 9px;
  font-size: 11px;
}
.badge {
  display: inline-block;
  color: #59d8a6;
  background: #14352d;
  border: 1px solid #255043;
  padding: 4px 8px;
  border-radius: 5px;
  font-size: 10px;
}
.badge.expired {
  color: #ff9692;
  background: #3b2228;
  border-color: #653339;
}
.feed-item {
  display: flex;
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid #25303b;
}
.feed-icon {
  width: 29px;
  height: 29px;
  display: grid;
  place-content: center;
  border-radius: 7px;
  background: #16362e;
  color: #69d8b1;
  flex-shrink: 0;
}
.feed-icon.pos {
  color: #eabc72;
  background: #382f21;
}
.feed-item p {
  margin: 0;
  color: #c4cfda;
  font-size: 11px;
}
.feed-item time {
  color: #748496;
  font-size: 10px;
  display: block;
  margin-top: 5px;
}
.empty {
  padding: 42px 18px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed #344050;
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.8;
}
.empty strong {
  display: block;
  color: #d6dee6;
  font-size: 15px;
}
.toolbar {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 18px;
}
input,
select {
  background: #0b1119;
  color: var(--text);
  border: 1px solid #344150;
  padding: 12px;
  border-radius: 7px;
  min-width: 0;
  outline: none;
}
input:focus,
select:focus {
  border-color: var(--red);
}
.toolbar input {
  flex: 1;
}
label.field {
  display: block;
  font-size: 11px;
  color: #aebdcd;
  margin: 18px 0 7px;
}
form input,
form select {
  width: 100%;
}
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 24px;
}
.error {
  color: #ff9c98;
  font-size: 12px;
  line-height: 1.6;
}
.notice {
  border-left: 3px solid var(--red);
  padding: 13px 17px;
  background: #21191f;
  color: #c5acb1;
  font-size: 12px;
  line-height: 1.8;
  margin-bottom: 20px;
}
.filters {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.filters .active {
  background: var(--red);
  border-color: var(--red);
}
.products {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  max-height: 550px;
  overflow: auto;
}
.product {
  text-align: left;
  background: #0d141d;
  padding: 17px;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
}
.product strong {
  font-size: 12px;
  line-height: 1.6;
  display: block;
}
.product p {
  font-size: 10px;
  margin: 5px 0;
}
.price {
  color: #fb7771;
  font-weight: 700;
}
.product .plus {
  background: #263241;
  padding: 5px 10px;
  border-radius: 6px;
}
.cart-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding: 13px 0;
  font-size: 12px;
}
.cart-row p {
  margin: 5px 0;
  font-size: 10px;
}
.total {
  display: flex;
  justify-content: space-between;
  font-size: 20px;
  font-weight: 700;
  padding: 24px 0;
  border-top: 1px solid var(--line);
  margin-top: 25px;
}
.checkout select {
  width: 100%;
  margin: 6px 0 10px;
}
.check {
  display: flex;
  align-items: start;
  gap: 10px;
  font-size: 11px;
  color: #bac6d1;
  line-height: 1.6;
  margin: 8px 0 16px;
}
.checkout .primary {
  width: 100%;
}
.poster {
  text-align: center;
  border-top: 4px solid var(--red);
  background:
    repeating-linear-gradient(
      135deg,
      transparent,
      transparent 10px,
      #ffffff02 10px,
      #ffffff02 11px
    ),
    var(--panel);
}
.poster h2 {
  font: 800 38px "Barlow Condensed";
  margin-top: 25px;
}
.poster canvas {
  max-width: 100%;
  border-radius: 10px;
}
.poster .scan-label {
  letter-spacing: 4px;
  font-size: 12px;
  color: #f27670;
}
.qr-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.portal {
  max-width: 430px;
  margin: auto;
}
.result {
  padding: 15px;
  background: #16382f;
  color: #84e5c0;
  margin-top: 20px;
  border-radius: 8px;
  line-height: 1.6;
  font-size: 13px;
}
.program {
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
}
.program h3 {
  font: 700 26px "Barlow Condensed";
  margin: 8px 0;
}
.program-number {
  font: 800 64px "Barlow Condensed";
  color: #3c2930;
  min-width: 75px;
}
.program-info {
  flex: 1;
}
pre {
  overflow: auto;
  background: #0b1119;
  padding: 20px;
  border-radius: 8px;
  line-height: 1.8;
  color: #bacbd9;
  font-size: 12px;
}
dialog {
  background: var(--panel);
  color: var(--text);
  border: 1px solid #3a4653;
  border-radius: 12px;
  max-width: 480px;
  width: calc(100% - 30px);
  padding: 32px;
}
dialog::backdrop {
  background: #03070ccf;
  backdrop-filter: blur(5px);
}
dialog h2 {
  font: 700 30px "Barlow Condensed";
}
.close {
  position: absolute;
  right: 12px;
  top: 10px;
  background: transparent;
  border: 0;
  font-size: 23px;
}
#toast {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  background: #253d34;
  border: 1px solid #5a826e;
  color: #d3f7e4;
  border-radius: 8px;
  padding: 14px 22px;
  max-width: 90vw;
  display: none;
  z-index: 10;
  font-size: 12px;
}
footer {
  display: flex;
  justify-content: space-between;
  padding: 20px 4%;
  border-top: 1px solid var(--line);
  color: #69798d;
  font-size: 9px;
  letter-spacing: 1.6px;
}
.skeleton {
  height: 180px;
  background: linear-gradient(100deg, #111821, #1d2732, #111821);
  border-radius: 10px;
  animation: pulse 1.5s infinite;
}
@keyframes pulse {
  50% {
    opacity: 0.45;
  }
}
@media (max-width: 1000px) {
  .kpis {
    grid-template-columns: 1fr 1fr;
  }
  .split {
    grid-template-columns: 1fr;
  }
  .qr-split {
    grid-template-columns: 1fr;
  }
  .products {
    max-height: 450px;
  }
}
@media (max-width: 600px) {
  header {
    padding: 16px;
  }
  .brand p span,
  .header-right .status {
    display: none;
  }
  .brand strong {
    font-size: 26px;
  }
  .mark {
    width: 42px;
    height: 45px;
  }
  .header-right button {
    font-size: 11px;
    padding: 9px;
  }
  main {
    padding: 24px 16px 45px;
  }
  nav {
    padding: 9px;
  }
  .title-row {
    align-items: start;
  }
  .title-row .live {
    display: none;
  }
  h1 {
    font-size: 31px;
  }
  .card {
    padding: 18px;
  }
  .kpis {
    gap: 10px;
  }
  .kpi label {
    font-size: 9px;
  }
  .kpi strong {
    font-size: 32px;
  }
  .kpi .corner {
    display: none;
  }
  .products {
    grid-template-columns: 1fr;
  }
  .toolbar {
    flex-wrap: wrap;
  }
  .program {
    flex-wrap: wrap;
  }
  .program-number {
    font-size: 45px;
    min-width: 40px;
  }
  footer span:last-child {
    display: none;
  }
  .total {
    font-size: 17px;
  }
}
@media print {
  header,
  nav,
  footer,
  #heading,
  .portal,
  #toast,
  .poster button {
    display: none !important;
  }
  .qr-split {
    display: block;
  }
  .poster {
    background: white;
    color: #111;
    border: 2px solid #111;
  }
  .poster p {
    color: #333;
  }
  .poster canvas {
    width: 300px;
    height: 300px;
  }
}

.member-access-card {
  max-width: 540px;
  margin: 0 auto;
}
