/* ============================================================
   首頁 Hero 大圖版型(作者專屬,可後台切換)
   共用 class .hhero + 變體 .hhero--<style>
   變體:split-right / split-left / center / minimal / glass
         banner / gradient / neon / stacked / duo
   ============================================================ */
.hhero { position: relative; margin: 0 0 1.4rem; border-radius: var(--r-lg); overflow: hidden; }
.hhero__inner { position: relative; z-index: 2; display: grid; gap: 1.6rem; align-items: center; padding: clamp(1.4rem, 4vw, 3rem); }
.hhero__text { display: flex; flex-direction: column; gap: .9rem; min-width: 0; }
.hhero__badges { display: flex; flex-wrap: wrap; gap: .45rem; }
.hhero__badges span { font-size: .78rem; color: var(--text-dim); background: rgba(255,255,255,.06);
  border: 1px solid var(--line); padding: .22rem .6rem; border-radius: var(--r-pill); white-space: nowrap; }
.hhero__badges span::before { content: "●"; color: var(--gold); margin-right: .35rem; font-size: .7em; vertical-align: 1px; }
.hhero__title { font-size: clamp(1.8rem, 5.2vw, 3rem); line-height: 1.12; letter-spacing: -.02em; font-weight: 700; }
.hhero__title .hl { color: var(--gold); }
.hhero__sub { color: var(--text-dim); font-size: clamp(.95rem, 2.4vw, 1.08rem); line-height: 1.6; max-width: 46ch; }
.hhero__cta { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: .3rem; }
.hhero__cta .btn { padding: .72rem 1.4rem; font-size: 1rem; border-radius: var(--r); }
.hhero__media { position: relative; display: flex; justify-content: center; align-items: center; min-width: 0; }
.hhero__media img { max-width: 100%; height: auto; display: block; border-radius: var(--r); object-fit: contain; }
.hhero--align-center .hhero__text { align-items: center; text-align: center; }
.hhero--align-center .hhero__sub { max-width: 60ch; }
.hhero--align-center .hhero__cta,
.hhero--align-center .hhero__badges { justify-content: center; }

/* 1) 文字左、圖右 ---------------------------------------- */
.hhero--split-right { background: linear-gradient(120deg, var(--surface) 0%, var(--surface2) 100%); border: 1px solid var(--line); }
.hhero--split-right .hhero__inner { grid-template-columns: 1.1fr .9fr; }
.hhero--split-right .hhero__media img { max-height: 420px; filter: drop-shadow(0 18px 40px rgba(0,0,0,.5)); }

/* 2) 圖左、文字右 ---------------------------------------- */
.hhero--split-left { background: linear-gradient(240deg, var(--surface) 0%, var(--surface2) 100%); border: 1px solid var(--line); }
.hhero--split-left .hhero__inner { grid-template-columns: .9fr 1.1fr; }
.hhero--split-left .hhero__media { order: -1; }
.hhero--split-left .hhero__media img { max-height: 420px; filter: drop-shadow(0 18px 40px rgba(0,0,0,.5)); }

/* 3) 滿版底圖 + 文字覆蓋置中 ------------------------------ */
.hhero--center { min-height: clamp(320px, 46vw, 520px); border: 1px solid var(--line); }
.hhero--center .hhero__inner { grid-template-columns: 1fr; justify-items: center; text-align: center; min-height: inherit; }
.hhero--center .hhero__text { align-items: center; text-align: center; }
.hhero--center .hhero__sub { max-width: 56ch; }
.hhero--center .hhero__cta, .hhero--center .hhero__badges { justify-content: center; }
.hhero--center .hhero__media { position: absolute; inset: 0; z-index: 1; }
.hhero--center .hhero__media img { width: 100%; height: 100%; object-fit: cover; border-radius: 0; opacity: .5; }
.hhero--center::after { content: ""; position: absolute; inset: 0; z-index: 1;
  background: radial-gradient(120% 90% at 50% 0%, transparent 25%, rgba(0,0,0,.55) 100%),
              linear-gradient(0deg, rgba(0,0,0,.6), rgba(0,0,0,.25)); }

/* 4) 極簡純文字(不放圖) --------------------------------- */
.hhero--minimal { background:
  radial-gradient(90% 120% at 50% -10%, rgba(227,188,114,.10), transparent 60%), var(--surface); border: 1px solid var(--line); }
.hhero--minimal .hhero__inner { grid-template-columns: 1fr; justify-items: center; text-align: center; padding-block: clamp(2.2rem, 6vw, 4rem); }
.hhero--minimal .hhero__text { align-items: center; text-align: center; }
.hhero--minimal .hhero__media { display: none; }
.hhero--minimal .hhero__cta, .hhero--minimal .hhero__badges { justify-content: center; }

