/* Ideal Kindergarten — home page (index.html, <body class="page-home">).
   Purpose: styles used only by the home page, one commented block per section, in page order.
   Shared pieces (header, footer, buttons, dialog, round buttons) are in global.css; variables are in tokens.css. */

/* ---------- 1. Page base ---------- */


/* ---------- 2. Hero (slider) ---------- */
/* Desktop hero is 50% taller than the first version (560px -> 840px); content stays vertically centred */
/* Mobile (<= 600px, see --bp-mobile in tokens.css): the photo shape is hidden, copy only */
@media (max-width: 600px) { .home-hero__art { display: none; } }
@media (min-width: 861px) { .home-hero { min-height: 840px; display: grid; align-content: center; } .home-hero > .page-wrap { width: 100%; } }
/* Hero buttons jump to #notice; keep it clear of the sticky header */
#notice { scroll-margin-top: 88px; }
.home-hero { position: relative; overflow: hidden; background: var(--sky-100); padding: var(--space-12) 0 140px; }
.home-hero__grid { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: var(--space-8); align-items: center; }
.home-hero__eyebrow { display: inline-flex; align-items: center; gap: var(--space-2); padding: 2px var(--space-3); border-radius: var(--radius-pill); background: var(--maroon-100); border: 2px solid var(--maroon-900); color: var(--maroon-900); font: 600 14px/24px var(--font-body); }
.home-hero__eyebrow i { color: var(--maroon-900); font-size: 13px; }
.home-hero h1 { margin: var(--space-4) 0 var(--space-3); font: 700 52px/62px var(--font-display); color: var(--ink); }
.home-hero h1 .accent { color: var(--sky-600); }
.home-hero p { margin: 0; font-size: 19px; line-height: 32px; color: var(--ink-muted); max-width: 46ch; }
.home-hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-6); }
.home-hero__art { position: relative; justify-self: center; width: min(520px, 100%); aspect-ratio: 1; max-width: 100%; }
.letter { position: absolute; display: grid; place-items: center; width: 74px; height: 74px; border-radius: var(--radius-lg); font: 700 38px/1 var(--font-display); color: var(--on-sky); box-shadow: var(--shadow-raised); animation: bob 5s ease-in-out infinite; cursor: default; transition: transform .4s var(--ease-spring); }
.letter:hover { animation-play-state: paused; transform: rotate(-14deg) scale(1.15); }
.letter--1 { top: 2%; left: 6%; background: var(--sky-600); rotate: -8deg; }
.letter--2 { top: 6%; right: 2%; background: var(--maroon-900); rotate: 10deg; animation-delay: -1.2s; }
.letter--3 { bottom: 4%; left: 0; background: var(--navy-900); rotate: 6deg; animation-delay: -2.4s; }
.letter--4 { bottom: 0; right: 8%; background: var(--teal-700); rotate: -6deg; animation-delay: -3.6s; }
@keyframes bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -12px; } }
@media (max-width: 860px) {
  .home-hero { padding-top: var(--space-8); text-align: center; }
  .home-hero__grid { grid-template-columns: minmax(0, 1fr); }
  .home-hero p { margin-inline: auto; }
  .home-hero__actions { justify-content: center; }
  .home-hero__art { width: min(300px, 80%); order: -1; }
  .letter { width: 56px; height: 56px; font-size: 28px; }
}
@media (max-width: 480px) { .home-hero h1 { font-size: 36px; line-height: 46px; } .home-hero p { font-size: 17px; line-height: 29px; } }

/* ---------- 15. Home revisions (v3) ---------- */
/* Hero sky: three organised clouds drifting in fixed lanes at different depths, and one smooth wave into the page. */
.home-hero { padding: var(--space-12) 0 112px; }

