/* Consistent app viewport and touch controls across customer and owner pages. */
html{-webkit-text-size-adjust:100%;text-size-adjust:100%;width:100%;overflow-x:clip}
body{min-width:0;max-width:100%;touch-action:pan-x pan-y}
button,a{touch-action:manipulation}
input,select,textarea{min-width:0;max-width:100%}
img,video,canvas,iframe{max-width:100%}
.content,.view,.layout,#screen,#booking-flow,#root,.portal-order,.portal-motion-card{min-width:0}
.portal-google-review-action{display:flex;align-items:center;justify-content:center;width:100%;min-height:44px;padding:12px 14px;border:1px solid #d7b243;border-radius:9px;background:#ffcf32;color:#171717;font-size:14px;font-weight:700;line-height:1.5;text-align:center;text-decoration:none;overflow-wrap:anywhere}
.portal-google-review-action:focus-visible{outline:3px solid #8b6700;outline-offset:3px}
.portal-google-review-thanks{margin:10px 0 0;text-align:center;color:#70461c;font-size:14px;font-weight:650;line-height:1.5}
#screen .portal-tabs .portal-history-count.has-history{color:#c62828;font-weight:900}
#screen .portal-tabs button[aria-selected="true"] .portal-history-count.has-history{color:#ff7878}

@media(max-width:680px){
 /* 16px prevents mobile Safari from zooming when a field receives focus. */
 input,select,textarea,body input,body select,body textarea{font-size:16px!important}
 input:not([type=checkbox]):not([type=radio]),select,textarea{box-sizing:border-box;max-width:100%}
 main,.layout,.content,.view,#screen,#root{max-width:100%;min-width:0}
 body.restored-portal>main{width:100%;padding:10px 10px max(24px,env(safe-area-inset-bottom))}
 #screen{width:100%}
 .restored-portal #screen .portal-brand{gap:8px!important}
 #screen .portal-brand>a.portal-brand-home{flex-shrink:1;min-width:0}
 #screen .portal-brand-home>div{min-width:0}
 #screen .portal-brand-home strong,#screen .portal-brand-home span{overflow-wrap:anywhere}
 .portal-contact-icons{flex-shrink:0;min-width:0}
 .portal-language-select{height:36px;min-width:0}
 .portal-section-title{flex-wrap:wrap;min-width:0}
 .portal-section-title>button{width:auto;flex:1 1 auto;min-width:0}
 .portal-section-title>span{overflow-wrap:anywhere}
 .portal-tabs,.booking-bike-grid,.guest-entry-buttons,.checkout-fields,.form-grid{min-width:0}
 .portal-tabs>button,.guest-entry-buttons>button{min-width:0;white-space:normal;overflow-wrap:anywhere}
 .portal-order-heading>strong,.portal-order-heading>span{min-width:0;overflow-wrap:anywhere}
 .portal-dates>span,.portal-money>span,.booking-summary>div{flex-wrap:wrap;min-width:0}
 .portal-dates strong,.portal-money strong,.booking-summary dd{max-width:100%;overflow-wrap:anywhere}
 .portal-bike-summary>div,.summary-bike>div{min-width:0;overflow-wrap:anywhere}
 .portal-order-detail-grid>div,.customer-fields>div,.record-form>label{min-width:0}
 .portal-order-detail-grid strong,.customer-fields dd{overflow-wrap:anywhere}
 dialog:not(.portal-history-dialog){max-width:calc(100% - 24px);max-height:calc(100dvh - 24px);overflow:auto;box-sizing:border-box}
 .calendar-scroll,.table-card,.table-wrap{min-width:0;max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
 .topbar,.workspace-header,.page-heading,.order-tools{min-width:0}
 .topbar-actions{flex-wrap:wrap;max-width:100%}
 .order-tools{grid-template-columns:minmax(0,1fr)}
 .metrics,.quick-grid,.fleet-grid,.record-form,.customer-heading{min-width:0}
 .metric,.record-card,.order-card,.customer-card,.fleet-card{min-width:0;overflow-wrap:anywhere}
 .record-form{grid-template-columns:minmax(0,1fr)}
 .record-form .wide{grid-column:auto}
 .report-line>span,.report-line>strong{min-width:0;overflow-wrap:anywhere}
 .report-line{flex-wrap:wrap}
 /* Embedded motorcycle selection uses the same field sizes and available width. */
 .portal-shell,.booking-wrap,.booking-card,.booking-date-controls,.date-grid,.pickup-choice,.bike-grid{min-width:0;max-width:100%}
 .date-grid,.pickup-choice{grid-template-columns:minmax(0,1fr)}
}
@media(max-width:380px){
 .restored-portal #screen .portal-brand{padding:10px 8px!important;gap:6px!important}
 #screen .portal-brand-home img{width:28px;height:28px;flex-shrink:0}
 #screen .portal-brand-home strong{font-size:11px;letter-spacing:.03em}
 #screen .portal-brand-home span{font-size:8px}
 #screen .portal-brand>a.portal-brand-home{gap:5px!important}
 #screen .portal-brand>.portal-contact-icons{gap:4px!important}
 #screen .portal-contact-icons a{width:28px!important;height:32px!important;min-width:28px}
 #screen .portal-language-select{width:60px!important;padding:0 2px!important}
 .restored-portal .guest-entry-buttons{grid-template-columns:1fr 1fr}
 .restored-portal .guest-entry-buttons .guest-price-button{grid-column:1/-1}
 .customer-heading{grid-template-columns:minmax(0,1fr)}
}