/* 5) 玻璃卡片 -------------------------------------------- */
.hhero--glass { border: 1px solid var(--line); min-height: clamp(320px, 44vw, 480px); }
.hhero--glass .hhero__media { position: absolute; inset: 0; z-index: 1; }
.hhero--glass .hhero__media img { width: 100%; height: 100%; object-fit: cover; border-radius: 0; }
.hhero--glass::before { content: ""; position: absolute; inset: 0; z-index: 1; background: rgba(8,10,16,.4); }
.hhero--glass .hhero__inner { grid-template-columns: minmax(0, 560px); justify-content: center; min-height: inherit; }
.hhero--glass .hhero__text { background: rgba(16,20,28,.55); backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2); border: 1px solid rgba(255,255,255,.12);
  padding: 1.6rem; border-radius: var(--r-lg); box-shadow: var(--sh-3); }

/* 6) 寬幅橫幅(圖滿、文字壓左下) ------------------------- */
.hhero--banner { min-height: clamp(260px, 38vw, 460px); border: 1px solid var(--line); }
.hhero--banner .hhero__media { position: absolute; inset: 0; z-index: 1; }
.hhero--banner .hhero__media img { width: 100%; height: 100%; object-fit: cover; border-radius: 0; }
.hhero--banner::after { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, rgba(0,0,0,.82) 0%, rgba(0,0,0,.5) 42%, transparent 78%); }
.hhero--banner .hhero__inner { grid-template-columns: 1fr; align-items: end; justify-items: start;
  min-height: inherit; }
.hhero--banner .hhero__text { max-width: 620px; }

/* 7) 動態漸層(不放圖) ---------------------------------- */
.hhero--gradient { border: 1px solid var(--line);
  background: linear-gradient(120deg, #1a1030, #0e1830, #301022, #102a2a); background-size: 300% 300%;
  animation: hheroShift 16s var(--ease) infinite; }
@keyframes hheroShift { 0%,100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
.hhero--gradient .hhero__inner { grid-template-columns: 1fr; justify-items: center; text-align: center;
  padding-block: clamp(2.2rem, 6vw, 4rem); }
.hhero--gradient .hhero__text { align-items: center; text-align: center; }
.hhero--gradient .hhero__media { display: none; }
.hhero--gradient .hhero__cta, .hhero--gradient .hhero__badges { justify-content: center; }
@media (prefers-reduced-motion: reduce) { .hhero--gradient { animation: none; } }

/* 8) 霓虹外框 + 文字左圖右 ------------------------------- */
.hhero--neon { background: var(--bg-deep); border: 1.5px solid var(--gold); box-shadow: 0 0 0 1px rgba(227,188,114,.25), 0 0 34px -6px rgba(227,188,114,.4) inset; }
.hhero--neon .hhero__inner { grid-template-columns: 1.1fr .9fr; }
.hhero--neon .hhero__title .hl { text-shadow: 0 0 18px rgba(227,188,114,.6); }
.hhero--neon .hhero__media img { max-height: 420px; filter: drop-shadow(0 0 28px rgba(227,188,114,.35)); }

/* 9) 直向堆疊(圖上文字下,手機感) ----------------------- */
.hhero--stacked { background: linear-gradient(180deg, var(--surface2), var(--surface)); border: 1px solid var(--line); }
.hhero--stacked .hhero__inner { grid-template-columns: 1fr; justify-items: center; text-align: center; }
.hhero--stacked .hhero__text { align-items: center; text-align: center; order: 2; }
.hhero--stacked .hhero__media { order: 1; }
.hhero--stacked .hhero__media img { max-height: 300px; filter: drop-shadow(0 16px 36px rgba(0,0,0,.5)); }
.hhero--stacked .hhero__cta, .hhero--stacked .hhero__badges { justify-content: center; }

/* 10) 強調雙色塊(文字左、圖右、主色光暈) ---------------- */
.hhero--duo { background:
  radial-gradient(70% 120% at 100% 0%, rgba(227,188,114,.16), transparent 55%),
  linear-gradient(120deg, var(--surface) 0%, var(--bg-deep) 100%); border: 1px solid var(--gold-deep); }
.hhero--duo .hhero__inner { grid-template-columns: 1.05fr .95fr; }
.hhero--duo .hhero__title { font-size: clamp(2rem, 5.6vw, 3.3rem); }
.hhero--duo .hhero__media img { max-height: 440px; filter: drop-shadow(0 20px 46px rgba(0,0,0,.55)); }

/* 數據列(4 格,接在 hero 下方) -------------------------- */
.hhero-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; margin: 0 0 1.4rem; }
.hhero-stats .st { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: .9rem 1rem; text-align: center; }
.hhero-stats .st b { display: block; font-size: clamp(1.1rem, 3.2vw, 1.5rem); color: var(--gold); line-height: 1.15; }
.hhero-stats .st .lb { font-size: .92rem; color: var(--text); margin-top: .15rem; }
.hhero-stats .st .sub { font-size: .76rem; color: var(--muted); margin-top: .1rem; }

/* 次要按鈕樣式(hero 內用) */
.hhero .btn.ghost { background: transparent; border: 1px solid var(--line); color: var(--text); }
.hhero .btn.ghost:hover { border-color: var(--gold); color: var(--gold); }

/* 背景底圖層(所有版型通用,跟角色圖分開) ---------------- */
.hhero__bg { position: absolute; inset: 0; z-index: 0; background-size: cover; background-position: center; }
.hhero.has-bg::before { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, rgba(8,10,16,.82) 0%, rgba(8,10,16,.45) 55%, rgba(8,10,16,.2) 100%); }
.hhero--align-center.has-bg::before,
.hhero--center.has-bg::before, .hhero--minimal.has-bg::before, .hhero--gradient.has-bg::before,
.hhero--stacked.has-bg::before {
  background: linear-gradient(180deg, rgba(8,10,16,.55), rgba(8,10,16,.75)); }