/* Hero art — see section 16 (photo frame). */
/* Highlights — quiet inline list under the buttons; hidden while #home-hero has data-highlights="none". */
.hero-points { display: flex; flex-wrap: wrap; gap: var(--space-4) var(--space-6); margin: var(--space-8) 0 0; padding: var(--space-6) 0 0; list-style: none; border-top: 1px solid rgba(37,49,71,.12); }
.home-hero[data-highlights="none"] .hero-points { display: none; }
.hero-points li { display: flex; align-items: center; gap: var(--space-3); min-width: 0; }
.hero-points__icon { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--surface-100); color: var(--sky-700); font-size: 15px; }
.hero-points strong { display: block; font: 600 15px/1.3 var(--font-body); color: var(--ink); }
.hero-points small { display: block; font-size: 13px; line-height: 20px; color: var(--ink-muted); }
@media (max-width: 860px) {
  .hero-points { justify-content: center; text-align: left; }
  .home-hero__art { width: min(320px, 82%); }
}
@media (max-width: 520px) { .hero-points { display: grid; justify-content: stretch; gap: var(--space-3); } }

/* ---------- 16. Hero photo frame (any image fits: object-fit cover inside the shape) ---------- */
.hero-frame { position: absolute; inset: 9%; display: block; }
.hero-frame__back, .hero-frame__photo { position: absolute; inset: 0; display: block; transition: transform .6s var(--ease-out), rotate .6s var(--ease-spring); }
.hero-frame__back { background: var(--sky-600); }
.hero-frame__photo { overflow: hidden; background: var(--sky-100); }
.hero-frame__photo[data-fill="maroon"] { background: var(--maroon-900); }
.hero-frame__photo[data-fill="teal"] { background: var(--teal-700); }
.hero-frame__photo[data-fill="navy"] { background: var(--navy-900); }
.hero-frame__photo img[hidden] { display: none; }
.hero-frame__photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease-out); }
.home-hero__art:hover .hero-frame__photo img { transform: scale(1.06); }

/* Letters around the photo */
.home-hero .letter { z-index: 2; width: 60px; height: 60px; font-size: 30px; }
.home-hero .letter--1 { top: 6%; left: 0; }
.home-hero .letter--2 { top: 0; right: 4%; }
.home-hero .letter--3 { bottom: 6%; left: 2%; }
.home-hero .letter--4 { bottom: 0; right: 2%; }
@media (max-width: 860px) { .home-hero .letter { width: 48px; height: 48px; font-size: 24px; } }

/* ---------- 17. Organic photo frame ----------
   The photo sits in a soft blob with a white rim; a sky blob and a teal blob drift behind it, each morphing on its own rhythm.
   Works for a single child (portrait) or a group photo (landscape) — object-fit: cover keeps faces centred; set object-position on the img to adjust. */
.hero-frame__back2 { display: none; }
.hero-frame[data-shape="organic"] { inset: 4% 0 4% 2%; }
.hero-frame[data-shape="organic"] .hero-frame__back2 { display: block; position: absolute; inset: 0; }
.hero-frame[data-shape="organic"] .hero-frame__back { inset: 10% -4% -6% 8%; background: var(--sky-600); border-radius: 63% 37% 54% 46% / 55% 48% 52% 45%; animation: organic-a 18s ease-in-out infinite alternate; }
.hero-frame[data-shape="organic"] .hero-frame__back2 { inset: -6% 12% 18% -6%; background: var(--teal-400); opacity: .7; border-radius: 42% 58% 70% 30% / 45% 45% 55% 55%; animation: organic-b 22s ease-in-out infinite alternate; transition: transform .6s var(--ease-out); }
.hero-frame[data-shape="organic"] .hero-frame__photo { border: 7px solid var(--surface-100); box-shadow: var(--shadow-raised); border-radius: 64% 36% 48% 52% / 58% 42% 58% 42%; animation: organic-photo 16s ease-in-out infinite alternate; }
.home-hero__art:hover .hero-frame[data-shape="organic"] .hero-frame__back { transform: translate(10px, 8px); }
.home-hero__art:hover .hero-frame[data-shape="organic"] .hero-frame__back2 { transform: translate(-10px, -8px); }
@keyframes organic-a { 50% { border-radius: 40% 60% 45% 55% / 60% 40% 60% 40%; rotate: 8deg; } 100% { border-radius: 55% 45% 62% 38% / 42% 58% 42% 58%; rotate: -4deg; } }
@keyframes organic-b { 50% { border-radius: 60% 40% 38% 62% / 52% 62% 38% 48%; rotate: -10deg; } 100% { border-radius: 35% 65% 58% 42% / 62% 38% 62% 38%; rotate: 6deg; } }
@keyframes organic-photo { 50% { border-radius: 44% 56% 62% 38% / 50% 60% 40% 50%; } 100% { border-radius: 58% 42% 36% 64% / 42% 52% 48% 58%; } }

