/* Application chrome and forms; game tables retain their spatial controls. */
:root{--ink:#382f26;--forest:#465e50;--forest2:#587463;--cream:#f5f1e9;--paper:#fffdf8;--line:#ded5c7;--muted:#7a6f61;--shadow:0 5px 20px #47321c08;--gold:#b59155}
body{font-family:"Noto Sans TC","Microsoft JhengHei",system-ui,sans-serif;background:#f3efe7;line-height:1.65}.shell{background:#f8f5ee;box-shadow:0 0 40px #47321c08}.topbar{background:#faf7f0f2;border-bottom:1px solid #e2dacd;padding:17px 20px}.brand{font-size:27px;letter-spacing:.035em}.eyebrow{font-size:10px;letter-spacing:.12em}.main{padding:22px 20px 110px}.card{border:1px solid var(--line);border-radius:18px;box-shadow:var(--shadow)}h1,h2,h3{letter-spacing:-.015em}h2{font-weight:650}button{font-weight:600;letter-spacing:0;border-radius:11px;box-shadow:none}button:hover{filter:none;background-color:var(--forest2)}button.secondary:hover,button.ghost:hover{background:#e5eade;color:#3d5546}.small{min-height:38px;font-size:12px}input,select,textarea{font:inherit;max-width:100%;border:1px solid #cfc4b3;border-radius:9px;background:#fffefa;padding:10px 12px;line-height:1.5;min-width:0;color:#443b31}input:focus,select:focus,textarea:focus{outline:2px solid #aa8a53;outline-offset:2px}textarea{resize:vertical}:focus-visible{outline:2px solid #a27e46;outline-offset:3px}.section-title{gap:14px;margin-top:26px;margin-bottom:16px;align-items:center}.section-title h2{font-size:21px}.section-title .muted{font-size:11px;line-height:1.6}.notice{background:#f2eddf;border:1px solid #e5d7bb;border-radius:12px;padding:14px 16px;font-size:12px;line-height:1.85;color:#766042}.field{font-size:12px;font-weight:600;gap:8px}.field input,.field select,.field textarea{font-weight:400}.field small{font-weight:400;color:#7f7669}.settings-group{border:1px solid #dfd6c8;border-radius:17px;padding:22px;background:#fffdf8;box-shadow:none}.settings-group h3{font-size:18px;font-weight:650}.settings-grid{gap:16px}.settings-grid .metric{background:#f5f0e5;border-radius:12px;border:1px solid #e6dcc9;padding:15px}.settings-grid .metric b{color:#645039;font-size:25px}.settings-group .notice{margin:12px 0 20px}.admin-header{border-color:#ded4c3;background:#fcf9f2}.admin-shell{background:#f6f2ea}.admin-nav button{font-size:13px;font-weight:600;border-radius:9px}.admin-nav button.active{background:#554635;color:#fff9ed}.admin-main table{border-collapse:separate;border-spacing:0;font-size:12px}.admin-main th{background:#eee7db;font-size:11px;font-weight:650;letter-spacing:.025em;color:#74624d}.admin-main td{border-bottom:1px solid #ebe3d6}.admin-main tr:hover td{background:#faf6ec}.modal-box{border-radius:20px;border:1px solid #e0d3bd;background:#fffcf6;padding:25px;box-shadow:0 25px 70px #31291b35;max-height:calc(100dvh - 40px)}.modal.open{background:#30261e88;backdrop-filter:blur(3px)}.modal-box h2{font-size:23px}.modal-box .action-row{gap:9px;margin-top:20px}.bottom-nav{background:#fcf9f1f5;backdrop-filter:blur(12px);border-top:1px solid #e0d6c5;box-shadow:0 -3px 15px #4a321207;padding-top:9px}.bottom-nav button{font-weight:500;border-radius:10px;transition:background .15s}.bottom-nav button.active{background:#e9e5d9;color:#415a46}.bottom-nav button:hover{background:#ece8dd}.hero{border-radius:20px}.hero-copy h1{letter-spacing:-.025em;line-height:1.3}.hero-copy p{line-height:1.85}.life-entry{font-size:12px!important;padding:10px 14px!important;border:1px solid #d8cbb0!important;border-radius:10px!important;background:#fff8e7!important;color:#655137!important}.community-card{border-color:#e1d7c7;border-radius:15px;box-shadow:none}.task-card,.task-row{border-color:#e2d8c9;border-radius:14px}.task-card h3{font-size:16px}.chat-compose textarea,.chat-form input{font-size:14px}.chat-message{border-radius:13px}.chat-bubble{box-shadow:none}.task-section-head{margin:24px 0 14px}.task-summary{box-shadow:none}.quest-entry{padding:24px;border:1px solid #dec9aa;background:#f5eddd;border-radius:18px}.quest-entry h2{font-size:26px;margin:6px 0 12px}.quest-entry p{font-size:13px;color:#7c684f;line-height:1.85}.quest-entry .entry-steps{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;padding:17px 0;margin:16px 0;border-top:1px solid #dfd1bc;border-bottom:1px solid #dfd1bc;list-style:none}.entry-steps li{font-size:12px;color:#665641}.entry-steps b{font-size:10px;display:block;color:#a18356;margin-bottom:4px}.quest-entry a{display:inline-flex;align-items:center;justify-content:center;min-height:46px;padding:11px 20px;border-radius:11px;background:#465e50;color:white;font-size:14px;font-weight:600;text-decoration:none}.quest-entry .muted{display:block;font-size:11px;margin-top:12px}.legacy-pot-label{display:block;padding:12px 15px;background:#eee8dc;color:#7a6548;border:1px solid #ded0b9;border-radius:12px;font-size:12px;margin:20px 0}.game-back{margin-bottom:16px}.hotpot-guide h1{font-weight:650}.feedback-form label{font-size:12px}.feed-cost-label{color:#946c44}
@media(max-width:480px){.main{padding:18px 14px 105px}.topbar{padding:14px 16px}.brand{font-size:24px}.card{border-radius:16px}.modal-box{padding:23px 19px;max-height:calc(100dvh - 28px)}.modal-box input,.modal-box select,.modal-box textarea{font-size:16px}.settings-group{padding:18px 15px}.settings-grid{gap:12px}.section-title h2{font-size:19px}.quest-entry{padding:22px 18px}.quest-entry h2{font-size:24px}.quest-entry .entry-steps{grid-template-columns:1fr 1fr;gap:13px}.quest-entry a{width:100%}.bottom-nav button{font-size:11px}.small{min-height:40px}}
@media(prefers-reduced-motion:reduce){button{transition:none}}
.admin-nav{background:#463b30;border:1px solid #5e4e3c}.admin-nav button.on{background:#f4e7cc1f;color:#fff5e0}.admin-nav button:hover{background:#f4e7cc15;color:#fff5e0}
[data-market-fee-summary] .section-title{flex-wrap:wrap;margin-top:0}[data-market-fee-summary] .stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:20px 0 14px}[data-market-fee-summary] .stat{display:flex;flex-direction:column;gap:7px;padding:16px;border:1px solid #e2d8c9;border-radius:12px;background:#f5f0e6;min-width:0}[data-market-fee-summary] .stat strong{font-size:28px;line-height:1.2;font-variant-numeric:tabular-nums;color:#365344;overflow-wrap:anywhere}[data-market-fee-summary] .stat span{font-size:12px;line-height:1.5;color:#71624f}[data-market-fee-summary] .stat:first-child{background:#284d3d;border-color:#284d3d}[data-market-fee-summary] .stat:first-child strong{color:#fff9e9}[data-market-fee-summary] .stat:first-child span{color:#e5e9d9}@media(max-width:480px){[data-market-fee-summary] .stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}[data-market-fee-summary] .stat:first-child{grid-column:1/-1}}
/* Shop scrolling is confined to the window, preserving the farm behind it. */
html.farm-shop-open{overflow:hidden;scrollbar-gutter:stable}
#modal.open:has([data-repeat-shop]){inset:var(--shop-visible-top,0px) 0 auto;height:var(--shop-visible-height,100dvh);box-sizing:border-box;align-items:flex-start;padding:10px 12px;overscroll-behavior:contain}
#modal:has([data-repeat-shop]) .modal-box{max-height:100%;box-sizing:border-box;overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable;padding:16px}
#modal [data-repeat-shop]>.fc-section-title{position:sticky;top:-16px;z-index:2;background:#fffcf6;margin-top:0;padding:10px 0;border-bottom:1px solid #e2d5bd}
#modal [data-repeat-shop] input{font-size:18px;min-height:44px}
.result-event-details{grid-column:1/-1;font-size:11px}.result-event-details summary{min-height:36px;padding:7px 0;cursor:pointer}.result-event-details ol{list-style:none;padding:0;margin:5px 0;max-height:220px;overflow-y:auto}.result-event-details li{display:flex;justify-content:space-between;gap:12px;border-top:1px solid #d6c49e;padding:7px 0}.result-event-details li span{overflow-wrap:anywhere}.result-event-details li b{white-space:nowrap}.result-event-card:has(.result-event-details[open]){align-items:flex-start}.result-event-card .result-event-copy{min-width:0}.result-event-card:has(.result-event-details[open]) .coin-change{padding-top:3px}
@media(max-width:700px){.shrimp-seat button,.shrimp-actions button,.shrimp-controls button,.entertainment-card button{min-height:44px!important}.shrimp-seat :is(.seat-name,.seat-caption,.shrimp-seat-name){background:#243b2ded;color:#fff;border-radius:7px;padding:4px 7px;text-shadow:none}.shrimp-seat button{background:#fff7df!important;color:#294333!important;border:1px solid #c9c6a1!important}.entertainment-card .entertainment-copy,.entertainment-card .entertainment-caption{background:#fff8e9eb;border-radius:12px;padding:10px;color:#3f4c36}.result-event-card{max-width:calc(100vw - 24px)}.result-event-card h3{font-size:13px}.result-event-card p{font-size:11px}.result-event-details summary{min-height:44px}}
@media(max-width:700px){.game-portal button,button.shrimp-seat{min-height:44px!important}.game-portal{background-color:#fcf4e4!important;color:#344933!important}.game-portal p{background:#fcf4e4e8;border-radius:8px;padding:7px;font-size:12px;line-height:1.6;color:#344933!important}.game-portal h2{text-shadow:none!important;color:#344933!important}.shrimp-seat>small,.shrimp-seat>b{background:#243b2dea;color:#fff;padding:3px 6px;border-radius:6px}.shrimp-seat>small{line-height:1.5}.shrimp-seat button{min-height:44px!important;font-size:12px!important}}

@media(max-width:700px){
 .shrimp-page .shrimp-seat.compact-seat{width:76px;min-width:76px;min-height:48px}
 .shrimp-page .shrimp-seat.compact-seat>b{font-size:11px;line-height:14px;white-space:normal;padding:4px 3px}
 .shrimp-page .shrimp-seat>small{color:#fff!important;font-size:10px;line-height:13px;white-space:normal}
}
