/* Pizza Style Profiler v119E.3.7.9.49.51 — consolidated UI Polish & Navigation.
   Screen presentation only. Print layouts intentionally unchanged for the next sprint. */
@media screen {
  :root{--psp-ui-gap:6px;--psp-ui-pad:10px;--psp-ui-line:1.34}
  body{line-height:var(--psp-ui-line)}
  details.card{margin-block:7px}
  details.card>summary{padding:9px 11px;line-height:1.22}
  details.card>.inner{padding:9px 11px}
  .card .row{margin-block:4px;padding-block:3px}
  .note,.small,.helpText{line-height:1.35}
  .pspReadabilityScope p{margin:4px 0}
  .pspReadabilityScope ul,.pspReadabilityScope ol{margin:4px 0 7px;padding-left:18px}
  .pspReadabilityScope li{margin:2px 0}
  .pspReadabilityScope h2,.pspReadabilityScope h3,.pspReadabilityScope h4{margin:8px 0 4px;line-height:1.22}
  .pspReadabilityScope table{margin-block:5px}
  .pspReadabilityScope th,.pspReadabilityScope td{padding:5px 6px;line-height:1.28}

  /* At-a-glance: compact enough to keep shortcuts nearby on iPhone. */
  #pspV98AtGlanceCard{margin:6px 8px}
  #pspV98AtGlanceCard>summary{padding:8px 10px}
  #pspV98AtGlanceBody{padding:7px 9px}
  #pspV98AtGlanceBody .pspV98GlanceGrid{gap:5px!important}
  #pspV98AtGlanceBody .pspV98FactGroup{padding:6px 8px!important}
  #pspV98AtGlanceBody .pspV98FactGroup h3{font-size:.92rem;margin:0 0 3px}
  #pspV98AtGlanceBody .pspV98FactGroup p,#pspV98AtGlanceBody li{margin:1px 0;line-height:1.25}
  #pspV98AtGlanceBody .pspV98Concepts{padding:6px 8px!important;margin-top:5px!important}
  #pspV98AtGlanceBody .pspV98Concepts ul{margin:3px 0 0;padding-left:17px}
  #pspV98AtGlanceBody .pspV98GlanceActions{gap:5px!important;margin-top:6px!important}
  #pspV98AtGlanceBody .pspV98GlanceActions button{min-height:34px;padding:6px 8px;font-size:.86rem}

  /* Timeline: tighter rhythm, date grouping, and dominant times. */
  #timeline{font-size:.93em}
  #timeline p,#timeline li,#timeline .row{line-height:1.28;margin-block:2px}
  #timeline table{border-spacing:0}
  #timeline th,#timeline td{padding:5px 5px}
  #timeline .pspTimelineTime{font-weight:850;font-size:1.04em;white-space:nowrap;color:#173f2d}
  #timeline .pspTimelineDateGroup{margin-top:8px;padding:5px 7px;border-radius:7px;background:#eef5f0;font-weight:850;letter-spacing:.01em}
  #timeline .pspTimelineItem{padding-block:3px;border-bottom:1px solid rgba(31,78,120,.10)}

  /* Fermentation hierarchy. Existing controls and calculations remain in place. */
  .pspFermentationPolishScope .pspUiRoleHeading{font-weight:850;color:#174f38;margin:7px 0 3px}
  .pspFermentationPolishScope .pspUiLearningBlock,
  .pspFermentationPolishScope .pspUiAdvancedBlock{font-size:.94em}
  #pspV87FermentationCurrentBatch,#pspFermentationPrefermentCurrentBatchV87,
  #fermentationLoadEngine,#fermentationIdentity,#pspV84ContainerGuidance{line-height:1.32}
  #pspV84ContainerGuidance p,#pspV84ContainerGuidance li{margin-block:2px}

  /* Warning Center: compact, actionable, and scan-first. */
  #pspV49WarningCenter,#pspActionableWarningCenterV883{line-height:1.3}
  #pspV49WarningCenter p,#pspActionableWarningCenterV883 p{margin:3px 0}
  #pspV49WarningCenter ul,#pspActionableWarningCenterV883 ul{margin:3px 0 6px;padding-left:18px}
  #pspV49WarningCenter li,#pspActionableWarningCenterV883 li{margin:2px 0}
  #pspV49WarningCenter button,#pspActionableWarningCenterV883 button{min-height:34px;padding:6px 9px}
  .pspWarningCompactGroup{padding:7px 9px!important;margin:5px 0!important}

  /* Procedure and kitchen recipe: action-oriented scan density. */
  #procedure,#kitchenRecipe{font-size:.95em}
  #procedure p,#kitchenRecipe p{margin:3px 0;line-height:1.31}
  #procedure li,#kitchenRecipe li{margin:2px 0;line-height:1.31}
  #procedure h3,#procedure h4,#kitchenRecipe h3,#kitchenRecipe h4{margin:7px 0 3px}

  /* Consistent mobile cards and no accidental horizontal overflow. */
  main,section,.inner,.card{min-width:0}
  .inner>*{max-width:100%}
  input,select,textarea,button{max-width:100%}
}
@media screen and (max-width:520px){
  body{font-size:15px}
  header{padding:8px 10px}
  header h1{font-size:1.2rem;margin:0}
  header p{font-size:.78rem;margin:2px 0 0}
  .stickyControlBar{gap:4px;padding:5px 6px}
  .stickyControlBar button{min-height:32px;padding:5px 7px;font-size:.78rem}
  details.card{margin-block:5px;border-radius:9px}
  details.card>summary{padding:8px 9px;font-size:.94rem}
  details.card>.inner{padding:7px 9px}
  #pspV98AtGlanceBody .pspV98GlanceGrid{grid-template-columns:1fr 1fr!important}
  #pspV98AtGlanceBody .pspV98FactGroup{font-size:.82rem}
  #pspV98AtGlanceBody .pspV98FactGroup:nth-child(n+3){grid-column:span 1}
  #pspV98AtGlanceBody .pspV98Concepts{font-size:.82rem}
  #timeline{font-size:.88em}
  #timeline th,#timeline td{padding:4px}
  #procedure,#kitchenRecipe{font-size:.91em}
}
@media screen and (max-width:390px){
  #pspV98AtGlanceBody .pspV98GlanceGrid{grid-template-columns:1fr!important}
  #pspV98AtGlanceBody .pspV98FactGroup{grid-column:auto!important}
  .stickyControlBar button{font-size:.74rem;padding-inline:6px}
}