/* Confetti — four small shapes in brand colours, floating slowly. */
.confetti { position: absolute; z-index: 1; animation: float-confetti 7s ease-in-out infinite; pointer-events: none; }
.confetti--triangle { top: 2%; left: 30%; width: 0; height: 0; border-left: 12px solid transparent; border-right: 12px solid transparent; border-bottom: 20px solid var(--maroon-900); rotate: 18deg; }
.confetti--ring { top: 46%; right: -3%; width: 26px; height: 26px; border-radius: 50%; border: 4px solid var(--sky-600); animation-delay: -2s; }
.confetti--dots { bottom: 18%; left: -5%; width: 44px; height: 44px; background: radial-gradient(circle, var(--teal-700) 2px, transparent 2.5px) 0 0 / 11px 11px; animation-delay: -4s; }
.confetti--zigzag { bottom: -2%; left: 38%; width: 48px; height: 12px; fill: none; stroke: var(--maroon-900); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; animation-delay: -1s; }
@keyframes float-confetti { 50% { translate: 0 -10px; } }

/* Hero slides rotate: text and photo fade when the slider sheet has more than one row. */
.home-hero__copy.is-swapping, .hero-frame__photo.is-swapping { opacity: 0; }
.home-hero__copy, .hero-frame__photo { transition: opacity .35s var(--ease-out); }
.home-hero__eyebrow[hidden] { display: none; }
.hero-dots { position: absolute; z-index: 3; left: 50%; bottom: var(--space-12); translate: -50% 0; display: flex; gap: var(--space-2); }
.hero-dots button { position: relative; width: 44px; height: 44px; padding: 0; border: 0; background: none; cursor: pointer; }
.hero-dots button::before { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 12px; translate: -50% -50%; border-radius: 50%; background: var(--sky-100); border: 2px solid var(--sky-600); transition: background-color .25s, scale .25s var(--ease-spring); }
.hero-dots button[aria-current="true"]::before { background: var(--sky-600); scale: 1.2; }

