:root {
  color-scheme: dark;
  --ink: #f7e7bd;
  --text: #f8f3e8;
  --muted: #b9ab90;
  --line: rgba(218, 174, 88, .34);
  --line-strong: rgba(241, 201, 118, .72);
  --paper: #070706;
  --panel: rgba(12, 13, 14, .86);
  --panel-solid: #10100e;
  --gold: #e9bf69;
  --gold-soft: #b98533;
  --gold-deep: #6b4619;
  --jade: #8fd5ae;
  --red: #8b1f19;
  --shadow: 0 24px 70px rgba(0, 0, 0, .45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(180deg, rgba(233, 191, 105, .05), transparent 360px),
    radial-gradient(circle at 50% -20%, rgba(170, 113, 34, .16), transparent 520px),
    var(--paper);
  color: var(--text);
  font-family: "Microsoft JhengHei", "Noto Sans TC", system-ui, sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 74px;
  padding: 12px clamp(18px, 4vw, 56px);
  border-bottom: 1px solid var(--line);
  background: rgba(5, 5, 5, .9);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 248px;
}

.brand-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background:
    linear-gradient(145deg, rgba(233, 191, 105, .18), rgba(0, 0, 0, .35)),
    #111;
  color: var(--gold);
  font-weight: 900;
  box-shadow: inset 0 0 22px rgba(233, 191, 105, .14), 0 10px 28px rgba(0, 0, 0, .35);
}

.brand strong,
.brand small {
  display: block;
  line-height: 1.12;
}

.brand strong {
  color: #fff3cf;
}

.brand small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.nav {
  display: flex;
  gap: 8px;
  color: var(--muted);
}

.nav a {
  min-width: 64px;
  padding: 10px 12px;
  border-radius: 8px;
  text-align: center;
}

.nav a:hover {
  background: rgba(233, 191, 105, .1);
  color: var(--ink);
}

.header-action,
.primary-action,
.secondary-action,
.submit-btn,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  font-weight: 900;
  white-space: nowrap;
}

.header-action,
.primary-action,
.submit-btn {
  border: 1px solid rgba(250, 222, 150, .6);
  background:
    linear-gradient(180deg, #f6d991, #ae792b 52%, #6b3f12);
  color: #140e05;
  box-shadow: 0 12px 26px rgba(185, 133, 51, .24);
}

.secondary-action,
.secondary-button {
  border: 1px solid var(--line);
  background: rgba(10, 10, 10, .72);
  color: var(--ink);
}

.hero {
  position: relative;
  min-height: calc(100vh - 74px);
  display: grid;
  align-content: end;
  padding: clamp(76px, 10vw, 128px) clamp(18px, 5vw, 72px) clamp(42px, 6vw, 78px);
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .92) 0%, rgba(0, 0, 0, .72) 38%, rgba(0, 0, 0, .32) 64%, rgba(0, 0, 0, .2) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, .18), rgba(0, 0, 0, .84)),
    url("assets/dragon-premium-hero.png") center / cover no-repeat;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 42%;
  background: linear-gradient(180deg, transparent, rgba(7, 7, 6, .94));
  pointer-events: none;
}

.hero-copy,
.hero-board {
  position: relative;
  z-index: 1;
}

.hero-copy {
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.12;
}

h1 {
  max-width: 860px;
  color: #fff2c9;
  font-family: "DFKai-SB", "KaiTi", "Microsoft JhengHei", serif;
  font-size: clamp(54px, 9vw, 112px);
  font-weight: 900;
  text-shadow: 0 4px 0 rgba(76, 43, 8, .55), 0 0 34px rgba(233, 191, 105, .28);
}

h2 {
  color: #fff2c9;
  font-size: clamp(28px, 4vw, 46px);
}

h3 {
  color: #fff4d2;
}

.hero-subtitle {
  width: fit-content;
  margin: 12px 0 0;
  padding: 8px 18px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: clamp(18px, 2.5vw, 30px);
  font-weight: 900;
  letter-spacing: .18em;
}

.lead {
  max-width: 660px;
  margin: 22px 0 0;
  color: #d6c6a7;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.75;
}

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

.hero-board {
  display: grid;
  gap: 18px;
  max-width: 1100px;
  margin-top: clamp(34px, 6vw, 70px);
}

.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.trust-grid article,
.flow-strip,
.hero-current,
.game-card,
.detail-hero,
.price-card,
.order-form,
.summary,
.admin-panel,
.admin-game {
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 244, 210, .055), rgba(255, 255, 255, .015)),
    rgba(8, 9, 9, .82);
  box-shadow: var(--shadow);
}

.trust-grid article {
  min-height: 126px;
  padding: 18px;
  border-radius: 8px;
}

