/* ==========================================================================
   edu-profil.css — profil szkoły w układzie makiety (profil-szkoly-makieta.html).
   Ładowany tylko na /szkola/…/ (php/_school.php). Kolory = zmienne z edu-theme.css,
   więc tryb ciemny działa automatycznie. Wszystko zawężone do .prof.
   ========================================================================== */
html{scroll-padding-top:126px}
@media (prefers-reduced-motion:no-preference){html{scroll-behavior:smooth}}

.prof h1,.prof h2,.prof h3{font-family:"Bricolage Grotesque",Inter,system-ui,sans-serif;color:var(--ink)}
.prof a:focus-visible,.prof [tabindex]:focus-visible{outline:2px solid var(--green);outline-offset:2px}

/* ---------- hero ---------- */
.prof-hero{
  border-bottom:1px solid var(--line);
  background:var(--paper);
  background-image:linear-gradient(var(--grid) 1px,transparent 1px),linear-gradient(90deg,var(--grid) 1px,transparent 1px);
  background-size:28px 28px;
  padding:18px 0 30px;
}
.prof .heroGrid{display:grid;grid-template-columns:1.5fr 1fr;gap:26px;align-items:start}
.prof .kicker{font-size:14px;color:var(--muted);margin:0 0 6px}
.prof h1{font-size:clamp(26px,4.4vw,40px);line-height:1.12;letter-spacing:-.02em;font-weight:800;margin:0 0 14px;max-width:22ch}
.prof .badges{display:flex;flex-wrap:wrap;gap:8px;margin:0 0 22px}
.prof .badge{font-size:13px;font-weight:500;border:1px solid var(--line);border-radius:999px;padding:4px 12px;
  background:var(--paper);color:var(--ink);line-height:1.5;white-space:normal;text-align:left}
.prof .badge.pub{border-color:var(--green);color:var(--green);background:var(--green-soft)}

.prof .scorecard{background:var(--paper);border:1px solid var(--line);border-radius:14px;padding:20px 22px;box-shadow:0 1px 0 var(--line2)}
.prof .scorecard h2{font-size:16px;font-weight:600;margin:0 0 2px;letter-spacing:0}
.prof .scorecard .sub{font-size:13px;color:var(--muted);margin:0 0 16px}
.prof .scores{display:grid;grid-template-columns:repeat(3,1fr)}
.prof .score{padding:0 18px;border-left:1px solid var(--line2)}
.prof .score:first-child{padding-left:0;border-left:none}
.prof .score .subj{font-size:14px;font-weight:600;margin:0 0 6px}
.prof .score .val{
  font-family:"Bricolage Grotesque",Inter,sans-serif;font-weight:800;font-size:clamp(30px,4vw,40px);line-height:1;
  display:inline-block;padding:2px 8px;margin-left:-8px;border-radius:4px;
  background:linear-gradient(104deg,transparent 4%,var(--marker) 5%,var(--marker) 96%,transparent 97%);
  color:var(--marker-ink);
}
.prof .score .cmp{font-size:13px;color:var(--muted);margin-top:8px;line-height:1.5}
.prof .score .cmp strong{color:var(--ink);font-weight:600}
.prof .rankline{margin:18px 0 0;padding-top:14px;border-top:1px dashed var(--line);font-size:14.5px}
.prof .rankline b{font-weight:600}
@media(max-width:680px){
  .prof .scores{grid-template-columns:1fr}
  .prof .score{border-left:none;border-top:1px solid var(--line2);padding:12px 0}
  .prof .score:first-child{border-top:none;padding-top:0}
}

.prof .facts{display:grid;gap:10px}
.prof .fact{background:var(--paper);border:1px solid var(--line);border-radius:12px;padding:14px 16px;
  display:flex;justify-content:space-between;align-items:baseline;gap:12px}
.prof .fact .k{font-size:14px;color:var(--muted)}
.prof .fact .v{font-family:"Bricolage Grotesque",Inter,sans-serif;font-weight:600;font-size:20px}
@media(max-width:900px){
  .prof .heroGrid{grid-template-columns:1fr}
  .prof .facts{grid-template-columns:repeat(auto-fit,minmax(150px,1fr))}
}

