html, body { height: 100%; margin: 0; font-family: system-ui, sans-serif; font-size: 14px; color: #1a1a1a; }
#map { position: absolute; top: 0; right: 0; bottom: 0; left: 380px; }

#casovniBaner {
  position: absolute; top: 12px; left: 380px; right: 0;
  z-index: 1000; display: flex; justify-content: center; pointer-events: none;
}
#casovniBaner span {
  display: inline-block; background: rgba(17, 24, 39, 0.85); color: #fff;
  padding: 8px 20px; border-radius: 8px; font-size: 20px; font-weight: 700;
  text-align: center; box-shadow: 0 2px 8px rgba(0,0,0,.3); max-width: 90%;
}

#panel {
  position: absolute; top: 0; left: 0; bottom: 0; width: 380px;
  overflow-y: auto; background: #f7f7f5; border-right: 1px solid #ddd;
  padding: 14px; box-sizing: border-box;
}

#panel h1 { font-size: 16px; margin: 0 0 4px; }
#panel h2 { font-size: 13px; margin: 18px 0 6px; text-transform: uppercase; letter-spacing: .03em; color: #555; }
#panel .sub { color: #666; font-size: 12px; margin-bottom: 10px; }

.card { background: #fff; border: 1px solid #e2e2e0; border-radius: 8px; padding: 10px; margin-bottom: 10px; }
.card label { display: block; font-size: 12px; color: #444; margin: 6px 0 2px; }
.card input, .card select { width: 100%; box-sizing: border-box; padding: 5px 6px; border: 1px solid #ccc; border-radius: 5px; font-size: 13px; }
.card .row { display: flex; gap: 6px; }
.card .row > * { flex: 1; }

button { cursor: pointer; border: 1px solid #bbb; background: #fff; border-radius: 6px; padding: 7px 10px; font-size: 13px; margin-top: 8px; width: 100%; }
button.primary { background: #2563eb; color: #fff; border-color: #2563eb; }
button.primary:hover { background: #1d4ed8; }
button:hover { background: #f0f0f0; }
button.primary:hover { background: #1d4ed8; }
button:disabled { opacity: .5; cursor: default; }

.eclipse-times { font-size: 12px; color: #333; }
.eclipse-times div { display: flex; justify-content: space-between; padding: 1px 0; }

#status {
  font-family: ui-monospace, 'Cascadia Code', 'Courier New', monospace;
  font-size: 11.5px; white-space: pre-wrap; color: #d1d5db;
  height: 4.2em; line-height: 1.4em; overflow-y: auto;
  margin-bottom: 12px; padding: 6px 8px;
  background: #111827; border-left: 4px solid #2563eb; border-radius: 4px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.05);
}
#status:empty { display: none; }
#status.err { color: #fca5a5; border-left-color: #dc2626; }

#layers { list-style: none; padding: 0; margin: 0; }
#layers li { display: flex; align-items: center; gap: 6px; padding: 4px 0; font-size: 12px; border-bottom: 1px dashed #e5e5e3; }
#layers li .swatch { width: 12px; height: 12px; border-radius: 3px; flex: none; }
#layers li .name { flex: 1; }
#layers li button { width: auto; margin: 0; padding: 2px 6px; font-size: 11px; }

.hint { font-size: 11px; color: #888; margin-top: 4px; }

#mfTekInfo {
  font-size: 13px; font-weight: 700; color: #92400e; text-align: center;
  background: #fffbeb; border: 1px solid #f59e0b; border-radius: 6px;
  padding: 7px 8px; margin-top: 8px;
}

.legenda { margin-top: 8px; display: flex; flex-direction: column; gap: 2px; }
.legenda .vrstica { display: flex; align-items: center; gap: 6px; font-size: 11px; color: #444; }
.legenda .barva { width: 16px; height: 12px; border-radius: 2px; flex: none; border: 1px solid rgba(0,0,0,.15); }

/* Plavajoč gumb za odpiranje/zapiranje plošče na mobilnih napravah —
   na širokih zaslonih skrit, plošča je tam stalno vidna stranska vrstica. */
#panelPreklop {
  display: none; position: fixed; z-index: 2100; bottom: 16px; left: 16px;
  width: auto; margin: 0; border-radius: 24px; padding: 12px 18px;
  background: #2563eb; color: #fff; border: none; font-size: 14px; font-weight: 700;
  box-shadow: 0 3px 10px rgba(0,0,0,.35);
}

#panelZatemnitev { display: none; }

@media (max-width: 760px) {
  #panelPreklop { display: block; }

  #panel {
    width: 86vw; max-width: 360px;
    transform: translateX(-100%);
    transition: transform .25s ease;
    z-index: 2000;
    box-shadow: 3px 0 16px rgba(0,0,0,.35);
    padding-bottom: 80px; /* prostor nad plavajočim gumbom */
  }
  #panel.odprta { transform: translateX(0); }

  #panelZatemnitev {
    display: block; position: fixed; inset: 0; z-index: 1900;
    background: rgba(0,0,0,0); pointer-events: none; transition: background .25s ease;
  }
  #panelZatemnitev.vidna { background: rgba(0,0,0,.4); pointer-events: auto; }

  #map { left: 0; }
  #casovniBaner { left: 0; top: 8px; }
  #casovniBaner span { font-size: 15px; padding: 6px 12px; }

  /* Večje tipke za prst */
  button { padding: 12px 14px; font-size: 15px; }
  #layers li button { padding: 6px 10px; font-size: 13px; }
  .card input, .card select { padding: 10px 8px; font-size: 15px; }
  input[type="checkbox"] { width: 20px; height: 20px; }
  .card label { font-size: 13px; }
}
