/* HUU 9.0.57: Safari focuses inputs without automatic viewport zoom. Do not
   set maximum-scale or user-scalable=no; the user keeps pinch-to-zoom. */
@media (max-width: 760px) {
  html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
  .auth-screen input:not([type="checkbox"]):not([type="radio"]),
  .auth-screen select, .auth-screen textarea,
  .app-shell input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
  .app-shell select, .app-shell textarea,
  #invoice-form .invoice-core-grid .huu-invoice-dates>label>input,
  #invoice-form .invoice-core-grid .huu-invoice-dates>label>select {
    font-size: 16px !important;
  }
}
.huu-register-extra { display: grid; gap: 13px; margin: 14px 0 16px; }
.huu-register-extra[hidden] { display: none !important; }
.huu-register-plans { border:0; padding:0; margin:0; min-width:0; }
.huu-register-plans legend { color:#24313d; font-size:13px; font-weight:650; margin:0 0 10px; }
.huu-register-plans { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; }
.huu-register-plans legend { grid-column:1/-1; }
.huu-register-plans label { position:relative; cursor:pointer; border:1px solid #e7e0d7; padding:10px 8px; border-radius:11px; display:flex; align-items:center; gap:8px; background:#fff; min-width:0; }
.huu-register-plans label:has(input:checked){ border-color:#e7792a;background:#fff3e9;box-shadow:0 0 0 1px #e7792a; }
.huu-register-plans input { width:16px;height:16px;flex:0 0 16px;accent-color:#e7792a; }
.huu-register-plans label>span { display:grid; gap:3px; }
.huu-register-plans strong {color:#1f2730;font-weight:650; font-size:13px;}
.huu-register-plans small {color:#5d6871;font-size:11px;white-space:nowrap;}
.huu-auth-vat {display:grid;gap:7px;color:#293641;font-size:13px;font-weight:600;}
.huu-auth-vat select {width:100%;height:44px;border-radius:9px;border:1px solid #d5dce3;background:white;color:#1f2934;padding:8px 10px;}
.huu-registration-info {font-size:11px;line-height:1.55;color:#65717a;margin:0;}
.huu-billing-panel { max-width:100%; }
.huu-billing-heading h2 {margin:0;font-size:19px;color:#202b32;font-weight:650;}
.huu-billing-heading p{margin:5px 0 15px;font-size:13px;color:#63707b;}
.huu-billing-plans{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;}
.huu-billing-option{border:1px solid #dfe5e8;border-radius:12px;padding:16px;min-width:0;display:flex;flex-direction:column;justify-content:space-between;gap:14px;background:#fff;}
.huu-billing-option>div {display:grid;gap:4px;}
.huu-billing-option strong{font-size:16px;color:#192b38;font-weight:700;}
.huu-billing-option small{font-size:13px;color:#66727e;}
.huu-billing-option button{font-size:13px;min-height:38px;}
.huu-billing-option.is-current{border-color:#2f9961;background:#f3faf6;}
.huu-billing-option.is-requested{border-color:#e88a3e;background:#fff9f3;}
.huu-billing-message {font-size:12px;line-height:1.6;color:#667480;margin:15px 0 8px;}
.huu-vat-alert, .huu-vat-profile-alert {border:1px solid #eab788;color:#734614;background:#fff8ed;padding:12px 14px;border-radius:10px;font-size:13px;line-height:1.55;}
.huu-vat-alert[hidden],.huu-vat-profile-alert[hidden]{display:none!important;}
@media(max-width:620px){
  .huu-billing-plans{grid-template-columns:1fr;gap:9px;}
  .huu-billing-option{flex-direction:row;align-items:center;gap:12px;padding:12px;}
  .huu-billing-option button{min-width:124px;}
  .huu-register-plans{grid-template-columns:1fr 1fr 1fr;gap:5px;}
  .huu-register-plans label{gap:5px;padding:9px 6px;}
  .huu-register-plans small{font-size:10px;}
}
@media(max-width:760px){
  /* The bottom navigation must not cover invoice inputs while iOS keyboard is up. */
  body:has(.app-shell input:focus, .app-shell select:focus, .app-shell textarea:focus) .bottom-nav { display:none!important; }
}
/* Hidden screens must not leak into layout even if an older component stylesheet
   declares display:grid/flex on the same element. */
[hidden] { display:none!important; }
@media (max-width:760px) {
  html body #app :is(#invoice-form,#personal-reminder-form,#contact-form,#expense-form,#recurring-form,#quote-form,#price-form,#profile-form,#goal-form,#settings-form,#category-editor)
  :is(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),select,textarea) {
    font-size:16px!important;
  }
}
