/* Opt-in class is set only for phone-sized touch devices; tablet/desktop untouched. */
.mobile-dock-grip{display:none}
html.phone-house-dock body.editing{overflow:hidden;overscroll-behavior:none}
html.phone-house-dock .stage{left:0;right:0;bottom:0;max-width:none}
html.phone-house-dock body.editing #dock{
  display:flex!important;flex-direction:column;left:0;right:0;width:auto;top:var(--phone-dock-top,45dvh);
  bottom:var(--phone-dock-bottom,0px);height:auto;max-height:none;overflow:hidden;
  padding:0;border-radius:17px 17px 0 0;background:#fff;
}
html.phone-house-dock .mobile-dock-grip{
  display:flex;align-items:center;justify-content:center;gap:6px;font-size:11px;color:#777;flex:0 0 36px;
  width:100%;min-height:36px;border:0;padding:0;background:transparent;
  touch-action:none;cursor:ns-resize;user-select:none;-webkit-user-select:none;
}
html.phone-house-dock .mobile-dock-grip .grip-bar{display:block;width:44px;height:5px;border-radius:9px;background:#c1c4ca}
html.phone-house-dock #dock .dock-in{
  flex:1 1 auto;min-height:0;width:100%;max-width:none;margin:0;
  overflow-y:auto;overscroll-behavior-y:contain;-webkit-overflow-scrolling:touch;
  padding:0 8px calc(14px + env(safe-area-inset-bottom));
}
html.phone-house-dock .mobile-dock-grip:focus-visible{outline:2px solid #ed1c24;outline-offset:-3px}

html.phone-house-dock .sliderow{position:static;inset:auto;width:100%;padding:0;border:0;border-radius:0;box-shadow:none;background:transparent}
html.phone-house-dock .desktop-actions{display:none}
html.phone-house-dock .feature-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;margin-top:4px}
html.phone-house-dock .feature-actions button{min-height:34px;padding:4px;font-size:11px;white-space:normal}
html.phone-house-dock .btns{grid-template-columns:repeat(2,minmax(0,1fr));gap:4px;margin-top:4px}
html.phone-house-dock .btns button{min-height:40px;padding:7px 3px}
html.phone-house-dock .radius-panel[open]{max-height:none;overflow:visible}

/* V80: match the 14px section title across phone controls. */
html.phone-house-dock #dock button,
html.phone-house-dock #dock label,
html.phone-house-dock #dock summary,
html.phone-house-dock #dock .deg,
html.phone-house-dock #dock .radius-status,
html.phone-house-dock #clearSelections,
html.phone-house-dock #assistPanel,
html.phone-house-dock #assistPanel button,
html.phone-house-dock .axislabel .dir,
html.phone-house-dock .axislabel .cap{font-size:14px}
html.phone-house-dock #dock button{line-height:1.3;white-space:normal;min-height:40px}
html.phone-house-dock #dock .mobile-dock-grip{flex-basis:40px}
html.phone-house-dock #dock .radius-options{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}
html.phone-house-dock #dock .radius-options label{padding:7px;gap:7px;min-height:38px}
html.phone-house-dock #dock .radius-options input,
html.phone-house-dock #hideFanText{width:18px;height:18px;flex-shrink:0}
html.phone-house-dock #dock .sliderow .deg{width:35px}

/* V81: expanded metric controls and export beside the existing image arrow. */
html.phone-house-dock #dock .radius-panel{
  box-sizing:border-box;width:100%;max-width:none;min-width:0;padding:12px 10px;
  grid-column:1 / -1;align-self:stretch;margin:8px 0;
}
html.phone-house-dock #dock .radius-panel summary,
html.phone-house-dock #dock .radius-panel label,
html.phone-house-dock #dock .radius-panel .radius-status,
html.phone-house-dock #dock .radius-panel button{font-size:16px;line-height:1.45}
html.phone-house-dock #dock .radius-options{gap:10px}
html.phone-house-dock #dock .radius-options label{min-height:46px;padding:10px;gap:10px}
html.phone-house-dock .house-image-actions{display:none!important}
html.phone-house-dock #newImg{display:block;top:50px;left:10px}
html.phone-house-dock .canvas-wrap #save{
  position:absolute;top:8px;right:8px;z-index:49;display:flex;align-items:center;
  justify-content:center;height:38px;min-height:38px;width:auto;min-width:104px;
  padding:8px 12px;border:1px solid #fff8;border-radius:12px;background:#ed1c24;
  color:#fff;font-size:16px;font-weight:700;box-shadow:0 3px 12px #0004;
}
.phone-save-overlay{
  position:fixed;inset:0;z-index:10000;background:#000b;display:grid;place-items:center;
  overflow:auto;padding:16px;touch-action:auto;
}
.phone-save-overlay section{
  width:min(100%,480px);max-height:90dvh;overflow:auto;padding:16px;background:#fff;
  border-radius:16px;color:#202124;box-sizing:border-box;overscroll-behavior:contain;
}
.phone-save-overlay h2{font-size:20px;margin:0 0 10px}
.phone-save-overlay p{font-size:16px;line-height:1.5;margin:10px 0}
.phone-save-overlay img{display:block;width:100%;height:auto;max-height:50dvh;object-fit:contain;-webkit-touch-callout:default;user-select:auto;touch-action:auto}
.phone-save-overlay section>div{display:flex;flex-wrap:wrap;gap:8px}
.phone-save-overlay button,.phone-save-overlay a{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:8px 12px;font:700 16px "SVN Century Gothic",Arial,sans-serif;border-radius:9px;text-decoration:none;box-sizing:border-box}
.phone-save-overlay .phone-save-share{color:#fff;background:#ed1c24;border-color:#ed1c24}
.phone-save-overlay .phone-save-download{color:#a51e25;border:1px solid #e7cacc}
.phone-save-overlay [hidden]{display:none!important}

/* V82: both image actions share the same top edge and height on phones. */
html.phone-house-dock #clearSelections{top:8px;left:8px;height:38px;min-height:38px}
