@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Noto+Sans+TC:wght@400;500;600;700;800&display=swap');

:root { --ink: #172a3a; --muted: #71808a; --line: #e3e9e6; --cream: #f4f6f0; --white: #fff; --mint: #c8f0dc; --green: #318b61; --orange: #ed9165; }
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--cream); color: var(--ink); font-family: 'Noto Sans TC', system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
button { font: inherit; }
.page-shell { max-width: 1240px; margin: 0 auto; padding: 0 52px 38px; }
.topbar { height: 92px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(23,42,58,.1); }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand-mark { width: 114px; height: 42px; display: block; flex: 0 0 auto; }
.brand-mark img { width: 100%; height: 100%; display: block; object-fit: contain; }
.brand strong { display: block; font-size: 16px; letter-spacing: .08em; }
.brand small { display: block; margin-top: 2px; color: #98a29f; font: 500 10px 'DM Mono', monospace; letter-spacing: .14em; }
.topbar-meta { display: flex; align-items: center; gap: 25px; color: #82908e; font-size: 14px; }
.live-dot { display: inline-flex; align-items: center; gap: 8px; }
.live-dot i { width: 7px; height: 7px; border-radius: 50%; background: #52ba7c; box-shadow: 0 0 0 4px rgba(82,186,124,.13); }
.topbar-date { font: 500 13px 'DM Mono', monospace; letter-spacing: .04em; }
.intro-row { display: flex; align-items: flex-end; justify-content: space-between; padding: 74px 0 48px; }
.eyebrow, .section-label { margin: 0; color: #7b908b; font-size: 12px; font-weight: 700; letter-spacing: .16em; }
.eyebrow { display: flex; align-items: center; gap: 9px; margin-bottom: 15px; }
.eyebrow span { display: block; width: 27px; height: 1px; background: var(--orange); }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 9px; font-size: clamp(32px, 4vw, 45px); font-weight: 700; letter-spacing: -.055em; line-height: 1.22; }
.intro-copy { margin: 0; color: #80908d; font-size: 16px; }
.current-time { text-align: right; }
.current-time span { display: block; font: 500 42px/1 'DM Mono', monospace; letter-spacing: -.08em; }
.current-time small { display: block; margin-top: 10px; color: #83918f; font-size: 12px; }
.dashboard-grid { width: min(100%, 820px); display: grid; gap: 18px; margin: 0 auto; }
.checkout-card, .live-card { background: var(--white); border: 1px solid rgba(23,42,58,.055); border-radius: 18px; box-shadow: 0 12px 38px rgba(27, 49, 57, .035); }
.checkout-card { min-height: 420px; padding: 36px 40px 30px; display: flex; flex-direction: column; }
.card-heading { display: flex; justify-content: space-between; align-items: flex-start; }
h2 { margin: 8px 0 0; font-size: 22px; letter-spacing: -.035em; }
.lock-badge { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 9px; background: #f2f7f3; color: #699177; }
.lock-badge svg { width: 17px; height: 17px; }
.feedback-form { margin-top: 28px; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.field { display: flex; flex-direction: column; gap: 7px; color: #7e8f8b; font-size: 14px; }
.field[hidden] { display: none !important; }
.field b, .question b { color: #e17c57; font-weight: 700; }
.field input, .field textarea { width: 100%; border: 1px solid #e0e8e3; border-radius: 8px; outline: none; background: #fbfcfa; color: var(--ink); font: 400 14px 'Noto Sans TC', sans-serif; transition: border-color .2s, box-shadow .2s, background .2s; }
.field input { height: 39px; padding: 0 12px; }
.field textarea { min-height: 71px; padding: 10px 12px; resize: vertical; line-height: 1.6; }
.field input::placeholder, .field textarea::placeholder { color: #b2bdb8; }
.field input:focus, .field textarea:focus { border-color: #8cc4a0; background: #fff; box-shadow: 0 0 0 3px #eaf7ee; }
.field input:disabled, .field textarea:disabled { color: #8c9b96; cursor: not-allowed; opacity: .75; }
.question { min-width: 0; margin: 21px 0 0; padding: 0; border: 0; }
.question legend { width: 100%; padding: 0; color: #526965; font-size: 14px; font-weight: 600; line-height: 1.65; }
.question legend small { color: #a1ada8; font-size: 12px; font-weight: 400; }
.rating-options { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; margin-top: 9px; }
.compact-options { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.rating-option { position: relative; min-width: 0; cursor: pointer; }
.rating-option input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.rating-option span { display: block; overflow: hidden; padding: 10px 3px; border: 1px solid #e5ebe7; border-radius: 7px; color: #92a09b; text-align: center; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; transition: color .2s, border-color .2s, background .2s; }
.rating-option:hover span { border-color: #b8dcc5; color: #4d8564; }
.rating-option input:checked + span { border-color: #8ac19b; background: #eaf7ee; color: #3e835b; font-weight: 600; }
.rating-option input:focus-visible + span { outline: 2px solid #8ac19b; outline-offset: 2px; }
.suggestion-fields { margin-top: 21px; }
.suggestion-fields + .field { margin-top: 16px; }
.identity-panel { display: flex; align-items: center; gap: 14px; margin: 37px 0 27px; padding: 16px 18px; border-radius: 13px; background: #f6f8f4; }
.avatar { width: 48px; height: 48px; display: grid; flex: 0 0 auto; place-items: center; border-radius: 50%; background: #b7dfc5; color: #35614d; font: 500 14px 'DM Mono', monospace; }
.identity-copy { min-width: 0; flex: 1; }
.identity-copy strong { display: block; margin-bottom: 3px; font-size: 15px; }
.identity-copy span { display: block; overflow: hidden; color: #8b9895; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.verified { display: inline-flex; align-items: center; gap: 4px; flex: 0 0 auto; color: #4a996e; font-size: 10px; }
.verified svg { width: 14px; height: 14px; padding: 2px; border-radius: 50%; background: #d9f2e3; }
.checkout-button { width: 100%; display: flex; align-items: center; justify-content: center; gap: 11px; margin-top: 30px; padding: 17px 22px; border: 0; border-radius: 10px; background: var(--ink); color: #fff; cursor: pointer; font-size: 16px; font-weight: 600; transition: transform .2s, background .2s, box-shadow .2s; }
.checkout-button svg { width: 19px; height: 19px; }
.checkout-button:hover { background: #27465a; box-shadow: 0 8px 20px rgba(23,42,58,.15); transform: translateY(-1px); }
.checkout-button:active { transform: translateY(0); }
.checkout-button:disabled { background: #b0bdb8; cursor: not-allowed; box-shadow: none; transform: none; }
.duplicate-message { margin: 12px 0 0; color: #bd6f52; text-align: center; font-size: 13px; font-weight: 600; line-height: 1.6; }
.live-card { padding: 26px 30px 22px; }
.live-heading { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; align-items: start; }
.live-heading h2 { font-size: 18px; }
.live-heading > div:first-child { min-width: 0; }
.live-meta { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px 16px; }
.live-count { color: #318b61; font-size: 14px; font-weight: 700; white-space: nowrap; }
.refresh-badge { display: inline-flex; align-items: center; gap: 6px; color: #92a29b; font: 500 12px 'DM Mono', monospace; white-space: nowrap; }
.refresh-badge i { width: 6px; height: 6px; border-radius: 50%; background: #52ba7c; box-shadow: 0 0 0 4px rgba(82,186,124,.12); }
.record-search { margin-top: 22px; padding-top: 18px; border-top: 1px solid #eef2ef; }
.record-search > label { display: block; margin-bottom: 8px; color: #7e8f8b; font-size: 13px; font-weight: 600; }
.search-controls { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr) 88px; gap: 8px; }
.search-controls input { width: 100%; height: 42px; padding: 0 12px; border: 1px solid #e0e8e3; border-radius: 8px; outline: none; background: #fbfcfa; color: var(--ink); font: 400 14px 'Noto Sans TC', sans-serif; }
.search-controls input:focus { border-color: #8cc4a0; background: #fff; box-shadow: 0 0 0 3px #eaf7ee; }
.search-controls button { height: 42px; border: 0; border-radius: 8px; background: #eaf7ee; color: #3e835b; cursor: pointer; font-size: 14px; font-weight: 600; }
.search-controls button:hover { background: #d9f2e3; }
.search-controls button:disabled { cursor: wait; opacity: .6; }
.search-result { margin: 10px 0 0; color: #318b61; font-size: 13px; font-weight: 600; line-height: 1.6; }
.search-result.no-result { color: #bd6f52; }
.live-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 22px; max-height: 380px; margin-top: 21px; padding-right: 8px; overflow-y: auto; scrollbar-color: #b8d8c1 #f1f5f2; scrollbar-width: thin; }
.empty-live { grid-column: 1 / -1; display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 70px; border: 1px dashed #dbe4df; border-radius: 10px; color: #8d9b97; font-size: 12px; }
.empty-live small { margin-top: 5px; color: #b2bcb8; font-size: 10px; }
.live-item { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 1px; border-bottom: 1px solid #eef2ef; }
.live-item-name { min-width: 0; flex: 1 1 auto; overflow: hidden; color: #526965; font-size: 14px; font-weight: 600; line-height: 1.4; text-overflow: ellipsis; white-space: nowrap; word-break: keep-all; }
.live-item-time { flex: 0 0 auto; color: #8d9996; font: 500 14px 'DM Mono', monospace; }
.live-item:nth-last-child(-n + 2) { border-bottom: 0; }
.live-error { grid-column: 1 / -1; padding: 12px; border-radius: 9px; background: #fff7f2; color: #b17459; text-align: center; font-size: 11px; }
.privacy-note { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 31px 0 0; color: #a3afab; font-size: 12px; }
.privacy-note svg { width: 15px; height: 15px; }
.admin-link { display: block; width: fit-content; margin: 12px auto 0; color: #91a09c; font-size: 11px; text-decoration: none; }
.admin-link:hover { color: #4e956d; text-decoration: underline; }
.toast { position: fixed; z-index: 20; bottom: 25px; left: 50%; padding: 12px 19px; border-radius: 8px; background: var(--ink); color: #fff; box-shadow: 0 8px 25px rgba(23,42,58,.18); opacity: 0; pointer-events: none; transform: translate(-50%, 12px); font-size: 12px; transition: opacity .25s, transform .25s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.top-button { position: fixed; z-index: 15; right: 24px; bottom: 24px; display: inline-flex; align-items: center; gap: 6px; padding: 10px 13px; border: 1px solid rgba(18,52,86,.12); border-radius: 999px; background: rgba(255,255,255,.94); color: var(--blue-dark); box-shadow: 0 8px 24px rgba(35,67,96,.14); cursor: pointer; font: 500 11px 'DM Mono', monospace; opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity .2s, transform .2s, background .2s; }
.top-button span { font-size: 15px; line-height: 10px; }
.top-button:hover { background: #fff8ef; }
.top-button.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
@media (max-width: 760px) { .page-shell { padding: 0 20px 28px; } .topbar { height: 76px; } .topbar-meta { gap: 0; } .topbar-date { display: none; } .intro-row { padding: 53px 0 35px; align-items: flex-end; } .current-time span { font-size: 29px; } .current-time small { margin-top: 7px; font-size: 10px; } .checkout-card { min-height: 398px; padding: 28px 24px 25px; } .live-card { padding-left: 24px; padding-right: 24px; } }
@media (max-width: 760px) { .field input, .field textarea { font-size: 16px; } }
@media (max-width: 560px) { .field-grid { grid-template-columns: 1fr; gap: 14px; } .rating-options, .compact-options { grid-template-columns: repeat(2, 1fr); } .question legend { font-size: 13px; } .search-controls { grid-template-columns: 1fr 1fr; } .search-controls button { grid-column: 1 / -1; } .search-controls input { font-size: 16px; } .live-list { grid-template-columns: 1fr; } .live-item:nth-last-child(-n + 2) { border-bottom: 1px solid #eef2ef; } .live-item:last-child { border-bottom: 0; } }
@media (max-width: 430px) { .intro-row { align-items: flex-start; gap: 12px; } .intro-row > div:first-child { min-width: 0; flex: 1; } h1 { font-size: 29px; } .intro-copy { font-size: 14px; } .current-time { display: block; flex: 0 0 auto; padding-top: 4px; } .current-time span { font-size: 23px; letter-spacing: -.08em; } .current-time small { margin-top: 6px; font-size: 10px; } }

/* Refined visual system */
:root {
  --ink: #173b63;
  --muted: #6f8498;
  --line: #dce8f2;
  --cream: #f5f8fc;
  --white: #ffffff;
  --mint: #ffe2b7;
  --green: #2a73a8;
  --orange: #ef8724;
  --orange-dark: #d86d12;
  --blue-dark: #123456;
  --blue-soft: #eaf3fa;
}

body {
  background: radial-gradient(circle at 10% 0%, #fff8ef 0, transparent 30%), var(--cream);
  color: var(--ink);
}

.page-shell { max-width: 1320px; padding: 0 58px 52px; }
.topbar { height: 84px; border-bottom-color: rgba(23, 59, 99, .12); }
.brand { gap: 13px; }
.brand strong { font-size: 17px; letter-spacing: .1em; }
.topbar-meta { color: #68829a; }
.live-dot i { background: var(--orange); box-shadow: 0 0 0 4px rgba(239, 135, 36, .16); }
.intro-row { width: min(100%, 1120px); margin: 0 auto; padding: 65px 0 34px; }
.eyebrow, .section-label { color: #64839f; }
.eyebrow span { background: var(--orange); height: 2px; border-radius: 2px; }
h1 { color: var(--blue-dark); font-size: clamp(34px, 4.2vw, 52px); letter-spacing: -.065em; }
.intro-copy { color: #71879b; }
.current-time span { color: var(--blue-dark); font-size: 44px; }
.current-time small { color: #7b94a9; }
.dashboard-grid { width: min(100%, 1120px); grid-template-columns: minmax(0, 1.08fr) minmax(350px, .92fr); gap: 24px; align-items: start; }
.checkout-card, .live-card { border: 1px solid rgba(23, 59, 99, .08); border-radius: 20px; box-shadow: 0 18px 55px rgba(35, 67, 96, .08); }
.checkout-card { position: relative; overflow: hidden; min-height: 0; padding: 34px 38px 30px; }
.checkout-card::before { position: absolute; inset: 0 0 auto; height: 4px; background: var(--orange); content: ''; }
.card-heading { align-items: center; }
.card-heading h2, .live-heading h2 { color: var(--blue-dark); }
.lock-badge { background: var(--blue-soft); color: #2c75a9; }
.feedback-form { margin-top: 25px; }
.field { color: #657f96; }
.field b, .question b { color: var(--orange-dark); }
.field input, .field textarea, .search-controls input { border-color: #d7e5f0; background: #fbfdff; }
.field input:focus, .field textarea:focus, .search-controls input:focus { border-color: #7fb4dc; box-shadow: 0 0 0 4px rgba(127, 180, 220, .18); }
.question { margin-top: 25px; }
.question legend { color: #355b7d; }
.rating-options { gap: 8px; margin-top: 10px; }
.rating-option span { min-height: 42px; display: flex; align-items: center; justify-content: center; border-color: #dbe7f0; background: #fcfeff; color: #7990a4; }
.rating-option:hover span { border-color: #efb36e; background: #fff9f1; color: #bc681b; }
.rating-option input:checked + span { border-color: #79acd2; background: var(--blue-soft); color: #236b9e; box-shadow: inset 0 0 0 1px rgba(42, 115, 168, .08); }
.suggestion-fields { margin-top: 25px; }
.checkout-button { margin-top: 26px; border-radius: 11px; background: var(--orange); box-shadow: 0 8px 18px rgba(239, 135, 36, .2); }
.checkout-button:hover { background: var(--orange-dark); box-shadow: 0 11px 24px rgba(216, 109, 18, .24); }
.live-card { padding: 28px 28px 24px; }
.live-heading { align-items: flex-start; }
.live-count { color: #246e9f; }
.record-search { margin-top: 20px; border-top-color: #e6eef5; }
.search-controls button { background: var(--blue-soft); color: #246e9f; }
.search-controls button:hover { background: #d8eaf7; }
.live-list { max-height: 460px; margin-top: 22px; scrollbar-color: #b6d1e7 #f0f6fa; }
.live-item { padding: 13px 3px; border-bottom-color: #e8f0f6; }
.live-item-name { color: #3d6383; }
.live-item-time { color: #7890a5; }
.privacy-note { margin-top: 26px; color: #8da2b4; }
.admin-link { color: #7991a7; }
.admin-link:hover { color: var(--orange-dark); }
.toast { background: var(--blue-dark); }

@media (max-width: 940px) {
  .dashboard-grid { grid-template-columns: 1fr; max-width: 820px; }
}
@media (max-width: 760px) {
  .page-shell { padding: 0 20px 34px; }
  .topbar { height: 76px; }
  .brand { gap: 8px; }
  .brand-mark { width: 94px; height: 34px; }
  .intro-row { padding: 50px 0 30px; }
  .checkout-card { padding: 30px 24px 26px; }
  .live-card { padding: 25px 24px 22px; }
  .top-button { right: 16px; bottom: 16px; }
}
@media (max-width: 560px) {
  .rating-options, .compact-options { gap: 7px; }
  .rating-option span { min-height: 44px; padding: 9px 4px; font-size: 12px; }
}

.schedule-banner {
  width: min(100%, 1120px);
  margin: 0 auto 24px;
  padding: 22px 26px 24px;
  border: 1px solid #f1c28c;
  border-left: 6px solid var(--orange);
  border-radius: 16px;
  background: #fff4e7;
  box-shadow: 0 12px 30px rgba(196, 107, 28, .08);
}
.schedule-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px 18px; }
.schedule-heading h2 { margin: 0; color: var(--blue-dark); font-size: 21px; font-weight: 800; letter-spacing: -.03em; }
.schedule-status { padding: 6px 12px; border-radius: 999px; background: #dff0e4; color: #226440; font-size: 13px; font-weight: 700; }
.schedule-status.closed { background: #ffe0ca; color: #98491d; }
.schedule-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; max-height: 210px; margin-top: 16px; overflow: auto; color: #365675; white-space: pre-line; }
.schedule-list:empty { display: none; }
.schedule-item { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 3px 16px; padding: 12px 16px; border: 1px solid #f3dfc7; border-radius: 10px; background: #fff; }
.schedule-date { color: var(--blue-dark); font-size: 17px; letter-spacing: .02em; }
.schedule-time { color: #b3570c; font: 700 19px/1.4 'DM Mono', 'Noto Sans TC', sans-serif; white-space: nowrap; }

@media (max-width: 760px) {
  .schedule-banner { padding: 20px; }
  .schedule-list { grid-template-columns: 1fr; }
}
@media (max-width: 430px) {
  .schedule-heading h2 { font-size: 19px; }
  .schedule-item { padding: 11px 13px; }
  .schedule-date { font-size: 16px; }
  .schedule-time { font-size: 18px; }
}
