:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;color:#1b1b1f;background:#f4f1ea;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}*{box-sizing:border-box}body{margin:0;min-width:320px}button,select,input{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.5}.app-shell{min-height:100vh;background:linear-gradient(135deg,#ffffffb8,#fff0),#f4f1ea;padding:28px}.workspace{max-width:1440px;margin:0 auto}.auth-panel{display:grid;gap:14px;max-width:460px;margin:13vh auto 0;border:1px solid rgba(27,27,31,.12);border-radius:8px;background:#ffffffd1;box-shadow:0 18px 42px #27211814;padding:24px}.auth-panel label{color:#48423a;font-weight:800}.auth-panel input{width:100%;border:1px solid rgba(27,27,31,.18);border-radius:7px;background:#fff;color:#1b1b1f;padding:12px 14px;font-weight:800}.auth-panel button{border:0;border-radius:7px;background:#008f86;color:#fff;font-weight:900;padding:13px 16px}.auth-message{margin:0;color:#684418;font-weight:700}.topbar,.panel-heading,.history-head,.history-row{display:flex;align-items:center;justify-content:space-between;gap:16px}.topbar{margin-bottom:22px}.eyebrow{margin:0 0 6px;color:#7a4f27;font-size:.74rem;font-weight:800;letter-spacing:.08em;text-transform:uppercase}h1,h2{margin:0;line-height:1.12}h1{margin-top:16px;max-width:760px;color:#008f86;font-family:"Noto Serif TC","Noto Serif HK",Songti TC,Microsoft JhengHei,PingFang HK,serif;font-size:clamp(1.5rem,2.7vw,2.75rem);font-weight:700;letter-spacing:0}h2{font-size:1.15rem}.layout-grid{display:grid;grid-template-columns:minmax(310px,390px) minmax(0,1fr);gap:22px;align-items:start}.control-panel,.preview-panel,.history-panel{border:1px solid rgba(27,27,31,.12);border-radius:8px;background:#ffffffc7;box-shadow:0 18px 42px #27211814}.control-panel{padding:18px;position:sticky;top:18px}.field-group{display:grid;gap:8px}.field-group label{color:#48423a;font-weight:800}.field-group select{appearance:none;width:100%;border:1px solid rgba(27,27,31,.18);border-radius:7px;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%2348423a' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") right 18px center / 18px 18px no-repeat,#fff;padding:12px 48px 12px 14px;color:#1b1b1f;font-size:1rem;font-weight:800}.field-group select.needs-selection{border-color:#d44316;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%238d2308' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") right 18px center / 18px 18px no-repeat,#fff0b8;color:#8d2308;font-weight:900;box-shadow:0 0 0 3px #d4431629}.field-group option{color:#1b1b1f;font-weight:800}.coupon-grid{display:grid;gap:12px;margin:18px 0}.coupon-grid.needs-coupon{border:1px solid rgba(196,122,44,.35);border-radius:8px;background:#fff7d7;padding:10px;box-shadow:0 0 0 3px #c47a2c1f}.coupon-card{display:grid;grid-template-columns:72px minmax(0,1fr);grid-template-rows:auto auto;gap:4px 12px;width:100%;border:1px solid rgba(27,27,31,.12);border-radius:8px;background:#fff;padding:10px;text-align:left;color:inherit;transition:border-color .18s ease,box-shadow .18s ease,transform .18s ease}.coupon-card:hover,.coupon-card.selected{border-color:#94714b;box-shadow:0 10px 24px #543a1e1f}.coupon-grid.needs-coupon .coupon-card{border-color:#c47a2c61;background:#fffdf3}.coupon-grid.needs-coupon .coupon-card:hover{border-color:#c47a2c;box-shadow:0 10px 24px #c47a2c33}.coupon-card.selected{border-color:#8c3215;background:#fff1d6;box-shadow:0 0 0 3px #c47a2c33}.coupon-card:hover{transform:translateY(-1px)}.coupon-card img{grid-row:1 / span 2;width:72px;height:96px;border-radius:4px;object-fit:cover;object-position:top;background:#ece7df}.coupon-card span,.coupon-card small{min-width:0}.coupon-card span{align-self:end;font-weight:800}.coupon-card small{color:#756b61}.primary-action{width:100%;border:0;border-radius:7px;background:#1c1b1a;color:#fff;font-weight:900;margin-top:18px;padding:14px 16px}.primary-action.ready{background:linear-gradient(90deg,#9d2d14,#c85d24);box-shadow:0 12px 28px #9d2d1447}.message{margin:12px 0 0;color:#684418;font-weight:700}.preview-panel{padding:18px}.panel-heading{margin-bottom:16px}.action-row{display:flex;flex-wrap:wrap;gap:10px;justify-content:flex-end}.action-row button{border:1px solid rgba(27,27,31,.18);border-radius:7px;background:#fff;color:#1b1b1f;font-weight:800;padding:10px 14px}.action-row.ready button{border-color:#9d2d1447;background:#fff0b8;color:#8d2308;box-shadow:0 8px 18px #9d2d1424}.action-row.ready button:hover{background:#ffe58a}.coupon-preview{display:grid;place-items:center;min-height:580px;overflow:auto;border-radius:8px;background:#24211f;padding:18px}.coupon-preview>img,.empty-preview>img{width:min(100%,760px);max-height:74vh;object-fit:contain;border-radius:3px;box-shadow:0 20px 45px #00000040}.empty-preview{display:grid;place-items:center;gap:14px;color:#f7efe5;text-align:center}.empty-preview div{display:grid;gap:4px}.empty-preview span{color:#d6c7b7}.empty-preview-text{min-height:320px}.history-panel{margin-top:22px;padding:18px}.history-panel h2{margin-bottom:12px}.history-table{display:grid;gap:8px}.history-head,.history-row{display:grid;grid-template-columns:120px minmax(220px,1fr) 150px 180px;padding:10px 12px}.history-head{color:#665f56;font-size:.85rem;font-weight:800}.history-row{border-radius:7px;background:#fff}.history-row span,.history-row strong{overflow-wrap:anywhere}.empty-history{margin:0;border-radius:7px;background:#fff;padding:12px;color:#665f56}@media(max-width:980px){.app-shell{padding:18px}.layout-grid{grid-template-columns:1fr}.control-panel{position:static}}@media(max-width:680px){.topbar,.panel-heading{align-items:flex-start;flex-direction:column}.coupon-preview{min-height:360px;padding:10px}.history-head{display:none}.history-row{grid-template-columns:1fr;gap:6px}}
