/* HANBO responsive layout patch 2026-10-15 r1. CSS only; no content mutation. */
@media screen and (max-width:900px){
  body>header{height:auto;min-height:100px;flex-wrap:wrap;padding-top:18px;padding-bottom:18px;gap:14px 20px}
  body>header>.brand,body>header>.customer-header{min-width:0}
  body>header>.customer-header{flex-wrap:wrap;white-space:normal}
  body>header>nav{order:10;flex-basis:100%;max-width:100%;display:flex;flex-wrap:wrap;justify-content:flex-end;gap:10px 22px}
  body>header>nav>a,body>header>nav>button{min-width:0;max-width:100%;white-space:normal;line-height:1.5}
  /* Hero height follows actual text length; bottom copy participates in flow. */
  .hero{height:auto;min-height:620px;display:flex;flex-direction:column;isolation:isolate}
  .hero-content{flex:1 0 auto;width:100%;max-width:760px;padding:76px 7% 28px;min-width:0}
  .hero h1{font-size:clamp(40px,6.4vw,60px);line-height:1.12;letter-spacing:-.025em;overflow-wrap:break-word;word-break:normal;max-width:100%;margin:0 0 24px}
  html[lang^="zh"] .hero h1{font-size:clamp(36px,5.8vw,54px);line-height:1.28;letter-spacing:0}
  .hero .hero-content p:not(.eyebrow),html[lang^="zh"] .hero .hero-content p:not(.eyebrow){max-width:500px;font-size:16px;line-height:1.75;margin:0 0 28px;overflow-wrap:break-word}
  .hero-content>.button{max-width:100%;min-height:48px;line-height:1.5;white-space:normal;text-align:left;gap:20px}
  .hero-content>.button>span{flex-shrink:0}
  .hero-contacts{display:flex;flex-wrap:wrap;align-items:center;gap:8px 24px;margin:20px 0 0;min-width:0}
  .hero-contacts a,.hero-contacts button{display:inline-flex;align-items:center;min-height:44px;max-width:100%;padding:8px 0;line-height:1.5;white-space:normal;overflow-wrap:anywhere}
  .hero-bottom{position:static;inset:auto;display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:end;gap:20px;margin:0;padding:8px 7% 28px;width:100%;min-width:0;font-size:11px;line-height:1.7;letter-spacing:.06em}
  .hero-bottom>span{display:block;max-width:none;min-width:0;width:auto;font-size:12px;line-height:1.75;letter-spacing:.04em;overflow-wrap:break-word}
  .hero-bottom>a{display:inline-flex;align-items:center;min-height:44px;line-height:1.6;max-width:100%;white-space:normal}
  /* Flexible tracks prevent min-content widths from pushing cards outside screen. */
  .intro,.plan,.expanded-editorial{grid-template-columns:repeat(2,minmax(0,1fr));gap:32px}
  .intro>*,.plan>*,.expanded-editorial>*,.cards>*,.features>*,.section-head>*{min-width:0}
  .cards{grid-template-columns:repeat(2,minmax(0,1fr));gap:30px 22px}
  .cards h3,.cards p,.card-bottom,.section-head h2,.editorial-copy h2,.plan h2{overflow-wrap:break-word;word-break:normal}
  .card-bottom{flex-wrap:wrap;align-items:start;gap:10px 14px;line-height:1.65}
  .card-bottom>*{min-width:0;max-width:100%}
}
@media screen and (max-width:650px){
  /* Readable single-column layout without suppressing browser zoom. */
  .hero{margin:0 10px;min-height:560px;background-position:center}
  .hero-content{padding:56px 20px 22px;max-width:none}
  .hero h1{font-size:clamp(32px,10vw,46px);line-height:1.14;letter-spacing:-.025em;margin-bottom:22px}
  html[lang^="zh"] .hero h1{font-size:clamp(30px,9.2vw,40px);line-height:1.3;letter-spacing:0}
  .hero .eyebrow{font-size:10px!important;line-height:1.6;letter-spacing:.1em;margin-bottom:18px;overflow-wrap:break-word}
  .hero .hero-content p:not(.eyebrow),html[lang^="zh"] .hero .hero-content p:not(.eyebrow){font-size:15px;line-height:1.8;max-width:none;margin-bottom:24px}
  .hero-content>.button{width:100%;justify-content:space-between;padding:16px 18px;font-size:14px;gap:16px}
  .hero-contacts{gap:4px 24px;margin-top:18px;font-size:13px}
  .hero-bottom{grid-template-columns:minmax(0,1fr);align-items:start;gap:12px;padding:0 20px 28px}
  .hero-bottom>span{font-size:11px;line-height:1.8;letter-spacing:.04em;max-width:100%}
  .hero-bottom>a{font-size:10px;letter-spacing:.08em;justify-self:start;padding:6px 0}
  /* A wrapped header cannot use a fixed 80px menu offset. */
  body>header{position:relative;height:auto;min-height:80px;display:flex;flex-wrap:wrap;gap:10px;padding:16px 20px 12px;align-items:center}
  body>header>.brand{min-width:0;max-width:calc(100% - 54px);font-size:27px;letter-spacing:4px;line-height:1.15;overflow-wrap:anywhere}
  body>header>.brand small{font-size:8px;line-height:1.6;letter-spacing:1.3px;white-space:normal}
  body>header>.language-control{margin-left:auto;max-width:100%;flex-shrink:0}
  body>header .language-control select{font-size:16px;min-width:100px;max-width:150px;min-height:44px;padding:8px 24px 8px 10px}
  body>header>.mobile{display:inline-flex;align-items:center;justify-content:center;min-width:44px;min-height:44px;padding:6px}
  body>header>.customer-header{order:5;width:100%;min-width:0;margin:0;gap:8px 16px;flex-wrap:wrap;justify-content:flex-end;white-space:normal}
  body>header>.customer-header a,body>header>.customer-header button{min-height:40px;display:inline-flex;align-items:center;line-height:1.5;white-space:normal;overflow-wrap:anywhere;font-size:12px}
  body>header>nav{display:none;position:static;inset:auto;order:10;width:100%;flex-basis:100%;padding:14px 0 4px;gap:8px;align-items:stretch;max-height:none}
  body>header>nav.open{display:flex}
  body>header>nav>a,body>header>nav>button{min-height:44px;display:flex;align-items:center;white-space:normal;line-height:1.5;padding:10px 12px;max-width:100%;overflow-wrap:break-word}
  .contact-strip{grid-template-columns:minmax(0,1fr);gap:8px;padding:10px 20px}
  .contact-strip>span{font-size:10px;line-height:1.7;min-width:0;overflow-wrap:break-word}
  .contact-strip>div{display:flex;flex-wrap:wrap;gap:6px 16px;justify-content:flex-start;min-width:0}
  .contact-strip a,.contact-strip button{max-width:100%;white-space:normal;overflow-wrap:anywhere;line-height:1.5;min-height:40px}
  .wrap{padding-left:20px;padding-right:20px}
  .intro,.plan,.expanded-editorial,.cards,.features{grid-template-columns:minmax(0,1fr)}
  .intro,.plan,.expanded-editorial{padding-top:48px;padding-bottom:48px;gap:24px}
  .intro h2,.plan h2,html[lang^="zh"] .intro h2,html[lang^="zh"] .plan h2{font-size:clamp(28px,8.2vw,38px);line-height:1.3;letter-spacing:0}
  .intro p,.plan>div>p:not(.eyebrow){max-width:none;overflow-wrap:break-word}
  .section-head{align-items:flex-start;flex-direction:column;gap:12px}
  .section-head h2,html[lang^="zh"] .section-head h2{font-size:clamp(28px,8vw,36px);line-height:1.3;letter-spacing:0}
  .filters{flex-wrap:wrap;gap:8px;margin:22px 0}
  .filters button{max-width:100%;min-height:44px;white-space:normal;line-height:1.5;overflow-wrap:break-word}
  .cards{gap:32px}
  .cards .image-button{height:auto;aspect-ratio:4/3;display:block}
  .cards .image-button>img{display:block;height:100%;width:100%;object-fit:cover}
  .cards h3,.journey-cards h3{min-height:0;font-size:25px;line-height:1.3}
  .cards article>p:not(.eyebrow){min-height:0;line-height:1.8}
  .card-bottom button{min-height:40px;line-height:1.6;text-align:left;white-space:normal}
  .difference{padding:48px 0}
  .difference>.wrap>h2,html[lang^="zh"] .difference>.wrap>h2{font-size:clamp(30px,9vw,40px);line-height:1.25;letter-spacing:0;overflow-wrap:break-word}
  .features{gap:24px;margin-top:28px}
  .features h3{font-size:23px;line-height:1.35;overflow-wrap:break-word}
  .editorial-image-space{height:auto;aspect-ratio:3/4;max-height:480px;width:100%;min-width:0}
  .editorial .editorial-image-space>img{height:100%;width:100%;object-fit:cover}
  .editorial-lead{font-size:20px;line-height:1.4}
  .editorial-main-title{font-size:clamp(28px,8vw,36px);line-height:1.3;overflow-wrap:break-word}
  .editorial-body p{font-size:14px;line-height:1.85;overflow-wrap:break-word}
  .editorial-journey-button{max-width:100%;line-height:1.7;white-space:normal;overflow-wrap:break-word}
  .plan .form-grid{grid-template-columns:minmax(0,1fr);gap:0}
  .plan label,.plan .form-grid>*,.plan .member-lock{min-width:0;max-width:100%;overflow-wrap:break-word}
  .plan input,.plan select,.plan textarea,.dialog input,.dialog select,.dialog textarea{font-size:16px;min-width:0;max-width:100%;box-sizing:border-box}
  .plan textarea,.dialog textarea{line-height:1.6}
  .plan .member-lock .text-link{margin:12px 0 0;display:block;width:fit-content;max-width:100%}
  .plan .button{max-width:100%;min-height:44px;white-space:normal;line-height:1.5;gap:12px}
  .faq{padding-bottom:48px}
  .faq summary{gap:14px;align-items:flex-start;font-size:15px;line-height:1.6;overflow-wrap:break-word}
  .faq summary>*{min-width:0}
  .faq summary>span:last-child{flex-shrink:0}
  .faq details p{line-height:1.8;overflow-wrap:break-word}
  .compact-site-footer .footer-main{grid-template-columns:minmax(0,1fr);gap:14px}
  .compact-site-footer .footer-main>.brand{font-size:27px;white-space:normal;max-width:100%;overflow-wrap:anywhere}
  .compact-site-footer .footer-main>p{justify-self:start;max-width:none;font-size:12px;line-height:1.8}
  .compact-site-footer .footer-secondary{flex-wrap:wrap;justify-content:flex-start;gap:10px 20px;line-height:1.7;max-width:100%}
  .compact-site-footer .footer-secondary>*,.compact-site-footer .footer-location-note{overflow-wrap:anywhere;max-width:100%}
  .compact-site-footer .footer-location-note{font-size:10px;line-height:1.7;margin-top:12px}
  .compact-site-footer{padding-bottom:calc(var(--footer-padding,20px) + 76px + env(safe-area-inset-bottom,0px))}
  /* Shorter floating controls share the bottom edge with the SEO link. */
  .floating-contact{right:10px;max-width:calc(55vw - 16px);flex-wrap:wrap;align-items:stretch}
  .floating-contact a,.floating-contact button{flex:1 1 auto;min-width:0;max-width:100%;min-height:44px;padding:10px 9px;font-size:11px;line-height:1.5;white-space:normal;overflow-wrap:anywhere}
  #hanbo-public-tours{max-width:calc(45vw - 24px)!important;box-sizing:border-box;white-space:normal;overflow-wrap:break-word;font-size:11px!important;line-height:1.5;min-height:44px}
  /* Mobile dialog scrolling stays inside the available viewport. */
  .modal{padding:12px;overflow-y:auto;overscroll-behavior:contain}
  .dialog,.journey-dialog{width:100%;max-width:100%;min-width:0;padding:48px 20px 24px;max-height:calc(100vh - 24px);max-height:calc(100dvh - 24px);overflow-y:auto;overscroll-behavior:contain;scroll-padding-top:48px}
  .dialog>.close{top:6px;right:6px;min-width:44px;min-height:44px;display:grid;place-items:center;line-height:1;z-index:5}
  .dialog h2,html[lang^="zh"] .dialog h2{font-size:28px;line-height:1.3;letter-spacing:0;overflow-wrap:break-word}
  .journey-summary,.journey-booking-actions,.journey-tabs{flex-wrap:wrap;gap:10px;min-width:0}
  .journey-summary>*,.journey-booking-actions>*,.journey-tabs>*{min-width:0;max-width:100%;white-space:normal;overflow-wrap:break-word;line-height:1.6}
  .journey-tabs button{min-height:44px;text-align:left}
  .daily-plan>li{grid-template-columns:44px minmax(0,1fr);gap:12px}
  .daily-plan>li>*{min-width:0;overflow-wrap:break-word}
  .daily-plan p,.daily-plan h4,.journey-dialog p{overflow-wrap:break-word}
  .about-gallery{grid-template-columns:minmax(0,1fr)}
  .about-gallery img{max-width:100%;height:auto}
}
@media screen and (prefers-reduced-motion:reduce){
  .hero,.cards img,.gallery-crossfade img{scroll-behavior:auto;transition:none}
}
