.mobile-view-short{display:none}
/* Phone-only rules: tablet and desktop retain their established composition. */
@media(max-width:650px),(max-width:950px) and (max-height:500px){
 body{overscroll-behavior:none}
 .topbar,.topbar:has(.tools[hidden]){padding:5px 14px}
 .brand-logo{width:136px}.brand{gap:1px}.brand-copy small{font-size:7px}
 #steps{padding:3px 7px;gap:3px}#steps button{min-height:32px;font-size:10px;padding:4px 2px}
 .flow-screen{padding:8px 12px 5px;--content-offset:0px!important}
 .screen-heading{padding-top:0;margin-bottom:6px}.screen-heading h1{font-size:23px;margin-bottom:6px}
 .screen-heading .eyebrow{font-size:9px;margin-bottom:4px}.screen-heading>p:not(.eyebrow){font-size:13px;line-height:1.3}
 .flow-meta{height:16px;padding-top:2px}.screen-body{gap:10px}
 footer{padding:5px 10px max(5px,env(safe-area-inset-bottom));min-height:52px}footer button{min-height:40px;padding:6px 10px}footer span{font-size:10px}
 .flow-screen[data-key="personal"]{padding-top:8px}.flow-screen[data-key="personal"] .screen-heading{margin-bottom:7px}
 .flow-screen[data-key="personal"] .journey-notice{height:auto;min-height:0;line-height:1.3}
 .flow-screen[data-key="personal"] .screen-body,.screen-body[data-editing="true"]{overflow:hidden}
 .field{font-size:14px}.field input,.field select,.flow-screen[data-key="personal"] .field input,.date-input{min-height:44px;font-size:16px;padding:8px 11px;margin-top:4px}
 .age-line{padding-top:3px}.consent-card{font-size:14px;line-height:1.4;padding:12px}
 .permission-content p,.mobile-permission p{font-size:14px;line-height:1.4;margin:0}
 .mobile-permission>.text-btn{justify-self:start;font-size:14px;min-height:36px}
 .review-screen .analysis-overview{display:grid;grid-template-columns:minmax(110px,.85fr) minmax(0,1.15fr);grid-template-rows:minmax(0,1fr) 46px;gap:7px 10px;height:100%;max-width:none;overflow:hidden}
 .review-screen .map-controls{display:contents}
 .review-screen .result-visual{grid-column:1;grid-row:1;display:flex;height:100%;min-height:0;gap:4px;margin:0;overflow:hidden}
 .review-screen .result-visual .result-image{flex:1 1 0;min-height:100px;width:100%;height:auto;margin:0}
 .review-screen .review-summary{grid-column:2;grid-row:1;display:flex!important;flex-direction:column;justify-content:center;gap:5px;min-height:0}
 .review-summary .score-card{padding:7px 4px;gap:4px}.review-summary .review-score-title{font-size:17px}
 .review-summary .score-card .map-value{font-size:24px}.review-summary .score-kind{font-size:10px}
 .review-summary .score-scale{font-size:11px}.review-summary .decision-note{font-size:12px;gap:3px}
 .review-summary .comparison-legend{font-size:10px}.review-summary .correction-actions{gap:3px 8px}
 .review-summary .correction-actions button{min-height:36px;font-size:12px;padding:4px 0}
 .review-screen .review-details-open{grid-column:1/-1;grid-row:2;min-height:44px;font-size:14px;margin:0}
 .review-photo-heading{margin:0}.review-photo-heading .eyebrow{font-size:8px;letter-spacing:.08em}
 .review-photo-heading p:not(.eyebrow){font-size:10px;line-height:1.25}
 .review-screen .photo-view-switch{display:grid;grid-template-columns:repeat(3,1fr);gap:4px;flex:none;width:100%;margin:0}
 .mobile-view-long{display:none}.mobile-view-short{display:inline}
 .review-screen .photo-view-switch button{min-height:32px;padding:4px 2px;font-size:11px;line-height:1.2;white-space:normal}
 #modal[open]{display:flex;flex-direction:column;width:calc(100% - 20px);max-height:calc(var(--app-height,100dvh) - 20px);padding:14px;margin:auto;overflow:hidden}
 #modal .modal-head{flex:none;gap:8px;margin-bottom:8px}#modal .modal-head h2{font-size:20px;line-height:1.2}
 #modal .modal-head button{min-height:40px;padding:6px 10px;flex:none}
 #modalBody{min-height:0;overflow:auto;overscroll-behavior:contain;touch-action:pan-y;font-size:14px}
 #modalBody>p{font-size:14px;line-height:1.4;margin:0 0 10px}
 #modal .correction-grid{gap:7px;margin:8px 0;grid-template-columns:1fr 1fr}
 #modal .correction-option{min-height:48px;padding:8px;font-size:14px;line-height:1.25}
 #modal .modal-actions{position:sticky;bottom:0;background:#fff;padding-top:8px;gap:6px}
 #modal .modal-actions button{min-height:40px;font-size:13px;padding:7px}
 .detail-layout{grid-template-columns:minmax(0,1fr) 95px;gap:10px}
 .detail-copy{display:flex;flex-direction:column;gap:6px}
 .detail-description{flex:1;align-self:stretch;display:flex;flex-direction:column;min-height:0;max-height:none}
 .detail-full{display:block!important;min-height:0;flex:1;overflow:hidden}.detail-compact{display:none!important}
 .detail-copy .detail-full p{font-size:15px;line-height:1.4;margin:0 0 12px}
 .detail-copy .refill-info{flex:none;gap:2px}.detail-copy .refill-info p{font-size:11px}
 .detail-selector{flex:none;grid-template-columns:1fr 1fr;gap:5px}
 .detail-selector .routine-choice{padding:6px;min-height:40px;gap:2px}
 .detail-selector .routine-choice small{font-size:10px}.detail-selector .routine-choice strong,.detail-selector .routine-choice span,.detail-selector .product-detail-cta{display:none}
 .detail-photo figcaption{font-size:11px}.detail-photo{min-height:0}
 .mobile-copy-nav{display:flex;flex:none;justify-content:space-between;align-items:center;gap:4px;padding:3px 0}
 .mobile-copy-nav button{font-size:12px;min-height:34px;padding:4px 7px}.mobile-copy-nav span{font-size:10px}
 .flow-screen[data-key="cream"] .screen-heading>p:not(.eyebrow){font-size:18px}
 .routine-choice .product-detail-cta{font-size:14px}.routine-grid{gap:6px}
 .routine-legend{gap:5px}.routine-choice{padding:7px;gap:3px}.routine-choice strong{font-size:14px}
 #introGate{height:var(--app-height,100dvh);padding:12px 16px;gap:10px}
 .intro-page h1{font-size:28px;margin-bottom:14px}.intro-page p:not(.eyebrow){font-size:18px;line-height:1.35}.intro-page p.intro-note{font-size:16px;margin-top:12px}
}
@media(min-width:651px) and (max-width:950px) and (max-height:500px){
 .topbar{display:none!important}#steps{padding:2px 8px}#steps button{min-height:28px}
 .review-screen .analysis-overview{grid-template-columns:minmax(150px,.8fr) minmax(0,1.2fr);grid-template-rows:minmax(0,1fr) 36px}
 .review-screen .result-visual{grid-row:1/3}
 .review-screen .map-controls{grid-column:2;grid-row:1/3;display:flex;gap:4px}
 .review-screen .review-summary{display:grid!important;grid-template-columns:1fr 1fr!important;gap:3px 8px;flex:none}
 .review-summary .score-scale,.review-summary .decision-note,.review-summary .correction-actions{grid-column:1/-1}
 .review-screen .review-details-open{min-height:36px;font-size:13px;padding:6px 10px;margin-top:auto}.review-summary .score-card .map-value{font-size:20px}
 .review-summary .score-card{padding:4px}.review-summary .review-score-title{font-size:16px}
 .review-photo-heading p:not(.eyebrow){display:none}.review-screen .photo-view-switch{grid-template-columns:repeat(3,1fr)}
 .detail-layout{grid-template-columns:minmax(0,1fr) 100px}.detail-selector{grid-template-columns:repeat(4,1fr)}
 .intro-header{display:none}.intro-page h1{font-size:25px;margin-bottom:8px}.intro-page p:not(.eyebrow){font-size:17px}
}

