/* planeta.css — widok powierzchni kolonii (28.09.2026); kolory z motywu/skórki przez zmienne */
#planetaView { position: fixed; inset: 0; z-index: 30; display: flex; flex-direction: column; background: var(--bg); color: var(--txt); }
#planetaView[hidden] { display: none; }
html.plOtwarta #app { visibility: hidden; }
.plHud { display: flex; align-items: center; gap: 12px; padding: calc(var(--sat, 0px) + 10px) 14px 10px; background: var(--hudbg); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.plWroc { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--line2); background: var(--hover); color: var(--txt); font-weight: 600; }
.plWroc .ic { width: 16px; height: 16px; }
.plTytul { display: flex; align-items: center; gap: 10px; min-width: 0; }
.plTytul h1 { margin: 0; font-size: 19px; }
.plTytul small { color: var(--acc); font-weight: 600; }
.plKula { width: 36px; height: 36px; border-radius: 50%; flex: none; background: radial-gradient(circle at 35% 30%, #d9f2ff, #7c8aa3 40%, #2b3346 80%); box-shadow: 0 0 14px rgba(160,190,255,.35); }
.plStaty { display: flex; gap: 6px; margin-left: auto; flex-wrap: wrap; }
.plSt { padding: 5px 10px; border-radius: 10px; background: var(--surf); border: 1px solid var(--line); min-width: 84px; }
.plSt small { display: block; font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--dim2); }
.plSt b { font-size: 14px; white-space: nowrap; }
.plSt.plus b { color: var(--good); } .plSt.minus b { color: var(--bad); }
.plGra { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) 370px; min-height: 0; }
.plMapa { position: relative; overflow: hidden; min-height: 0; background: radial-gradient(140% 70% at 50% -10%, #1b2d52 0%, #0b1428 40%, #070b16 100%); }
.plHoryzont { position: absolute; left: -10%; right: -10%; top: 8%; height: 160px; border-radius: 50%; background: radial-gradient(ellipse at 50% 100%, rgba(120,200,255,.26), transparent 60%); filter: blur(8px); pointer-events: none; }
#plPlansza { position: absolute; inset: 0 0 40px 0; width: 100%; height: calc(100% - 40px); }   /* 40 px na legendę terenu pod planszą */
.plHex { cursor: pointer; transition: filter .15s; }
.plHex:hover { filter: brightness(1.22); }
.plHex.wyb polygon.ramka { stroke: var(--acc); stroke-width: 3.5; }
.plPlus { opacity: .0; transition: opacity .15s; }
.plHex:hover .plPlus, .plHex.wyb .plPlus { opacity: 1; }
.plSwiatlo { animation: plMrug 2.4s ease-in-out infinite; }
@keyframes plMrug { 50% { opacity: .35; } }
.plDym { animation: plDym 3s ease-in-out infinite; }
@keyframes plDym { 0% { opacity: 0; transform: translateY(4px); } 40% { opacity: .7; } 100% { opacity: 0; transform: translateY(-12px); } }
.plLegenda { position: absolute; left: 10px; bottom: 10px; display: flex; gap: 6px; flex-wrap: wrap; right: 10px; }
.plLegenda span { display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 999px; background: rgba(6,10,20,.8); border: 1px solid var(--line); font-size: 11px; color: #c9d6ee; }
.plLegenda i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.plPanel { background: var(--sidebg); border-left: 1px solid var(--line); overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.plKarta { background: var(--surf); border: 1px solid var(--line); border-radius: var(--r); padding: 12px; }
.plKarta h3 { margin: 0 0 8px; font-size: 12px; text-transform: uppercase; letter-spacing: .07em; color: var(--dim); }
.plOpis { margin: 0; color: var(--dim); font-size: 13.5px; }
.plPoleNag { display: flex; gap: 10px; align-items: center; }
.plPoleNag i { width: 36px; height: 36px; border-radius: 9px; flex: none; }
.plPoleNag b { display: block; font-size: 16px; } .plPoleNag small { color: var(--dim); }
.plBud { display: grid; grid-template-columns: 42px 1fr auto; gap: 10px; align-items: center; width: 100%; text-align: left; padding: 9px; margin-top: 6px; border-radius: 12px; border: 1px solid var(--line); background: var(--hover); color: var(--txt); }
.plBud:hover { border-color: var(--line2); }
.plBud.nie { opacity: .5; }
.plIk { width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; background: var(--panel2); }
.plIk svg { width: 30px; height: 30px; }
.plBud b { display: block; font-size: 14px; } .plBud small { display: block; color: var(--dim); font-size: 12px; }
.plKoszt { text-align: right; font-weight: 700; color: var(--gold); white-space: nowrap; font-size: 13px; }
.plKoszt small { display: block; color: var(--dim2); font-weight: 500; font-size: 11px; }
@media (max-width: 860px) {
  #planetaView { overflow-y: auto; }
  .plGra { grid-template-columns: 1fr; flex: none; }
  .plMapa { height: auto; min-height: 0; flex: none; padding: 6px 0 10px; }
  #plPlansza { position: relative; inset: auto; display: block; width: 100%; height: 70vw; max-height: 62vh; }
  .plLegenda { position: static; padding: 0 10px; }
  .plPanel { border-left: 0; border-top: 1px solid var(--line); overflow: visible; }
  .plStaty { margin-left: 0; width: 100%; display: grid; grid-template-columns: repeat(3, 1fr); }
  .plSt { min-width: 0; }
  .plLegenda span { font-size: 10px; padding: 3px 7px; }
}
/* retro: nagłówek jest ciemny jak pasek gry, więc tytuł jasny, a przycisk i liczniki jak kremowe karty */
:root[data-skin="retro"] .plTytul h1 { color: #fff8ea; }
:root[data-skin="retro"] .plTytul small { color: #7fe3d6; }
:root[data-skin="retro"] .plWroc { background: #fff8ea; color: #1a1a2e; border: 2px solid #1a1a2e; }
:root[data-skin="retro"] .plSt { background: #fff8ea; border: 2px solid #1a1a2e; }
:root[data-skin="retro"] .plSt small { color: #5b5670; }
/* „Co ta planeta daje Twojemu domowi” (29.09.2026) */
.plWplyw { display: flex; gap: 10px; align-items: flex-start; padding: 7px 0; border-top: 1px solid var(--line); }
.plWplyw:first-of-type { border-top: 0; padding-top: 0; }
.plWIk { flex: none; width: 26px; text-align: center; font-size: 17px; line-height: 1.2; }
.plWplyw b { display: block; font-size: 13.5px; }
.plWplyw small { display: block; color: var(--dim); font-size: 12px; line-height: 1.4; margin-top: 1px; }

/* wybór planety przy wielu koloniach (30.09.2026) */
.plPrzel .plLicznik { width: auto !important; min-width: 52px; padding: 0 8px; font-size: 12.5px !important; color: var(--txt); white-space: nowrap; }
.plWybor { position: fixed; z-index: 60; top: 64px; left: max(10px, env(safe-area-inset-left)); width: min(360px, calc(100vw - 20px)); max-height: min(70vh, 560px);
  display: flex; flex-direction: column; background: var(--modalbg, var(--sidebg)); border: 1px solid var(--line2); border-radius: 14px; box-shadow: 0 14px 44px rgba(0, 0, 0, .5); overflow: hidden; }
.plWybor[hidden] { display: none; }
.plWybor input { margin: 10px; height: 38px; border-radius: 9px; border: 1px solid var(--line2); background: var(--bg); color: var(--txt); padding: 0 10px; font: inherit; font-size: 14px; }
.plWyborLista { overflow-y: auto; padding: 0 6px 8px; }
.plWyborGrupa { margin: 10px 8px 4px; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
.plWyborGrupa span { color: var(--txt); }
.plWyborWiersz { display: grid; gap: 1px; width: 100%; text-align: left; padding: 8px 10px; border-radius: 9px; border: 1px solid transparent; background: transparent; color: var(--txt); font: inherit; cursor: pointer; }
.plWyborWiersz b { font-size: 14px; font-weight: 600; }
.plWyborWiersz small { font-size: 12px; color: var(--dim); }
.plWyborWiersz .plSied { color: var(--acc); font-weight: 600; }
.plWyborWiersz:hover { background: var(--surf2); }
.plWyborWiersz.on { border-color: var(--acc); background: rgba(56, 232, 255, .08); }

/* stan kasy w mapie planety (30.09.2026) */
.plSt.plKasa { border-color: var(--gold, #e8b84a); }
.plSt.plKasa b { color: var(--gold, #e8b84a); }
.plKoszt small.bad { color: var(--bad); font-weight: 600; }

/* dymek przy klikniętym polu mapy planety (30.09.2026) */
.plDymek { position: absolute; z-index: 5; width: 230px; padding: 10px 12px 11px; border-radius: 12px; background: var(--modalbg, var(--sidebg)); color: var(--txt);
  border: 1px solid var(--acc); box-shadow: 0 10px 30px rgba(0, 0, 0, .5); display: grid; gap: 5px; font-size: 13px; }
.plDymek::after { content: ''; position: absolute; left: calc(var(--strz, 50%) - 7px); bottom: -7px; width: 12px; height: 12px; background: inherit;
  border-right: 1px solid var(--acc); border-bottom: 1px solid var(--acc); transform: rotate(45deg); }
.plDymek.pod::after { bottom: auto; top: -7px; transform: rotate(225deg); }
.plDymek > b { font-size: 14px; padding-right: 18px; }
.plDymek small { color: var(--dim); font-size: 12px; line-height: 1.35; }
.plDymek small.bad { color: var(--bad); font-weight: 600; }
.plDyCena, .plDyKasa { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.plDyCena span, .plDyKasa span { color: var(--dim); font-size: 12px; }
.plDyCena b { color: var(--gold, #e8b84a); font-variant-numeric: tabular-nums; white-space: nowrap; }
.plDyKasa b { font-variant-numeric: tabular-nums; white-space: nowrap; }
.plDymek .primary { height: 36px; margin-top: 3px; font-size: 13px; }
.plDyX { position: absolute; top: 4px; right: 6px; width: 24px; height: 24px; border: 0; background: transparent; color: var(--dim); font-size: 18px; line-height: 1; cursor: pointer; }
.plKasaLista { padding: 6px 10px; margin: -2px 0 8px; border-radius: 9px; border: 1px solid var(--line); }
.plKasaLista b { color: var(--gold, #e8b84a); }
@media (max-width: 699px) { .plDymek { width: 205px; padding: 8px 10px 9px; font-size: 12.5px; } }