/* ---------- 3. Notice board + notice dialog ---------- */
.notice-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: var(--space-6); align-items: start; }
@media (max-width: 960px) { .notice-layout { grid-template-columns: minmax(0, 1fr); } }
.notice-list { display: grid; gap: var(--space-3); }
.ik-notice { position: relative; display: grid; grid-template-columns: 88px minmax(0, 1fr) 36px; gap: var(--space-4); align-items: center; padding: var(--space-4); background: var(--surface-100); border: 1px solid var(--line); border-radius: var(--radius-lg); color: var(--ink); text-decoration: none; transition: transform .3s var(--ease-out), box-shadow .3s var(--ease-out), border-color .3s; }
.ik-notice:hover { transform: translateX(4px); box-shadow: var(--shadow-raised); border-color: transparent; }
.ik-notice__date { display: grid; place-content: center; min-width: 0; min-height: 68px; padding: var(--space-2); border-radius: var(--radius-md); background: var(--sky-100); color: var(--sky-700); text-align: center; line-height: 1.1; transition: background-color .3s, color .3s, transform .4s var(--ease-spring); }
.ik-notice:hover .ik-notice__date { background: var(--sky-600); color: var(--on-sky); transform: rotate(-4deg); }
.ik-notice__day { font: 700 28px/1 var(--font-display); }
.ik-notice__month { font: 600 13px/1.4 var(--font-body); }
.ik-notice__body { min-width: 0; display: grid; gap: 2px; }
.ik-notice__title { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); font: 600 18px/1.45 var(--font-body); }
.ik-notice__text { margin: 0; color: var(--ink-muted); font-size: 15px; line-height: 24px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ik-notice__go { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; color: var(--sky-700); background: var(--sky-050); opacity: 0; transform: translateX(-8px); transition: opacity .3s, transform .3s var(--ease-out); }
.ik-notice:hover .ik-notice__go, .ik-notice:focus-visible .ik-notice__go { opacity: 1; transform: none; }
.ik-notice--important { background: var(--maroon-100); border-color: transparent; }
.ik-notice--important .ik-notice__date { background: var(--maroon-900); color: var(--on-maroon); }
@media (max-width: 480px) { .ik-notice { grid-template-columns: 80px minmax(0, 1fr); } .ik-notice__go { display: none; } }
@media (hover: none) { .ik-notice__go { opacity: 1; transform: none; } }

/* Notice cards open a dialog. */
button.ik-notice { width: 100%; font: inherit; text-align: left; cursor: pointer; }
.notice-dialog { width: min(620px, calc(100% - 2 * var(--space-4))); }
.notice-dialog__label { display: inline-flex; align-items: center; gap: var(--space-2); font: 600 15px/1.4 var(--font-body); color: var(--maroon-900); }
.notice-dialog__body { padding: var(--space-6); }
.notice-dialog__meta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); }
.notice-dialog__date { display: inline-flex; align-items: center; gap: var(--space-2); padding: 0 var(--space-3); border-radius: var(--radius-pill); background: var(--sky-100); color: var(--sky-700); font: 600 14px/30px var(--font-body); }
.notice-dialog h3 { margin: 0; font: 700 24px/1.4 var(--font-display); color: var(--ink); }
.notice-dialog__text p { margin: 0 0 var(--space-3); font-size: 17px; line-height: 30px; }
.notice-dialog__text p:last-child { margin: 0; }
/* Notice dialog images (images_url column) */
.notice-dialog__images { display: grid; gap: var(--space-3); margin-top: var(--space-4); }
.notice-dialog__images img { width: 100%; height: auto; border-radius: var(--radius-md); background: var(--sky-050); }
.notice-dialog__images .skeleton { aspect-ratio: 4 / 3; }