@media(min-width:651px) and (max-width:950px) and (max-height:500px){
 .review-screen .analysis-overview{grid-template-columns:minmax(150px,.65fr) minmax(0,1.35fr)}
 .review-screen .review-summary{grid-template-columns:minmax(135px,.8fr) minmax(0,1.2fr)!important;gap:2px 8px;justify-content:start}
 .review-summary .score-card{grid-column:1;grid-row:1/3;align-self:stretch;justify-content:center}
 .review-summary .score-scale{grid-column:2;grid-row:2;font-size:10px;line-height:1.2;margin:0}
 .review-summary .decision-note{grid-column:1;grid-row:3;font-size:10px;line-height:1.2}
 .review-summary .correction-actions{grid-column:2;grid-row:3;gap:2px 8px}
 .review-summary .correction-actions button{font-size:11px;min-height:30px}
}

@media(min-width:651px) and (max-width:950px) and (max-height:500px){
 .review-summary .comparison-row{margin:0 0 3px}
 .review-summary .comparison-row-heading,.review-summary .comparison-row-heading strong{font-size:10px;line-height:11px;margin-bottom:2px}
 .review-summary .comparison-track{height:6px}.review-summary .comparison-marker{height:12px}
 .review-summary .comparison-axis{font-size:8px;line-height:9px;margin-top:1px}
 .review-summary .comparison-row:has(+.comparison-row) .comparison-axis{display:none}
 .review-summary .effective-label,.review-summary .comparison-legend{font-size:10px;line-height:1.15;margin:0}
 .review-summary .decision-note{gap:2px}
}

@media(min-width:651px) and (max-width:950px) and (max-height:340px){
 .review-screen .analysis-overview{grid-template-columns:minmax(150px,.45fr) minmax(0,1.55fr)}
 .review-screen .review-summary{grid-template-columns:115px minmax(140px,1fr) minmax(150px,1fr)!important}
 .review-summary .score-card{grid-column:1;grid-row:1/3}
 .review-summary .score-scale{grid-column:2;grid-row:2}
 .review-summary .decision-note{grid-column:3;grid-row:1}
 .review-summary .correction-actions{grid-column:3;grid-row:2;align-content:start}
}
