/* Homepage, Nov 9 premium pass: sunlit hero with two real app phones and the cast, the loop, a look inside,
   the reef postcard with all twelve companions, answers, and one download ending. Phones are always whole on screen. */
.home-section{padding-block:var(--space)}
.home-heading{text-align:center;max-width:780px;margin:0 auto 64px}
.home-heading p{max-width:56ch;margin:24px auto 0;font-size:18px;line-height:1.7;color:var(--ink2)}

/* Hero */
.home-hero{position:relative;overflow:hidden;background:var(--water);border-bottom:var(--line)}
.home-hero-layout{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:56px;min-height:min(940px,100svh);padding-block:calc(var(--header) + 56px) 88px}
.home-hero-copy{position:relative;z-index:2}
.hero-icon{width:96px;height:96px;margin-bottom:32px;border:var(--line);border-radius:24px;box-shadow:var(--drop)}
.hero-lede{max-width:30em;margin-top:28px;font-size:clamp(18px,1.6vw,21px);line-height:1.6}
.home-download{display:flex;align-items:center;margin-top:36px}
.home-download .store-badge img{width:192px;height:64px}
.home-free{font-size:15px;line-height:1.6;margin-top:18px}
/* Phone fan: sizes and positions all follow --p (the front phone's width), so the whole group scales as one. */
.home-hero-art{--p:300px;position:relative;width:calc(var(--p) * 1.78);height:calc(var(--p) * 2.42);min-width:0}
.home-device{margin:0}
.home-hero-art .home-device{position:absolute}
.home-hero-art .device-frame{width:100%}
.hero-phone-front{width:var(--p);left:calc(var(--p) * .1);top:calc(var(--p) * .12);z-index:2}
.hero-phone-back{width:calc(var(--p) * .84);right:calc(var(--p) * .04);top:calc(var(--p) * .4);rotate:6deg;z-index:1}
.hero-cast{position:absolute;max-width:none;height:auto;filter:var(--sticker);pointer-events:none;z-index:3}
.hero-manta{width:calc(var(--p) * .52);right:calc(var(--p) * .02);top:0;z-index:1;animation-duration:11s}
.hero-clown{width:calc(var(--p) * .5);left:calc(var(--p) * -.12);top:calc(var(--p) * 1.58)}
.hero-turtle{width:calc(var(--p) * .54);right:calc(var(--p) * -.02);top:calc(var(--p) * 1.98);animation-delay:-4s}

/* The loop: three tone cards */
.home-loop{background:var(--paper)}
.home-steps,.home-use-cases{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:28px;text-align:center}
.home-steps article,.home-use-cases article{position:relative;padding:40px 28px 40px;border:var(--line);border-radius:28px;box-shadow:var(--drop)}
.home-steps article:nth-child(1){background:var(--coral)}.home-steps article:nth-child(2){background:var(--sand)}.home-steps article:nth-child(3){background:var(--lagoon)}
.step-number{position:absolute;top:18px;left:18px;display:grid;place-items:center;width:36px;height:36px;border:2px solid var(--ink);border-radius:50%;background:var(--paper);font-size:15px;font-weight:800;line-height:1}
.home-step-art{height:140px;margin-bottom:24px;display:flex;align-items:center;justify-content:center}
.home-step-art>img{width:112px;height:112px}
.home-step-art>img[src*=cast]{width:min(210px,80%);height:auto;filter:var(--sticker)}
.home-step-time span{display:inline-flex;align-items:center;padding:4px 20px;background:var(--paper);border:var(--line);border-radius:24px;box-shadow:var(--drop);font-size:54px;font-weight:800;line-height:1.15;letter-spacing:-.03em;font-variant-numeric:tabular-nums}
.home-steps h3,.home-use-cases h3{font-size:23px}
.home-steps p,.home-use-cases p{font-size:16px;line-height:1.7;max-width:30ch;margin:12px auto 0;color:var(--ink)}