.trust-grid span,
.hero-current span,
.summary-top span,
.summary-line span,
.payment-box > span {
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
}

.trust-grid strong {
  display: block;
  margin: 8px 0;
  color: #fff2c9;
  font-size: 20px;
}

.trust-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.flow-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 78px;
  padding: 18px;
  border-radius: 8px;
  color: var(--ink);
}

.flow-strip span {
  padding-right: 12px;
  color: #fff2c9;
  font-size: 22px;
  font-weight: 900;
}

.flow-strip b {
  font-size: 15px;
}

.flow-strip i {
  width: 38px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.hero-current {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  width: fit-content;
  padding: 14px 18px;
  border-radius: 8px;
}

.hero-current strong {
  color: #fff2c9;
  font-size: 24px;
}

.store-shell,
.detail-panel,
.order-zone,
.admin-shell {
  padding: 60px clamp(18px, 5vw, 72px);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
}

.section-head.compact {
  margin-bottom: 22px;
}

.search-box {
  width: min(360px, 100%);
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid rgba(218, 174, 88, .26);
  border-radius: 8px;
  background: rgba(0, 0, 0, .56);
  color: #fff5da;
  outline: none;
}

input,
select {
  min-height: 48px;
  padding: 0 14px;
}

textarea {
  padding: 14px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: rgba(222, 205, 171, .55);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--line-strong);
  box-shadow: 0 0 0 3px rgba(233, 191, 105, .12);
}

.category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
}

.category-tab,
.pay {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid rgba(218, 174, 88, .28);
  border-radius: 8px;
  background: rgba(12, 12, 12, .78);
  color: var(--muted);
}

.category-tab.active,
.category-tab:hover,
.pay.active,
.pay:hover {
  border-color: var(--line-strong);
  background: linear-gradient(180deg, rgba(233, 191, 105, .2), rgba(107, 70, 25, .18));
  color: var(--ink);
}

.game-grid,
.price-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.game-card {
  display: grid;
  grid-template-rows: auto 1fr;
  overflow: hidden;
  border-radius: 8px;
  transition: transform .18s ease, border-color .18s ease;
}

.game-card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
}

.game-cover {
  position: relative;
  display: grid;
  aspect-ratio: 16 / 10;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(233, 191, 105, .22), rgba(0, 0, 0, .15)),
    radial-gradient(circle at 70% 35%, rgba(233, 191, 105, .26), transparent 90px),
    #111;
}

.game-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.game-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, .34));
}

.game-cover span {
  position: relative;
  z-index: 1;
  color: #fff0c8;
  font-family: "DFKai-SB", "KaiTi", "Microsoft JhengHei", serif;
  font-size: 58px;
  font-weight: 900;
  text-shadow: 0 0 24px rgba(233, 191, 105, .3);
}

.game-card-body {
  display: grid;
  min-height: 72px;
  place-items: center;
  padding: 16px;
  text-align: center;
}

.game-card-body h3 {
  font-size: 20px;
}

.game-card-body p,
.detail-hero p,
.price-card small,
.verify-status,
.admin-game span {
  color: var(--muted);
  line-height: 1.6;
}

.detail-panel {
  background:
    linear-gradient(180deg, rgba(233, 191, 105, .04), transparent),
    #080807;
}

.detail-hero {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 20px;
  align-items: center;
  margin-bottom: 24px;
  padding: 24px;
  border-radius: 8px;
}

.game-emblem {
  display: grid;
  width: 82px;
  height: 82px;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  color: var(--gold);
  font-family: "DFKai-SB", "KaiTi", "Microsoft JhengHei", serif;
  font-size: 34px;
  font-weight: 900;
  background: rgba(0, 0, 0, .45);
}

.detail-score {
  display: grid;
  min-width: 110px;
  justify-items: center;
  padding: 16px;
  border: 1px solid rgba(218, 174, 88, .28);
  border-radius: 8px;
  background: rgba(0, 0, 0, .42);
}

.detail-score strong {
  color: var(--gold);
  font-size: 34px;
}

.detail-score span,
.detail-score small {
  color: var(--muted);
}

.price-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: center;
  min-height: 148px;
  padding: 18px;
  border-radius: 8px;
}

.price-card.selected {
  border-color: var(--line-strong);
  box-shadow: 0 0 0 1px rgba(233, 191, 105, .2), var(--shadow);
}

.price-card span {
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
}

.price-card strong {
  color: #fff2c9;
  font-size: 22px;
}

.select-plan {
  grid-column: 1 / -1;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0, 0, 0, .52);
  color: var(--ink);
  font-weight: 900;
}

.select-plan:hover {
  border-color: var(--line-strong);
}

.order-zone {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, .38fr);
  gap: 22px;
  align-items: start;
}

