
  :root {
    --brand: #123c52;
    --brand-dark: #0c2c3d;
    --bg: #f4f7f9;
    --border: #dbe3e8;
    --danger: #c0392b;
    --ok: #1a7a4c;
  }
  * { box-sizing: border-box; }
  body {
    margin: 0; background: var(--bg); color: #222;
    font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", sans-serif;
    padding-bottom: env(safe-area-inset-bottom);
  }
  .wrap { max-width: 480px; margin: 0 auto; padding: 20px 16px 40px; }
  .header { text-align: center; margin-bottom: 20px; }
  .header .logo { font-size: 15px; color: var(--brand); font-weight: bold; }
  .header h1 { font-size: 20px; margin: 4px 0 0; color: var(--brand-dark); }
  .card {
    background: #fff; border: 1px solid var(--border); border-radius: 14px;
    padding: 18px; margin-bottom: 16px; box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  }
  .center { text-align: center; }
  .muted { color: #667; font-size: 13px; line-height: 1.6; }
  label { display: block; font-size: 13px; font-weight: bold; color: #445; margin: 14px 0 6px; }
  label:first-of-type { margin-top: 0; }
  input[type="text"], input[type="number"] {
    width: 100%; padding: 11px 12px; border: 1px solid var(--border); border-radius: 8px;
    font-size: 16px; background: #fff;
  }
  .stepper { display: flex; align-items: center; gap: 10px; }
  .stepper input { text-align: center; flex: 1; }
  .stepper button {
    width: 42px; height: 42px; border-radius: 8px; border: 1px solid var(--border);
    background: #fff; font-size: 20px; color: var(--brand-dark); flex-shrink: 0;
  }
  .stepper button:active { background: var(--bg); }
  .fee-box {
    margin-top: 16px; padding: 12px 14px; border-radius: 10px; background: var(--bg);
    display: flex; justify-content: space-between; align-items: baseline;
  }
  .fee-box .label { font-size: 13px; color: #556; }
  .fee-box .amount { font-size: 22px; font-weight: bold; color: var(--brand-dark); }
  .fee-note { font-size: 11px; color: #889; margin-top: 6px; }
  .notice {
    margin-top: 12px; padding: 10px 12px; border-radius: 8px; font-size: 13px;
    background: #fff6e5; color: #8a5a00; border: 1px solid #f0d9a6; display: none;
  }
  .btn {
    display: block; width: 100%; margin-top: 18px; padding: 14px; border: none; border-radius: 10px;
    background: var(--brand); color: #fff; font-size: 16px; font-weight: bold; cursor: pointer;
  }
  .btn:disabled { background: #9fb0ba; }
  .btn.secondary { background: #fff; color: var(--brand); border: 1px solid var(--brand); margin-top: 10px; }
  .error-msg {
    margin-top: 12px; padding: 10px 12px; border-radius: 8px; font-size: 13px;
    background: #fdecea; color: var(--danger); border: 1px solid #f5c6c0; display: none;
  }
  .ticket-no {
    font-size: 48px; font-weight: bold; color: var(--brand-dark); letter-spacing: 2px;
    text-align: center; margin: 6px 0 2px;
  }
  .ticket-label { text-align: center; font-size: 13px; color: #667; }
  .result-list { margin-top: 18px; }
  .result-list .row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
  .result-list .row:last-child { border-bottom: none; }
  .spinner {
    width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--border);
    border-top-color: var(--brand); margin: 30px auto; animation: spin 0.8s linear infinite;
  }
  @keyframes spin { to { transform: rotate(360deg); } }
  .hidden { display: none !important; }

/* Original LIFF brand tokens, safe responsive/keyboard interaction additions. */
.wrap{max-width:720px}header{text-align:center;margin-bottom:20px}.brand{font-weight:700;color:var(--brand)}h1{font-size:23px;color:var(--brand-dark)}h2{font-size:18px;color:var(--brand-dark)}h3{font-size:19px}nav{display:flex;gap:12px;justify-content:center;flex-wrap:wrap}a{color:var(--brand);overflow-wrap:anywhere;min-height:44px;display:inline-flex;align-items:center;padding:8px}button,input,select,textarea{font:inherit;max-width:100%;min-height:44px}button{touch-action:manipulation}input:not([type=checkbox]),select,textarea{width:100%;padding:10px 12px;border:1px solid var(--border);border-radius:8px;background:white}input[type=checkbox]{width:24px;min-width:24px;height:24px;min-height:24px;margin:10px;vertical-align:middle}label{min-height:44px;line-height:1.5}label:has(input[type=checkbox]){display:flex;align-items:center;font-weight:500}fieldset{border:1px solid var(--border);border-radius:8px;min-width:0;padding:12px;margin:16px 0}legend{font-size:14px;color:var(--brand-dark);padding:0 4px}.btn{min-height:48px;margin-top:12px;white-space:normal}.btn:disabled{cursor:not-allowed}.error{color:var(--danger);line-height:1.65}.error:empty{display:none}.support{font-size:12px;overflow-wrap:anywhere}.row{padding:12px 0;border-bottom:1px solid var(--border)}.amount{font-size:22px;font-weight:700;color:var(--brand-dark)}.secret-code{display:block;overflow-wrap:anywhere;user-select:all;background:var(--bg);font-family:monospace;padding:12px;border-radius:8px}.secret-code:empty{display:none}p{line-height:1.65;overflow-wrap:anywhere}[hidden]{display:none!important}:focus-visible{outline:3px solid #d58d00;outline-offset:3px}@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}}@media(min-width:900px){.wrap{padding-top:32px}}
