:root{font-family:system-ui,Avenir,Helvetica,Arial,sans-serif;line-height:1.5;font-weight:400;color-scheme:light dark;color:#ffffffde;background-color:#242424;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}a{font-weight:500;color:#646cff;text-decoration:inherit}a:hover{color:#535bf2}body{margin:0;display:flex;place-items:center;min-width:320px;min-height:100vh}h1{font-size:3.2em;line-height:1.1}button{border-radius:8px;border:1px solid transparent;padding:.6em 1.2em;font-size:1em;font-weight:500;font-family:inherit;background-color:#1a1a1a;cursor:pointer;transition:border-color .25s}button:hover{border-color:#646cff}button:focus,button:focus-visible{outline:4px auto -webkit-focus-ring-color}@media(prefers-color-scheme:light){:root{color:#213547;background-color:#fff}a:hover{color:#747bff}button{background-color:#f9f9f9}}.help-building-header{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap}.help-building-header h4{margin:0}.help-section-header{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap}.help-building-level-control{display:flex;align-items:center;gap:8px;font-size:.9rem}.help-building-level-control select{background:#0f172a99;border:1px solid rgba(99,102,241,.4);border-radius:8px;padding:6px 10px;color:#f8fafc;font-weight:600}.help-building-level-control select:focus{outline:none;border-color:#6366f1cc;box-shadow:0 0 0 2px #6366f140}.builder-select-label{display:flex;flex-direction:column;gap:6px;margin-bottom:8px;font-size:.9rem}.builder-select{background:#0f172a99;border:1px solid rgba(99,102,241,.4);border-radius:10px;padding:10px 12px;color:#f8fafc;font-weight:600;transition:border-color .15s ease,box-shadow .15s ease}.builder-select:focus{outline:none;border-color:#6366f1cc;box-shadow:0 0 0 2px #6366f140}.modal-card.danger .modal-footer{justify-content:space-between}body{font-family:Space Grotesk,Segoe UI,system-ui,-apple-system,BlinkMacSystemFont,sans-serif;background:radial-gradient(circle at top,#14213d,#0b1121 60%);min-height:100vh;height:100vh;margin:0;overflow:hidden}.map-tile-popup-overlay{position:fixed;inset:0;z-index:2500;display:flex;align-items:center;justify-content:center;background:#04070f8c;pointer-events:auto}.map-tile-popup{background:#080c18f2;border-radius:20px;padding:28px;width:min(420px,90vw);border:1px solid rgba(59,130,246,.35);box-shadow:0 25px 50px #020617a6;position:relative;pointer-events:auto}.tile-popup-close{position:absolute;top:16px;left:16px;border:none;background:#0f172acc;color:#f8fafc;border-radius:50%;width:32px;height:32px;cursor:pointer;font-size:1rem}.tile-popup-subtitle{margin-top:4px;color:#e2e8f0cc;font-size:.9rem}.tile-popup-section{margin-top:16px;padding-top:12px;border-top:1px solid rgba(148,163,184,.2)}.tile-popup-section h4{margin:0 0 8px;color:#cbd5f5}.tile-popup-yields{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:4px}.tile-popup-yields li,.tile-popup-section ul li{font-size:.9rem;color:#e2e8f0e6}.tile-popup-section ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:4px}.building-preview-wrapper{width:100%;min-height:260px;display:flex;align-items:center;justify-content:center}.building-preview{width:100%;height:260px}.building-preview canvas{width:100%!important;height:100%!important}.tile-building-status{margin:4px 0;font-size:.85rem;color:#e2e8f0d9}.tile-building-status.debuffed{color:#fcd34d;font-weight:600}.tile-popup-empty{margin:0;font-size:.85rem;color:#e2e8f0a6}.player-panel .unit-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px}.player-panel .unit-list button{width:100%;display:flex;justify-content:space-between;align-items:center;border-radius:10px;border:1px solid rgba(59,130,246,.4);background:#0f172ab3;color:#e2e8f0;padding:6px 10px;cursor:pointer}.player-panel .unit-list button.selected{border-color:transparent;background:linear-gradient(135deg,#3b82f6,#8b5cf6);color:#fff;box-shadow:0 0 12px #3b82f680}.player-panel .unit-list button span{font-size:.8rem;color:#e2e8f0cc}.tile-panel h5{margin:8px 0 4px;font-size:.85rem;color:#cbd5f5}.tile-panel ul{list-style:none;margin:0;padding:0;font-size:.8rem;color:#e2e8f0d9}.tile-panel li{padding:2px 0}#root{width:100%;height:100%}.app-shell{height:100vh;padding:32px clamp(16px,4vw,64px);color:#f8fafc;display:flex;flex-direction:column;gap:32px;box-sizing:border-box;overflow:hidden}.app-header{display:flex;align-items:center;justify-content:space-between}.app-header h1{font-size:clamp(1.8rem,4vw,2.6rem);letter-spacing:.08em;margin:0}.app-header .session{display:flex;align-items:center;gap:12px}.user-menu{position:relative}.user-menu-trigger{display:flex;align-items:center;gap:8px;background:#0f172ab3;color:#f8fafc;border:1px solid rgba(148,163,184,.3);border-radius:999px;padding:6px 12px;cursor:pointer;font-weight:600}.user-name{max-width:140px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.user-menu-chevron{font-size:.75rem;opacity:.8}.user-menu-dropdown{position:absolute;top:calc(100% + 8px);right:0;min-width:200px;display:flex;flex-direction:column;background:#04070ff2;border:1px solid rgba(59,130,246,.3);border-radius:12px;padding:8px;box-shadow:0 15px 30px #020617b3;z-index:100}.user-menu-dropdown button{background:none;border:none;cursor:pointer;font:inherit;color:inherit}.user-menu-dropdown button{padding:8px 10px;border-radius:8px;font-weight:500;cursor:pointer}.user-menu-dropdown button:hover{background:#3b82f633}.user-menu-dropdown button.danger{color:#fecaca}.user-menu-dropdown button.danger:hover{background:#b91c1c59}.app-header .session button{background:transparent;color:#f472b6;border:1px solid rgba(244,114,182,.5);padding:6px 12px;border-radius:8px;cursor:pointer;font-weight:600}.resources{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.resource{font-weight:600;font-size:.95rem;background:#0f172a99;border:1px solid rgba(148,163,184,.3);border-radius:999px;padding:4px 12px}.resource.clickable{cursor:pointer;border-color:#3b82f68c;box-shadow:0 0 0 1px #3b82f640;transition:transform .15s ease,box-shadow .15s ease,background .15s ease}.resource.clickable:hover,.resource.clickable:focus-visible{background:#3b82f633;box-shadow:0 5px 18px #3b82f659;transform:translateY(-1px);outline:none}.resource.clickable:focus-visible{box-shadow:0 0 0 3px #3b82f666}.trade-modal .modal-body{display:flex;flex-direction:column;gap:16px}.trade-form .helper-text{margin:0;font-size:.9rem;color:#e2e8f0d9}.trade-field-group{display:flex;flex-direction:column;gap:8px}.trade-field-group label{font-size:.9rem;font-weight:600;color:#e2e8f0e6}.pill-toggle{display:inline-flex;border-radius:999px;background:#0f172acc;border:1px solid rgba(148,163,184,.35);overflow:hidden}.pill-toggle button{border:none;background:transparent;color:#e2e8f0bf;padding:6px 16px;font-weight:600;cursor:pointer;transition:background .15s ease,color .15s ease}.pill-toggle button.active{background:linear-gradient(120deg,#3b82f6,#8b5cf6);color:#fff}.pill-toggle button:not(.active):hover{background:#3b82f633}.trade-field-group input[type=number]{background:#0f172ab3;border:1px solid rgba(99,102,241,.4);border-radius:10px;padding:10px 12px;color:#f8fafc;font-size:1rem}.trade-field-group input[type=number]:focus{outline:none;border-color:#6366f1cc;box-shadow:0 0 0 2px #6366f140}.panel.stats-panel{display:flex;flex-direction:column;gap:16px;max-height:60vh;overflow:hidden}.panel.stats-panel .stats-scroll{flex:1;overflow-y:auto;padding-right:4px;scrollbar-width:thin;scrollbar-color:rgba(59,130,246,.6) rgba(15,23,42,.6)}.panel.stats-panel .stats-scroll::-webkit-scrollbar{width:6px}.panel.stats-panel .stats-scroll::-webkit-scrollbar-track{background:#0f172a80;border-radius:999px}.panel.stats-panel .stats-scroll::-webkit-scrollbar-thumb{background:linear-gradient(180deg,#60a5fae6,#6366f1e6);border-radius:999px}.panel.stats-panel .panel-header button{background:#3b82f626;border:1px solid rgba(59,130,246,.4);color:#dbeafe;border-radius:8px;padding:6px 12px;cursor:pointer;font-weight:600}.panel.stats-panel .panel-header button:disabled{opacity:.6;cursor:not-allowed}.diplomacy-contact .contact-header{display:flex;flex-direction:column;gap:4px;margin-bottom:4px}.diplomacy-contact .contact-name{font-weight:600;letter-spacing:.02em}.diplomacy-contact .contact-date{font-size:.85rem;color:#e2e8f0bf}.diplomacy-contact .contact-meta{display:block;margin-bottom:8px;color:#e2e8f0b3}.stats-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:16px}.stats-grid section{background:#0f172a99;border:1px solid rgba(59,130,246,.25);border-radius:14px;padding:16px}.stats-grid h5{margin:0 0 8px;font-size:1rem;color:#e0e7ff}.account-settings-panel{display:flex;flex-direction:column;gap:24px}.account-settings-panel .settings-section{background:#0f172a80;border:1px solid rgba(59,130,246,.35);border-radius:16px;padding:18px;box-shadow:0 15px 30px #02061759}.account-settings-panel .settings-section h4{margin:0 0 6px}.account-settings-panel .settings-form{display:flex;flex-direction:column;gap:16px}.account-settings-panel .form-grid{display:grid;grid-template-columns:1fr;gap:12px}.account-settings-panel .password-grid{grid-template-columns:1fr}.account-settings-panel .form-field{display:flex;flex-direction:column;gap:6px;font-size:.85rem}.account-settings-panel .form-field input{background:#0f172abf;border:1px solid rgba(99,102,241,.35);border-radius:10px;padding:10px 12px;color:#f8fafc;font-size:.95rem}.account-settings-panel .form-field input::placeholder{color:#f8fafc8c}.account-settings-panel .form-field input:focus{outline:none;border-color:#6366f1bf;box-shadow:0 0 0 2px #6366f140}.account-settings-panel .settings-actions{display:flex;justify-content:flex-end}.account-settings-panel .settings-actions button{border:none;border-radius:999px;padding:10px 20px;font-weight:600;cursor:pointer;background:linear-gradient(135deg,#2563eb,#7c3aed);color:#fff;transition:opacity .15s ease}.account-settings-panel .settings-actions button:disabled{opacity:.6;cursor:not-allowed}.stats-table{width:100%;border-collapse:collapse;font-size:.9rem}.stats-table th,.stats-table td{text-align:left;padding:6px 8px}.stats-table thead{background:#60a5fa1f}.stats-table tbody tr:nth-child(odd){background:#0f172a59}.stats-table .positive{color:#34d399;font-weight:600}.stats-table .negative{color:#f87171;font-weight:600}.stats-count-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}.stats-count-list li{display:flex;justify-content:space-between;align-items:center;font-size:.95rem;padding:6px 0;border-bottom:1px solid rgba(148,163,184,.15)}.stats-count-list li:last-child{border-bottom:none}.stats-count-list .label{color:#e2e8f0d9;text-transform:capitalize}.stats-count-list .value{font-weight:700;color:#f8fafc}main{display:flex;justify-content:flex-start;flex:1;overflow:hidden}main.login-screen{flex:1;align-items:center;justify-content:center;min-height:60vh}.play-area{display:flex;gap:32px;flex-wrap:nowrap;justify-content:flex-start;align-items:flex-start;width:100%;margin:0;height:100%;overflow:hidden}.view-toggle{display:flex;gap:12px;justify-content:center;margin-bottom:16px}.map-column{display:flex;flex-direction:column;align-items:stretch;gap:16px;flex:1;min-width:0;max-width:calc(100% - 352px);height:100%;overflow:hidden;min-height:0}.map-views{width:100%;position:relative;flex:1;display:flex;min-height:0}.map-views.auto-ending{opacity:.35;pointer-events:none}.view-toolbar{display:flex;align-items:center;justify-content:space-between;width:100%;gap:16px}.camera-toggle{display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:.85rem}.camera-toggle span{opacity:.8}.camera-toggle button{background:#0f172a99;border:1px solid rgba(148,163,184,.3);border-radius:999px;padding:6px 12px;color:#e2e8f0;cursor:pointer;transition:all .2s ease;font-size:.8rem}.camera-toggle button.active{background:linear-gradient(135deg,#3b82f6,#8b5cf6);border-color:transparent;color:#fff}.map-view-panel{width:100%;height:100%;display:flex;flex-direction:column}.map-view-panel.hidden{position:absolute;pointer-events:none;opacity:0;width:0;height:0;overflow:hidden;display:none}.map-view-panel.active{position:relative;opacity:1;width:100%;height:100%;display:flex}.turn-popup-overlay{position:fixed;inset:0;display:flex;align-items:flex-start;justify-content:center;padding-top:48px;background:linear-gradient(180deg,#060a1647,#060a160d);z-index:2000;pointer-events:none}.turn-popup{background:#0a101cf2;border-radius:18px;padding:28px 36px;border:1px solid rgba(59,130,246,.4);box-shadow:0 25px 45px #020617b3;text-align:center;max-width:360px}.turn-popup h3{margin:14px 0 10px;font-size:1.25rem}.turn-popup p{margin:0;font-size:.95rem;color:#cbd5f5}.turn-popup-spinner{width:56px;height:56px;border-radius:50%;border:6px solid rgba(148,163,184,.25);border-top-color:#38bdf8;margin:0 auto;animation:turn-spin .9s linear infinite}@keyframes turn-spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.commands{width:min(320px,90vw);flex:0 0 320px;display:flex;flex-direction:column;gap:16px;background:#0c1220bf;padding:16px;border-radius:16px;border:1px solid rgba(59,130,246,.2);box-shadow:0 15px 30px #02061766;max-height:calc(100vh - 80px);overflow-y:auto}.commands::-webkit-scrollbar{width:8px}.commands::-webkit-scrollbar-thumb{background:#3b82f666;border-radius:999px}.commands::-webkit-scrollbar-track{background:transparent}.turn-control{display:flex;align-items:center;justify-content:space-between;padding:12px;border-radius:12px;background:#0f172abf;border:1px solid rgba(148,163,184,.2)}.turn-counter{font-size:.9rem;font-weight:600;color:#f8fafc}.turn-control button{margin-left:auto;border:none;border-radius:999px;padding:6px 14px;background:linear-gradient(135deg,#22c55e,#3b82f6);color:#fff;font-weight:600;cursor:pointer}.abandon-button{width:100%;margin:12px 0;border-radius:10px;border:1px solid rgba(248,113,113,.4);padding:10px 12px;background:#7f1d1d80;color:#fecaca;font-weight:600;cursor:pointer;transition:background .2s ease,transform .1s ease}.abandon-button:hover{background:#b91c1cb3;transform:translateY(-1px)}.command-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;background:#050c1dcc;border-radius:18px;padding:8px}@media(max-width:420px){.command-tabs{grid-template-columns:repeat(2,minmax(0,1fr))}}.command-tabs button{border:none;background:transparent;color:#cbd5f5;font-weight:600;border-radius:12px;padding:10px 12px;cursor:pointer;transition:background .2s ease;min-height:44px}.command-tabs button .tab-warning{display:inline-flex;align-items:center;justify-content:center;width:10px;height:10px;border-radius:50%;background:#f97316;margin-left:6px;box-shadow:0 0 8px #f9731699}.command-tabs button.active{background:linear-gradient(135deg,#3b82f6,#8b5cf6);color:#fff;box-shadow:0 4px 12px #3b82f666}.command-panels{display:flex;flex-direction:column;gap:16px}.panel{display:flex;flex-direction:column;gap:8px;padding:12px;border-radius:12px;border:1px solid rgba(148,163,184,.2);background:#0a101cb3}.research-panel .research-levels{display:flex;flex-direction:column;gap:4px;font-size:.85rem;color:#cbd5f5}.research-panel .research-progress .progress-bar{width:100%;height:8px;border-radius:999px;background:#94a3b833;overflow:hidden;margin:6px 0}.research-panel .research-progress .progress-value{height:100%;background:linear-gradient(135deg,#22d3ee,#6366f1)}.research-panel .research-idle{display:flex;flex-direction:column;gap:8px;font-size:.9rem;color:#cbd5f5}.research-panel .research-idle button{align-self:flex-start;border:none;border-radius:10px;padding:6px 12px;background:linear-gradient(135deg,#3b82f6,#8b5cf6);color:#fff;cursor:pointer}.research-choice-list{gap:10px}.research-choice-item{padding:0;background:#080d1ed9;border:1px solid rgba(148,163,184,.35);border-radius:12px;box-shadow:0 12px 25px #02061759}.research-choice-item .research-choice{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;padding:14px 16px}.research-choice-title{font-size:1.5rem;letter-spacing:.03em}.research-choice-description{display:block;margin-top:6px;color:#e2e8f0f2;font-size:1.25rem;line-height:1.5}.research-choice-metrics,.research-choice-cost,.research-choice-gain,.research-choice-perks{display:flex;flex-direction:column;gap:4px;margin-top:10px;font-size:1rem}.research-choice-cost strong,.research-choice-gain strong{font-size:1.1rem;color:#fbbf24}.research-choice-metrics span,.research-choice-perks span{color:#e2e8f0e6;font-size:.95rem}.research-choice-meta{display:block;margin-top:6px;color:#94a3b8;font-size:.9rem}.research-choice-hint{display:inline-block;margin-top:8px;padding:4px 8px;border-radius:999px;background:#3b82f62e;color:#dbeafe;font-size:.82rem}.research-choice button{flex-shrink:0;border:none;border-radius:10px;padding:10px 16px;font-weight:600;background:linear-gradient(135deg,#06b6d4,#6366f1);color:#fff;cursor:pointer;transition:transform .15s ease,box-shadow .15s ease}.research-choice button:hover:not(:disabled){transform:translateY(-1px);box-shadow:0 8px 18px #06b6d459}.research-choice button:disabled{opacity:.5;cursor:not-allowed;box-shadow:none}.panel label{display:flex;flex-direction:column;font-size:.85rem;gap:4px}.research-options{display:flex;flex-direction:column;gap:12px;list-style:none;padding:0;margin:0}.research-option{display:flex;justify-content:space-between;gap:12px;padding:10px;border-radius:10px;border:1px solid rgba(148,163,184,.3);background:#0f172a99}.research-option button{align-self:center;border:none;border-radius:8px;padding:6px 12px;background:#3b82f640;color:#dbeafe;cursor:pointer}.panel input,.panel select{border-radius:8px;border:1px solid rgba(148,163,184,.3);padding:6px 10px;background:#050c1d;color:#fff}.panel button{margin-top:8px;border-radius:999px;border:none;padding:8px 12px;color:#fff;font-weight:600;cursor:pointer;background:linear-gradient(135deg,#3b82f6,#8b5cf6)}.build-option-list{display:flex;flex-direction:column;gap:12px;list-style:none;padding:0 8px 0 0;margin:0;max-height:480px;overflow-y:auto}.build-option-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px}.build-option-row{display:flex;align-items:center;justify-content:space-between;gap:12px}.build-option-row.minimal{justify-content:space-between}.build-labels{display:flex;flex-direction:column;gap:2px}.build-cost{font-size:.78rem;color:#94a3b8}.build-option-main{display:flex;align-items:center;gap:8px}.build-name{font-weight:600;color:#e2e8f0}.build-icon-group{display:flex;gap:8px;align-items:center}.build-icon-placeholder{display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;border-radius:999px;border:1px dashed rgba(148,163,184,.5);color:#f8fafcd9;font-weight:700;font-size:.95rem}.build-option-heading{display:flex;flex-direction:column;line-height:1.2}.build-option-heading span{font-size:.78rem;color:#94a3b8}.build-option-list button{margin-top:0}.building-list{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:8px}.building-list-scroll{max-height:240px;overflow-y:auto;padding-right:6px}.building-list-scroll::-webkit-scrollbar{width:6px}.building-list-scroll::-webkit-scrollbar-thumb{background:#3b82f680;border-radius:999px}.building-list-scroll::-webkit-scrollbar-track{background:transparent}.panel.attack-panel{border:1px solid rgba(239,68,68,.35);background:#7f1d1d1f}.attack-target-list{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:10px}.attack-target-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border-radius:10px;background:#ef444414;border:1px solid rgba(239,68,68,.25)}.attack-target-meta{display:flex;flex-direction:column;gap:4px;font-size:.9rem}.building-row{display:flex;align-items:center;gap:8px}.building-row>button:first-of-type{flex:1;display:flex;justify-content:space-between;align-items:center;text-align:left;border-radius:10px;border:1px solid rgba(59,130,246,.4);background:#0f172ab3;color:#e2e8f0;padding:6px 10px;cursor:pointer;transition:border-color .15s ease,background .15s ease,color .15s ease,box-shadow .15s ease}.building-row>button:first-of-type.selected{border-color:transparent;background:linear-gradient(135deg,#3b82f6,#8b5cf6);color:#fff;box-shadow:0 0 12px #3b82f680}.building-meta{font-size:.78rem;color:#94a3b8;margin-left:4px}.building-label{font-weight:600}.icon-circle.upgrade{flex-shrink:0;margin-left:auto;border:none;background:transparent;width:auto;height:auto;padding:0}.info-button{width:28px;height:28px;border-radius:50%;border:1px solid rgba(148,163,184,.4);background:#0f172acc;color:#f8fafc;font-size:.85rem;cursor:pointer;display:flex;align-items:center;justify-content:center}.icon-circle{width:36px;height:36px;border-radius:50%;border:1px solid rgba(148,163,184,.4);background:#0f172acc;display:flex;align-items:center;justify-content:center;cursor:pointer;font-size:.95rem;transition:transform .15s ease,border-color .15s ease}.icon-circle.info:hover{border-color:#3b82f6b3;transform:translateY(-1px)}.icon-circle.build{border-color:#22c55e99}.icon-circle.build:hover{border-color:#34d399e6;transform:translateY(-1px)}.icon-circle.info,.icon-circle.build{width:auto;height:auto;border:none;background:transparent;font-size:1.1rem;transition:transform .15s ease,color .15s ease}.icon-circle.info:hover,.icon-circle.build:hover{transform:translateY(-1px);color:#fbbf24}.icon-circle.close{width:32px;height:32px;color:#fff}.build-option-summary{margin:6px 0 4px;font-size:.85rem;color:#dbeafe}.inline-city-name{margin-top:6px}.quick-city-form{margin-top:10px;display:flex;flex-direction:column;gap:8px;padding:10px;border-radius:10px;background:#0f172a99;border:1px dashed rgba(96,165,250,.5)}.quick-city-form button{align-self:flex-start}.modal-backdrop{position:fixed;inset:0;background:#020617bf;display:flex;align-items:center;justify-content:center;z-index:1500;-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px)}.modal-backdrop.info-modal{z-index:1700}.modal-card{width:min(1020px,95vw);background:#060b1a;border-radius:16px;border:1px solid rgba(148,163,184,.25);box-shadow:0 25px 40px #02061799;padding:18px;display:flex;flex-direction:column;gap:16px;max-height:calc(90vh - 40px);overflow:hidden}.modal-card.research-modal{width:min(760px,96vw);padding:24px;gap:20px}.modal-card.help-modal{width:min(880px,96vw);padding:24px;gap:20px}.modal-card header{display:flex;align-items:center;justify-content:space-between;gap:8px}.modal-card h3{margin:0;font-size:1.1rem}.modal-body{display:flex;flex-direction:column;gap:8px;font-size:.95rem;overflow-y:auto;padding-right:8px}.help-content{gap:16px}.help-content section{display:flex;flex-direction:column;gap:10px;padding:12px;border-radius:12px;background:#0f172abf;border:1px solid rgba(59,130,246,.2)}.help-table-wrapper{overflow-x:auto}.help-table{width:100%;border-collapse:collapse;font-size:.88rem}.help-table th,.help-table td{padding:8px 10px;text-align:left;border:1px solid rgba(148,163,184,.25);vertical-align:top}.help-table thead th{font-size:.78rem;text-transform:uppercase;letter-spacing:.05em;color:#94a3b8}.help-table tbody tr:hover{background:#3b82f61a}.terrain-yield-list{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:4px}.terrain-yield-label{display:inline-flex;align-items:center;gap:4px;font-weight:600}.terrain-yield-range{margin-left:8px;color:#cbd5f5}.modal-lead{color:#cbd5f5;font-size:.9rem}.modal-status-list{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:6px}.modal-status-list li{padding:8px 10px;border-radius:8px;font-size:.9rem}.modal-status-list li.status-ok{background:#22c55e14;border:1px solid rgba(34,197,94,.3)}.modal-status-list li.status-ko{background:#f8717114;border:1px solid rgba(248,113,113,.3)}.modal-city-field{display:flex;flex-direction:column;gap:4px;font-size:.9rem}.modal-actions{display:flex;justify-content:flex-end;gap:10px}.modal-actions button{padding:8px 14px;border-radius:999px;border:none;font-weight:600;cursor:pointer;color:#fff;background:linear-gradient(135deg,#3b82f6,#8b5cf6)}.modal-actions button.ghost{background:transparent;border:1px solid rgba(148,163,184,.4);color:#e2e8f0}.modal-actions button.danger{background:linear-gradient(135deg,#dc2626,#f97316)}.modal-actions button:disabled{opacity:.4;cursor:not-allowed}.action-message{border-radius:8px;padding:8px 10px;font-size:.85rem}.action-message.success{background:#10b98126;border:1px solid rgba(16,185,129,.3)}.action-message.error{background:#f8717126;border:1px solid rgba(248,113,113,.3)}.view-toggle button{background:#0f172a99;border:1px solid rgba(148,163,184,.3);border-radius:999px;padding:8px 16px;color:#e2e8f0;cursor:pointer;transition:all .2s ease}.view-toggle button.active{background:linear-gradient(135deg,#3b82f6,#8b5cf6);border-color:transparent;color:#fff}@media(max-width:768px){.play-area{flex-direction:column;align-items:center;flex-wrap:wrap}.commands{width:100%;flex:unset;position:relative}.map-column{width:100%;flex:unset}}.login-form{background:#0f121ae6;border:1px solid #2b3345;border-radius:16px;padding:24px;width:320px;display:flex;flex-direction:column;gap:12px;color:#f3f5fa}.login-form h2{margin:0;font-size:1.4rem}.login-form label{display:flex;flex-direction:column;gap:4px;font-size:.9rem}.login-form input{padding:10px 12px;border-radius:8px;border:1px solid #404a63;background:#121625;color:#fff}.login-form button{background:linear-gradient(135deg,#3b82f6,#7c3aed);border:none;border-radius:8px;color:#fff;padding:12px;font-weight:700;cursor:pointer;transition:opacity .2s}.login-form button:disabled{opacity:.6;cursor:not-allowed}.login-form .mode-switch{background:transparent;border:1px solid #404a63}.login-form .error{color:#f87171;font-size:.85rem}.consent-group{display:flex;flex-direction:column;gap:8px;margin:8px 0 4px;padding:10px 12px;border:1px solid #2b3345;border-radius:10px;background:#0f121a59}.consent-checkbox{display:flex;align-items:center;gap:8px;font-size:.85rem}.consent-checkbox input{width:16px;height:16px}.map-grid-wrapper{width:100%;height:100%;display:flex;flex-direction:column;border-radius:18px;border:1px solid rgba(148,163,184,.35);padding:16px;background:#0c122099;box-shadow:0 25px 45px #02061759}.map-grid-scroll{flex:1;min-height:0;overflow:auto;border-radius:12px;border:1px solid rgba(148,163,184,.2);padding:8px;background:#02061759}.map-grid{display:grid;gap:2px;width:max-content}.map-grid-wrapper .grid-controls{display:flex;align-items:center;justify-content:space-between;gap:16px}.grid-controls{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:8px;color:#e2e8f0;font-size:.85rem}.grid-controls input[type=range]{width:160px;margin-left:8px}.influence-legend{display:flex;align-items:center;gap:10px;font-size:.78rem;color:#e2e8f0b3}.legend-swatch{display:inline-flex;width:16px;height:8px;border-radius:9999px;border:1px solid rgba(255,255,255,.3);margin-right:4px}.legend-swatch.friendly{background:#4ade804d}.legend-swatch.enemy{background:#f8717159}.legend-swatch.contested{background:linear-gradient(90deg,#4ade8059,#f8717166)}.tile{position:relative;border-radius:6px;border:1px solid rgba(0,0,0,.15);display:flex;flex-direction:column;padding:8px;gap:6px;font-weight:600;color:#f8fafc;overflow:hidden}.tile:after{content:"";position:absolute;inset:2px;border-radius:2px;opacity:0;border:2px solid transparent;pointer-events:none;transition:opacity .2s ease}.tile.influence-friendly:after{opacity:1;border-color:#4ade808c;box-shadow:0 0 6px #4ade8066}.tile.influence-enemy:after{opacity:1;border-color:#f8717199;box-shadow:0 0 6px #f8717180}.tile.influence-contested:after{opacity:1;border-color:#f472b6bf;box-shadow:0 0 8px #f472b680}.tile.selected{border:2px solid #f97316;box-shadow:0 0 10px #f97316bf;background:#3b82f61a}.tile-yields{display:flex;flex-direction:column;gap:2px;align-items:center;font-size:.78rem;line-height:1.2;color:#000}.yield-row{display:flex;align-items:center;justify-content:center;gap:6px;border-radius:6px;padding:4px 8px;text-align:center;width:100%}.yield-icon{font-size:1.2rem}.yield-value{font-variant-numeric:tabular-nums;font-weight:700;font-size:.9rem;color:#000}.tile-markers{position:absolute;top:4px;inset-inline:4px;display:flex;justify-content:center;gap:4px;pointer-events:none}.tile-marker{width:22px;height:22px;display:inline-flex;align-items:center;justify-content:center;border-radius:999px;font-size:.9rem;line-height:1;border:1px solid rgba(255,255,255,.25);box-shadow:0 2px 4px #02061773;background:#0f172ad9}.tile-marker.building{background:#0f172ad9}.tile-marker.gift{background:#3b82f6e6}.tile-marker.unit-builder{background:#facc15f2}.tile-marker.unit-combat{background:#ef4444e6}.tile-marker.player{background:#22c55ee6}.grid-placeholder{color:#94a3b8;font-style:italic}.map3d-wrapper{width:100%;height:100%;border-radius:18px;overflow:hidden;box-shadow:0 30px 55px #0206178c;border:1px solid rgba(59,130,246,.35);position:relative;background:#030712e6;display:flex;flex-direction:column;min-height:0}.terrain-action-popup{min-width:220px;background:#0f172aeb;border:1px solid rgba(59,130,246,.35);border-radius:12px;padding:12px 16px;display:flex;flex-direction:column;gap:8px;color:#f8fafc;text-align:center;box-shadow:0 10px 30px #020617a6}.terrain-action-popup h4{margin:0;font-size:.95rem}.terrain-action-popup p{margin:0;font-size:.8rem;color:#cbd5f5}.terrain-action-popup button{border:none;border-radius:999px;padding:6px 12px;font-weight:600;cursor:pointer}.terrain-action-popup button.primary{background:linear-gradient(135deg,#22c55e,#16a34a);color:#041204}.terrain-action-popup button.danger{background:linear-gradient(135deg,#f87171,#ef4444);color:#fff;width:100%}.terrain-action-popup button.ghost{background:transparent;border:1px solid rgba(148,163,184,.5);color:#e2e8f0}.terrain-action-list{display:flex;flex-direction:column;gap:6px}.terrain-action-empty{font-size:.75rem;color:#fbbf24;margin:0}.terrain-action-error{color:#f87171;font-size:.78rem;margin:0}.map3d-wrapper canvas{width:100%!important;height:100%!important}.map3d-wrapper.fullscreen{width:100vw;height:100vh;border-radius:0;border:none}.map3d-canvas{flex:1;min-height:0;position:relative}.map3d-arrow{position:absolute;top:12px;left:12px;z-index:3;display:flex;flex-direction:column;align-items:center;gap:4px;padding:6px 10px;background:#050c1dd9;border-radius:12px;border:1px solid rgba(148,163,184,.3);color:#cbd5f5;font-size:.75rem}.arrow-indicator{width:36px;height:36px;border:1px solid rgba(148,163,184,.4);border-radius:50%;display:flex;align-items:center;justify-content:center;transition:transform .2s ease;position:relative}.arrow-body{display:block;width:0;height:0;border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:20px solid #f97316}.arrow-body:after{content:"";position:absolute;top:8px;left:50%;width:2px;height:24px;background:#0f172ae6;transform:translate(-50%);border-radius:999px}.arrow-label{font-weight:600;letter-spacing:.06em;font-size:.7rem}.map3d-actions{position:absolute;top:8px;right:8px;z-index:2;display:flex;gap:12px;align-items:center}.map3d-actions button{background:#0f172acc;color:#cbd5f5;border:1px solid rgba(59,130,246,.4);padding:6px 14px;border-radius:999px;cursor:pointer;font-weight:600}.map3d-action-buttons{display:flex;gap:8px}.map3d-compass{display:flex;flex-direction:column;align-items:center;gap:4px;padding:6px;background:#020617d9;border-radius:12px;border:1px solid rgba(59,130,246,.4);color:#cbd5f5;font-size:.75rem}.compass-ring{position:relative;width:46px;height:46px;border:1px solid rgba(148,163,184,.5);border-radius:50%}.compass-n{position:absolute;top:4px;left:50%;transform:translate(-50%);font-size:.7rem;font-weight:700;color:#f8fafc}.compass-pointer{position:absolute;bottom:6px;left:50%;width:2px;height:18px;background:linear-gradient(180deg,#f97316,#ef4444);transform-origin:bottom center;border-radius:999px}.compass-label{font-weight:600;letter-spacing:.05em}.map3d-instructions{position:absolute;bottom:12px;left:50%;transform:translate(-50%);width:calc(100% - 32px);text-align:center;padding:8px 12px;font-size:.85rem;background:#0f172aa6;border-radius:12px;border:1px solid rgba(148,163,184,.25);z-index:2}.unit-warning{display:inline-flex;align-items:center;gap:4px;padding:4px 8px;border-radius:999px;background:#0f172ae6;border:1px solid rgba(248,113,113,.7);color:#fecaca;font-size:.7rem;font-weight:600;box-shadow:0 6px 16px #02061799;white-space:nowrap}.unit-warning-icon{display:inline-flex;align-items:center;justify-content:center;font-size:.85rem}.enemy-unit-flag{display:inline-flex;align-items:center;gap:4px;padding:3px 8px 3px 6px;border-radius:8px;background:#1e293beb;border:1px solid rgba(248,250,252,.35);color:#f8fafc;font-size:.65rem;font-weight:600;letter-spacing:.02em;text-transform:uppercase;box-shadow:0 6px 16px #020617a6;white-space:nowrap}.enemy-unit-flag-icon{font-size:.8rem;line-height:1}.enemy-unit-flag-label{max-width:72px;overflow:hidden;text-overflow:ellipsis}
