/* ============================================================
   Tablet and phone layouts — from the designer's mobile/tablet exports.
   >= 960px : desktop design (site.css + page css), untouched here.
   700–959px: tablet    < 700px: phone
   ============================================================ */

/* Tablet + phone: shared fixes (static hero, tap targets, overflow) */
@media (max-width:959px){
html { -webkit-text-size-adjust: 100%; }
h1, h2, h3, .metric-card strong { overflow-wrap: break-word; }
.wrap, .wrap > *, .school-hero-grid > *, .proof-grid > *, .contact-layout > *, .system-layout > *, .form-row > * { min-width: 0; }
.site-header .header-actions { gap: 8px; }
.menu-toggle, .close-dialog, .quick-close { min-width: 44px; min-height: 44px; }
.header-actions .button, .gallery-tabs button, .copy-button, .carousel-pause, .hero-bottom button { min-height: 44px; }
.field :is(input,textarea,select), .quick-contact .field input { min-width: 0; width: 100%; font-size: 16px; }
dialog { max-width: calc(100% - 24px); max-height: calc(100dvh - 24px); overscroll-behavior: contain; }
body .quick-contact { max-height: calc(100dvh - 32px); }
.faq-item summary { min-height: 44px; }
.site-zone { min-height: 40px; }
.demo-chapters { margin-top: 4px; }
.demo-chapters button, .demo-chapters button.active { height: 40px; background: linear-gradient(var(--chapter-color,#ccd5e6),var(--chapter-color,#ccd5e6)) center / 100% 4px no-repeat; }
.demo-chapters button.active { --chapter-color: var(--blue); }
.carousel-dots button { position: relative; }
.carousel-dots button::after { content: ''; position: absolute; inset: -15px -2px; }
body .footer-top > div:last-child { display: block; }
.hero-scroll, .no-motion .hero-scroll { height: auto; min-height: 0; }
body .hero-stage { position: relative; height: auto; min-height: 0; display: grid; align-items: center; }
.hero-stage .hero-copy, .hero-stage .camera-scene, .hero-stage .orbit-card { transform: none !important; opacity: 1 !important; will-change: auto; }
.hero-stage .camera-scene { position: relative; top: auto; right: auto; bottom: auto; left: auto; margin: 0; }
.hero-stage .camera-scene video { position: absolute; inset: 0; transform: scale(1.25) translateX(20.5%); }
.hero-stage .orbit-card { position: relative; inset: auto; width: auto; height: auto; margin: 0; }
.hero-stage :is(.hero-zone,.hero-small-tag,.hero-stat,.hero-shield) { display: none; }
.hero-stage .hero-bottom { position: static; grid-column: 1 / -1; gap: 8px; font-size: 10px; }
.hero-bottom button { font-size: 11px; }
.hero-copy p br { display: none; }
.hero-scroll + .about-section { margin-top: 0; }
.school-hero .school-art { min-width: 0; }
.sector .school-art figcaption { max-width: none; }
}

@media (hover:none) {
  .button:hover, .solution-card:hover, .school-detail-card:hover { transform: none; }
}

/* Phone: < 700px */
@media (max-width:699px){
.wrap { width: min(580px, calc(100% - 2 * clamp(16px, 4.6vw, 24px))); }
.site-header { height: 70px; }
.site-header .logo { width: clamp(88px, 25vw, 110px); }
.header-inner { gap: 8px; }
.header-actions { margin-left: auto; }
.header-actions .button { font-size: 11px; padding: 9px 12px; gap: 7px; }
.menu-toggle { display: block; }
.nav { display: none; position: absolute; top: 62px; left: max(12px,calc((100% - 580px)/2)); right: max(12px,calc((100% - 580px)/2)); padding: 10px; gap: 0; flex-direction: column; align-items: stretch; border: 1px solid var(--line); border-radius: 16px; background: white; box-shadow: 0 15px 35px #22355517; max-height: calc(100dvh - 74px); overflow-y: auto; }
.nav.open { display: flex; }
.nav a { padding: 10px 14px; font-size: 15px; min-height: 44px; }
.hero-stage { grid-template-columns: repeat(2,minmax(0,1fr)); padding: 92px max(clamp(16px,4.6vw,24px),calc((100% - 580px)/2)) 16px; gap: 0 10px; }
.hero-stage .hero-copy { width: 100%; grid-column: 1 / -1; padding: 0; text-align: left; }
.hero-copy .pill { font-size: 9px; }
.hero-copy h1 { font-size: clamp(31px,9.1vw,54px); line-height: 1.04; margin: 19px 0 14px; max-width: none; }
.hero-copy p, .school-hero-copy > p { font-size: 15px; line-height: 1.55; max-width: 46ch; margin: 0; }
.hero-copy .actions, .school-hero-copy .actions { margin-top: 20px; gap: 8px; justify-content: flex-start; }
.hero-copy .actions { display: grid; grid-template-columns: auto auto; justify-content: start; }
.hero-copy .actions .button { font-size: 12px; padding: 10px 12px; gap: 8px; min-height: 46px; }
.hero-stage .camera-scene { grid-column: 1 / -1; width: 100%; height: clamp(145px,45vw,230px); }
.hero-stage .hero-event, .hero-stage .hero-local { display: flex; flex-direction: column; justify-content: center; align-self: stretch; padding: 13px 12px; border-radius: 15px; }
.hero-event .card-head, .hero-local .card-head { margin: 0 0 7px; }
.hero-stage .orbit-card b { font-size: 12px; }
.hero-stage .orbit-card small, .hero-event .card-footer { font-size: 9px; }
.hero-stage .hero-event .event-row { margin: 2px 0 8px; }
.hero-stage .hero-local .local-bars { height: 17px; margin-top: 7px; }
.hero-stage .hero-signal { display: none; }
.hero-stage .hero-bottom { margin-top: 8px; }
.hero-bottom > span { display: none; }
.school-hero, .sector .school-hero { padding: 90px 0 40px; }
.school-hero .school-crumb { margin: 0 0 24px; }
.school-hero .school-hero-grid, .sector .school-hero-grid { grid-template-columns: minmax(0,1fr); gap: 24px; }
.school-hero .school-hero-copy h1 { font-size: clamp(35px,9.5vw,55px); line-height: 1.05; }
.school-hero-copy > p { margin-top: 16px; }
.school-hero .school-art { width: 100%; margin: 0; }
.school-page .school-art > img { max-height: 320px; object-fit: contain; }
.school-page .school-art figcaption { position: static; max-width: 100%; transform: none; margin-top: 6px; }
.section, .solutions-section, .media-section, .school-detail-section, .proof-section { padding: 54px 0; }
h2, .sector .about-statement, .about-statement, .platform-top h2, .press-layout .media-intro h2 { font-size: clamp(30px,8.4vw,43px); }
.section-intro { display: block; margin-bottom: 24px; }
.section-intro p, .center-intro p, .proof-copy p, .infrastructure-copy > p, .faq-item p, .school-detail-card p, .sector-flow p, .solution-card p, .evidence-panel figcaption p, .bento .bento-copy p, .process-step p, .contact-intro > p, .school-page #about .about-bottom p, .hero-copy p { font-size: 15px; line-height: 1.58; }
.section-intro p { margin-top: 14px; max-width: 48ch; }
.solution-grid, .school-detail-grid, .sector .school-detail-grid, .bento-grid, .proof-grid, .sector .proof-grid, .contact-layout, .press-layout, .infrastructure { display: grid; grid-template-columns: minmax(0,1fr); }
.solution-card { min-height: 0; padding: 22px; }
.solution-card p { margin-bottom: 20px; }
.bento-grid { gap: 12px; }
.bento-grid .bento { grid-column: 1; min-width: 0; padding: 22px; }
.bento-grid .bento.scene-card { display: flex; flex-direction: column; gap: 16px; min-height: 0; align-items: stretch; }
.scene-card .hall-preview { position: relative; inset: auto; height: clamp(160px,47vw,260px); width: 100%; order: -1; }
.bento-grid .bento.notify-card { min-height: 0; }
.notify-card .bento-copy, .data-card .bento-copy { max-width: none; }
.notify-card .notification-stack { position: relative; inset: auto; transform: none; width: 100%; margin-top: 20px; }
.bento-grid .people-card, .bento-grid .smoke-card, .bento-grid .data-card { min-height: 0; padding-bottom: 145px; }
.data-card .data-viz { left: 24px; right: 24px; bottom: 18px; height: 94px; }
.bento-grid .bento h3 { font-size: 25px; }
.sector .sector-flow, .sector .system-layout, .faq-layout, .contact-form-card .form-row, .form-row, .about-bottom { grid-template-columns: minmax(0,1fr); }
.sector .school-hero-note { margin-top: 15px; }
.sector .gallery-tabs, .school-page .gallery-tabs { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px; }
.sector .gallery-tabs button, .school-page .gallery-tabs button { padding: 7px 11px; font-size: 12px; }
.evidence-top { flex-wrap: wrap; }
.sector .metric-card { padding: 16px; }
.sector .about-metrics { grid-template-columns: repeat(2,minmax(0,1fr)); }
.sector .metric-card strong { font-size: clamp(21px,5.7vw,29px); }
.contact-layout .contact-form-card, .dialog-body { padding: 22px 16px; }
.cta-section .wrap { width: min(560px,calc(100% - 28px)); }
.site-footer .footer-top { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 24px 14px; }
.footer-top > div:first-child, .footer-top > div:last-child { grid-column: 1/-1; }
.footer-top a, .footer-top button { padding-block: 5px; }
@media(max-width:355px){
 .header-actions .button .arrow { display:none; }
 .hero-copy .actions { grid-template-columns: minmax(0,1fr); justify-content: stretch; }
 .sector .about-metrics { grid-template-columns: minmax(0,1fr); }
 .sector .metric-card { min-height: 0; }
}
}

/* Tablet: 700–959px */
@media (min-width:700px) and (max-width:959px){
.wrap { width: min(1192px,calc(100% - 2 * clamp(24px,4.2vw,64px))); }
.site-header { height: 80px; }
.hero-stage { grid-template-columns: repeat(6,minmax(0,1fr)); column-gap: clamp(12px,2vw,28px); row-gap: 22px; padding: clamp(112px,11vw,160px) max(4.2vw,calc((100% - 1192px)/2)) 20px; }
.hero-stage .hero-copy { width: 100%; grid-column: 1 / 5; grid-row: 1; padding: 0; margin: 0; text-align: left; }
.hero-copy h1 { font-size: clamp(44px,5.7vw,78px); line-height: 1.06; margin: 22px 0 17px; }
.hero-copy p { margin: 0; max-width: 45ch; font-size: clamp(15px,1.5vw,18px); line-height: 1.6; }
.hero-copy .actions { justify-content: flex-start; gap: 10px; margin-top: 22px; }
.hero-copy .button { min-height: 46px; padding-inline: 16px; gap: 12px; }
.hero-stage .camera-scene { grid-column: 4 / 7; grid-row: 1; width: 112%; justify-self: end; height: clamp(260px,34vw,420px); z-index: 1; pointer-events: none; }
.hero-stage .hero-copy .actions { width: fit-content; }
.hero-stage .hero-event, .hero-stage .hero-local, .hero-stage .hero-signal { display: flex; align-self: stretch; grid-row: 2; grid-column: span 2; border-radius: 16px; padding: 16px 18px; }
.hero-stage .hero-event, .hero-stage .hero-local { flex-direction: column; justify-content: center; }
.hero-stage .hero-local .local-bars { height: 20px; margin-top: 7px; }
.hero-stage .orbit-card .card-head { margin-bottom: 6px; }
.hero-stage .hero-signal { align-items: center; justify-content: space-between; }
.hero-stage .hero-event .event-row { margin: 6px 0; }
.hero-stage .orbit-card b { font-size: 14px; }
.hero-stage .orbit-card small { font-size: 10px; }
.hero-stage .hero-signal .orbit-stat { font-size: 38px; }
.hero-stage .hero-bottom { grid-row: 3; }
.school-hero, .sector .school-hero { padding: 109px 0 55px; }
.school-hero .school-crumb { margin: 0 0 24px; }
.school-hero .school-hero-grid, .sector .school-hero-grid { display: grid; grid-template-columns: minmax(0,1.08fr) minmax(0,1fr); gap: clamp(22px,3.2vw,46px); align-items: center; }
.school-hero .school-hero-copy h1 { font-size: clamp(38px,4.6vw,69px); }
.school-hero .school-hero-copy > p { font-size: clamp(15px,1.55vw,18px); line-height: 1.6; margin-top: 20px; }
.school-hero .school-art { width: 100%; margin: 0; }
.school-page .school-art figcaption { transform: none; right: 0; bottom: -10px; }
.sector .school-art > img { aspect-ratio: 4/3; object-fit: cover; }
.section, .solutions-section, .media-section, .school-detail-section, .proof-section { padding: clamp(64px,7vw,100px) 0; }
.section-intro { align-items: end; gap: 26px; }
.section-intro p, .process-step p, .school-detail-card p, .solution-card p, .bento .bento-copy p, .proof-copy p, .faq-item p { font-size: 15px; line-height: 1.58; }
.solution-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; }
.solution-card { min-height: 240px; }
.school-page #about .about-bottom:has(.radar-card) { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 26px; }
.bento-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
.bento-grid .bento { grid-column: auto; min-width: 0; }
.bento-grid .scene-card { grid-column: 1/-1; display: grid; grid-template-columns: minmax(0,.86fr) minmax(0,1.14fr); align-items: center; gap: 24px; min-height: 230px; }
.scene-card .hall-preview { position: relative; inset: auto; width: 100%; height: clamp(175px,22vw,285px); }
.bento-grid :is(.notify-card,.people-card,.smoke-card,.data-card) { min-height: 332px; }
.bento .bento-copy { max-width: none; }
.bento.notify-card .notification-stack { left: 20px; right: 20px; bottom: 15px; transform: none; }
.bento.data-card .data-viz { left: 28px; right: 28px; height: 110px; }
.sector .school-detail-grid, .school-page .school-detail-grid { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; }
.sector .school-detail-card, .school-page .school-detail-card { padding: clamp(18px,2.1vw,30px); }
.school-detail-grid .school-detail-card h3 { font-size: clamp(22px,2.4vw,30px); }
.sector .system-layout { grid-template-columns: minmax(0,1.25fr) minmax(0,1fr); }
.sector .site-plan { min-height: 350px; border-right: 1px solid #d6e2f6; border-bottom: 0; }
.zone-information { padding: 22px; }
.sector .sector-flow { grid-template-columns: repeat(3,minmax(0,1fr)); }
.contact-layout { grid-template-columns: minmax(0,.9fr) minmax(0,1.1fr); gap: clamp(22px,3vw,50px); align-items: start; }
.contact-form-card { padding: clamp(20px,2.4vw,32px); }
.contact-intro h2 { font-size: clamp(36px,4.6vw,65px); }
.footer-top { grid-template-columns: 1.35fr 1fr 1fr 1fr; gap: 16px; }

 .menu-toggle { display: block; }
 .header-actions { margin-left: auto; }
 .nav { display: none; position: absolute; top: 67px; left: auto; right: 4.2vw; width: 300px; flex-direction: column; align-items: stretch; gap: 0; padding: 12px; background: white; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 15px 35px #22355517; max-height: calc(100dvh - 80px); overflow-y: auto; }
 .nav.open { display: flex; }
 .nav a { padding: 10px 14px; font-size: 15px; min-height: 44px; }
 .contact-form-card .form-row { grid-template-columns: minmax(0,1fr); }
 .school-art figcaption { font-size: 12px; }
 .sector .proof-grid, .school-page .proof-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 24px; }
 .sector .site-zone { padding-inline: 7px; font-size: 9px; }
}