/* ---------- 4. Facebook card ---------- */
.fb-card { display: grid; background: var(--surface-100); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-card); overflow: hidden; }
.fb-card__head { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-4); border-bottom: 1px solid var(--line); }
.fb-card__head img { width: 44px; height: 44px; border-radius: 50%; }
.fb-card__head strong { display: block; font-weight: 600; line-height: 1.3; }
.fb-card__head span { font-size: 13px; color: var(--ink-muted); }
.fb-card__logo { margin-left: auto; color: var(--facebook); font-size: 24px; }
.fb-feed { display: grid; max-height: 420px; overflow-y: auto; }
.fb-post { display: grid; gap: var(--space-2); padding: var(--space-4); border-bottom: 1px solid var(--line); transition: background-color .2s; }
.fb-post:hover { background: var(--sky-050); }
.fb-post time { font-size: 13px; color: var(--ink-muted); }
.fb-post p { margin: 0; font-size: 15px; line-height: 24px; }
.fb-post img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-md); }
.fb-post__meta { display: flex; gap: var(--space-4); font-size: 13px; color: var(--ink-muted); }
.fb-card__foot { padding: var(--space-4); }
.fb-card iframe { width: 100%; height: 500px; border: 0; display: block; }
.ik-btn--facebook { background: var(--facebook-button); color: #ffffff; }
.ik-btn--facebook:hover { box-shadow: 0 10px 22px rgba(24,119,242,.3); }
/* Facebook widget inside .fb-card (assets/js/facebook-widget.js owns the markup) */
.fb-card .fb-wrapper { position: relative; min-height: 420px; }
.fb-card .fb-content { position: relative; z-index: 1; }
.fb-card .fb-skeleton-overlay { position: absolute; inset: 0; z-index: 2; background: var(--surface-100); padding: var(--space-4); transition: opacity .3s ease; }
.fb-card .fb-skeleton-overlay.fade-out { opacity: 0; pointer-events: none; }
.fb-card #facebook-widget { min-width: 0; }
.fb-card .fb-page, .fb-card .fb-page span, .fb-card .fb-page iframe { max-width: 100% !important; }

/* ---------- 5. Why choose us ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-4); }
.ik-feature { position: relative; display: grid; gap: var(--space-3); align-content: start; padding: var(--space-6); min-height: 210px; background: var(--surface-100); border-radius: var(--radius-lg); box-shadow: var(--shadow-card); overflow: hidden; isolation: isolate; transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out), color .3s; }
.ik-feature::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--sky-600); clip-path: circle(0 at 48px 48px); transition: clip-path .55s var(--ease-out); }
.ik-feature__title { margin: 0; font: 600 19px/28px var(--font-display); transition: color .3s; }
.ik-feature__text { margin: 0; color: var(--ink-muted); font-size: 15px; line-height: 25px; max-height: 0; opacity: 0; transform: translateY(8px); transition: max-height .45s var(--ease-out), opacity .3s, transform .4s var(--ease-out), color .3s; }
.ik-feature:hover, .ik-feature:focus-within, .ik-feature:focus { transform: translateY(-6px); box-shadow: var(--shadow-raised); }
.ik-feature:hover::before, .ik-feature:focus::before, .ik-feature--featured::before { clip-path: circle(150% at 48px 48px); }
.ik-feature:hover .ik-feature__icon, .ik-feature:focus .ik-feature__icon { transform: rotate(-12deg) scale(1.1); background: var(--surface-100); color: var(--sky-700); }
.ik-feature:hover .ik-feature__title, .ik-feature:focus .ik-feature__title, .ik-feature:hover .ik-feature__text, .ik-feature:focus .ik-feature__text { color: var(--on-sky); }
.ik-feature:hover .ik-feature__text, .ik-feature:focus .ik-feature__text, .ik-feature--featured .ik-feature__text { max-height: 220px; opacity: 1; transform: none; }
.ik-feature--featured { grid-column: span 2; color: var(--on-sky); }
.ik-feature--vertical { grid-column: auto; grid-row: span 2; align-content: center; }
.ik-feature--featured .ik-feature__icon { background: var(--surface-100); }
.ik-feature--featured .ik-feature__title, .ik-feature--featured .ik-feature__text { color: var(--on-sky); }
.ik-feature__hint { position: absolute; right: var(--space-4); bottom: var(--space-3); font-size: 13px; color: var(--ink-muted); transition: opacity .2s; }
.ik-feature:hover .ik-feature__hint, .ik-feature:focus .ik-feature__hint, .ik-feature--featured .ik-feature__hint { opacity: 0; }
@media (max-width: 960px) { .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .feature-grid { grid-template-columns: minmax(0, 1fr); } .ik-feature--featured, .ik-feature--vertical { grid-column: auto; grid-row: auto; } }
@media (hover: none) { .ik-feature__text { max-height: none; opacity: 1; transform: none; } .ik-feature__hint { display: none; } .ik-feature { min-height: 0; } }

/* ---------- 6. Alumni stories (carousel + story dialog) ---------- */
.carousel { position: relative; }
.carousel__track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 2 * var(--space-4)) / 3); gap: var(--space-4); overflow-x: auto; scroll-snap-type: x mandatory; padding: var(--space-2) var(--space-1) var(--space-6); scrollbar-width: none; }
.carousel__track::-webkit-scrollbar { display: none; }
.carousel__controls { display: flex; gap: var(--space-2); }
.story { scroll-snap-align: start; display: grid; grid-template-rows: auto 1fr; background: var(--surface-100); border-radius: var(--radius-lg); border: 1px solid var(--line); overflow: hidden; text-align: left; padding: 0; font: inherit; color: inherit; cursor: pointer; transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out); }
.story:hover { transform: translateY(-6px); box-shadow: var(--shadow-raised); }
.story__media { position: relative; aspect-ratio: 1 / 1; max-width: 100%; overflow: hidden; background: var(--navy-900); }
.story__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease-out); }
.story:hover .story__media img { transform: scale(1.06); }
.story__media::after { content: ""; position: absolute; inset: 0; background: rgba(37,49,71,0); transition: background-color .3s; }
.story:hover .story__media::after { background: rgba(37,49,71,.25); }
.story__open { position: absolute; z-index: 1; left: 50%; top: 50%; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: var(--surface-100); color: var(--sky-700); font-size: 20px; translate: -50% -50%; scale: .6; opacity: 0; transition: scale .4s var(--ease-spring), opacity .25s; }
.story:hover .story__open, .story:focus-visible .story__open { scale: 1; opacity: 1; }
.story--video .story__open { opacity: 1; scale: 1; background: var(--sky-600); color: var(--on-sky); }
.story--video:hover .story__open { animation: pulse 1.4s ease-out infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,255,255,.7); } 100% { box-shadow: 0 0 0 18px rgba(255,255,255,0); } }
.story__video-art { width: 100%; height: 100%; display: grid; place-items: center; background: var(--navy-900); }
.story__video-art img { width: 46%; height: auto; opacity: .35; border-radius: 50%; }
.story__body { display: grid; gap: 2px; align-content: start; padding: var(--space-4); }
.story__name { margin: 0; font: 600 17px/1.4 var(--font-body); }
.story__role { margin: 0; font-size: 14px; line-height: 22px; color: var(--ink-muted); }
/* Stories: three per row on desktop so the row overflows and auto-advances; the open icon has its own hover. */
@media (max-width: 1000px) { .carousel__track { grid-auto-columns: calc((100% - var(--space-4)) / 2); } }
@media (max-width: 640px) { .carousel__track { grid-auto-columns: 80%; } }
.story__open { transition: scale .4s var(--ease-spring), opacity .25s, background-color .25s, color .25s, rotate .4s var(--ease-spring), box-shadow .3s; box-shadow: 0 6px 18px rgba(15,26,44,.25); }
.story__open:hover, .carousel.is-preview .story:first-child .story__open { background: var(--sky-600); color: var(--on-sky); scale: 1.15; rotate: -10deg; box-shadow: 0 0 0 8px rgba(255,255,255,.35), 0 10px 24px rgba(15,26,44,.3); }
.story--video .story__open:hover { background: var(--maroon-900); color: var(--on-maroon); }
.carousel.is-preview .story:first-child { transform: translateY(-6px); box-shadow: var(--shadow-raised); }
.carousel.is-preview .story:first-child .story__media img { transform: scale(1.06); }
.carousel.is-preview .story:first-child .story__media::after { background: rgba(37,49,71,.25); }
.carousel.is-preview .story:first-child .story__open { opacity: 1; }
.carousel__controls[hidden] { display: none; }
/* Section head: title on the left, carousel arrows on the right */
.section-head { display: flex; align-items: end; justify-content: space-between; gap: var(--space-4); margin-bottom: var(--space-6); }
.section-head .ik-section-title { margin: 0; }
/* Text-only story: the text fills the square media area */
.story__text { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 7; overflow: hidden; padding: var(--space-6); color: var(--on-sky); background: var(--sky-600); font-size: 16px; line-height: 26px; text-align: left; }
.story--text .story__media { background: var(--sky-600); }
.story--text .story__text { position: absolute; inset: 0; }
.story--text .story__open { background: var(--surface-100); }
/* Story dialog */
.story-dialog { width: min(1000px, calc(100% - 2 * var(--space-4))); }
.story-dialog__actions { display: flex; gap: var(--space-2); }
.story-dialog__stage { position: relative; display: grid; border-radius: var(--radius-md); overflow: hidden; background: var(--navy-900); }
.story-dialog__stage.is-frame { aspect-ratio: 16 / 10; }
.story-dialog__stage.is-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.story-dialog__stage > .skeleton { position: absolute; inset: 0; border-radius: 0; }
.story-dialog__stage.is-text { background: transparent; }
.story-dialog__text { font-size: 17px; line-height: 30px; }
.story-dialog__text p { margin: 0 0 var(--space-3); }
.story-dialog__text p:last-child { margin: 0; }
.story-dialog__caption { margin: 0; color: var(--ink-muted); font-size: 14px; }