/* ---------- nawigacja sekcji (pod stałym menu 64 px) ---------- */
.prof .secnav{position:sticky;top:64px;z-index:15;background:var(--paper);border-bottom:1px solid var(--line)}
.prof .secnav .container{display:flex;gap:4px;overflow-x:auto;scrollbar-width:none}
.prof .secnav .container::before,.prof .secnav .container::after{display:none}
.prof .secnav a{white-space:nowrap;text-decoration:none;color:var(--muted);font-size:14.5px;font-weight:500;
  padding:12px;border-bottom:2px solid transparent}
.prof .secnav a:hover,.prof .secnav a.on{color:var(--ink);border-bottom-color:var(--green);text-decoration:none}

/* ---------- układ ---------- */
.prof .cols{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:34px;padding:30px 0 10px}
@media(max-width:900px){.prof .cols{grid-template-columns:minmax(0,1fr)}}
.prof main{min-width:0}
.prof .prof-sec{padding:6px 0 34px}
.prof main h2{font-size:24px;letter-spacing:-.01em;font-weight:800;margin:0 0 4px}
.prof .lead{color:var(--muted);font-size:14.5px;margin:0 0 18px;font-weight:400;line-height:1.6}
.prof .intro{font-size:15px;color:var(--ink);margin:0 0 22px;max-width:70ch}
.prof .intro p{margin:0 0 10px}

/* wyniki: tabela */
.prof .res-wrap{overflow-x:auto}
.prof table.res{width:100%;border-collapse:collapse;font-size:15px}
.prof table.res th,.prof table.res td{padding:10px;text-align:right;border-bottom:1px solid var(--line2);white-space:nowrap}
.prof table.res th:first-child,.prof table.res td:first-child{text-align:left;padding-left:0;white-space:normal}
.prof table.res thead th{font-size:13px;font-weight:600;color:var(--muted);border-bottom:1px solid var(--line)}
.prof table.res tbody tr[data-chart]{cursor:pointer}
.prof table.res tbody tr[data-chart]:hover td{background:var(--paper2)}
.prof table.res tbody tr.sel td:first-child{box-shadow:inset 3px 0 0 var(--green);font-weight:600;padding-left:10px}
.prof table.res tbody td:first-child{padding-left:10px}
.prof table.res td.now{font-weight:600;background:var(--green-soft);border-radius:4px}
.prof .delta{font-size:12.5px;margin-left:6px}
.prof .up{color:var(--good)} .prof .down{color:var(--bad)}
.prof .tblnote{font-size:12.5px;color:var(--muted);margin-top:10px}

/* wykres */
.prof .chartbox[hidden]{display:none}
.prof .chart{border:1px solid var(--line);border-radius:12px;padding:16px 16px 8px;margin-top:22px;overflow-x:auto}
.prof .chart h3{font-size:15px;font-weight:600;margin:0 0 2px;letter-spacing:0}
.prof .chart .sub{font-size:12.5px;color:var(--muted);margin:0 0 8px}
.prof .chart svg{display:block;min-width:520px;width:100%;height:auto}
.prof .l-dot{display:inline-block;width:10px;height:10px;border-radius:50%;background:var(--green);vertical-align:-1px;margin:0 4px 0 2px}
.prof .l-dash{display:inline-block;width:16px;border-top:2px dashed var(--muted);vertical-align:3px;margin:0 4px 0 8px}

/* paski percentyli */
.prof .pctl{margin-top:22px;display:grid;gap:12px}
.prof .pctl .row{display:grid;grid-template-columns:minmax(150px,220px) 1fr 52px;gap:12px;align-items:center;font-size:14px;margin:0}
.prof .pctl .row::before,.prof .pctl .row::after{display:none}
.prof .bar{height:10px;border-radius:5px;background:var(--line2);position:relative;overflow:hidden}
.prof .bar i{position:absolute;inset:0 auto 0 0;background:var(--green);border-radius:5px}
.prof .pctl .n{font-family:"Bricolage Grotesque",Inter,sans-serif;font-weight:600;text-align:right}
@media(max-width:520px){.prof .pctl .row{grid-template-columns:1fr 46px}.prof .pctl .row .bar{grid-column:1/-1;grid-row:2}}

