@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');
:root{font-family:Manrope,system-ui,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;color:#f5f0e7;background:#101b1a;font-synthesis:none}*{box-sizing:border-box}body{margin:0;min-width:320px}button{font:inherit;cursor:pointer}button:disabled{opacity:.38;cursor:not-allowed}.app{min-height:100dvh;display:flex;flex-direction:column;max-width:1550px;margin:auto;padding:0 26px}.topbar{height:84px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #ffffff18}.brand{display:flex;align-items:center;gap:11px}.brandmark{display:grid;place-items:center;width:39px;height:39px;border:1px solid #d7b97380;border-radius:12px;color:#e7c87f;font-size:27px}.brand strong{display:block;letter-spacing:.24em;font-size:17px}.brand small{color:#9da9a4;font-size:10px;letter-spacing:.08em}.top-actions{display:flex;gap:10px}.text-button{color:#d8dcd3;background:#ffffff0b;border:1px solid #ffffff17;padding:10px 15px;border-radius:10px;font-size:12px;font-weight:700}.text-button:hover{background:#ffffff1c}.game{width:100%;flex:1;display:grid;grid-template-columns:238px minmax(0,1fr) 270px;gap:22px;padding:24px 0 14px;align-items:stretch}.scoreboard,.controls{min-width:0}.scoreboard{background:#182925;border:1px solid #ffffff13;border-radius:18px;padding:19px;align-self:start}.score-heading,.hand-heading{display:flex;justify-content:space-between;align-items:center;color:#bbcaaf;font-size:10px;letter-spacing:.15em;font-weight:800}.score-heading span:last-child{color:#8fa29a;letter-spacing:0}.score-list{margin-top:19px;display:grid;gap:10px}.score-row{border:1px solid #ffffff12;background:#ffffff08;padding:12px;border-radius:12px}.score-row.active{border-color:#d4b36b70;background:#bc965a12}.score-row-top{display:flex;justify-content:space-between;gap:8px;align-items:center}.score-name{font-size:12px;font-weight:800}.score-num{color:#eed69e;font-weight:800;font-size:23px}.score-sub{font-size:10px;color:#9aaba3;margin-top:3px}.progress{height:4px;border-radius:6px;background:#ffffff15;margin-top:10px;overflow:hidden}.progress span{display:block;height:100%;background:#ddbd73;border-radius:6px}.score-guide{margin-top:20px;padding-top:16px;border-top:1px solid #ffffff18;color:#a6b7ad;font-size:11px;line-height:1.65}.score-guide strong{display:block;color:#e5d7b8;font-size:11px;margin-bottom:4px}.table-frame{min-height:610px;background:#473b2a;border:1px solid #a58450;border-radius:34px;padding:12px;box-shadow:0 20px 50px #0006,inset 0 0 0 3px #271e18}.felt{height:100%;min-height:584px;border-radius:24px;background:radial-gradient(circle at 50% 40%,#245047 0,#1a3b35 55%,#13302c 100%);border:1px solid #c39b5680;box-shadow:inset 0 0 70px #0617138a;display:flex;flex-direction:column;padding:23px;overflow:hidden}.opponent-area{min-height:95px;display:flex;justify-content:center;gap:9px;flex-wrap:wrap;align-items:start}.opponent{display:flex;align-items:center;gap:9px;padding:8px 11px;border:1px solid #ffffff22;border-radius:13px;background:#0b2926a8;min-width:130px}.opponent.active{border-color:#e0bd71;background:#b89b5724}.avatar{height:31px;width:31px;border-radius:9px;background:#d3b574;color:#1e302c;display:grid;place-items:center;font-weight:800;font-size:13px}.opponent strong,.opponent small{display:block}.opponent strong{font-size:11px}.opponent small{font-size:10px;color:#a4bdb4;margin-top:2px}.back-fan{display:flex;margin-left:auto;padding-left:8px}.back-fan i{height:26px;width:18px;margin-left:-8px;border:2px solid #d8c8a8;border-radius:4px;background:repeating-linear-gradient(45deg,#6d3938 0 3px,#e4c9a6 3px 5px);transform:rotate(8deg)}.table-heading{display:flex;justify-content:space-between;gap:15px;align-items:start}.eyebrow{color:#c7b582;letter-spacing:.2em;font-weight:800;font-size:10px}.table-heading h1{font-size:22px;line-height:1.25;margin:7px 0 4px}.table-heading p{color:#aac1b5;font-size:12px;margin:0}.deck-counter{display:flex;align-items:center;gap:8px;border:1px solid #ffffff28;background:#08241fb0;padding:8px 11px;border-radius:12px}.mini-deck{height:35px;width:25px;display:grid;place-items:center;border-radius:4px;border:2px solid #cab48b;color:#e8d6b3;background:repeating-linear-gradient(45deg,#70443e 0 3px,#8a5350 3px 6px)}.deck-counter strong,.deck-counter small{display:block}.deck-counter strong{font-size:15px}.deck-counter small{font-size:9px;color:#9ab3aa}.table-cards{flex:1;align-content:center;display:flex;flex-wrap:wrap;gap:12px;justify-content:center;align-items:center;overflow:auto;padding:16px 4px;min-height:210px}.empty-table{border:1px dashed #ffffff39;border-radius:16px;padding:34px 25px;text-align:center;color:#afc1b8;font-size:12px}.card{width:75px;height:109px;flex:none;border:1px solid #d5cec0;border-radius:9px;background:#f7f4eb;color:#242b2a;box-shadow:0 6px 12px #071c1890;position:relative;display:flex;align-items:center;justify-content:center;transition:transform .15s,box-shadow .15s,border-color .15s;user-select:none;padding:0}.card.red{color:#b2433e}.card:hover:not(:disabled),.card.selected{transform:translateY(-7px);box-shadow:0 13px 20px #071c18a8;border-color:#e9c271}.card.selected{outline:3px solid #edca79;outline-offset:2px}.card .corner{position:absolute;top:8px;left:9px;display:flex;flex-direction:column;font-family:Georgia,serif;font-weight:700;font-size:16px;line-height:15px}.card .corner.bottom{left:auto;top:auto;right:9px;bottom:8px;transform:rotate(180deg)}.card .pip{font-family:Georgia,serif;font-size:37px}.card .pip.figure{font-size:30px}.table-cards .card{cursor:pointer}.table-cards .card:not(.selectable){cursor:default}.table-cards .card:not(.selectable):hover{transform:none;box-shadow:0 6px 12px #071c1890}.build-card{position:relative;display:flex;flex-direction:column;justify-content:center;align-items:center;width:109px;height:109px;border:2px solid #d8b978;border-radius:13px;color:#f7e3a8;background:linear-gradient(145deg,#876439,#4b573c);box-shadow:0 6px 12px #061813b0}.build-card.selectable{cursor:pointer}.build-card.selected{outline:3px solid #fff2af;outline-offset:3px}.build-card strong{font-size:23px}.build-card small{font-size:10px}.build-card em{font-style:normal;font-size:10px;margin-top:3px}.table-footer{border-top:1px solid #ffffff24;padding-top:13px;display:flex;justify-content:space-between;gap:10px;color:#c8d7cd;font-size:11px}.pile-icon{color:#ebd086}.deal-indicator{color:#a8bbb0}.controls{display:flex;flex-direction:column;align-self:stretch;padding-top:8px}.hand-heading{gap:8px}.hand-heading span:last-child{text-align:right;letter-spacing:0;color:#9ea99d}.hand{display:flex;flex-wrap:wrap;gap:8px;margin-top:22px;margin-bottom:20px;align-content:start;min-height:252px}.hand .card{width:70px;height:103px}.actionbar{display:grid;gap:9px}.action{min-height:44px;border-radius:10px;border:1px solid transparent;font-weight:800;font-size:12px}.action.primary{background:#e2c47d;color:#18322c}.action.primary:hover:not(:disabled){background:#f1d790}.action.secondary{color:#f1d5a0;background:#b18a4c24;border-color:#c9aa6a66}.action.secondary:hover:not(:disabled){background:#bd995548}.action.ghost{color:#dce4d8;background:#ffffff10;border-color:#ffffff24}.action.ghost:hover:not(:disabled){background:#ffffff1b}.action-hint{color:#a3b4a9;font-size:11px;line-height:1.6;min-height:55px;margin-top:15px}.action-hint b{color:#eed38e}footer{display:flex;justify-content:space-between;gap:15px;color:#7e918a;font-size:10px;padding:15px 0 22px}.modal-scrim{position:fixed;inset:0;background:#071412cf;z-index:10;display:flex;align-items:center;justify-content:center;padding:18px;backdrop-filter:blur(8px)}.modal-scrim[hidden]{display:none}.modal-card{background:#f5f0e6;color:#24342f;width:min(100%,470px);max-height:min(90dvh,760px);overflow:auto;border-radius:23px;padding:29px;box-shadow:0 28px 90px #0008}.modal-kicker{color:#a67f3d;letter-spacing:.18em;font-size:10px;font-weight:800}.modal-card h2{font-size:27px;line-height:1.18;margin:8px 0 10px;letter-spacing:-.04em}.modal-card p{font-size:13px;line-height:1.65;color:#5f7068}.choice-label{display:block;font-size:11px;font-weight:800;margin:24px 0 9px;letter-spacing:.08em}.choice-row{display:flex;gap:8px}.choice{flex:1;border:1px solid #c9d1c9;background:#fff;border-radius:11px;padding:12px;color:#385046;font-weight:800}.choice.active{background:#284b40;color:#fff;border-color:#284b40}.mode-row{margin-top:15px;display:flex;gap:10px;align-items:start}.mode-row input{accent-color:#284b40;margin-top:4px}.mode-row label{font-size:12px;font-weight:800}.mode-row small{display:block;color:#697870;font-weight:400;margin-top:2px}.modal-main{width:100%;background:#d9ba78;border:0;border-radius:12px;padding:15px;color:#25372e;font-weight:800;margin-top:24px}.modal-secondary{width:100%;background:transparent;border:0;color:#465a4f;font-weight:700;padding:12px;margin-top:3px}.rule-grid{display:grid;grid-template-columns:1fr 1fr;gap:7px;margin:18px 0}.rule-chip{background:#e8e8dc;padding:11px;border-radius:9px;font-size:11px;line-height:1.5}.rule-chip b{display:block;color:#25483c}.rules-list{padding-left:19px;color:#495b50;font-size:12px;line-height:1.7}.rules-list li{margin-bottom:7px}.note{background:#fff3d8;border-left:3px solid #c4974b;border-radius:5px;padding:10px;font-size:11px;line-height:1.55;color:#6b5b3d}.result-row{display:flex;justify-content:space-between;border-bottom:1px solid #d7ddd3;padding:11px 0;font-size:13px}.result-row strong{font-size:17px}.toast{position:fixed;bottom:24px;left:50%;transform:translateX(-50%);z-index:30;background:#e9c87f;color:#24362d;border-radius:10px;padding:12px 17px;font-size:12px;font-weight:800;box-shadow:0 10px 30px #0005;max-width:90vw;text-align:center}.toast[hidden]{display:none}
@media(max-width:1100px){.game{grid-template-columns:190px minmax(0,1fr);gap:15px}.controls{grid-column:1/-1;display:block}.hand{min-height:0;justify-content:center;flex-wrap:nowrap;overflow-x:auto;padding:9px 4px;margin:10px 0 5px}.actionbar{grid-template-columns:repeat(3,1fr)}.action-hint{text-align:center;margin:8px 0 0;min-height:0}.table-frame{min-height:490px}.felt{min-height:464px}}
@media(max-width:650px){.app{padding:0 12px}.topbar{height:67px}.brandmark{height:33px;width:33px}.brand strong{font-size:13px}.brand small{font-size:9px}.top-actions{gap:5px}.text-button{padding:8px 7px;font-size:10px}.game{display:flex;flex-direction:column;gap:12px;padding-top:12px}.scoreboard{padding:10px 12px;width:100%}.score-heading{font-size:9px}.score-list{margin-top:8px;display:flex;gap:8px;overflow-x:auto}.score-row{min-width:105px;flex:1;padding:8px}.score-name{font-size:10px}.score-num{font-size:18px}.score-sub,.score-guide{display:none}.progress{margin-top:5px}.table-frame{min-height:370px;border-radius:21px;padding:7px}.felt{min-height:350px;border-radius:15px;padding:12px}.opponent-area{min-height:69px;gap:5px}.opponent{min-width:95px;gap:5px;padding:5px 6px}.avatar{width:23px;height:23px;font-size:10px}.opponent strong{font-size:9px}.opponent small{font-size:8px}.back-fan i{height:21px;width:13px;margin-left:-7px}.eyebrow{font-size:8px}.table-heading h1{font-size:18px;margin:4px 0}.table-heading p{font-size:10px}.deck-counter{padding:5px 6px}.mini-deck{width:20px;height:28px}.table-cards{min-height:155px;gap:7px;padding:8px 0}.table-cards .card{width:48px;height:72px}.card .corner{top:5px;left:5px;font-size:11px;line-height:10px}.card .corner.bottom{bottom:5px;right:5px}.card .pip{font-size:25px}.card .pip.figure{font-size:20px}.build-card{width:74px;height:74px}.build-card strong{font-size:18px}.build-card small,.build-card em{font-size:8px}.table-footer{font-size:9px;padding-top:8px}.controls{padding:2px 0 0}.hand-heading{font-size:9px}.hand{justify-content:start;min-height:111px}.hand .card{width:61px;height:91px}.actionbar{gap:5px}.action{min-height:43px;font-size:11px}.action-hint{font-size:10px}footer{font-size:9px;padding-top:4px}.modal-card{padding:23px}}
.table-cards .card.selectable:not(.selected),.table-cards .build-card.selectable:not(.selected){box-shadow:0 0 0 2px #e3c373,0 6px 12px #071c1890}
.hint-toggle{border:1px solid #8b9f8f5c;background:#294138;color:#dcead9;border-radius:9px;padding:8px 10px;font-size:10px;font-weight:800;letter-spacing:0;white-space:nowrap}.hint-toggle[aria-pressed="true"]{border-color:#e0c17a88;color:#f5dda2;background:#ae8b4d24}.hint-toggle b{margin-left:4px}.hand-status{color:#9ea99d;font-size:10px;display:block;margin-top:8px;min-height:15px}.hint-panel{border:1px solid #d3b57066;background:#273b3199;border-radius:13px;padding:11px;margin:4px 0 15px}.hint-panel[hidden]{display:none}.hint-title{font-size:10px;color:#ead29d;font-weight:800;letter-spacing:.1em;margin:0 0 7px}.hint-intro{color:#b7c7b6;font-size:11px;line-height:1.5;margin:0}.hint-choice{width:100%;display:flex;align-items:start;gap:8px;text-align:left;background:#ffffff0b;color:#ecf0e6;border:1px solid #ffffff18;border-radius:10px;padding:9px 7px;margin-top:6px}.hint-choice:hover,.hint-choice.active{background:#d9be7830;border-color:#e5c88199}.hint-number{flex:none;width:19px;height:19px;border-radius:50%;display:grid;place-items:center;background:#e0c17a;color:#20392f;font-size:10px;font-weight:800}.hint-choice strong{font-size:10px;line-height:1.4;display:block}.hint-choice small{display:block;color:#b2c4b6;font-size:9px;line-height:1.5;margin-top:3px}.hint-choice>span:last-child{min-width:0}.hint-more{color:#a9bbaa;font-size:9px;margin:8px 2px 1px}.last-take{margin-top:auto;padding-top:15px;border-top:1px solid #ffffff20}.last-take-button{display:block;text-align:left;width:100%;background:#ffffff08;border:1px solid #ffffff17;color:#e9eee5;border-radius:12px;padding:11px}.last-take-button:hover{background:#ffffff13}.last-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;color:#ddc589;font-size:10px;font-weight:800;letter-spacing:.08em}.last-description{font-size:11px;display:block;margin:6px 0;color:#b9cabd}.last-cards{display:flex;align-items:center;gap:3px;overflow:hidden;min-height:42px}.last-cards .card{width:28px;height:39px;border-radius:4px;box-shadow:none}.last-cards .card .corner{font-size:8px;top:3px;left:3px;line-height:8px}.last-cards .card .corner.bottom{display:none}.last-cards .card .pip{font-size:14px}.last-cards .card .pip.figure{font-size:12px}.last-plus{font-size:11px;color:#e9cf91;font-weight:800;margin-left:4px}.last-empty{color:#98aca1;font-size:10px;line-height:1.5;margin:7px 0 1px}.take-detail{display:flex;flex-wrap:wrap;gap:7px;margin:15px 0}.take-detail .card{width:57px;height:82px;box-shadow:0 4px 12px #0002}.take-detail .card .pip{font-size:29px}.take-detail .card .pip.figure{font-size:24px}.take-detail .card .corner{font-size:12px;line-height:11px}.take-caption{font-size:11px;font-weight:800;color:#6c806f;display:block;margin-top:12px}.motion-layer{position:fixed;inset:0;pointer-events:none;z-index:25;overflow:hidden}.motion-ghost{position:fixed;box-shadow:0 17px 32px #0008!important;will-change:transform,opacity;transform-origin:center;pointer-events:none}.move-flash{position:fixed;z-index:28;left:50%;top:40%;transform:translate(-50%,-50%);padding:12px 18px;border-radius:12px;background:#f0cf84;color:#173127;font-weight:800;font-size:15px;box-shadow:0 12px 34px #0008;pointer-events:none;animation:flash-enter .9s ease-out forwards}@keyframes flash-enter{0%{opacity:0;transform:translate(-50%,-40%) scale(.8)}25%,72%{opacity:1;transform:translate(-50%,-50%) scale(1)}100%{opacity:0;transform:translate(-50%,-65%) scale(1.04)}}
@media(max-width:1100px){.last-take{margin-top:12px}.hint-panel{margin-top:10px}.hand-status{margin-top:5px}}
@media(max-width:650px){.hint-panel{padding:9px;margin:8px 0}.hint-choice{padding:9px}.hint-choice strong{font-size:11px}.last-take{padding-top:9px}.last-cards .card{width:31px;height:43px}.hand{margin-top:7px}.hand-heading{align-items:center}.hint-toggle{font-size:9px;padding:7px 8px}}
@media(prefers-reduced-motion:reduce){.card{transition:none}.move-flash{animation:none}}
.table-cards .card.recommended:not(.selected),.table-cards .build-card.recommended:not(.selected){box-shadow:0 0 0 3px #f0d789,0 0 22px #e5c26c8c;animation:recommended-pulse 1.9s ease-in-out infinite}@keyframes recommended-pulse{50%{box-shadow:0 0 0 2px #f0d789,0 0 8px #e5c26c70}}.hand .card.dealt{animation:deal-in .42s cubic-bezier(.2,.8,.3,1) both}@keyframes deal-in{from{opacity:0;transform:translate(45px,-28px) rotate(9deg) scale(.85)}to{opacity:1;transform:translate(0,0) rotate(0deg) scale(1)}}
@media(prefers-reduced-motion:reduce){.table-cards .card.recommended,.table-cards .build-card.recommended,.hand .card.dealt{animation:none}}
.lottery-layout{display:grid;grid-template-columns:110px 1fr;gap:12px;margin-top:16px}.lottery-table,.lottery-stage{min-height:160px;border:1px solid #c9d0c4;background:#e8eadf;border-radius:13px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:10px}.lottery-table>span,.lottery-stage strong{font-size:10px;font-weight:800;color:#4e6859;text-align:center}.lottery-table .card{width:52px;height:76px;box-shadow:0 3px 8px #0002}.lottery-table .card .corner{font-size:11px;line-height:10px}.lottery-table .card .pip{font-size:24px}.lottery-table .card .corner.bottom{display:none}.lottery-empty{border:1px dashed #7d9984;border-radius:8px;width:52px;height:76px;display:grid;place-items:center;color:#7d9984}.lottery-stage .card{width:73px;height:104px;box-shadow:0 6px 14px #0003}.lottery-stage small{color:#9b7538;font-size:9px;font-weight:800}.lottery-back{width:70px;height:100px;display:grid;place-items:center;color:#f5e6c4;border:3px solid #e3cfaa;border-radius:9px;background:repeating-linear-gradient(45deg,#754942 0 5px,#945e52 5px 10px);font-size:32px}.lottery-flip{animation:lottery-flip .28s ease-out}@keyframes lottery-flip{from{opacity:.25;transform:rotateY(80deg) translateY(-12px)}to{opacity:1;transform:rotateY(0) translateY(0)}}.lottery-progress{text-align:center;font-size:10px;color:#758376;margin-top:10px}.opening-preview{display:grid;place-items:center;background:#e6e9dd;border:1px dashed #bac6b6;border-radius:13px;padding:16px;margin:15px 0}.opening-preview .card{width:86px;height:124px;box-shadow:0 8px 18px #0003}.opening-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}.opening-actions .modal-main{margin:0;min-height:54px;padding:10px;font-size:11px}.modal-outline{border:1px solid #426c52;border-radius:12px;background:transparent;color:#305b42;font-size:11px;font-weight:800;padding:10px}.modal-outline:hover{background:#e3e9db}.opening-note{font-size:11px!important;margin-top:13px}.opening-thinking{text-align:center;color:#6c7b70;font-size:12px;font-weight:800;min-height:54px;padding:16px}.table-cards .card.opening-dealt{animation:deal-in .42s cubic-bezier(.2,.8,.3,1) both}
@media(max-width:650px){.opening-actions{grid-template-columns:1fr}.opening-actions .modal-main,.modal-outline{min-height:47px}.lottery-layout{grid-template-columns:90px 1fr}.lottery-table,.lottery-stage{min-height:145px}}
@media(prefers-reduced-motion:reduce){.lottery-flip,.table-cards .card.opening-dealt{animation:none}}
.table-cards .card.first-opening-card{box-shadow:0 0 0 2px #ecd18d,0 6px 12px #071c1890}.table-cards .card.first-opening-card::after{content:'ПЕРВАЯ';position:absolute;top:-16px;left:50%;transform:translateX(-50%);font:800 9px Manrope,system-ui,sans-serif;letter-spacing:.05em;color:#efdb9d;white-space:nowrap;pointer-events:none}.table-cards .card.first-opening-card:hover{box-shadow:0 0 0 2px #ecd18d,0 6px 12px #071c1890}
.dealer-badge{display:inline-block;margin-top:8px;border-radius:100px;padding:5px 9px;background:#e1c27c1e;border:1px solid #dabe7c76;color:#efdaaa;font-size:10px;font-weight:800}
@media(max-width:650px){.dealer-badge{font-size:9px;padding:4px 7px;margin-top:5px}}
.opening-inline{display:flex;flex-direction:column;align-items:center;gap:7px;text-align:center;margin:10px auto 0;width:min(100%,480px);padding:13px 12px;background:#0d3029c9;border:1px solid #e2bf7466;border-radius:15px;box-shadow:0 9px 22px #06191255}.opening-inline[hidden]{display:none}.opening-inline-title{color:#f5d996;font-weight:800;font-size:12px}.opening-card-stage{display:grid;place-items:center;min-height:109px}.opening-inline-note{color:#bdcfc0;font-size:10px;line-height:1.4}.opening-inline-actions{display:flex;justify-content:center;gap:9px;width:100%}.opening-inline-actions button{border:1px solid #e2c47d;background:#e2c47d;color:#18322c;border-radius:10px;padding:10px 13px;font-weight:800;font-size:11px}.opening-inline-actions button+button{background:#24463d;color:#f6e5bf}.preview-placeholder{display:block;width:75px;height:109px;border:1px dashed #dac585;border-radius:9px}.table-cards.dealing-table{min-height:128px}.deal-slot{width:75px;height:109px;flex:none;border:1px dashed #c8d3bd55;border-radius:10px;display:grid;place-items:center}.deal-slot:has(.card){border-color:transparent}.deal-slot>.card{width:100%;height:100%}.deal-hand-slot{width:70px;height:103px;flex:none;border:1px dashed #b7c2b766;border-radius:9px;display:grid;place-items:center}.deal-hand-slot>.card,.deal-hand-slot>.deal-card-back{width:100%;height:100%}.deal-card-back{display:block;border:2px solid #e4d0aa;border-radius:9px;background:repeating-linear-gradient(45deg,#70443e 0 6px,#8a5350 6px 12px);box-shadow:0 6px 12px #071c1890}.motion-ghost.deal-card-back{position:fixed}.lottery-face{flex:none;color:#1e302c;background:#e7d2a3;border-radius:5px;padding:5px;font-family:Georgia,serif;font-weight:800;font-size:13px}@media(max-width:650px){.opening-inline{margin-top:6px;padding:9px;gap:5px}.opening-card-stage{min-height:72px}.opening-card-stage .card,.preview-placeholder{width:48px;height:72px}.opening-inline-note{font-size:9px}.opening-inline-actions button{padding:8px 11px}.deal-slot{width:48px;height:72px}.deal-hand-slot{width:61px;height:91px}.table-cards.dealing-table{min-height:94px}.lottery-face{font-size:10px}}
.deal-hand-display{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:9px;width:100%;min-height:150px;padding-top:10px}.deal-hand-stack,.opponent-stack{position:relative;display:block;flex:none;border:1px dashed #d1c99a7d;border-radius:8px}.deal-hand-stack{width:70px;height:103px}.opponent-stack{width:42px;height:60px;margin-left:auto}.deal-stack-layer{position:absolute;inset:0;display:block;transform:translate(calc(var(--pile-index) * 1.1px),calc(var(--pile-index) * -1.2px)) rotate(var(--pile-tilt));transform-origin:center;filter:drop-shadow(0 2px 2px #041c1780)}.deal-stack-layer .card,.deal-stack-layer .deal-card-back{width:100%;height:100%;border-radius:7px}.deal-stack-count{color:#d9c38b;font-size:11px;font-weight:800}.opponent-stack .card .corner,.deal-flying-card .corner{top:4px;left:4px;font-size:10px;line-height:9px}.opponent-stack .card .corner.bottom,.deal-flying-card .corner.bottom{left:auto;right:4px;top:auto;bottom:4px}.opponent-stack .card .pip,.deal-flying-card .pip{font-size:22px}.opponent-stack .card .pip.figure,.deal-flying-card .pip.figure{font-size:18px}.opponent-dealing{min-height:73px}.opponent-dealing .back-fan{display:none}@media(max-width:650px){.deal-hand-display{min-height:98px;padding-top:2px;gap:5px}.deal-hand-stack{width:48px;height:72px}.deal-stack-count{font-size:10px}.opponent-dealing{min-height:66px}.opponent-stack{width:38px;height:54px}.deal-hand-stack .card .corner{font-size:11px;line-height:10px;top:5px;left:5px}.deal-hand-stack .card .corner.bottom{left:auto;right:5px;top:auto;bottom:5px}.deal-hand-stack .card .pip{font-size:25px}.deal-hand-stack .card .pip.figure{font-size:20px}}
.opening-card-stage .opening-secret-card{width:75px;height:109px}.opening-secret-card{box-shadow:0 8px 18px #0005}@media(max-width:650px){.opening-card-stage .opening-secret-card{width:48px;height:72px}}
.build-card.locked-build{border-color:#f0d48b;background:linear-gradient(145deg,#856734,#385342)}.build-card.locked-build small{color:#fff0bb}.build-card.locked-build em{color:#f7e4aa}
.build-proposal{margin:14px 0 12px;padding:15px;border:1px solid #d7b973a8;border-radius:14px;background:#ddbd7321;display:grid;gap:9px;color:#f3ead5}.build-proposal[hidden]{display:none}.build-proposal strong{font-size:14px}.build-proposal span{font-size:12px;line-height:1.5;color:#d7e0d4}.proposal-actions{display:flex;gap:8px;flex-wrap:wrap}.proposal-actions button{padding:10px 12px;border-radius:9px;font-weight:800;font-size:12px}.proposal-actions button:first-child{border:1px solid #e5c982;background:#e4c780;color:#152724}.proposal-actions button:last-child{border:1px solid #e5c98270;background:transparent;color:#e9d8b2}
.build-card{width:122px;height:116px;justify-content:space-between;padding:10px 5px 7px;overflow:hidden}.build-card small{font-size:10px;font-weight:900;letter-spacing:.05em}.build-card em{font-size:9px;font-weight:800;margin:0;white-space:nowrap}.build-fan{display:flex;align-items:center;overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:none;max-width:100%;width:100%;min-height:54px;padding:3px 6px 5px}.build-fan::-webkit-scrollbar{display:none}.build-mini{flex:none;width:27px;height:43px;margin-left:-5px;padding:4px 2px;display:flex;flex-direction:column;align-items:flex-start;color:#24342e;background:#f8f4eb;border:1px solid #e6dcc7;border-radius:4px;box-shadow:1px 3px 5px #06181388;transform:rotate(var(--tilt));font:700 12px/1 Georgia,serif}.build-mini:first-child{margin-left:0}.build-mini.red{color:#b7443c}.build-mini b,.build-mini i{font:inherit}.build-mini i{font-size:11px}.build-card.locked-build .build-mini{color:#24342e}.build-card.locked-build .build-mini.red{color:#b7443c}@media(max-width:650px){.build-card{width:94px;height:98px;padding:7px 3px 5px}.build-card small{font-size:8px}.build-card em{font-size:8px}.build-fan{min-height:48px;padding:3px 3px}.build-mini{width:23px;height:37px;margin-left:-5px;font-size:11px;padding:3px 2px}.build-mini i{font-size:10px}}
.app{max-width:1440px}.topbar{height:64px}.brand small{font-size:11px}.scorebar{display:flex;align-items:center;justify-content:space-between;gap:12px;border-bottom:1px solid #ffffff1e;padding:10px 0}.score-summary{display:flex;align-items:center;gap:7px;overflow-x:auto;scrollbar-width:none;min-width:0}.score-summary::-webkit-scrollbar{display:none}.score-pill{display:flex;align-items:center;gap:8px;flex:none;padding:7px 10px;border:1px solid #e2bd7370;border-radius:9px;background:#d2aa5820;white-space:nowrap}.score-pill b{font-size:12px;font-weight:700}.score-pill strong{color:#f0d393;font-size:17px}.score-details-button{flex:none;border:1px solid #ffffff35;border-radius:9px;background:#ffffff10;color:#f5ead1;padding:9px 12px;font-size:12px;font-weight:800}.game{grid-template-columns:minmax(0,1fr) minmax(250px,300px);gap:16px;padding:14px 0}.controls{grid-column:auto}.hand{min-height:180px}.menu-options{display:grid;gap:8px;margin:18px 0}.menu-options button{background:#fff;border:1px solid #d4d8cd;border-radius:11px;text-align:left;padding:13px;color:#244338;font-size:14px;font-weight:750}.menu-options button:hover{background:#e8e8dc}.score-detail-row{border:1px solid #d6dfd4;border-radius:12px;padding:12px;margin:10px 0;background:#fff}.score-detail-row>div{display:flex;justify-content:space-between;align-items:center;gap:10px}.score-detail-row strong{font-size:23px;color:#977039}.score-detail-row p{margin:9px 0 0;font-size:12px}.score-detail-row p b{color:#3c553f;white-space:nowrap}.setting-item{display:flex;align-items:center;justify-content:space-between;gap:12px;border-bottom:1px solid #d6dfd4;padding:16px 4px;font-weight:750}.setting-item input{width:20px;height:20px;accent-color:#254b3e}.app>footer{display:none}
@media(max-width:1100px){.game{grid-template-columns:1fr;gap:12px}.controls{grid-column:1}.hand{min-height:0}.table-frame{min-height:480px}}
@media(max-width:650px){.app{padding:0 10px}.topbar{height:55px}.brandmark{width:31px;height:31px}.brand strong{font-size:13px}.brand small{font-size:10px}.text-button{font-size:12px;padding:7px 9px}.scorebar{padding:7px 0;gap:7px}.score-summary{gap:5px}.score-pill{gap:5px;padding:5px 7px}.score-pill b{font-size:11px}.score-pill strong{font-size:15px}.score-details-button{padding:7px 9px}.game{padding:8px 0 12px;gap:8px}.table-frame{min-height:clamp(330px,49dvh,470px)}.felt{min-height:clamp(315px,47dvh,455px)}.table-cards{min-height:clamp(120px,19dvh,210px)}.hand{min-height:0;margin:6px 0;padding:7px 4px}.controls{padding:0}.last-cards{display:none}.last-take-button{padding:9px}.last-take{padding-top:7px}}
.app[hidden],.front-screen[hidden]{display:none}.front-screen{min-height:100dvh;background:radial-gradient(ellipse at 50% 12%,#245045 0,#142c29 48%,#101b1a 90%);padding:0 18px;color:#f5f0e7}.front-inner{max-width:720px;margin:0 auto;min-height:100dvh;display:flex;flex-direction:column;padding-bottom:30px}.front-top{display:flex;justify-content:space-between;align-items:center;min-height:72px;border-bottom:1px solid #e2bb7330;gap:14px}.front-brand{font-weight:850;letter-spacing:.16em;color:#e8cf96;font-size:16px}.front-brand small{font-size:10px;color:#b9c6b5;letter-spacing:.08em;margin-left:8px}.front-back{color:#e2d5bb;border:1px solid #e9d49c5c;border-radius:10px;background:#ffffff12;padding:9px 12px;font-size:12px}.front-hero{text-align:center;margin:clamp(22px,5dvh,70px) 0 22px}.front-symbol{width:60px;height:60px;margin:auto;display:grid;place-items:center;border:1px solid #e1c681;border-radius:18px;color:#ead088;font-size:40px;box-shadow:0 0 50px #d7ba6c33}.front-hero h1{font-size:clamp(32px,6vw,52px);margin:12px 0 0;letter-spacing:-.04em}.front-hero p,.front-heading p{font-size:14px;color:#b6cbc0;line-height:1.55;margin:6px 0}.front-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.front-actions button{display:flex;flex-direction:column;gap:7px;min-height:100px;padding:18px;background:linear-gradient(130deg,#284a3e,#17342e);color:#f6ead0;border:1px solid #d6b57775;border-radius:18px;text-align:left;box-shadow:0 10px 25px #091b1780}.front-actions button:hover{background:linear-gradient(130deg,#315c4b,#214236)}.front-actions strong{font-size:18px}.front-actions span{font-size:12px;color:#bacdc0;line-height:1.45}.front-resume{margin-top:18px;width:100%;border:1px solid #e4c780;background:#dabc7f;color:#17352b;border-radius:12px;padding:14px;font-weight:800}.front-footer{margin-top:auto;padding-top:30px;color:#9cb3a5;font-size:11px;text-align:center}.front-heading{margin:25px 0 16px}.front-heading>span{font-size:11px;font-weight:800;letter-spacing:.12em;color:#d8ba7d}.front-heading h1{font-size:clamp(28px,5vw,38px);margin:7px 0}.front-box{padding:18px;margin-bottom:14px;border:1px solid #d8b7785e;border-radius:17px;background:#18332ed9}.front-box h2{font-size:17px;margin:0 0 13px;color:#f1d594}.front-box h2:not(:first-child){margin-top:18px}.front-choices{display:flex;flex-wrap:wrap;gap:8px}.front-choices button{border:1px solid #c5ba9780;background:#ffffff0d;border-radius:10px;color:#f2ecde;padding:11px 13px;font-size:13px;font-weight:750}.front-choices button.active{background:#dcbf7d;color:#19362c;border-color:#e8cc89}.front-choices small{display:block;color:#b2c5b5;font-size:10px;margin-top:5px}.front-choices .active small{color:#425b4c}.front-note{font-size:11px;line-height:1.5;color:#b8c9bb;margin:12px 0 0}.front-main{width:100%;border:0;border-radius:11px;background:#e0c27e;color:#19352d;font-weight:800;padding:13px;margin-top:17px}.front-main:disabled{background:#d6c9a3}.front-field{display:grid;gap:7px;color:#d8e1d6;font-size:12px;font-weight:750;margin-top:16px}.front-field input,.front-field select{width:100%;border:1px solid #c9d3c480;background:#102a25;color:#f3e9d3;border-radius:9px;padding:11px;font-size:14px}.front-field input::placeholder{color:#819a8c}.seat-list{display:grid;gap:8px}.seat{display:flex;align-items:center;gap:10px;padding:10px;border:1px solid #e0c57e57;border-radius:12px;background:#ffffff0d}.seat-number{flex:none;width:31px;height:31px;display:grid;place-items:center;border-radius:9px;background:#ddbe7b;color:#16362b;font-weight:900}.seat-info{min-width:0;flex:1}.seat-info strong,.seat-info small{display:block}.seat-info strong{font-size:13px}.seat-info small{font-size:11px;color:#acc0b4;margin-top:3px}.seat-add{flex:none;min-width:39px;min-height:37px;border:1px solid #e5c7829e;border-radius:8px;background:#ddc48022;color:#f8dfa0;font-size:16px}.seat-picker{margin-top:14px;padding:12px;border:1px solid #b6c8b063;border-radius:12px}.seat-picker h3{font-size:13px;margin:0 0 9px}.seat-picker .front-choices button{font-size:11px;padding:9px}.seat-remove{margin-top:12px;color:#d9e3d9;background:transparent;border:0;text-decoration:underline}.lobby-code{display:grid;gap:3px;padding:11px;border-radius:10px;background:#e2c47d19;border:1px dashed #d6ba75}.lobby-code span,.lobby-code small{font-size:10px;color:#c8d6c9}.lobby-code strong{letter-spacing:.2em;font-size:24px;color:#f1d594}.rating-preview>div{display:flex;justify-content:space-between;padding:14px 0;border-top:1px solid #ffffff1a;font-size:13px}.rating-preview b{color:#f0d394}.modal-card .music-field{color:#304b3e}.modal-card .music-field select{background:#fff;color:#304b3e;border-color:#c9d3c4}
@media(max-width:550px){.front-screen{padding:0 13px}.front-top{min-height:60px}.front-brand{font-size:13px}.front-brand small{display:block;margin:2px 0 0;font-size:9px}.front-back{font-size:11px;padding:7px}.front-hero{margin:21px 0 17px}.front-symbol{height:48px;width:48px;font-size:30px}.front-hero h1{font-size:34px}.front-actions{grid-template-columns:1fr;gap:8px}.front-actions button{min-height:69px;padding:11px 14px;gap:2px}.front-actions strong{font-size:16px}.front-actions span{font-size:11px}.front-heading{margin:17px 0 12px}.front-box{padding:13px}.front-choices button{font-size:12px;padding:10px}.front-footer{padding-top:18px;font-size:10px}}
.score-list{grid-template-columns:repeat(var(--score-columns,2),minmax(0,1fr));align-items:stretch;gap:6px}.score-row{display:flex;flex-direction:column;min-width:0;padding:9px}.score-row-top{align-items:flex-start;flex-wrap:wrap}.score-name{overflow-wrap:anywhere}.score-num{font-size:20px}.score-ledger{margin-top:9px;min-height:66px;max-height:210px;overflow-y:auto;border-top:1px solid #ffffff1b;border-bottom:1px solid #ffffff1b}.score-roundline{padding:7px 0;border-bottom:1px solid #ffffff0d;display:flex;flex-direction:column;gap:1px}.score-roundline small{font-size:9px;color:#aebeb0}.score-roundpoints{font-size:17px;font-weight:800;color:#f6ebd2;line-height:1}.pastura-marks{color:#ecc982;letter-spacing:-.16em;margin-left:5px;font-size:18px}.score-pending{display:block;font-size:9px;line-height:1.4;color:#91a69a;padding:10px 0}.score-sub{margin-top:auto;padding-top:8px}.score-guide{grid-column:1/-1;margin-top:2px;padding-top:10px}
@media(max-width:1100px){.score-list{display:grid;grid-template-columns:repeat(var(--score-columns,2),minmax(0,1fr))}}
@media(max-width:650px){.score-list{display:flex;gap:6px;overflow-x:auto}.score-row{min-width:100px;flex:1}.score-num{font-size:18px}.score-ledger{min-height:48px;max-height:90px}.score-guide{display:none}.score-sub{display:block;font-size:8px}}
.hand .card:disabled{opacity:1;cursor:default}

/* Each opponent keeps a fixed seat around the felt, independent of turn. */
.felt{position:relative}
.opponent-area{position:absolute;inset:12px;z-index:2;display:block;min-height:0;pointer-events:none}
.opponent{position:absolute;min-width:0;max-width:160px;box-shadow:0 7px 20px #061b1870}
.opponent.seat-top{top:0;left:50%;transform:translateX(-50%)}
.opponent.seat-left,.opponent.seat-right{top:51%;width:clamp(80px,13vw,120px);flex-direction:column;gap:4px;text-align:center;transform:translateY(-50%)}
.opponent.seat-left{left:0}.opponent.seat-right{right:0}
.opponent.seat-left .back-fan,.opponent.seat-right .back-fan{margin:2px auto 0}
.opponent.seat-left .opponent-stack,.opponent.seat-right .opponent-stack{margin:2px auto}
.opponent-area.seats-2~.table-heading,.opponent-area.seats-4~.table-heading{margin-top:76px}
.opponent-area.seats-3~.table-cards,.opponent-area.seats-4~.table-cards{padding-left:clamp(72px,13vw,130px);padding-right:clamp(72px,13vw,130px)}
@media(max-width:650px){
 .opponent-area{inset:8px;min-height:0}
 .opponent.seat-top{max-width:130px}
 .opponent.seat-left,.opponent.seat-right{width:75px;padding:5px 3px;top:52%}
 .opponent.seat-left strong,.opponent.seat-right strong{font-size:9px}
 .opponent.seat-left small,.opponent.seat-right small{font-size:8px;line-height:1.2}
 .opponent-area.seats-2~.table-heading,.opponent-area.seats-4~.table-heading{margin-top:64px}
 .opponent-area.seats-3~.table-cards,.opponent-area.seats-4~.table-cards{padding-left:68px;padding-right:68px}
}

/* In games with three or four seats, give labels, players and cards separate rows. */
.felt.multi-seats{display:grid;grid-template-columns:minmax(78px,1fr) minmax(0,4fr) minmax(78px,1fr);grid-template-rows:auto auto auto minmax(180px,1fr) auto;column-gap:10px;row-gap:12px;height:auto;align-items:stretch}
.felt.multi-seats .opponent-area{display:contents}
.felt.multi-seats .opponent{position:relative;top:auto;left:auto;right:auto;transform:none;align-self:center;justify-self:center;max-width:100%}
.felt.multi-seats .opponent.seat-top{grid-column:2;grid-row:1}
.felt.multi-seats .opponent.seat-left{grid-column:1;grid-row:4}
.felt.multi-seats .opponent.seat-right{grid-column:3;grid-row:4}
.felt.multi-seats .table-heading{grid-column:1/-1;grid-row:2;margin-top:0}
.felt.multi-seats .opening-inline{grid-column:1/-1;grid-row:3}
.felt.multi-seats .table-cards{grid-column:2;grid-row:4;min-width:0;padding:8px 0;overflow:visible}
.felt.multi-seats .table-footer{grid-column:1/-1;grid-row:5}
@media(max-width:650px){
 .felt.multi-seats{grid-template-columns:minmax(66px,1fr) minmax(0,3fr) minmax(66px,1fr);grid-template-rows:auto auto auto minmax(155px,1fr) auto;column-gap:5px;row-gap:9px}
 .felt.multi-seats .opponent.seat-left,.felt.multi-seats .opponent.seat-right{width:100%;max-width:78px}
 .felt.multi-seats .table-cards{min-height:155px;padding:6px 0}
 .felt.multi-seats .table-heading{gap:7px;min-width:0}
 .felt.multi-seats .table-heading>div:first-child{min-width:0}
 .felt.multi-seats .deck-counter{flex:none}
}

/* The score drawer floats over the table without stopping the live turn. */
.scorebar{position:relative;z-index:4;gap:8px}
.turn-clock{font-size:13px;font-weight:800;color:#dfc581;white-space:nowrap;font-variant-numeric:tabular-nums}
.turn-clock.urgent{color:#e6856a}
.score-panel[hidden]{display:none}
.score-panel{position:fixed;right:max(12px,env(safe-area-inset-right));top:calc(82px + env(safe-area-inset-top));z-index:12;width:min(390px,calc(100vw - 24px));max-height:min(70vh,650px);overflow:auto;background:#f4efe5;color:#21342e;border:2px solid #c49e65;border-radius:18px;padding:18px;box-shadow:0 16px 48px #0009}
.score-panel h2{margin:6px 0 12px}
.score-panel p{line-height:1.45;font-size:13px}
.score-panel .score-detail-row{border-block-start:1px solid #c6c8b7;padding:8px 0}
.score-panel #scorePanelClose{position:sticky;bottom:0;width:100%;padding:10px;border:0;border-radius:9px;background:#d9bd7f;color:#24332c;font-weight:800;cursor:pointer}
@media(max-width:700px){.score-panel{top:auto;bottom:calc(12px + env(safe-area-inset-bottom));max-height:48vh}.turn-clock{font-size:12px}.scorebar{flex-wrap:wrap}}
.modal-card .volume-control{display:grid;gap:7px;margin:12px 0 18px;color:#2d463c;font-weight:750;font-size:14px}
.volume-control span{display:flex;justify-content:space-between;gap:12px}
.volume-control output{font-variant-numeric:tabular-nums;color:#806332}
.volume-control input[type=range]{width:100%;accent-color:#ad874c;min-height:30px;cursor:pointer}
.turn-notice{position:fixed;z-index:31;left:50%;top:calc(13vh + env(safe-area-inset-top));transform:translateX(-50%);pointer-events:none;background:#e6ca83;color:#19362d;border:1px solid #fbebc0;border-radius:100px;box-shadow:0 8px 26px #071a16b0;padding:10px 19px;font-size:14px;font-weight:850;white-space:nowrap;animation:turn-notice-in 2.3s ease forwards}
@keyframes turn-notice-in{0%{opacity:0;transform:translate(-50%,-12px)}12%,78%{opacity:1;transform:translate(-50%,0)}100%{opacity:0;transform:translate(-50%,-6px)}}

.brandmark{overflow:hidden}.brandmark img{width:100%;height:100%;object-fit:cover;border-radius:inherit}.front-brand img{width:25px;height:25px;vertical-align:middle;border-radius:7px;margin-right:5px}.front-symbol{overflow:hidden}.front-symbol img{height:100%;width:100%;object-fit:cover;border-radius:inherit}

/* Compact rules are available from the main screen. */
.front-rules-link{align-self:center;display:block;margin:18px auto 2px;padding:10px 18px;border:1px solid #d6b57775;border-radius:11px;background:#d6b57712;color:#f1d594;font-size:15px;font-weight:750}
.front-rules-link:hover{background:#d6b5772e}
.rules-quick{color:#dce6da;font-size:15px;line-height:1.55}
.rules-quick p{margin:0 0 10px}
.rules-quick p:last-child{margin-bottom:0}
.rules-quick p b{color:#eed18e}
.rules-points{display:grid;gap:6px}
.rules-points>div{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:8px 11px;border:1px solid #d6b57733;border-radius:10px;background:#102822}
.rules-points b{font-weight:650}
.rules-points strong{flex:none;color:#f3d088;font-size:18px}
.rules-points .rules-special{border-color:#d6b57780;background:#7d653d2f}

/* Make the chosen lobby seat unmistakable before adding or changing a bot. */
.seat.selected{border-color:#e9c875;background:#b8974d30;box-shadow:inset 0 0 0 1px #e9c87590,0 0 0 2px #caa76125}
.seat.selected .seat-number{background:#f1d38c}
.seat.selected .seat-add{background:#e5c781;color:#19342c;border-color:#f6df9e;font-weight:900}
.seat .seat-selected-note{color:#f3d588;font-size:12px;font-weight:750}
.front-actions .front-online{display:flex;flex-direction:column;gap:7px;min-height:100px;padding:18px;background:linear-gradient(130deg,#d9bd7a,#a98a49);color:#102820;border:1px solid #f0d293;border-radius:15px;text-decoration:none;justify-content:center}.front-actions .front-online strong{font-size:18px}.front-actions .front-online span{font-size:12px}.front-actions .front-online:hover{filter:brightness(1.1)}@media(max-width:550px){.front-actions .front-online{min-height:70px;padding:11px 14px;gap:2px}}
.lobby-code{width:100%;text-align:left;color:inherit;font:inherit;cursor:pointer}.lobby-code:hover,.lobby-code:focus-visible{background:#e2c47d30;border-color:#f0d18c;outline:none}.lobby-code strong{letter-spacing:.12em;font-variant-numeric:tabular-nums}
