/* Physical dimensions stay usable when older WebKit ignores logical CSS,
   math functions, inset, aspect-ratio, or the Tailwind cascade-layer reset. */
.neoShell { width: 100%; max-width: 1440px; margin-left: auto; margin-right: auto; padding-left: 22px; padding-right: 22px; padding-left: clamp(22px,5vw,76px); padding-right: clamp(22px,5vw,76px); }
.neoTopbar { top: 0; right: 0; left: 0; height: 78px; height: calc(78px + env(safe-area-inset-top)); padding-left: 22px; padding-right: 22px; padding-left: clamp(22px,5vw,76px); padding-right: clamp(22px,5vw,76px); }
.neoHero { padding-top: 78px; padding-top: calc(78px + env(safe-area-inset-top)); }
.neoHeroBackdrop, .neoHeroBackdrop::after, .neoMethodVisual picture, .neoMethodVisual img, .neoSystemLabels { top: 0; right: 0; bottom: 0; left: 0; }
.neoMethodVisual::after, .neoAboutMark::after { right: 0; bottom: 0; left: 0; }
.neoAboutMark figcaption { right: 24px; bottom: 28px; left: 24px; }
.neoAboutMark { width: 100%; max-width: 620px; }
.neoMethodContent { padding-top: 15px; padding-bottom: 15px; }
.takumiFooter p, .takumiFooter h2 { margin-top: 0; }
.takumiFooter a { word-wrap: break-word; }

@media(max-width:860px) {
  .neoHeroBackdrop { top: auto; right: auto; bottom: auto; left: auto; }
  .neoNavLinks { top: 78px; top: calc(78px + env(safe-area-inset-top)); right: 14px; left: 14px; bottom: auto; max-height: calc(100vh - 98px); }
}
@media(max-width:640px) {
  .neoAboutMark { max-width: 420px; }
  .neoAboutMark figcaption { right: 18px; bottom: 20px; left: 18px; }
}
@media(max-width:390px) {
  .neoShell { padding-left: 16px; padding-right: 16px; }
}
@supports not (height:min(1px,2px)) {
  @media(max-width:860px) { .neoHeroBackdrop { height:93.816vw; max-height:430px; } }
}
@supports(padding-left:max(1px,2px)) {
  .neoShell, .neoTopbar { padding-left:max(clamp(22px,5vw,76px),env(safe-area-inset-left)); padding-right:max(clamp(22px,5vw,76px),env(safe-area-inset-right)); }
  @media(max-width:390px) { .neoShell { padding-left:max(16px,env(safe-area-inset-left)); padding-right:max(16px,env(safe-area-inset-right)); } }
}

/* A layout with missing aspect-ratio gets explicit image frames and margin
   spacing; this also covers the older Safari releases without flex gaps. */
@supports not (aspect-ratio:1 / 1) {
  .neoBrand { width:152px; height:64px; }
  .neoBrandArtwork { width:100%; height:100%; }
  .neoAboutMark { height:auto; }
  .neoAboutMark::before { content:""; display:block; padding-top:100%; }
  .neoAboutSymbol { position:absolute; top:0; left:0; width:100%; height:100%; }
  .neoNavLinks, .neoHeroActions, .neoHeroEyebrow, .neoHeroBooking, .neoHeroChallenges article,
  .neoSectionIndex, .neoContactEyebrow, .neoSystemLabel, .neoContactBottom, .takumiFooterLegal { gap:0; }
  .neoNavLinks>a { margin-right:24px; }
  .neoNavLinks>a:last-child { margin-right:0; }
  .neoHeroActions>*+* { margin-top:12px; }
  .neoHeroEyebrow::before { margin-right:18px; }
  .neoHeroBooking svg, .neoHeroChallenges svg { margin-right:12px; }
  .neoSectionIndex>span, .neoContactEyebrow>span { margin-right:16px; flex-shrink:0; }
  .neoSystemLabel b { margin-right:8px; }
  .neoContactBottom>p { margin-right:24px; }
  .takumiFooterLegal>small { margin-right:24px; }
  .neoNavCta svg, .neoButton svg, .neoContactBottom a svg { margin-left:9px; flex-shrink:0; }
  .neoHeroBooking span { flex:1; min-width:0; }
  .neoHeroChallenges p { flex:1; min-width:0; }
  @media(max-width:860px) {
    .neoNavLinks>a { margin-right:0; }
    .neoHeroEyebrow::before { margin-right:12px; }
  }
  @media(max-width:640px) {
    .neoContactBottom>p { margin-right:0; margin-bottom:24px; }
    .takumiFooterLegal>small { margin-right:0; margin-bottom:4px; }
    .takumiFooter { padding:36px 20px 28px; }
  }
}

@supports not (font-size:clamp(1rem,2vw,2rem)) {
  .neoHeroContent h1 { font-size:72px; }
  .neoHeroLead { font-size:20px; }
  .neoManifesto, .neoMethod, .neoFaq { padding-top:110px; padding-bottom:110px; }
  .neoCapabilities, .neoAbout { padding-top:110px; padding-bottom:110px; }
  .neoHeroChallenges { grid-gap:0; }
  .neoCapabilityGrid { grid-gap:14px; }
  .neoCapabilityCard { padding:30px; }
  .neoMethodSeal span { font-size:60px; }
  .takumiFooter { padding:56px 5vw 28px; }
  .takumiFooterGrid { grid-gap:32px; }
  @media(max-width:860px) {
    .neoHeroContent h1 { font-size:52px; }
    .neoHeroLead { font-size:18px; }
  }
  @media(max-width:640px) {
    .neoManifesto, .neoMethod, .neoFaq { padding-top:72px; padding-bottom:72px; }
    .neoCapabilities, .neoAbout { padding-top:72px; padding-bottom:72px; }
    .neoMethodVisual { min-height:430px; }
    .neoCapabilityCard { padding:28px 24px; }
    .takumiFooter { padding:36px 20px 28px; }
    .takumiFooterGrid { grid-gap:26px 20px; }
  }
  @media(max-width:480px) { .neoHeroContent h1 { font-size:40px; } }
}

@media(max-width:860px) and (orientation:landscape) and (max-height:520px) {
  .neoNavLinks { max-height:calc(100vh - 84px); }
}
@media(max-width:359px) {
  .neoHeroChallenges { grid-template-columns:minmax(0,1fr); }
  .neoHeroChallenges article, .neoHeroChallenges article:first-child, .neoHeroChallenges article:last-child { border-right:0; border-bottom:1px solid var(--line); min-height:76px; padding:14px 8px; }
  .neoHeroChallenges article:last-child { border-bottom:0; }
}