/* ---------- 7. Gallery preview (sky band + mosaic) ---------- */
.mosaic { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: 180px 180px; gap: var(--space-4); }
.mosaic .tile:first-child, .mosaic .skeleton-tile:first-child { grid-row: span 2; }
.tile { position: relative; display: block; overflow: hidden; border-radius: var(--radius-lg); background: var(--sky-100); color: var(--on-sky); text-decoration: none; }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease-out); }
.tile:hover img { transform: scale(1.08); }
.tile__label { position: absolute; left: var(--space-3); right: var(--space-3); bottom: var(--space-3); padding: var(--space-2) var(--space-3); border-radius: var(--radius-md); background: rgba(37,49,71,.82); font-weight: 600; font-size: 15px; line-height: 1.4; transform: translateY(6px); opacity: .92; transition: transform .3s var(--ease-out), opacity .3s; }
.tile:hover .tile__label { transform: none; opacity: 1; }
.skeleton-tile { border-radius: var(--radius-lg); }
.gallery-more--foot { display: none; }
@media (max-width: 760px) {
  .gallery-more--head { display: none; }
  .gallery-more--foot { display: flex; justify-content: center; margin-top: var(--space-6); }
  .mosaic { grid-template-columns: 1fr 1fr; grid-template-rows: 200px 140px 140px; }
  .mosaic .tile:first-child, .mosaic .skeleton-tile:first-child { grid-column: span 2; grid-row: auto; }
}

