/* Prima del Live - correzioni conservative dell'interfaccia.
   Nessuna modifica a contenuti, palette principale, calcoli o esportazioni. */
:root { --pdl-nav-height:66px; }
html { scroll-padding-top:calc(var(--pdl-nav-height) + 18px); }
section[id] { scroll-margin-top:18px; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline:2px solid var(--a); outline-offset:3px;
}
.pdl-open-menu, .pdl-mobile-overlay { display:none; }
.pdl-open-menu {
  width:48px; height:48px; padding:0; margin:0; border:0;
  background:transparent; color:var(--t); cursor:pointer; touch-action:manipulation;
  flex:0 0 48px; align-items:center; justify-content:center; flex-direction:column; gap:5px;
}
.pdl-open-menu span {
  display:block; width:25px; height:2px; background:currentColor;
  transform-origin:center; transition:transform .22s ease, opacity .18s ease;
}
.pdl-open-menu.is-open span:nth-child(1) { transform:translateY(7px) rotate(45deg); }
.pdl-open-menu.is-open span:nth-child(2) { opacity:0; }
.pdl-open-menu.is-open span:nth-child(3) { transform:translateY(-7px) rotate(-45deg); }
.pdl-mobile-overlay {
  position:fixed; inset:0; z-index:99999; background:#090b0a;
  overflow:auto; overscroll-behavior:contain;
}
.pdl-mobile-links { padding:82px var(--p) max(32px,env(safe-area-inset-bottom)); }
.pdl-mobile-links a {
  display:block; padding:11px 0; border-bottom:1px solid #242724;
  color:var(--t); text-decoration:none; text-transform:uppercase; text-align:left;
  font-weight:800; font-size:clamp(19px,5.6vw,25px); line-height:1.08;
}
.pdl-mobile-links small {
  display:block; color:var(--a); font-size:9px; line-height:1;
  letter-spacing:.12em; margin-bottom:3px;
}
.hf .arrow { justify-self:start; }
.layout > *, .app > * { min-width:0; }
/* Il grigio resta neutro, ma i testi minuti non si perdono nel fondo. */
.pdl-site footer { color:#898d84; }
.pdl-configurator { --d:#898d84; --pdl-nav-height:62px; }
.pdl-configurator input, .pdl-configurator select, .pdl-configurator button { font-family:inherit; }
.pdl-configurator input[type=number], .pdl-configurator input[type=text], .pdl-configurator select {
  min-width:0; max-width:100%; border-radius:0; color-scheme:dark;
}
.pdl-configurator input[type=number] {
  background:#101110; color:var(--t); border:1px solid var(--l); padding:11px; width:100%;
}
.pdl-configurator input::placeholder { color:#999d94; opacity:1; }
.pdl-configurator .app { grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr); }
/* Le opzioni sono leggibili anche prima di aprire il menu nativo. */
.pdl-configurator .r { grid-template-columns:minmax(0,1fr) 170px; }
.pdl-configurator .r > div { display:grid; gap:5px; }
.pdl-configurator .r > input { width:94px; justify-self:end; }
.pdl-configurator .r > div > input { width:94px; justify-self:end; }
.pdl-configurator .r select { font-size:14px; }
.pdl-configurator .customrow, .pdl-configurator .pdl-custom-titles {
  display:grid; grid-template-columns:minmax(0,1.4fr) minmax(122px,1fr) 76px 40px; gap:8px;
}
.pdl-configurator .pdl-custom-titles {
  font-size:10px; color:var(--s); line-height:1.4; margin-top:16px;
}
.pdl-configurator .customrow { align-items:end; }
.pdl-configurator .customrow label { min-width:0; display:grid; gap:6px; }
.pdl-configurator .customrow label > span {
  position:absolute; width:1px; height:1px; overflow:hidden;
  clip-path:inset(50%); white-space:nowrap;
}
.pdl-configurator .customrow input, .pdl-configurator .customrow select,
.pdl-configurator .customrow .x, .pdl-configurator .drumextra .x { min-height:42px; }
.pdl-configurator .customrow .x, .pdl-configurator .drumextra .x { color:var(--s); font-size:20px; }
.pdl-configurator .band-details { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; margin-bottom:18px; }
.pdl-configurator .ch { grid-template-columns:28px minmax(0,1fr) 82px minmax(96px,1.15fr); }
.pdl-configurator .ch span { overflow-wrap:break-word; }
.pdl-configurator .stage-tools select { flex:1 1 240px; width:auto; }
.pdl-configurator .stage-tools button { flex:0 1 auto; }
.pdl-configurator .stage-inspector > *, .pdl-configurator .stage-meta label,
.pdl-configurator .stage-monitor-panel label { min-width:0; max-width:100%; }
.pdl-configurator .stage-monitor-panel label { flex-wrap:wrap; }
.pdl-configurator .stage-monitor-panel [hidden] { display:none; }
.pdl-configurator .stage-meta label { overflow-wrap:anywhere; }
.pdl-configurator #pdl-keyboard-mode-wrap { display:flex; flex-wrap:wrap; }
.pdl-configurator #pdl-source-count-wrap { flex-wrap:wrap; align-items:center; gap:8px; font-size:12px; }
.pdl-configurator #pdl-source-count { width:75px; }
/* Il palco conserva la scala: solo il riquadro scorre, non tutta la pagina. */
.pdl-configurator .stage-board-wrap {
  overflow:auto; overscroll-behavior-x:contain;
  scrollbar-width:thin; scrollbar-color:#64705d #101410;
}
.pdl-configurator .stage-board-wrap:focus-visible { outline:2px solid var(--a); outline-offset:3px; }
.pdl-configurator #stage-board { min-width:800px; touch-action:pan-x pan-y; }
.pdl-configurator .stage-item > span:not(.stage-rotate),
.pdl-configurator .stage-item > small.stage-ch-info {
  max-width:160px!important; font-size:11px!important; margin-top:0;
}
@media (min-width:761px) and (max-width:1180px) {
  .pdl-configurator .app { gap:32px; }
}
@media (max-width:1000px) {
  .pdl-configurator .app { grid-template-columns:minmax(0,1fr); gap:30px; }
  .pdl-configurator .side { position:static; }
}
@media (max-width:760px) {
  :root, .pdl-configurator { --pdl-nav-height:59px; }
  header nav { height:var(--pdl-nav-height); gap:12px; padding:0; }
  header nav > a { flex-shrink:0; }
  header nav .menu, header nav .links { display:none; }
  .pdl-open-menu { display:flex; margin-left:auto; }
  body > .pdl-open-menu.is-open {
    position:fixed; z-index:100002; top:calc((var(--pdl-nav-height) - 48px) / 2);
    right:var(--p); margin:0;
  }
  .pdl-mobile-overlay.is-open { display:block; }
  body.pdl-nav-open { overflow:hidden; }
  .pdl-configurator header nav > .micro { margin-left:auto; text-align:right; }
  .pdl-configurator header nav .pdl-open-menu { margin-left:0; }
  .pdl-configurator input[type=text], .pdl-configurator input[type=number],
  .pdl-configurator select, .pdl-configurator .ch .model-input { font-size:16px; }
  .pdl-configurator .r { grid-template-columns:minmax(0,1fr) 180px; }
  .pdl-configurator .v10-dimensions label { flex:0 1 150px; }
  .pdl-configurator .v10-dimensions input { width:100%; }
  .pdl-configurator .v10-extra input { width:75px; }
  .pdl-configurator .stage-tools { gap:8px; }
  .pdl-configurator .stage-tools select { flex-basis:100%; }
  .pdl-configurator .stage-tools button { flex:1 1 140px; }
  .pdl-configurator .stage-inspector button { min-height:42px; }
}
@media (max-width:600px) {
  .pdl-configurator .pdl-custom-titles { display:none; }
  .pdl-configurator .customrow {
    grid-template-columns:minmax(0,1fr) 76px 40px; gap:10px 8px;
    margin:14px 0; padding-bottom:14px; border-bottom:1px solid var(--l);
  }
  .pdl-configurator .customrow .custom-name { grid-column:1 / 3; grid-row:1; }
  .pdl-configurator .customrow .custom-connection { grid-column:1; grid-row:2; }
  .pdl-configurator .customrow .custom-count { grid-column:2 / 4; grid-row:2; }
  .pdl-configurator .customrow .x { grid-column:3; grid-row:1; }
  .pdl-configurator .customrow label > span {
    position:static; width:auto; height:auto; overflow:visible; clip-path:none;
    white-space:normal; color:var(--s); font-size:11px;
  }
  .pdl-configurator .customrow .custom-count input { width:100%; }
}
@media (max-width:540px) {
  .pdl-configurator .band-details { grid-template-columns:1fr; }
  .pdl-configurator .ch { grid-template-columns:26px minmax(0,1fr) 90px; gap:6px 8px; font-size:12px; }
  .pdl-configurator .ch .model-input { grid-column:2 / -1; padding:10px 8px; }
  .pdl-configurator .ch.head { font-size:10px; }
  .pdl-configurator .ch.head span:nth-child(4) { grid-column:2 / -1; }
  .pdl-configurator .r > input, .pdl-configurator .r > div > input { width:75px; }
}
@media (max-width:400px) {
  .pdl-configurator header nav > .micro { max-width:68px; font-size:9px; letter-spacing:.1em; }
  .pdl-configurator .r:has(select) { grid-template-columns:1fr; gap:8px; }
  .pdl-configurator .r:has(select) > div { grid-template-columns:75px minmax(0,1fr); gap:8px; }
  .pdl-configurator .r:not(:has(select)) { grid-template-columns:minmax(0,1fr) 75px; }
  .pdl-configurator .customrow { grid-template-columns:minmax(0,1fr) 60px 40px; }
  .pdl-configurator .v10-dimensions label { flex:1 1 110px; }
  .pdl-configurator .v10-dimensions button { flex:1 1 120px; }
}
@media (prefers-reduced-motion:reduce) {
  html { scroll-behavior:auto; }
  .pdl-open-menu span { transition:none; }
}