/* A look inside */
.home-preview{background:var(--lagoon);border-block:var(--line)}
.home-preview-layout{display:grid;grid-template-columns:auto minmax(0,1fr);gap:112px;align-items:center;max-width:1000px;margin:auto}
.home-preview-device{padding:8px 0 14px}
.home-preview-device .device-frame{width:300px}
.home-preview-copy{min-width:0}
.home-preview-switcher{display:flex;flex-wrap:wrap;gap:10px;margin:36px 0 32px}
.home-preview-copy h3{font-size:clamp(26px,2.6vw,34px);line-height:1.15}
.home-preview-copy article{min-height:250px}
.home-preview-copy article>p{max-width:42ch;font-size:18px;line-height:1.7;margin-top:18px}
.home-preview-copy .home-preview-note{display:inline-flex;align-items:center;min-height:40px;font-size:14px;line-height:1.4;margin-top:20px;padding:8px 16px;background:var(--paper);border:2px solid var(--ink);border-radius:20px}

/* Reef postcard and the twelve */
.home-world{background:var(--paper)}
.home-world-art{position:relative;aspect-ratio:2.1;max-width:1120px;margin:auto;overflow:hidden;border:var(--line);border-radius:32px;box-shadow:0 6px 0 var(--ink);background:url('/assets/reef.webp') center 74%/cover}
.home-world-art img{position:absolute;max-width:none;height:auto;filter:var(--sticker)}
.home-world-whale{width:44%;left:7%;top:13%}
.home-world-manta{width:20%;right:7%;top:7%}
.home-world-turtle{width:25%;right:13%;bottom:9%}
.home-world-clown{width:17%;left:42%;bottom:8%;animation-delay:-3s}
.cast-title{text-align:center;font-size:clamp(22px,2.2vw,28px);margin:88px 0 32px}
.cast-grid{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:16px}
.cast-grid li{display:flex;flex-direction:column;align-items:center;gap:12px;padding:20px 10px 16px;border:var(--line);border-radius:24px;box-shadow:0 3px 0 var(--ink);background:var(--paper)}
.cast-grid li:nth-child(6n+1){background:var(--lagoon)}.cast-grid li:nth-child(6n+2){background:var(--sand)}.cast-grid li:nth-child(6n+3){background:var(--coral)}
.cast-grid li:nth-child(6n+4){background:var(--mint)}.cast-grid li:nth-child(6n+5){background:var(--lilac)}
.cast-grid img{width:100%;height:84px;object-fit:contain;filter:var(--sticker)}
.cast-grid span{font-size:14px;font-weight:800;line-height:1.25;text-align:center}
.home-centered-link{display:flex;width:max-content;max-width:100%;margin:36px auto 0}

/* Use cases */
.home-day{background:var(--paper);padding-top:0}
.home-use-cases article{padding:36px 28px}
.home-use-cases article:nth-child(1){background:var(--sand)}.home-use-cases article:nth-child(2){background:var(--coral)}.home-use-cases article:nth-child(3){background:var(--mint)}

/* Maker note */
.home-maker{padding-block:0 var(--space);background:var(--paper)}
.home-maker-layout{display:grid;grid-template-columns:140px minmax(0,1fr);align-items:center;gap:36px;max-width:900px;padding:40px 44px;background:var(--lilac);border:var(--line);border-radius:30px;box-shadow:var(--drop)}
.home-maker-layout>img{width:140px;filter:var(--sticker)}
.home-maker h2{font-size:clamp(26px,2.6vw,32px);line-height:1.2}
.home-maker p{font-size:17px;line-height:1.75;margin-top:14px;max-width:62ch}
.home-maker .home-signature{font-size:15px;font-weight:800;margin-top:14px}

/* Questions and download */
.home-questions{background:var(--lagoon);border-top:var(--line)}
.home-questions .home-heading{margin-bottom:44px}
.home-launch{text-align:center;padding-block:var(--space);background:var(--water);border-top:var(--line)}
.launch-icon{width:112px;height:112px;margin:0 auto 36px;border:var(--line);border-radius:28px;box-shadow:var(--drop)}
.home-launch h2{font-size:clamp(38px,5.2vw,68px);line-height:1.02}
.home-launch>.wrap>p:not(.home-free){font-size:19px;margin-top:22px}
.launch-badge{display:flex;justify-content:center;margin-top:36px}
.launch-badge .store-badge img{width:192px;height:64px}
.home-launch .home-free{margin-top:20px}