/* ============================================================
   首頁入口大卡(儲值專區 / 帳號專區),背景圖 + 側邊角色圖分開
   ============================================================ */
.home-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: 0 0 1.6rem; }
.hcard { position: relative; display: block; min-height: 180px; border-radius: var(--r-lg);
  overflow: hidden; border: 1.5px solid var(--gold-dim); background: linear-gradient(135deg, var(--surface2), var(--bg-deep));
  box-shadow: var(--sh-2); transition: transform .14s var(--ease), border-color .14s, box-shadow .14s; isolation: isolate; }
.hcard:hover { transform: translateY(-4px); border-color: var(--gold); box-shadow: 0 16px 40px -10px rgba(0,0,0,.6), 0 0 22px -6px rgba(227,188,114,.45); }
.hcard__bg { position: absolute; inset: 0; z-index: 0; background-size: cover; background-position: center; opacity: .55; }
.hcard::after { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(8,10,16,.25), rgba(8,10,16,.72)); }
.hcard__body { position: relative; z-index: 2; padding: 1.3rem 1.4rem; display: flex; flex-direction: column;
  gap: .35rem; height: 100%; max-width: 70%; }
.hcard__title { font-size: clamp(1.3rem, 4vw, 1.7rem); font-weight: 700; color: var(--text); letter-spacing: .02em; }
.hcard__eng { font-size: .78rem; letter-spacing: .22em; color: var(--gold); text-transform: uppercase; }
.hcard__desc { font-size: .9rem; color: var(--text-dim); margin-top: .2rem; }
.hcard__btn { margin-top: auto; align-self: flex-start; display: inline-flex; align-items: center; gap: .3rem;
  background: linear-gradient(135deg, var(--gold), var(--gold-dim)); color: var(--gold-ink); font-weight: 700;
  padding: .5rem 1.1rem; border-radius: var(--r-pill); font-size: .9rem; margin-top: .9rem; }
.hcard__char { position: absolute; right: -6px; bottom: 0; z-index: 2; height: 108%; max-width: 52%;
  object-fit: contain; object-position: bottom right; pointer-events: none;
  filter: drop-shadow(0 10px 22px rgba(0,0,0,.5)); }

/* ============================================================
   手機優化:雙欄→直向、卡片縮排、角色圖縮小
   ============================================================ */
@media (max-width: 760px) {
  .hhero--split-right .hhero__inner, .hhero--split-left .hhero__inner,
  .hhero--neon .hhero__inner, .hhero--duo .hhero__inner { grid-template-columns: 1fr; }
  .hhero--split-left .hhero__media, .hhero--split-right .hhero__media,
  .hhero--neon .hhero__media, .hhero--duo .hhero__media { order: -1; }
  .hhero--split-right .hhero__media img, .hhero--split-left .hhero__media img,
  .hhero--neon .hhero__media img, .hhero--duo .hhero__media img, .hhero--stacked .hhero__media img { max-height: 230px; }
  .hhero__inner { padding: 1.2rem; gap: 1rem; }
  .hhero-stats { grid-template-columns: repeat(2, 1fr); gap: .55rem; }
  .home-cards { grid-template-columns: 1fr; gap: .8rem; }
  .hcard { min-height: 150px; }
  .hcard__body { max-width: 66%; padding: 1.05rem 1.1rem; }
  .hcard__char { max-width: 44%; height: 104%; }
}
@media (max-width: 420px) {
  .hhero__title { font-size: 1.65rem; }
  .hhero__badges span { font-size: .72rem; }
  .hhero-stats .st { padding: .7rem .5rem; }
  .hcard__char { opacity: .9; }
}