/* ---------- 8. Visit strip (above footer) ---------- */
/* Visit strip — quiet line above the footer instead of the navy box. */
.visit-strip { border-top: 1px solid var(--line); background: var(--surface-000); }
.visit-strip__inner { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: var(--space-4) var(--space-6); align-items: center; padding-block: var(--space-8); }
.visit-strip__icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--sky-100); color: var(--sky-700); font-size: 20px; }
.visit-strip h2 { margin: 0; font: 700 20px/1.4 var(--font-display); }
.visit-strip p { margin: 0; font-size: 15px; line-height: 24px; color: var(--ink-muted); }
.visit-strip__links { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-6); }
@media (max-width: 760px) { .visit-strip__inner { grid-template-columns: auto minmax(0, 1fr); } .visit-strip__links { grid-column: 1 / -1; } }

/* ---------- 9. Loading, empty and error states ---------- */
.skeleton-line { height: 16px; margin-block: var(--space-2); }
.skeleton-line.short { width: 40%; }
.skeleton-notice { height: 96px; border-radius: var(--radius-lg); }
.skeleton-feature { height: 200px; border-radius: var(--radius-lg); }
.skeleton-story { min-height: 320px; border-radius: var(--radius-lg); }
.home-hero.is-loading .skeleton-line { background-color: var(--sky-050); }
.skeleton-hero-title { height: 48px; width: 80%; margin-bottom: var(--space-4); }
.skeleton-hero-btn { height: 46px; width: 180px; margin-top: var(--space-6); }
.skeleton-hero-art { position: absolute; inset: 12% 4% 10% 6%; border-radius: 63% 37% 54% 46% / 55% 48% 52% 45%; background-color: var(--sky-050); }
.empty-text { margin: 0; color: var(--ink-muted); }

/* ---------- 10. Reduced motion (home only) ---------- */
@media (prefers-reduced-motion: reduce) { .home-hero__copy, .hero-frame__photo { transition: none; } }