@media(max-width:1100px){
 .home-hero-art{--p:260px}
 .home-preview-layout{gap:64px}
 .cast-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
}
@media(min-width:761px) and (max-width:1000px){
 .home-hero-layout{grid-template-columns:1fr;justify-items:center;gap:64px;min-height:0;padding-block:calc(var(--header) + 56px) 80px}
 .home-hero-copy{width:100%;max-width:640px}
 .home-hero-art{--p:270px}
 .home-steps,.home-use-cases{grid-template-columns:1fr;max-width:560px;margin-inline:auto}
}
@media(max-width:760px){
 .home-heading{margin-bottom:44px}.home-heading p{font-size:17px}
 .home-hero-layout{grid-template-columns:1fr;justify-items:center;gap:48px;min-height:0;padding-block:calc(var(--header) + 36px) 64px}
 .home-hero-copy{width:100%}
 .hero-icon{width:76px;height:76px;border-radius:19px;margin-bottom:24px}
 .hero-lede{margin-top:22px}
 .home-download{margin-top:28px}.home-download .store-badge img{width:180px;height:60px}
 /* The fan narrows: box is 1.5 phones wide, the back phone tucks further behind. */
 .home-hero-art{--p:min(240px,calc((100vw - 40px) / 1.56));width:calc(var(--p) * 1.42);height:calc(var(--p) * 2.34)}
 .hero-phone-front{left:calc(var(--p) * .04)}
 .hero-phone-back{right:calc(var(--p) * .02)}
 .hero-manta{width:calc(var(--p) * .42);right:calc(var(--p) * -.02)}
 .hero-clown{width:calc(var(--p) * .42);left:calc(var(--p) * -.04)}
 .hero-turtle{width:calc(var(--p) * .46);right:calc(var(--p) * -.02)}
 .home-steps,.home-use-cases{grid-template-columns:1fr;gap:20px;max-width:460px;margin-inline:auto}
 .home-steps article{padding:32px 22px}
 .home-step-art{height:120px;margin-bottom:18px}
 .home-step-time span{font-size:46px}
 .home-preview-layout{display:grid;grid-template-columns:minmax(0,1fr);gap:0;max-width:460px;justify-items:center}
 .home-preview-copy{display:contents}
 .home-preview-copy h2{order:1;text-align:center}
 .home-preview-switcher{order:2;justify-content:center;margin:28px 0 32px}
 .home-preview-device{order:3}
 #app-preview-content{order:4;width:100%;margin-top:32px}
 .home-preview-copy .text-link{order:5;justify-self:start}
 .home-preview-device .device-frame{width:250px}
 .home-preview-copy article{min-height:0}
 .home-preview-copy article>p{font-size:17px}
 .home-world-art{aspect-ratio:auto;height:380px;border-radius:24px;background-position:center 78%}
 .home-world-whale{width:78%;left:5%;top:7%}
 .home-world-manta{width:30%;right:4%;top:46%}
 .home-world-turtle{width:40%;left:6%;right:auto;bottom:7%}
 .home-world-clown{width:30%;left:auto;right:8%;bottom:5%}
 .cast-title{margin:64px 0 24px}
 .cast-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
 .cast-grid li{padding:16px 6px 12px;border-radius:20px}
 .cast-grid img{height:60px}.cast-grid span{font-size:12.5px}
 .home-maker-layout{grid-template-columns:1fr;justify-items:start;gap:20px;padding:30px 24px}.home-maker-layout>img{width:96px}
 .launch-icon{width:92px;height:92px;border-radius:23px;margin-bottom:28px}
 .home-launch>.wrap>p:not(.home-free){font-size:17px}
}
@media(max-width:360px){
 .home-preview-switcher{gap:8px}.home-preview-switcher button{padding-inline:14px}
}
