/* Tharvik - phonefit.css (2026-10-27): the app fits a phone screen (header on one line, no zoom, no sliding). Pairs with js/phonefit.js. */

/* iOS zooms the whole page the moment you tap a text field whose letters are smaller than 16px (and often stays zoomed): every field is 16px */
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):not([type="color"]), textarea, select{ font-size:16px !important; }

/* the header always holds "THARVIK AI" on one line; the tagline gives way (…) before the name does */
header > div:not(.header-spacer){ min-width:0; }
.wordmark{ white-space:nowrap; }
.tagline{ white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
@media (max-width:420px){
  header{ gap:6px; }
  header .emblem{ width:30px; height:30px; }
  .wordmark{ font-size:17px; letter-spacing:.05em; }
  .ai-badge{ font-size:9px; padding:2px 5px; }
  #hoyBtn{ padding:0 6px; gap:4px; }
}
@media (max-width:365px){ .wordmark{ font-size:15.5px; } }
/* the installed app is one fixed screen: nothing under it scrolls or bounces, and a pinch does nothing */
html.store-app, html.store-app body{ overflow:hidden; overscroll-behavior:none; touch-action:pan-x pan-y; }

/* In the store app the page is kept clear of the clock and the home bar (storemode.css), which left the side menu stopping short of both edges, with a band of
   another shade above and below it. The menu is a fixed layer instead (so it covers the whole screen) and its content keeps clear of the clock and the home bar. */
html.store-app #sidePanel{ position:fixed; inset:0; }
html.store-app .side-sheet{ padding-top:calc(18px + var(--sat, env(safe-area-inset-top, 0px))); padding-bottom:calc(18px + var(--sab, env(safe-area-inset-bottom, 0px))); }
/* The same for every feature screen (Today, Calendar, Calories, Team, Settings, ...): each one is a fixed full-screen layer, so its colour glow starts at the true top of the
   screen and its background reaches the true bottom; its content keeps clear of the clock and the home bar through the padding (2026-10-28). The plan reveal and the
   celebration already size their own padding for a full-screen layer. */
html.store-app #app > [id$="Panel"]:not(#sidePanel){ position:fixed; inset:0; padding-top:var(--sat, env(safe-area-inset-top, 0px)); padding-bottom:var(--sab, env(safe-area-inset-bottom, 0px)); }
html.store-app #planReveal, html.store-app #celebrate{ position:fixed; inset:0; }
/* 2026-11-12: while the keyboard is up (phonefit.js sets html.kb-open) it covers the home / navigation bar, so the strip kept for that bar is zero: no black gap
   between the app and the keyboard. Must beat the inline --sab that phonefit.js writes for Android. */
html.kb-open{ --sab:0px !important; }
/* and the message bar sits close above the keyboard (the 16-20px breathing room under it only makes sense above the home bar, with the keyboard down) */
html.kb-open #app #inputRow{ margin-bottom:6px; }
/* --sat / --sab are the room kept for the system bars. They are the phone's own numbers (env) unless phonefit.js has to supply them: an Android web view that draws the page under the status and navigation bars but reports no size for them (2026-10-28). */