/* informacje */
.prof .info{display:grid;grid-template-columns:1fr 1fr;gap:0 30px}
.prof .info dl{margin:0}
.prof .info dl>div{display:flex;justify-content:space-between;gap:16px;padding:10px 0;border-bottom:1px solid var(--line2);font-size:15px}
.prof .info dt{color:var(--muted);font-weight:400}
.prof .info dd{margin:0;font-weight:500;text-align:right}
@media(max-width:680px){.prof .info{grid-template-columns:1fr}}

/* mapa */
.prof .map{border:1px solid var(--line);border-radius:12px;overflow:hidden}
.prof .map #map-canvas{min-height:320px;height:320px;border:0;border-radius:0;background:var(--paper2)}
.prof .map iframe{display:block;width:100%;height:100%;border:0}
.prof .map .addr{padding:12px 16px;font-size:14.5px;display:flex;flex-wrap:wrap;gap:6px 18px}
.prof .map .addr a{font-weight:500}

/* w okolicy */
.prof .near{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}
.prof .near a{text-decoration:none;color:var(--ink);border:1px solid var(--line);border-radius:12px;
  padding:14px 16px;display:flex;flex-direction:column;background:var(--paper)}
.prof .near a:hover{border-color:var(--green);text-decoration:none}
.prof .near .nm{font-weight:600;font-size:15px;line-height:1.35;margin:0 0 6px}
.prof .near .meta{font-size:13px;color:var(--muted)}
.prof .near .sc{font-family:"Bricolage Grotesque",Inter,sans-serif;font-weight:600;color:var(--green);font-size:15px;margin-top:8px}
@media(max-width:900px){.prof .near{grid-template-columns:repeat(2,1fr)}}
@media(max-width:560px){.prof .near{grid-template-columns:1fr}}

/* kolumna boczna */
.prof .aside .card{border:1px solid var(--line);border-radius:12px;padding:18px;margin-bottom:22px;background:var(--paper)}
.prof .aside h3{font-size:15px;font-weight:600;margin:0 0 12px;letter-spacing:0}
.prof .aside .row{display:flex;justify-content:space-between;gap:10px;font-size:14.5px;padding:7px 0;
  border-bottom:1px solid var(--line2);margin:0}
.prof .aside .row::before,.prof .aside .row::after{display:none}
.prof .aside .row:last-child{border-bottom:none}
.prof .aside .row>span:first-child{color:var(--muted);flex:none}
.prof .aside .row>:last-child{text-align:right;overflow-wrap:anywhere}
.prof .aside table.mini{width:100%;font-size:14px;border-collapse:collapse;margin-bottom:6px}
.prof .aside table.mini th{font-size:12.5px;color:var(--muted);font-weight:600;text-align:right;padding:4px 0;border-bottom:1px solid var(--line)}
.prof .aside table.mini td{text-align:right;padding:7px 0;border-bottom:1px solid var(--line2);white-space:nowrap}
.prof .aside table.mini th:first-child,.prof .aside table.mini td:first-child{text-align:left;white-space:normal}
.prof .aside ul.links{list-style:none;margin:0;padding:0;font-size:14.5px}
.prof .aside ul.links li{padding:7px 0;border-bottom:1px solid var(--line2);line-height:1.4}
.prof .aside ul.links li:last-child{border-bottom:none}

/* stare sekcje (egzamin gimnazjalny) w nowym kontenerze */
.prof .prof-legacy .panel{margin-bottom:0}
@media(max-width:900px){.prof .fact{flex-direction:column;align-items:flex-start;gap:2px;padding:12px 14px}}

