/* Round 2: phone/tablet only. Desktop starts at 1100px. */
@media (width < 1100px) {
  body .rail a.ghost {
    display:flex;
    width:fit-content;
    min-height:44px;
    margin-top:12px;
  }
  body .work .rail a.ghost+a.ghost { margin-top:12px; }

  /* One compact bar, with navigation always available inside it. */
  html.phone-bar-active { --navoff:0px!important; scroll-padding-top:72px; }
  html.phone-bar-active body .snav {
    transform:translateY(-101%);
    visibility:hidden;
    pointer-events:none;
  }
  body .wbar.on { transform:none; }
  body .wbar-in {
    height:55px;
    min-height:55px;
    padding:5px var(--gut);
    gap:12px;
  }
  body .wbar .btn { min-height:44px; padding:8px 16px; }
  body .wbar-t b { font-size:18px; }
  body .bar-menu {
    display:inline-flex;
    justify-content:center;
    align-items:center;
    flex:none;
    min-width:66px;
    min-height:44px;
    padding:8px 12px;
    border:1px solid var(--rule-2);
    font-size:16px;
    line-height:1.4;
  }
  body .filters { top:0; transition:none; }
  body .filters .wrap {
    min-height:54px;
    height:54px;
    scrollbar-width:none;
    padding-top:5px;
    padding-bottom:5px;
    margin-right:calc(var(--gut) + 78px);
    padding-right:24px;
    align-items:center;
  }
  body .filters .bar-menu { position:absolute; right:var(--gut); top:5px; }
  body .filters::after {
    content:'›';
    position:absolute;
    right:calc(var(--gut) + 78px);
    top:5px;
    width:32px;
    height:44px;
    display:flex;
    align-items:center;
    justify-content:end;
    background:linear-gradient(90deg,transparent,var(--paper) 65%);
    color:var(--brick);
    font-size:26px;
    pointer-events:none;
  }
  body .filters[data-scroll-end]::after { opacity:0; }
  body .filters .fgroup { align-items:center; }
  /* Labeled selects remain in the page flow below the compact chip bar. */
  body .phone-filter-fields {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:16px;
    padding:20px var(--gut);
    border-bottom:1px solid var(--rule);
  }
  body .phone-filter-fields .fgroup { display:grid; gap:6px; }
  body .phone-filter-fields .fgroup>.lbl { display:block; }
  body .phone-filter-fields .fsort { display:contents; }
  body .phone-filter-fields select { min-height:44px; width:100%; font-size:16px; }

  body #olympeion-credit {
    position:static;
    display:flex;
    align-items:center;
    min-height:44px;
    max-width:100%;
    margin-top:24px;
    padding:10px 12px;
    font-size:12px;
    background:var(--sheet);
    opacity:1;
    visibility:visible;
    pointer-events:auto;
    transition:none;
  }
  body .foot { padding-bottom:max(32px,env(safe-area-inset-bottom)); }
  body .foot .bottom>span:last-child { display:grid; justify-items:start; font-size:0; }
  body .foot .bottom a { display:flex; align-items:center; min-height:44px; font-size:15px; }
  body :is(.crumbs a,.adviser-email,.listing-mail,.c-info a) {
    display:inline-flex;
    align-items:center;
    min-height:44px;
    padding-top:8px;
    padding-bottom:8px;
  }
  body .crumbs { align-items:center; }
  body .formnote a { display:inline-flex; align-items:center; min-height:44px; }
  body .tax-form label { display:grid; gap:6px; }
  body .tax-form label>.lbl { display:block; }
  body .tax-form .sel { display:block; position:relative; }
  body .tax-form .sel::after { position:absolute; right:6px; top:50%; pointer-events:none; }
  body .tax-form .sel select { min-height:44px; width:100%; padding-right:24px; font-size:16px; }
  body .slider input { height:44px; min-height:44px; }
  body .slider input::-webkit-slider-thumb { width:28px; height:28px; }
  body .slider input::-moz-range-thumb { width:28px; height:28px; box-sizing:border-box; }

  body :is(.sun-footnote,.plan-colophon,.case-facts,.case-summary p,
    .dossier-details .kgroup dt,.dossier-adviser .adviser-hours,
    .property-plan .light-note h3 span,.layers-tag,.card-light>span>span,
    .sun-hours button span,.day-hours button span,.plan-pan-hint,
    .room-enlarge,.case-tabs button span,.spine .property-adviser a:last-child) {
    font-size:14px;
  }
  body .r1-case .case-facts,body .r1-layers .day-hours button span { font-size:14px; }
  body .confirmation-note { font-size:14px!important; }
  body .plan-enlarged-canvas svg { min-width:1000px; max-width:none; max-height:none; }
  body .plan-enlarged-canvas text { font-size:max(12px,1em); }
  body .plan-pan-hint { display:block; }
  body .phone-plan {
    width:calc(100% - 24px);
    max-width:1000px;
    max-height:90dvh;
    margin:auto;
    padding:20px;
    border:1px solid var(--rule);
    background:var(--sheet);
    color:var(--ink);
    overflow:auto;
  }
  body .phone-plan::backdrop { background:rgba(27,25,22,.65); }
  body .phone-plan>header { display:flex; align-items:center; justify-content:space-between; gap:16px; }
  body .phone-plan .plan-enlarged-canvas { overflow-x:auto; margin-top:20px; }
  body .phone-plan .plan-enlarged-canvas svg { display:block; width:1000px; height:auto; }
  body .phone-plan .plan-pan-hint { margin-top:16px; }
  /* These documentary rows intentionally swipe. Keep each complete caption reachable. */
  body .band-row { scroll-padding-inline:var(--gut); }
  body .band-row figure { scroll-snap-align:start; }
  body .g-tabs { scroll-padding-inline:3px; }
  body .filters .wrap::-webkit-scrollbar { display:none; }
}
@media (width < 700px) {
  body .wbar-t { display:none; }
  body .wbar .btn { flex:1; }
}