.order-form,
.summary,
.admin-panel {
  padding: 24px;
  border-radius: 8px;
}

.form-grid,
.admin-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
  color: #fff2c9;
  font-weight: 900;
}

.wide,
.admin-wide,
.verify-row {
  grid-column: 1 / -1;
}

.verify-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 10px;
  align-items: end;
}

.member-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
  padding: 16px;
  border: 1px solid rgba(218, 174, 88, .24);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(233, 191, 105, .12), rgba(0, 0, 0, .16)),
    rgba(0, 0, 0, .28);
}

.member-panel.active {
  border-color: rgba(143, 213, 174, .56);
  background:
    linear-gradient(135deg, rgba(143, 213, 174, .13), rgba(233, 191, 105, .08)),
    rgba(0, 0, 0, .28);
}

.member-panel span,
.member-panel small {
  display: block;
}

.member-panel span {
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
}

.member-panel strong {
  display: block;
  margin-top: 4px;
  color: #fff2c9;
  font-size: 19px;
}

.member-panel small {
  margin-top: 5px;
  color: var(--muted);
  line-height: 1.5;
}

.member-panel .line-login-button {
  min-width: 118px;
}

.secure-badge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.verify-status {
  margin: 16px 0;
  padding: 12px 14px;
  border: 1px solid rgba(218, 174, 88, .2);
  border-radius: 8px;
  background: rgba(0, 0, 0, .32);
}

.verify-status.success {
  border-color: rgba(143, 213, 174, .55);
  color: #bff2ce;
}

.verify-status.error {
  border-color: rgba(215, 88, 76, .6);
  color: #ffb0a9;
}

.verify-status.pending {
  color: var(--ink);
}

.check-row,
.admin-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 16px 0;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.65;
}

.check-row input {
  width: 18px;
  min-height: 18px;
  margin-top: 4px;
}

.summary {
  position: sticky;
  top: 98px;
}

.summary-top {
  display: grid;
  gap: 8px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.summary-top strong {
  color: #fff2c9;
  font-size: 34px;
}

.summary-line {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid rgba(218, 174, 88, .16);
}

.summary-line b {
  color: #fff2c9;
  text-align: right;
}

.payment-box {
  display: grid;
  gap: 12px;
  padding-top: 16px;
}

.payment-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.confirmation {
  margin-top: 16px;
  padding: 14px;
  border: 1px solid rgba(143, 213, 174, .45);
  border-radius: 8px;
  background: rgba(13, 63, 39, .24);
  color: #c9f7d3;
  line-height: 1.65;
}

.confirmation .copy-order {
  margin-top: 10px;
}

.admin-page {
  background: var(--paper);
}

.admin-shell {
  display: grid;
  grid-template-columns: minmax(320px, .9fr) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.admin-shell h1 {
  font-size: clamp(32px, 4vw, 54px);
}

.admin-list,
.admin-plans {
  display: grid;
  gap: 10px;
}

.admin-game {
  padding: 16px;
  margin-top: 14px;
  border-radius: 8px;
}

.admin-game-head,
.admin-plan {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.admin-game button,
.admin-plan button {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0, 0, 0, .48);
  color: var(--ink);
}

.admin-plans {
  margin-top: 12px;
}

.admin-plan {
  padding: 10px;
  border: 1px solid rgba(218, 174, 88, .2);
  border-radius: 8px;
  background: rgba(0, 0, 0, .3);
}

.accent-pink,
.accent-mint,
.accent-blue,
.accent-yellow,
.accent-purple,
.accent-orange {
  --accent: var(--gold);
}

@media (max-width: 1160px) {
  .trust-grid,
  .game-grid,
  .price-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .order-zone,
  .admin-shell,
  .detail-hero {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    background-position: 66% center;
  }

  .summary {
    position: static;
  }
}

@media (max-width: 700px) {
  .topbar {
    position: static;
    flex-wrap: wrap;
  }

  .brand {
    flex: 1 1 100%;
  }

  .nav {
    order: 3;
    width: 100%;
    gap: 4px;
    justify-content: space-between;
  }

  .nav a {
    min-width: auto;
    flex: 1;
    padding: 9px 6px;
    font-size: 14px;
    white-space: nowrap;
  }

  h1 {
    font-size: 48px;
  }

  .hero {
    padding-top: 54px;
  }

  .section-head,
  .summary-line,
  .admin-game-head,
  .admin-plan {
    align-items: flex-start;
    flex-direction: column;
  }

  .trust-grid,
  .game-grid,
  .price-list,
  .form-grid,
  .admin-form,
  .verify-row,
  .member-panel,
  .payment-options {
    grid-template-columns: 1fr;
  }

  .member-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .flow-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .flow-strip i {
    display: none;
  }
}
