/* Shared tablet and mobile behavior. Desktop layouts remain unchanged. */
*, *::before, *::after { box-sizing: border-box; }
img, iframe { max-width: 100%; }
.nav-toggle { display: none; }

@media (max-width: 1050px) {
  .header { height: 86px; padding: 0 28px; }
  .header .logo img { width: min(220px, 42vw); height: auto; }
  .nav-toggle {
    position: relative; z-index: 1002; display: grid; place-items: center;
    width: 46px; height: 46px; padding: 0; border: 1px solid #ddd4cb;
    border-radius: 50%; background: #fff; color: #222; cursor: pointer;
  }
  .nav-toggle::before, .nav-toggle::after, .nav-toggle span {
    content: ""; display: block; position: absolute; width: 20px; height: 2px;
    border-radius: 2px; background: currentColor; transition: .25s ease;
  }
  .nav-toggle::before { transform: translateY(-6px); }
  .nav-toggle::after { transform: translateY(6px); }
  .nav-toggle[aria-expanded="true"] span { opacity: 0; }
  .nav-toggle[aria-expanded="true"]::before { transform: rotate(45deg); }
  .nav-toggle[aria-expanded="true"]::after { transform: rotate(-45deg); }
  .header > nav {
    position: fixed; z-index: 1000; inset: 86px 0 auto; display: none;
    flex-direction: column; gap: 0; max-height: calc(100vh - 86px); overflow-y: auto;
    padding: 18px 28px 28px; background: rgba(255,255,255,.98);
    border-top: 1px solid #eee8e2; box-shadow: 0 18px 35px rgba(30,30,30,.09);
  }
  .header > nav.is-open { display: flex; }
  .header > nav a { width: 100%; padding: 16px 4px; border-bottom: 1px solid #eee8e2; }
  body.nav-open { overflow: hidden; }
  .footer-nav { display: flex !important; }

  .service-header { flex-direction: column; align-items: flex-start; gap: 24px; }
  .service-header h2, .service-intro { width: 100%; max-width: none; }
  .service-layout { grid-template-columns: 1fr !important; }
  .contact-inner { grid-template-columns: 1fr !important; gap: 42px !important; }
  .contact-map { width: 100%; }

  .service-section-heading, .service-business-layout { grid-template-columns: 1fr !important; gap: 42px !important; }
  .service-flow-list { grid-template-columns: repeat(2, minmax(0,1fr)) !important; }

  .property-pickup-card { grid-template-columns: 1fr !important; height: auto !important; }
  .property-pickup-gallery { height: 430px !important; }
  .property-pickup-main-image { height: 430px !important; min-height: 0 !important; }
  .property-pickup-content { min-width: 0; }

  .detail-hero-card { grid-template-columns: 1fr !important; height: auto !important; min-height: 0 !important; overflow: visible !important; }
  .detail-gallery { height: 500px !important; min-height: 0 !important; }
  .detail-main-image { height: 100% !important; }
  .detail-summary { height: auto !important; min-height: 0 !important; overflow: visible !important; }
  .detail-living-layout { grid-template-columns: 1fr !important; gap: 24px !important; }
  .detail-living-panel { min-width: 0; }

  .home-news-layout { grid-template-columns: 1fr !important; gap: 38px !important; }
}

@media (max-width: 700px) {
  html { scroll-padding-top: 74px; }
  body { overflow-x: hidden; }
  .header { height: 74px; padding: 0 18px; }
  .header .logo img { width: min(178px, 52vw); }
  .nav-toggle { width: 42px; height: 42px; }
  .header > nav { inset-block-start: 74px; max-height: calc(100vh - 74px); padding: 12px 20px 24px; }
  .header > nav a { padding: 15px 2px; font-size: 15px; }

  .footer-main, .footer-inner, .footer-content { grid-template-columns: 1fr !important; gap: 38px !important; }
  .footer-nav { flex-direction: column; align-items: flex-start; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 18px; }
  .footer-policy { flex-wrap: wrap; gap: 12px 22px; }

  .about-profile-list { grid-template-columns: 1fr !important; }
  .about-profile-item { width: 100% !important; transform: none !important; }
  .about-company-heading { position: static !important; top: auto !important; }
  .about-company-panel { gap: 34px !important; padding: 40px 24px !important; }
  .about-company-heading h2 { font-size: 38px !important; }
  .about-company-row { grid-template-columns: 1fr !important; gap: 6px !important; padding: 18px 0 !important; }
  .about-company-row dt, .about-company-row dd { width: 100%; word-break: normal; overflow-wrap: anywhere; }

  .service-section { padding-inline: 20px !important; }
  .service-header h2 { font-size: 34px !important; }
  .service-main { height: 450px !important; }
  .service-main-content { left: 24px !important; right: 24px !important; bottom: 28px !important; }
  .service-main h3 { font-size: 27px !important; }
  .service-sub { grid-template-columns: 1fr !important; }
  .service-sub-image { height: 210px; }
  .service-sub-content { padding: 25px 24px 55px !important; }

  .news-section, .flow-section { padding-inline: 20px !important; }
  .news-timeline-inner { width: calc(100% - 40px) !important; }
  .news-timeline-heading { grid-template-columns: 1fr !important; gap: 24px !important; }
  .home-news-featured { grid-template-columns: 1fr !important; min-height: 0 !important; }
  .home-news-featured-image { height: 260px; }
  .home-news-featured-content { padding: 28px 24px !important; }
  .home-news-featured h3 { font-size: 22px !important; }
  .home-news-read { margin-top: 28px; }
  .home-news-slot { grid-template-columns: 45px 1fr !important; padding: 20px 4px !important; }
  .home-news-slot small { grid-column: 2; }
  .news-ribbon { grid-template-columns: 1fr !important; gap: 28px !important; min-height: 0 !important; }
  .news-ribbon-main { width: 100% !important; height: 280px !important; transform: none !important; }
  .news-ribbon-main img, .news-ribbon-main-content { transform: none !important; }
  .news-ribbon-main-content { left: 24px !important; right: 24px !important; bottom: 26px !important; }
  .news-ribbon-history { display: grid !important; grid-template-columns: 1fr !important; gap: 14px !important; height: auto !important; overflow: hidden !important; }
  .news-ribbon-entry { width: 100% !important; height: auto !important; margin: 0 !important; display: block !important; }
  .news-ribbon-entry + .news-ribbon-entry { margin-left: 0 !important; }
  .news-ribbon-entry > time { position: static !important; display: block; margin: 0 0 8px 4px; }
  .news-ribbon-entry > time::after { display: none !important; }
  .news-ribbon-item { width: 100% !important; height: auto !important; min-height: 130px; padding: 34px 24px !important; transform: none !important; }
  .news-ribbon-bottom { flex-direction: column; align-items: flex-start !important; gap: 20px; }

  .flow-heading { margin-bottom: 48px !important; }
  .flow-heading h2 { font-size: 34px !important; }
  .flow-list { grid-template-columns: 1fr !important; gap: 42px !important; }
  .flow-list::before { display: none !important; }
  .flow-item { width: 100%; }
  .flow-item > p { max-width: 300px !important; }
  .flow-bottom { flex-direction: column; align-items: flex-start !important; gap: 22px !important; }

  .contact-section { padding: 46px 20px 55px !important; border-radius: 30px 30px 0 0 !important; }
  .contact-info h2 { font-size: 31px !important; }
  .contact-meta { display: grid !important; grid-template-columns: 1fr 1fr; gap: 18px !important; }
  .contact-meta strong { font-size: 18px !important; overflow-wrap: normal; word-break: keep-all; }
  .contact-map { height: 270px !important; }

  .property-hero-content { text-align: left !important; }
  .property-hero-content h1 { font-size: 36px !important; line-height: 1.45 !important; }
  .property-pickup-card { overflow: hidden; }
  .property-pickup-content { min-width: 0; padding: 32px 20px !important; }
  .property-pickup-content h3 { font-size: 27px !important; }
  .property-pickup-summary { grid-template-columns: 1fr !important; gap: 18px !important; padding: 22px 18px !important; }
  .property-summary-divider { display: none !important; }
  .property-summary-item { width: 100%; }
  .property-summary-price, .property-summary-area { font-size: 25px !important; white-space: normal !important; }
  .property-pickup-points { grid-template-columns: 1fr !important; gap: 14px !important; padding: 18px !important; }
  .property-pickup-point { grid-template-columns: 44px minmax(0,1fr) !important; padding: 0 !important; }
  .property-pickup-point p { font-size: 13px !important; line-height: 1.65 !important; writing-mode: horizontal-tb !important; word-break: normal !important; }
  .property-card-detail { grid-template-columns: 1fr !important; }
  .property-request-content h2 { font-size: 32px !important; }
  .property-search-row { grid-template-columns: 1fr !important; gap: 28px !important; }
  .property-search-group { width: 100%; }
  .property-type-buttons { display: grid !important; grid-template-columns: repeat(2, minmax(0,1fr)) !important; gap: 10px !important; margin-bottom: 0 !important; }
  .property-type-buttons button { width: 100%; min-height: 46px; padding: 10px 8px !important; }

  .detail-hero-card { height: auto !important; min-height: 0 !important; overflow: visible !important; }
  .detail-gallery { height: auto !important; min-height: 0 !important; }
  .detail-main-image { height: 340px !important; }
  .detail-summary { height: auto !important; overflow: visible !important; }
  .detail-summary h1 { font-size: 34px !important; }
  .detail-price-card { grid-template-columns: 1fr !important; }
  .detail-price-main { min-width: 0; }
  .detail-price-main strong { font-size: 24px !important; white-space: normal; }
  .detail-gallery-layout { grid-template-columns: 1fr !important; gap: 20px !important; }
  .detail-plan-card { padding: 22px !important; }
  .detail-plan-image { min-height: 0 !important; height: 330px !important; }
  .detail-photo-viewer { width: 100%; min-width: 0; }
  .detail-photo-main-wrap { height: 300px !important; }
  .detail-photo-thumbnails { width: 100%; overflow-x: auto !important; }
  .detail-photo-thumbnail { flex-basis: 105px !important; height: 76px !important; }
  .detail-living-layout { grid-template-columns: 1fr !important; gap: 20px !important; }
  .detail-living-panel { min-width: 0; padding: 24px 20px !important; }
  .detail-living-panel-heading { flex-direction: column; align-items: flex-start !important; gap: 8px !important; }
  .detail-living-panel-heading p { width: 100%; }
  .detail-facility-list { grid-template-columns: 1fr !important; }
  .detail-facility-list li { width: 100%; }
  .detail-surrounding-list li { gap: 12px !important; padding: 13px 14px !important; }
  .detail-surrounding-list span { min-width: 0; overflow-wrap: anywhere; }
  .detail-surrounding-list strong { flex: 0 0 auto; white-space: nowrap; }

  .service-section-heading { gap: 24px !important; }
  .service-business-layout, .service-flow-list { grid-template-columns: 1fr !important; }
  .service-flow-list { gap: 14px !important; }

  .method-hero { min-height: 700px !important; background: #faf7f0; }
  .method-hero > img { inset: auto 0 0 24% !important; width: 76% !important; height: 45% !important; }
  .method-hero-overlay { width: 100% !important; height: 68% !important; border-radius: 0 0 48% 0 !important; }
  .method-hero-content { width: calc(100% - 40px) !important; padding-top: 90px !important; }
  .method-hero-content h1 { font-size: clamp(36px, 11vw, 50px) !important; }
  .method-hero-doodles { opacity: .35 !important; }
  .doodle-cloud { display: none !important; }
  .feature-grid, .immune-benefits, .method-principles { grid-template-columns: 1fr !important; }
  .method-container { width: calc(100% - 40px) !important; }

  .journal-closing-card { min-height: 0 !important; padding: 38px 24px !important; }
  .journal-closing-town { display: none; }
  .journal-card { height: 510px; min-height: 510px; }
}
