:root{--pine:#153c33;--pine2:#295443;--ivory:#fffaea;--brass:#e5b65f;--glass:#18372fef;--stroke:#c4ab72;--ink:#20382e}
body{background:#102b25;color:var(--ink)}
.at-gate .topbar,.at-gate #stage{display:none}
#gate{height:100dvh;overflow:auto}
.founding{min-height:100%;position:relative;isolation:isolate;display:flex;flex-direction:column;align-items:flex-start;padding:clamp(18px,4vw,68px) clamp(18px,7vw,104px);color:#fff7dc;background:linear-gradient(270deg,#102d27 0%,#122f29ed 28%,#162c2380 52%,transparent 80%),linear-gradient(0deg,#102d27bb,transparent 35%),url('./assets/barood/mahad/world.webp') center/cover}
.gate-mast{display:flex;gap:12px;align-items:center;font:bold 24px Display,Sarab}.gate-mast small{font:12px Sarab;color:#ecdab1}.gate-mast i{height:22px;width:1px;background:#cfb98599}
.gate-sigil{display:grid;place-items:center;width:40px;height:44px;border:1px solid #d7b87d;color:var(--brass);border-radius:6px 6px 16px 16px;background:#143e34}
.found-form{margin-block:auto;width:min(100%,530px);padding-block:35px}.edition,.gate-colophon{font-size:12px;color:#edd4a4;display:flex;align-items:center;gap:10px}.edition i,.gate-colophon i{width:36px;height:1px;background:var(--brass)}.found-form h1{font:clamp(70px,8vw,114px)/1.05 Display,Sarab;margin:12px 0;color:#fff1c6;text-shadow:0 2px 14px #092b20}
.synopsis{font-size:clamp(15px,1.5vw,19px);line-height:1.8;color:#f3ead4;max-width:440px;margin:0 0 22px}
.found-form fieldset{border:0;padding:0;margin:0}.found-form legend,.name-label{font-size:13px;font-weight:bold;margin:0 0 7px;display:block;color:#f7e4bb}
.origins{display:grid;grid-template-columns:repeat(3,1fr);gap:9px}.origin{display:block;position:relative;border-radius:11px;border:1px solid #fff3;overflow:hidden;height:125px;cursor:pointer;background:#214037}.origin img{width:100%;height:100%;object-fit:cover;transition:transform .22s}.origin:hover img{transform:scale(1.07)}.origin input{position:absolute;left:7px;top:7px;z-index:2;accent-color:#d5a951}.origin span{position:absolute;inset:auto 0 0;display:grid;padding:21px 10px 8px;background:linear-gradient(transparent,#102b26ee 65%);color:white}.origin b{font-size:17px}.origin small{font-size:10px;color:#e6d8bb}.origin:has(:checked){border:2px solid #efc46a;box-shadow:0 0 0 2px #15392f}.origin:focus-within{outline:2px solid white}
.origin-facts{font-size:12px;color:#e6c98b;margin:8px 0 20px}.found-line{display:flex;gap:8px}.found-line input{min-width:0;flex:1;background:#0c251de0;border:1px solid #b8a07177;border-radius:8px;padding:11px;color:white}.found-line button,.gate-error button{display:flex;align-items:center;justify-content:space-between;gap:12px;background:#e6b966;border-radius:8px;padding:10px 19px;color:#273a2f;font-weight:bold}.gate-colophon{margin-top:auto;opacity:.85}.gate-colophon b{font-size:9px;color:var(--brass)}.gate-error{margin:10vh auto;background:#fff4dc;max-width:540px;padding:24px;border-radius:16px}
.topbar{background:#12382f;color:#fff4d9;border-bottom:1px solid #c19b5b;box-shadow:0 4px 18px #0b241e33;height:66px}.brand{min-width:88px;color:#ffebbb}.brand b{font-size:34px}.brand small{color:#d4ba86}.resource strong{color:#fff7dc}.resource small,.resource .rate{color:#cbbd98}.resources{gap:clamp(9px,2vw,27px)}.time-controls button{background:#244a3e;color:#ffedbb;border-color:#54705b}#stage{height:calc(100% - 66px);isolation:isolate}
.location{background:var(--glass);padding:9px 15px;border:1px solid #d3bb8659;border-radius:10px;text-shadow:none;right:104px;top:14px}.location h1{font-size:22px;line-height:1.2;color:#fff2d2}.location .kicker,.location>span:last-child{color:#dbcda7}
.dock{right:12px;top:14px;background:var(--glass);border-color:#dfc48a88;width:76px;box-shadow:0 9px 32px #182d2755}.dock button{color:#fff0cb;min-height:51px;padding:4px 2px}.dock button.active,.dock button:hover:not(.active){background:#53715a}
.camera-controls button,.weather-chip,.view-tabs{background:#fff7e8ed}.camera-controls{left:16px}.weather-chip{left:16px;top:14px}.mini-wrap{width:126px}.mini-wrap canvas{width:120px;height:66px}.bottom-left{left:16px;bottom:25px}.bottom-status{height:18px;bottom:0}.quest-peek{right:105px;bottom:27px;max-width:265px}.quest-peek em{max-width:175px}
.capital-console{position:absolute;z-index:6;bottom:28px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:5px;padding:6px 9px;background:var(--glass);border:1px solid #d8bd86;border-radius:12px;box-shadow:0 5px 18px #20352c3a;color:#ffefd2}.command-word{font-size:10px;color:#d9c38e;padding:2px 5px}.capital-console button{border-radius:7px;padding:7px 11px;font-size:12px;color:#fff2d4;background:#ffffff12}.capital-console button:hover{background:#446b51}.on-world .capital-console,body:has(#panel:not([hidden])) .capital-console,body:has(#placement:not([hidden])) .capital-console{display:none}
.village-life{top:15px;background:#fbf4e5ed}.panel{background:#fffaee;box-shadow:0 15px 50px #0d29284a;border:1px solid #dec995;z-index:18}.panel header{background:#1b4035;color:#fff2d1}.panel header small,.panel header h2{color:#fff0cd}.panel header button{background:#e6ddc6}.button{font-weight:700}.route-field,.territory-art{width:100%;height:130px;border-radius:10px;object-fit:cover;background-position:center;background-size:cover;display:block}.route-field{overflow:hidden;display:flex;flex-direction:column;padding-bottom:5px}.route-field svg{display:block;width:100%;min-height:0;flex:1}.route-field small{color:#fff5d3;text-align:center}.route-field path{animation:march 1.3s linear infinite}@keyframes march{to{stroke-dashoffset:-24}}.unit-portrait{width:44px;height:54px;object-fit:cover;object-position:50% 24%;border-radius:8px}
.dispatch{border:1px solid #e0d0ac;border-radius:12px;background:#f8eed9;padding:13px;margin-bottom:10px}.dispatch small,.dispatch p{font-size:11px;color:#7c725b}.dispatch h3{margin:3px 0 6px}.result{border-radius:5px;background:#e8d6c2;color:#814a37;padding:2px 8px}.result.win{background:#dcead4;color:#316743}.dispatch dl{display:grid;grid-template-columns:repeat(4,1fr);gap:5px;margin:6px 0 0}.dispatch dl div{background:#fff8e9;text-align:center;padding:5px;border-radius:6px}.dispatch dt{font-size:9px}.dispatch dd{font-weight:bold;margin:0}
@media(min-width:701px) and (max-width:1150px){.command-word,.quest-peek em,.mini-wrap,.location .kicker{display:none}.quest-peek{max-width:175px;right:92px}.resources{gap:10px}}
@media(max-width:700px){
  .founding{padding:16px 17px 20px;background-position:59% 50%;background-image:linear-gradient(90deg,#102a20af,#102d26ee),url('./assets/barood/mahad/world.webp')}.found-form{padding:22px 0;max-width:520px}.found-form h1{font-size:64px;margin:8px 0}.origin{height:98px}.found-line button{padding:10px 13px}.edition,.gate-colophon{font-size:10px}.gate-mast{font-size:20px}.synopsis{font-size:15px;margin-bottom:15px}
  .topbar{height:94px;padding:5px 12px;gap:5px}.brand{min-width:auto}.brand small{font-size:8px}.brand b{font-size:25px}.resources{bottom:5px}.resource small{color:#d4c8a5}.resource strong{font-size:13px}.resource>.illustrated-icon{width:25px;height:25px}
  #stage{height:calc(100% - 94px);height:calc(100dvh - 94px)}.dock{left:0;right:0;top:auto;bottom:0;width:100%;max-height:none;border-radius:12px 12px 0 0;padding:4px 4px max(4px,env(safe-area-inset-bottom));display:flex;flex-direction:row;justify-content:space-around;gap:0}.dock button{min-height:44px;min-width:0;flex:1;padding:1px}.dock button b{font-size:9px}.dock button>span,.dock button .illustrated-icon{height:25px!important;width:27px!important}
  .location{right:8px;top:8px;padding:6px 10px;max-width:62%}.location h1{font-size:16px;margin:0}.location .kicker{display:none}.location>span:last-child{font-size:9px}.weather-chip{left:8px;top:8px;padding:5px 7px}.weather-chip b{font-size:10px}.weather-chip small{font-size:8px}.weather-chip>span:first-child{font-size:18px}
  .camera-controls{top:58px;left:8px;gap:3px}.camera-controls button{width:31px;height:31px}.bottom-left{right:8px;left:auto;bottom:64px}.view-tabs button{padding:8px 10px}.mini-wrap,.quest-peek,.bottom-status{display:none}.village-life{top:64px;right:8px;left:auto;padding:5px 7px;min-width:0}.village-life small{display:none}.village-life b{font-size:9px}
  .capital-console{left:8px;transform:none;bottom:65px;padding:3px;gap:2px}.command-word{display:none}.capital-console button{padding:6px;font-size:10px}.world-tools{top:58px;left:50%;width:calc(100% - 94px);max-width:400px}.world-tools input{min-width:0}
  .panel,.panel.wide{position:absolute;top:auto;bottom:54px;left:5px;right:5px;width:auto;max-width:none;max-height:min(73dvh,calc(100% - 60px));border-radius:15px}.panel header{position:sticky;top:0;z-index:1}.placement{bottom:64px;max-width:96%;width:max-content;padding:7px;gap:5px}.placement span{font-size:10px}#toasts{top:56px;max-width:84%}.toast{font-size:11px}
}
@media(max-height:540px) and (orientation:landscape){.founding{padding:10px 4vw}.gate-mast,.gate-colophon{display:none}.found-form{margin:auto;padding:6px}.found-form h1{font-size:38px}.origin{height:66px}.synopsis,.origin-facts{margin:4px 0}.gate-mast{position:static}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;transition:none!important}}