/* ---------- opinie (templates/_opinie.html) ---------- */
.prof .op-summary{display:flex;align-items:baseline;flex-wrap:wrap;gap:6px 12px;margin:6px 0 18px}
.prof .op-avg{font-family:"Bricolage Grotesque",Inter,sans-serif;font-weight:800;font-size:34px;line-height:1;
  padding:2px 8px;border-radius:4px;background:linear-gradient(104deg,transparent 4%,var(--marker) 5%,var(--marker) 96%,transparent 97%);color:var(--marker-ink)}
.prof .op-stars{color:#c99a00;letter-spacing:2px;font-size:17px}
.prof .op-cnt{color:var(--muted);font-size:14px}
.prof .op-list{display:grid;gap:14px;margin-bottom:22px}
.prof .op{border:1px solid var(--line);border-radius:12px;padding:16px 18px;background:var(--paper)}
.prof .op header{display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 12px;margin-bottom:8px}
.prof .op header b{font-weight:600}
.prof .op .op-stars{font-size:15px}
.prof .op-meta{font-size:13px;color:var(--muted)}
.prof .op-txt{font-size:15px;overflow-wrap:anywhere}

.prof .reviews{border:1px solid var(--line);border-radius:12px;padding:22px;background:var(--paper2)}
.prof .reviews-txt{margin:0 0 14px;max-width:52ch}
.prof .btn-op{display:inline-block;background:var(--green);color:#fff;font-weight:600;font-size:14.5px;
  border:none;border-radius:999px;padding:10px 20px;cursor:pointer}
.prof .btn-op:hover{filter:brightness(1.08)}
.prof .btn-op:disabled{opacity:.55;cursor:default;filter:none}
.prof .btn-op[hidden]{display:none}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]) .prof .btn-op{color:#0c1712}}

.prof .op-form{display:grid;gap:16px;margin-top:4px}
.prof .op-form[hidden]{display:none}
.prof .op-form label{display:block;font-weight:600;font-size:14px;margin:0}
.prof .op-form label small{font-weight:400;color:var(--muted)}
.prof .op-form input[type=text],.prof .op-form select,.prof .op-form textarea{
  display:block;width:100%;margin-top:6px;font:inherit;font-weight:400;font-size:15px;color:var(--ink);
  background:var(--paper);border:1px solid var(--line);border-radius:9px;padding:9px 12px}
.prof .op-form textarea{resize:vertical;min-height:130px}
.prof .op-form input:focus,.prof .op-form select:focus,.prof .op-form textarea:focus{outline:none;border-color:var(--green);box-shadow:0 0 0 3px var(--green-soft)}
.prof .op-row{display:grid;grid-template-columns:1fr 1fr;gap:16px}
@media(max-width:560px){.prof .op-row{grid-template-columns:1fr}}
.prof .op-hp{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}
.prof .op-rating{border:0;padding:0;margin:0;min-width:0}
.prof .op-rating legend{font-size:14px;font-weight:600;border:0;margin:0 0 4px;color:var(--ink);width:auto}
/* gwiazdki: radio w odwrotnej kolejności (5..1) + row-reverse, żeby :checked ~ label zaznaczało w lewo */
.prof .op-rate{display:inline-flex;flex-direction:row-reverse;gap:2px}
.prof .op-rate input{position:absolute;opacity:0;width:1px;height:1px}
.prof .op-rate label{font-size:30px;line-height:1;color:var(--line);cursor:pointer;font-weight:400;padding:0 2px}
.prof .op-rate input:checked ~ label,.prof .op-rate label:hover,.prof .op-rate label:hover ~ label{color:#e0ad00}
.prof .op-rate input:focus-visible + label{outline:2px solid var(--green);outline-offset:2px;border-radius:4px}
.prof .op-check{display:flex!important;gap:10px;align-items:flex-start;font-weight:400!important;font-size:13.5px!important}
.prof .op-check input{margin-top:3px;flex:none}
.prof .op-actions{display:flex;flex-wrap:wrap;align-items:center;gap:12px}
.prof .op-msg{font-size:14px}
.prof .op-msg.ok{color:var(--good)} .prof .op-msg.err{color:var(--bad)}
.prof .op-note{font-size:12.5px;color:var(--muted)}
