/* studiolointeractive.com: the site's layout. Colours, fonts and the logo come from /brand/brand.css. */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; }
img, video, canvas { max-width: 100%; display: block; }
h1, h2, h3 { margin: 0 0 0.5em; text-wrap: balance; }
p { margin: 0 0 1em; text-wrap: pretty; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(1160px, 100% - 3rem); margin-inline: auto; }
.small { font-size: 0.9rem; }
.muted { color: var(--muted); }
.eyebrow { font-family: var(--font-text); font-size: 0.8rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
           color: var(--red); margin-bottom: 0.75rem; }
.lead { font-size: 1.2rem; line-height: 1.55; max-width: 36em; }
section { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
section + section { border-top: 1px solid var(--line); }

.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: var(--paper); padding: .6rem 1rem; z-index: 10; }
.skip:focus { left: 1rem; top: 1rem; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--paper); position: sticky; top: 0; z-index: 5; }
.site-header .bar { display: flex; flex-direction: column; align-items: center; gap: .8rem; padding-block: 1.25rem .9rem; }
.site-header .logo img { height: 3rem; width: auto; }
.site-header nav { display: flex; gap: clamp(1rem, 3vw, 2.25rem); }
.site-header nav a { color: var(--ink); text-decoration: none; font-weight: 500; font-size: 0.98rem; }
.site-header nav a:hover { color: var(--red); }
.site-header nav a[aria-current="page"] { color: var(--red); }
@media (max-width: 640px) {
  .site-header .bar { gap: .7rem; padding-block: 1rem .7rem; }
  .site-header .logo img { height: 2.9rem; }
  .site-header nav { gap: 1.4rem; }
  .site-header nav a { font-size: 0.95rem; }
}

/* Buttons */
.button { transition: filter .15s ease; }
.button:hover { filter: brightness(1.08); }
.button.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.button.ghost:hover { box-shadow: inset 0 0 0 1.5px var(--ink); filter: none; }
.button[aria-disabled="true"] { background: var(--line); color: var(--muted); pointer-events: none; }
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: center; }

/* Home: hero */
.hero { padding-block: clamp(2.5rem, 6vw, 5rem); border-top: 0; }
.hero .grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.hero h1 { font-size: clamp(2.5rem, 5vw + 0.5rem, 4.4rem); letter-spacing: -0.02em; line-height: 1.02; }
.hero .art { margin: 0; position: relative; aspect-ratio: 4 / 3; border-radius: 22px; overflow: hidden; background: var(--paper-raised);
             box-shadow: 0 30px 60px -30px rgb(0 0 0 / .35); }
.hero .art img, .hero .art canvas { width: 100%; height: 100%; object-fit: cover; }
.hero .art figcaption { position: absolute; left: 1rem; bottom: 1rem; font-size: 0.8rem; background: rgb(0 0 0 / .55); color: #fff;
                        padding: .3rem .7rem; border-radius: 999px; }
@media (max-width: 860px) { .hero .grid { grid-template-columns: 1fr; } }

/* Home: only the honeycomb, filling the screen. Pointy-top hexagons of "radius" --r (centre to corner): the logo's
   crest (twice the size) on top, then rows Mosaico, Ripresa / Tela, Rubato, Lux / Bottega, Gioco. --r is the largest
   that lets the whole honeycomb (5.2r wide, 8.5r tall, plus gaps) fit the screen.
   The camera: choosing a hexagon moves the whole honeycomb (one transform on .hive, set by site.js), so it looks as
   if we fly in to it. main holds the perspective, the "lens"; the hexagons live in its 3D space. */
.home .site-header { display: none; }
.home main { position: relative; height: 100svh; overflow: clip; perspective: 1600px;
             touch-action: none; }   /* pinch and drag move the honeycomb's camera (site.js), not the page (15 Nov) */
/* The frame the honeycomb sits in. On a landscape screen (body.turned, set by site.js with some hysteresis) it turns
   90° counterclockwise: the crest moves to the left and the honeycomb runs across the screen. The hexagons turn with
   it; their text and the logo are turned back, so they stay upright. Sizes inside use the frame's own width and
   height (cqw, cqh), so the same rules fit either way. */
.turn { position: absolute; inset: 0; display: grid; place-items: center; padding: 1rem; container-type: size;
        transform-style: preserve-3d; }
body.turned .turn { inset: auto; left: 50%; top: 50%; width: 100svh; height: 100vw; transform: translate(-50%, -50%) rotate(-90deg); }
.hive { --gap: clamp(5px, .9vmin, 12px);
        --r: clamp(44px, min(calc((100cqw - 2 * var(--gap)) / 5.2), calc((100cqh - 4 * var(--gap)) / 10)), 170px);
        --w: calc(var(--r) * 1.7320508); --h: calc(var(--r) * 2); --step: calc(var(--w) + var(--gap));
        --cy: calc(6 * var(--r) + 1.7320508 * var(--gap));      /* the centre hexagon's distance from the top */
        --zoom: 1;                                               /* the camera's zoom, set by site.js */
        --edge: color-mix(in srgb, var(--line) 55%, var(--paper-raised));   /* every hexagon's edge: one faint colour */
        position: relative; margin: 0 auto; transform-origin: 0 0; transform-style: preserve-3d;
        width: calc(2 * var(--step) + var(--w)); height: calc(10 * var(--r) + 3.4641016 * var(--gap)); }   /* down to Mostra's bottom corner */
.hex { --x: 0; --y: 0; --hexagon: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
       position: absolute; width: var(--w); height: var(--h); isolation: isolate; margin: 0;
       left: calc(50% - var(--w) / 2 + var(--x) * var(--step)); top: calc(var(--cy) - var(--h) / 2 + var(--y) * var(--step));
       clip-path: var(--hexagon); background: var(--edge);          /* the background is the hexagon's edge */
       display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
       gap: calc(var(--r) * .06); color: var(--ink); text-decoration: none; outline: none;
       transition: transform .45s cubic-bezier(.2,.7,.2,1), opacity .5s ease, background .2s; }
.hex::before { content: ""; position: absolute; inset: 1.5px; z-index: -1; clip-path: var(--hexagon); background: var(--paper-raised); }
/* Each card's accent (15 Nov): two thin hexagonal lines in the app's fall colour (brand.css), one inlaid in the other,
   a little inside the card's edge, every line running on past its corners to the edge, so the corners hold small
   rhombi. Drawn by img/hex-frame.svg as a mask over the accent (tools/brand/make_hex_frame.py makes it, with each
   line's position and width); the card itself stays neutral. */
.hex[data-app]::after { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--accent); pointer-events: none;
      -webkit-mask: url(/img/hex-frame.svg) center / 100% 100% no-repeat; mask: url(/img/hex-frame.svg) center / 100% 100% no-repeat; }
/* The crest's own frame (15 Nov): the same two inlaid hexagons in the brand's red, its lines as thin and as far from
   its edge on screen as the cards' (img/hex-frame-crest.svg) */
.hex.crest::after { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--red); pointer-events: none;
      -webkit-mask: url(/img/hex-frame-crest.svg) center / 100% 100% no-repeat; mask: url(/img/hex-frame-crest.svg) center / 100% 100% no-repeat; }
/* The outer border on each card's own edge (15 Nov, 22:05): the app's own dark fall colour (brand.css: oxblood,
   sienna, old gold, olive, pine, slate blue, aubergine, plum, at their deep shade, --accent-strong), twice the inner
   lines' width (the lines are .01 of the apothem: .00866 r). A coming-soon card's border is a muted tint of its
   colour, lighter again when it's opened (zoomed in, the border grows thick and would read darker). The inlaid lines
   are grey on every card; the crest keeps its sunset yellow. */
.hex { --soon-grey: color-mix(in srgb, var(--muted) 45%, var(--paper-raised));   /* the inlaid lines' grey */
       --sunset: #D48C24; }   /* 16 Nov: a little darker (was #E9A23B) */                                                        /* the crest's border */
.hex[data-app] { --border: var(--accent-strong); background: var(--border); }
.hex[data-app].live { --border: color-mix(in oklch, var(--accent-strong) 72%, var(--paper-raised)); }   /* a live card's: slightly muted (15 Nov) */
.hex[data-app]:not(.live) { --border: color-mix(in oklch, var(--accent-strong) 24%, var(--paper-raised)); }   /* muted (15 Nov, 22:06: was 40%) */
.hive.zoomed .hex.focused[data-app]:not(.live) { --border: color-mix(in oklch, var(--accent-strong) 15%, var(--paper-raised));
                                                 --soon-grey: color-mix(in srgb, var(--muted) 25%, var(--paper-raised)); }
.hex[data-app]::after, .hex.crest::after { background: var(--soon-grey); }
.hex.crest { background: var(--sunset); }
/* Tela's card (16 Nov): its middle line in the card's own border colour, the inner one grey as on the others. The
   middle line is drawn by .frame-mid (index.html) with img/hex-frame-middle.svg; ::after keeps only the inner line
   (img/hex-frame-inner.svg). Both made by tools/brand/make_hex_frame.py (.95 .96 and .92 .93, as in hex-frame.svg). */
.hex.live::after { -webkit-mask-image: url(/img/hex-frame-inner.svg); mask-image: url(/img/hex-frame-inner.svg); }
.hex .frame-mid { position: absolute; inset: 0; z-index: -1; pointer-events: none; background: var(--border);
      -webkit-mask: url(/img/hex-frame-middle.svg) center / 100% 100% no-repeat; mask: url(/img/hex-frame-middle.svg) center / 100% 100% no-repeat; }
.hex[data-app]::before, .hex.crest::before { inset: max(1.5px, calc(var(--r) * .0173)); }
.hex[data-app][data-tap]:focus-visible { background: var(--ink); }   /* keyboard focus still shows */
.pos-tr { --x: .5;  --y: -.8660254; }   .pos-r { --x: 1; }   .pos-br { --x: .5;  --y: .8660254; }
.pos-bl { --x: -.5; --y: .8660254; }    .pos-l { --x: -1; }  .pos-tl { --x: -.5; --y: -.8660254; }
.pos-b  { --y: 1.7320508; }             /* Mostra: below Rubato, nested between Bottega and Gioco */
/* Landscape only (16 Nov): Mosaico and Lux swap places, and so do Tela and Gioco. Portrait keeps the order above. */
body.turned .hex[data-app="mosaico"] { --x: 1;   --y: 0; }            /* Lux's place */
body.turned .hex[data-app="lux"]     { --x: -.5; --y: -.8660254; }    /* Mosaico's place */
body.turned .hex[data-app="tela"]    { --x: .5;  --y: .8660254; }     /* Gioco's place */
body.turned .hex[data-app="gioco"]   { --x: -1;  --y: 0; }            /* Tela's place */

.hex-icon { width: calc(var(--r) * .5); height: calc(var(--r) * .5); border-radius: 24%; overflow: hidden; flex: none;
            display: grid; place-items: center; font-family: var(--font-logo); font-weight: 600; font-size: calc(var(--r) * .27);
            background: var(--line); color: var(--muted); }
.hex-icon img { width: 100%; height: 100%; }
.face { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: calc(var(--r) * .06); }
.face .lockup .app-name { font-size: calc(var(--r) * .2); line-height: 1.1; }   /* larger (16 Nov: was .17) */
/* Each app's name with its one-word title below, both centred */
.lockup { display: inline-flex; flex-direction: column; align-items: center; }   /* name and title centred (15 Nov) */
.lockup .kind { font-family: var(--font-logo); font-weight: 500; text-transform: uppercase; color: var(--red);   /* lighter, smaller and wider under the Black name (16 Nov) */
                font-size: max(9px, calc(var(--r) * .1)); letter-spacing: .3em; margin-right: -.3em;   /* the last letter's spacing */
                line-height: 1; margin-top: calc(var(--r) * .025); }

/* Turned (landscape): each hexagon's face and details turned back upright. Each is a box the size of its hexagon
   with width and height swapped, centred, turned 90° the other way. */
body.turned .face, body.turned .over-face { position: absolute; left: 50%; top: 50%; width: var(--h); height: var(--w);
                                            transform: translate(-50%, -50%) rotate(90deg); }
body.turned .over-face { padding: 0 20%; }
body.turned .hex.crest .crest-lockup { transform: rotate(90deg) translateY(var(--rule-lift)); width: 84%; }   /* 16 Nov: 80%, then 92%, then a little smaller */

/* Apps that aren't out yet: their name and title muted, so only Tela reads as ready */
.hex:not(.live) .face .app-name { color: color-mix(in srgb, var(--muted) 80%, var(--paper-raised)); font-size: calc(var(--r) * .17); }   /* 16 Nov: a little more muted (3.6:1 in the light, 4.6:1 at night); smaller than Tela's (.2), so the live app leads */
.hex.live .face .app-name { font-size: calc(var(--r) * .23); }   /* 16 Nov: Tela's name a little bigger (was .2) */
.hex.live .face .hex-icon { width: calc(var(--r) * .75); height: calc(var(--r) * .75); }   /* 16 Nov: Tela's icon 50% larger (was .5) */
/* Tela's "Try it free" (16 Nov), where the others say "Coming soon": in red, without the rule above it, to leave room
   for the larger icon */
.face .soon.try { color: var(--red); margin-top: 0; }
.face .soon.try::before { display: none; }
.hex.live .face { gap: calc(var(--r) * .04); }   /* a little tighter, for the larger icon */
@media (max-width: 600px) {   /* phones: the text's floors make it larger beside the hexagon, so the icon grows less */
  .hex.live .face .hex-icon { width: calc(var(--r) * .55); height: calc(var(--r) * .55); }
  .face .soon.try { font-size: max(8px, calc(var(--r) * .075)); letter-spacing: .1em; padding-left: .1em; }
}
.hex:not(.live) .face .hex-icon { background: color-mix(in srgb, var(--line) 50%, var(--paper-raised));
                                  color: color-mix(in srgb, var(--muted) 45%, var(--paper-raised));
                                  width: calc(var(--r) * .35); height: calc(var(--r) * .35); font-size: calc(var(--r) * .19); }   /* 30% smaller */
.face .soon { font-size: max(9.5px, calc(var(--r) * .075)); font-weight: 600; letter-spacing: .14em; padding-left: .14em; line-height: 1.45;
              text-transform: uppercase; color: var(--muted); margin-top: calc(var(--r) * .02); }   /* 16 Nov: the muted ink itself (5:1 on the card; was half of it, about 2:1) */
/* 16 Nov: a quieter red that can still be read (about 5:1 in the light and at night; was red at 45%, about 2:1) */
.hex:not(.live) .face .kind { color: color-mix(in srgb, var(--red) 70%, var(--muted)); }
/* Small rules on each card's face (15 Nov): one between the icon and the name; a fainter, shorter one between the name
   and "Coming soon" */
.face .hex-icon + .lockup::before, .face .soon::before { content: ""; display: block; margin: 0 auto;
      height: max(1px, calc(var(--r) * .008)); }
.face .hex-icon + .lockup::before { width: calc(var(--r) * .34); margin-bottom: calc(var(--r) * .06);
      background: var(--line); }
.face .soon::before { width: calc(var(--r) * .22); margin-bottom: calc(var(--r) * .045);
      background: color-mix(in srgb, var(--line) 60%, var(--paper-raised)); }

/* The crest: twice the size, holding the logo, nested in the notch between Mosaico and Ripresa. Its lower edges lie
   flush against their upper edges, --gap apart, which puts its top at the top of the honeycomb. */
.hex.crest { width: calc(2 * var(--w)); height: calc(2 * var(--h)); left: calc(50% - var(--w)); top: 0; font-size: inherit; }
.hex.crest .crest-lockup { width: 76%; position: relative; display: block; transform: translateY(var(--rule-lift)); }   /* 16 Nov: 72%, then 84%, then a little smaller */   /* the logo alone, so it sits at the hexagon's exact centre */
.hex.crest picture { width: 100%; }
/* The motto under the logo (15 Nov): "art for art's sake", in Italian */
.hex.crest .motto { font-family: var(--font-logo); font-weight: 500; color: var(--muted);
                    font-size: calc(var(--r) * .118); letter-spacing: .24em; text-indent: .24em; line-height: 1.55; text-align: center; text-transform: uppercase;   /* 16 Nov: two lines, centred, in capitals */
                    position: absolute; top: 100%; left: 50%; transform: translateX(-50%); white-space: nowrap;
                    margin-top: calc(var(--r) * .3); }   /* hung below the logo, out of its centring; .3: its distance */
.hex.crest img { width: 100%; height: auto; }

/* The sheet (15 Nov): Support, Contact, Privacy and Terms over the screen (a modal dialog, site.js). Close sits
   at its top right, above the text, which scrolls below it. */
dialog.sheet { width: min(46rem, calc(100vw - 2rem)); max-height: min(86svh, 60rem); padding: 0; border: 1px solid var(--line);
               border-radius: 18px; background: var(--paper-raised); color: var(--ink); overflow: hidden;
               box-shadow: 0 30px 80px -30px rgb(34 30 27 / .45); }
dialog.sheet[open] { display: flex; flex-direction: column; animation: sheet-in .28s cubic-bezier(.2,.7,.2,1); }
dialog.sheet::backdrop { background: rgb(34 30 27 / .42); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
@keyframes sheet-in { from { opacity: 0; transform: translateY(14px) scale(.98); } }
.sheet-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: .5rem clamp(1.25rem, 5vw, 3.25rem) 2.5rem;
              max-width: none; outline: none; }
.sheet-body > :first-child { margin-top: 0; }
.sheet-body h1 { font-size: clamp(1.8rem, 3vw + .8rem, 2.6rem); }
.sheet-close { flex: none; align-self: flex-end; margin: .75rem .75rem 0; display: inline-flex;   /* above the text, which scrolls below it */ align-items: center; gap: .4em;
               font: 500 .9rem var(--font-text); color: var(--ink); background: var(--paper-raised); border: 1px solid var(--line);
               border-radius: 999px; padding: .45em .95em; cursor: pointer; }
.sheet-close span { font-size: 1.15em; line-height: 1; }
.sheet-close:hover { border-color: var(--ink); }
.sheet-close:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { dialog.sheet[open] { animation: none; } }

/* At rest: a hexagon lifts towards you under the mouse or keyboard focus */
.hex[data-tap] { cursor: pointer; }
@media (hover: hover) and (pointer: fine) { .hive:not(.zoomed) :is(.hex.live, .hex.crest)[data-tap]:hover { transform: translateZ(60px); } }   /* 16 Nov: Tela's only; the coming-soon cards stay put under the mouse */
.hive:not(.zoomed) .hex[data-tap]:focus-visible { transform: translateZ(60px); }
.hex[data-tap]:focus-visible { background: var(--ink); }   /* keyboard focus only */

/* Zoomed in: the chosen hexagon rises a little (parallax against the rest), the others dim, the crest takes you back */
.hive.zoomed .hex.focused { transform: translateZ(40px); cursor: default; }
.hive.zoomed .hex:not(.focused) { opacity: .2; }   /* 16 Nov: fainter (was .45), so the opened card is what's read */
.hive.zoomed .hex:not(.focused)[data-tap] { cursor: pointer; }
.hive.zoomed .hex.crest:not(.focused) { cursor: pointer; }

/* The details, shown once the camera has arrived. Sizes are divided by the zoom, so on screen they're exactly these. */
.hex-over { position: absolute; inset: 1.5px; z-index: 1; clip-path: var(--hexagon); opacity: 0; pointer-events: none;
            visibility: hidden; transition: opacity .35s ease, visibility 0s linear .35s;   /* hidden: out of the tab order too */
            display: flex; flex-direction: column; background: transparent; }
.hive.arrived .hex.focused .hex-over { opacity: 1; pointer-events: auto; visibility: visible; transition-delay: 0s; }
/* The details are see-through, so the card's frame stays in view around them: the card's own face fades out instead */
.hex .face, .hex.crest .crest-lockup { transition: opacity .35s ease; }
.hive.arrived .hex.focused .face, .hive.arrived .hex.focused .crest-lockup { opacity: 0; }
/* The details. Sizes follow the hexagon (var(--r)), so they scale with the card on screen; each has a floor (divided
   by the zoom, so the floor is in screen pixels) for small screens. */
.over-face { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center;
             gap: calc(var(--r) * .028); padding: 0 17%; }
.hex-over .lockup .app-name { font-size: calc(max(calc(34px / var(--zoom)), calc(var(--r) * .2)) * var(--t, 1)); line-height: 1.05; }   /* 16 Nov: was 22px, .125 */
.hex-over .lockup .kind { font-size: calc(max(calc(10px / var(--zoom)), calc(var(--r) * .05)) * var(--t, 1)); margin-top: calc(var(--r) * .012); }
.hex-over .desc { font-size: calc(max(calc(11px / var(--zoom)), calc(var(--r) * .038)) * var(--t, 1)); color: var(--muted); }
.hex-over .tagline { font-family: var(--font-text); font-weight: 600; line-height: 1.2; text-wrap: balance;
                     font-size: calc(max(calc(14px / var(--zoom)), calc(var(--r) * .058)) * var(--t, 1)); margin: calc(var(--r) * .015) 0 0; }
.hex-over ul.points { list-style: none; margin: calc(var(--r) * .01) 0; padding: 0; display: flex; flex-direction: column;
                      gap: calc(var(--r) * .014); font-size: calc(max(calc(11px / var(--zoom)), calc(var(--r) * .039)) * var(--t, 1)); line-height: 1.35; }
.hex-over ul.points li { text-wrap: balance; }
.hex-over ul.points li::before { content: "·"; color: var(--red); font-weight: 700; margin-right: .4em; }
.hex-over .where { font-size: calc(max(calc(10px / var(--zoom)), calc(var(--r) * .032)) * var(--t, 1)); color: var(--muted); margin: 0; }
.hex-over .where.avail { margin-top: calc(var(--r) * .02); }   /* "Available on the", above the buttons (15 Nov) */
.hex-over.info .status { font-size: calc(max(calc(10px / var(--zoom)), calc(var(--r) * .032)) * var(--t, 1)); font-weight: 600; letter-spacing: .12em; padding-left: .12em;
                         line-height: 1.6; text-transform: uppercase; color: var(--red); }

/* The way to get an app, in its card: the web version, and the store for the visitor's system (site.js) */
.get-row { display: flex; gap: calc(var(--r) * .03); margin-top: calc(var(--r) * .025); }
.get { font-family: var(--font-text); font-weight: 600; font-size: calc(max(calc(13px / var(--zoom)), calc(var(--r) * .046)) * var(--t, 1));
       padding: .55em 1.35em; border-radius: 999px; background: var(--red); color: var(--red-ink); text-decoration: none; white-space: nowrap;
       transition: filter .15s, transform .2s cubic-bezier(.2,.7,.2,1); }
.get.native { background: var(--ink); color: var(--paper); }
.get:not([aria-disabled]):hover { filter: brightness(1.1); transform: scale(1.08); }   /* a live link grows a little */
.get:focus-visible { outline: max(2px, calc(var(--r) * .008)) solid var(--red); outline-offset: .2em; }
.get[aria-disabled="true"] { background: color-mix(in srgb, var(--line) 55%, var(--paper-raised));   /* not out yet: very muted, no hover */
                             color: color-mix(in srgb, var(--muted) 45%, var(--paper-raised)); cursor: default; filter: none; transform: none; }

/* Small screens: the card is small too, so the lists step aside */
@media (max-width: 600px), (max-height: 500px) {
  .hex-over .desc { display: none; }
  .hex-over { --t: 1.2; }                                  /* the card's text 20% larger on phones (15 Nov) */
  /* 16 Nov: the three points are kept on a phone (they were hidden, which left Tela's card with its name and a button
     only), a little smaller than the rest and in a narrower column, so they stay inside the hexagon */
  .hex-over ul.points { --t: 1; }
  .mostra-hex .hex-over ul.points { display: none; }       /* Mostra's card holds the most; its points still step aside */
  .over-face { padding: 0 13%; }
}

@media (prefers-reduced-motion: reduce) { .hex, .hex-over { transition: none; } }

/* The home page is one screen: no scrolling, no footer (its links are in the "i" menu, bottom right, 16 Nov) */
html:has(body.home) { overflow: hidden; }
body.home { overflow: hidden; height: 100svh; overscroll-behavior: none; }
.home .site-footer { display: none; }

/* The information menu: a small dark hexagon with an "i", bottom right. Hover (with a mouse), keyboard focus or a tap
   (class "open", site.js) opens the links above it. */
.info-menu { position: fixed; right: max(1.1rem, env(safe-area-inset-right)); bottom: max(1.1rem, env(safe-area-inset-bottom)); z-index: 36; }   /* above the night's darkened corners (34) */
/* The button is a small hexagon like the cards: the same faint edge and the same fill, with the "i" in ink */
.info-btn { --info-hex: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
            position: relative; isolation: isolate; width: 50px; height: 57.7px; border: 0; padding: 0; cursor: pointer;
            display: grid; place-items: center; clip-path: var(--info-hex);
            background: color-mix(in srgb, var(--line) 55%, var(--paper-raised));          /* the edge, as on the cards */
            color: var(--ink); font: 600 1.45rem/1 var(--font-text); transition: color .2s; }
.info-btn::before { content: ""; position: absolute; inset: 1.5px; z-index: -1; clip-path: var(--info-hex); background: var(--paper-raised); }
.info-btn:hover, .info-menu.open .info-btn { color: var(--red); }
body.turned .info-btn { --info-hex: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); width: 57.7px; height: 50px; }   /* turned with the honeycomb */
.info-btn:focus-visible { outline: none; background: var(--ink); color: var(--red); }
.info-links { position: absolute; right: 0; bottom: calc(100% + 12px); min-width: 190px; display: flex; flex-direction: column;
              padding: .45rem; background: var(--paper-raised); border: 1px solid var(--line); border-radius: 14px;
              box-shadow: 0 18px 40px -18px rgb(0 0 0 / .35); transform-origin: 100% 100%;
              opacity: 0; visibility: hidden; transform: translateY(6px) scale(.96);
              transition: opacity .18s ease, transform .18s ease, visibility 0s linear .18s; }
.info-links::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 14px; }   /* bridges the gap for the mouse */
.info-links a { padding: .7rem 1rem; border-radius: 9px; color: var(--ink); text-decoration: none; font-weight: 500; }
.info-links a:hover, .info-links a:focus-visible { background: var(--line); outline: none; }
.info-menu.open .info-links, .info-menu:has(:focus-visible) .info-links { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
@media (hover: hover) and (pointer: fine) { .info-menu:hover .info-links { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; } }
@media (prefers-reduced-motion: reduce) { .info-links { transition: none; } }

/* Shown while zoomed in: the way back to the whole honeycomb (on a phone the neighbours fill the screen) */
.cam-back { position: fixed; top: max(1rem, env(safe-area-inset-top)); left: 1rem; z-index: 20; font: 500 .95rem var(--font-text);
            color: var(--ink); background: var(--paper-raised); border: 1px solid var(--line); border-radius: 999px;
            padding: .55rem 1rem; cursor: pointer; box-shadow: 0 6px 20px -10px rgb(0 0 0 / .35); }
.cam-back:hover { border-color: var(--ink); }
.cam-back:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }

.centered { text-align: center; }
.centered .lead { margin-inline: auto; }

/* Home: the name */
.story .grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(2rem, 5vw, 4rem); }
.story h2 { font-size: var(--h2); }
@media (max-width: 860px) { .story .grid { grid-template-columns: 1fr; } }

/* Home: Mostra */
/* Always a dark band, in light and dark mode */
.mostra { --band: #1C1917; --band-ink: #F0E9DC; background: var(--band); color: var(--band-ink); border-top: 0 !important; }
@media (prefers-color-scheme: dark) { .mostra { --band: #26221F; } }
.mostra .eyebrow { color: #DB5F4A; }
.mostra .muted { color: #A39A8E; }
.mostra .button { background: #DB5F4A; color: #1C1917; }
.mostra .grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (max-width: 860px) { .mostra .grid { grid-template-columns: 1fr; } }
.mostra-name { font-family: var(--font-logo); font-weight: 600; letter-spacing: .08em; }
.signup { background: rgb(255 255 255 / .05); border: 1px solid rgb(255 255 255 / .14); border-radius: var(--radius); padding: 1.5rem; }
.signup label { display: block; font-weight: 500; margin-bottom: .4rem; }
.signup input[type=email] { width: 100%; font: inherit; padding: .8rem 1rem; border-radius: 10px; border: 1px solid transparent;
                            background: #F6F1E8; color: #221E1B; }
.signup fieldset { border: 0; padding: 0; margin: 1.1rem 0; display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; }
.signup legend { font-weight: 500; margin-bottom: .5rem; padding: 0; }
.signup .choice { display: flex; gap: .5rem; align-items: center; font-weight: 400; margin: 0; }
.signup input[type=radio] { accent-color: var(--red); width: 1.1rem; height: 1.1rem; }
.signup button { border: 0; cursor: pointer; font-size: 1rem; }
.signup .note { margin: .9rem 0 0; font-size: .85rem; }
.signup .message { margin-top: 1rem; font-weight: 500; min-height: 1.5em; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* App page */
.app-hero .top { display: flex; gap: 1.5rem; align-items: center; margin-bottom: 1.75rem; }
.app-hero .top img { width: 112px; height: 112px; border-radius: 26px; box-shadow: 0 16px 32px -18px rgb(0 0 0 / .45); }
.app-hero .app-name { font-size: clamp(2.6rem, 6vw, 4rem); display: block; line-height: 1; }
.app-hero .desc { font-size: 1.15rem; color: var(--muted); }
.app-hero h1 { font-size: clamp(2rem, 3.5vw + .5rem, 3.2rem); max-width: 18em; }
.media { margin-top: 2.5rem; aspect-ratio: 16 / 9; max-height: 280px; width: 100%; border-radius: 22px; background: var(--paper-raised); border: 1px dashed var(--line);
         display: grid; place-items: center; text-align: center; color: var(--muted); padding: 1rem; }
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 2rem 2.5rem; margin-top: 2rem; }
.features h3 { font-size: 1.2rem; margin-bottom: .4rem; }
.price-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; margin: 2rem 0 1.25rem; }
@media (max-width: 760px) { .price-grid { grid-template-columns: 1fr; } }
.plan { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.75rem; background: var(--paper-raised); }
.plan.unlock { border-color: color-mix(in srgb, var(--red) 40%, var(--line)); }
.plan .price { font-family: var(--font-head); font-size: 2.4rem; font-weight: 600; line-height: 1; margin: .4rem 0 .3rem; }
.plan ul { padding-left: 1.2rem; margin: 1rem 0 0; }
.plan li { margin-bottom: .35rem; }
.facts { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.5rem; padding: 0; list-style: none; }
.facts li { border: 1px solid var(--line); border-radius: 999px; padding: .35rem .9rem; font-size: .92rem; }

/* Text pages (privacy, terms, support) */
.prose { max-width: 44rem; }
.prose h1 { font-size: var(--h1); }
.prose h2 { font-size: 1.5rem; margin-top: 2.2em; }
.prose h3 { font-size: 1.15rem; margin-top: 1.6em; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: .4rem; }
.draft { background: color-mix(in srgb, var(--red) 10%, var(--paper)); border: 1px solid color-mix(in srgb, var(--red) 35%, var(--line));
         border-radius: 10px; padding: .8rem 1rem; font-size: .92rem; margin-bottom: 2rem; }
details { border-bottom: 1px solid var(--line); padding: 1rem 0; }
details summary { cursor: pointer; font-weight: 600; font-family: var(--font-head); font-size: 1.1rem; }
details[open] summary { margin-bottom: .6rem; }

/* Footer */
.site-footer { background: #1C1917; color: #F0E9DC; padding-block: 3rem 2rem; border-top: 1px solid #3A342F; }
.site-footer a { color: #F0E9DC; text-decoration: none; }
.site-footer a:hover { color: #DB5F4A; }
.foot-grid { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2rem; align-items: flex-start; }
.foot-logo { height: 2.2rem; width: auto; margin-bottom: 1rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: .75rem 2rem; }
.site-footer .small { color: #A39A8E; }
.site-footer .legal { margin-top: 2.5rem; padding-top: 1.25rem; border-top: 1px solid #3A342F; }
.signup .note a { color: inherit; }
.centered .prose { margin-inline: auto; }
.centered-actions { justify-content: center; }


/* (17 Nov: the Mostra page, /mostra/, was taken out, with "Tell me more" in its card) */
.mostra-points { padding-left: 1.2rem; margin: 1.6rem 0; max-width: 36em; }
.mostra-points li { margin-bottom: .6rem; }
.info-links .soon { font-size: .7rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-left: .4rem; }

/* Mostra's hexagon on the home page: its name and "coming soon"; the camera flies in like the apps */
/* (Mostra's face is now laid out like the apps': its M, its name and EXHIBITION, 15 Nov) */
.hex-over .footnote { font-size: calc(max(calc(8.5px / var(--zoom)), calc(var(--r) * .026)) * var(--t, 1)); color: var(--muted);
                      margin: calc(var(--r) * .01) 0 0; max-width: 85%; text-wrap: balance; line-height: 1.35; }

/* ---------------------------------------------------------------- the About story (15 Nov)
   A scroll-driven story: a small honeycomb (an SVG of the home page's) stays beside the text, and each chapter lights
   its part: the crest for the studiolo and the company, each app as its line passes, Mostra, then the whole honeycomb
   for the studio in Langley. On /about/ it's the page; from the home page's crest it opens full screen (dialog.story-sheet).
   site.js (initStory) sets data-active and data-app on .story as the chapters cross the middle of the screen. */
.story { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(1.5rem, 5vw, 5rem);
         max-width: 78rem; margin: 0 auto; padding: 0 clamp(1.25rem, 5vw, 4rem); }
.story-visual { position: sticky; top: 0; height: 100svh; display: flex; flex-direction: column; align-items: center;
                justify-content: center; gap: 1.2rem; }
.story-hive { width: min(100%, 26rem); height: auto; overflow: visible; }
.story-hive polygon { fill: var(--paper-raised); stroke: var(--line); stroke-width: 1.5; vector-effect: non-scaling-stroke;
                      transition: fill .6s ease, stroke .6s ease, opacity .6s ease; }
.story-hive .cell { transition: opacity .7s ease, transform .9s cubic-bezier(.2,.7,.2,1); transform-box: fill-box; transform-origin: center; }
.story-hive text { font-family: var(--font-logo); font-weight: 600; font-size: 34px; text-anchor: middle; fill: var(--muted);
                   transition: fill .6s ease; }
.story-hive .mark { font-size: 27px; letter-spacing: .08em; fill: var(--ink); }
.story-hive .mark.sub { font-size: 14px; letter-spacing: .32em; fill: var(--red); }
.story-hive .inlay { fill: none; stroke: var(--line); opacity: 0; }
.story-caption { font-family: var(--font-logo); font-weight: 600; text-transform: uppercase; letter-spacing: .2em;
                 font-size: .78rem; color: var(--muted); min-height: 1.2em; margin: 0; text-align: center; transition: opacity .4s; }

/* chapter by chapter */
.story[data-active="room"] .cell:not(.crest), .story[data-active="company"] .cell:not(.crest) { opacity: .12; }
.story[data-active="room"] .cell.crest { transform: scale(1.06); }
.story[data-active="room"] .crest polygon:first-child { stroke: #D48C24; stroke-width: 2.5; }
.story[data-active="room"] .crest .inlay { opacity: 1; stroke: color-mix(in srgb, #D48C24 60%, var(--line)); }
.story[data-active="company"] .crest polygon:first-child { stroke: #D48C24; stroke-width: 2.5; }
.story[data-active="apps"] .cell.crest, .story[data-active="apps"] .cell[data-app="mostra"] { opacity: .2; }
.story[data-active="apps"] .cell[data-app]:not([data-app="mostra"]) polygon { stroke: color-mix(in oklch, var(--accent-strong) 45%, var(--paper-raised)); }
.story[data-active="mostra"] .cell:not([data-app="mostra"]) { opacity: .16; }
.story[data-active="langley"] .crest polygon:first-child { stroke: #D48C24; stroke-width: 2.5; }
.story[data-active="langley"] .cell[data-app] polygon { stroke: color-mix(in oklch, var(--accent-strong) 55%, var(--paper-raised)); }
/* the app being read, and Mostra in its chapter: filled with its fall colour */
.story[data-active="apps"][data-app="tela"] .cell[data-app="tela"], .story[data-active="apps"][data-app="mosaico"] .cell[data-app="mosaico"],
.story[data-active="apps"][data-app="ripresa"] .cell[data-app="ripresa"], .story[data-active="apps"][data-app="bottega"] .cell[data-app="bottega"],
.story[data-active="apps"][data-app="rubato"] .cell[data-app="rubato"], .story[data-active="apps"][data-app="lux"] .cell[data-app="lux"],
.story[data-active="apps"][data-app="gioco"] .cell[data-app="gioco"], .story[data-active="mostra"] .cell[data-app="mostra"] { transform: scale(1.12); }
.story[data-active="apps"][data-app="tela"] .cell[data-app="tela"] polygon, .story[data-active="apps"][data-app="mosaico"] .cell[data-app="mosaico"] polygon,
.story[data-active="apps"][data-app="ripresa"] .cell[data-app="ripresa"] polygon, .story[data-active="apps"][data-app="bottega"] .cell[data-app="bottega"] polygon,
.story[data-active="apps"][data-app="rubato"] .cell[data-app="rubato"] polygon, .story[data-active="apps"][data-app="lux"] .cell[data-app="lux"] polygon,
.story[data-active="apps"][data-app="gioco"] .cell[data-app="gioco"] polygon, .story[data-active="mostra"] .cell[data-app="mostra"] polygon
  { fill: var(--accent-strong); stroke: var(--accent-strong); }
.story[data-active="apps"][data-app="tela"] .cell[data-app="tela"] text, .story[data-active="apps"][data-app="mosaico"] .cell[data-app="mosaico"] text,
.story[data-active="apps"][data-app="ripresa"] .cell[data-app="ripresa"] text, .story[data-active="apps"][data-app="bottega"] .cell[data-app="bottega"] text,
.story[data-active="apps"][data-app="rubato"] .cell[data-app="rubato"] text, .story[data-active="apps"][data-app="lux"] .cell[data-app="lux"] text,
.story[data-active="apps"][data-app="gioco"] .cell[data-app="gioco"] text, .story[data-active="mostra"] .cell[data-app="mostra"] text
  { fill: var(--paper-raised); }

/* the text: one chapter a screen, each rising into place as it arrives */
.story-text { padding: 0 0 20svh; }
.chapter { min-height: 100svh; display: flex; flex-direction: column; justify-content: center; padding: 12svh 0; max-width: 36rem; }
.chapter h1, .chapter h2 { font-size: clamp(2.1rem, 3.4vw + 1rem, 3.6rem); line-height: 1.04; letter-spacing: -.02em; margin: .25em 0 .5em; text-wrap: balance; }
.chapter .lead { font-size: clamp(1.1rem, .6vw + 1rem, 1.35rem); line-height: 1.55; }
.chapter p { max-width: 34em; }
.chapter .motto-line { font-style: italic; color: var(--muted); margin-top: 1.2em; }
.chapter .scroll-hint { margin-top: 3rem; font-size: .72rem; font-weight: 600; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); }
/* (the line under "Scroll" was taken out, 15 Nov) and the next chapter follows closer: */
.chapter + .chapter { border-top: 0; }   /* no rule between the story's chapters (the site's sections have one) */
.chapter[data-chapter="room"] { min-height: 86svh; padding-bottom: 0; }
.chapter[data-chapter="company"] { min-height: 70svh; justify-content: flex-start; padding-top: 6svh;
                                   border-top: 1px solid var(--line); }   /* the one divider, after the motto (15 Nov) */
.chapter.apps { min-height: auto; }
.story-apps { list-style: none; padding: 0; margin: 1.5rem 0 0; }
.story-apps li { min-height: 34svh; display: flex; flex-direction: column; justify-content: center; border-top: 1px solid var(--line);
                 padding: 1.5rem 0; opacity: .32; transition: opacity .5s ease; }
.story-apps li:last-child { border-bottom: 1px solid var(--line); }
.story-apps li.on { opacity: 1; }
.story-apps .app-name { font-size: clamp(1.7rem, 2vw + 1rem, 2.4rem); line-height: 1; }
.story-apps .what { font-family: var(--font-logo); font-weight: 600; text-transform: uppercase; letter-spacing: .16em; font-size: .78rem;
                    color: var(--accent-strong); margin: .55rem 0 .7rem; }
.story-apps .line { font-size: 1.08rem; color: var(--ink); max-width: 30em; }
.story .reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s ease, transform .9s cubic-bezier(.2,.7,.2,1); }
.story .reveal.in { opacity: 1; transform: none; }

/* phones and narrow windows: the honeycomb small and pinned at the top, the text running under it */
@media (max-width: 860px) {
  .story { grid-template-columns: 1fr; gap: 0; }
  .story-visual { position: sticky; top: 0; z-index: 1; height: 38svh; padding: .9rem 0 .5rem; gap: .35rem;
                  background: var(--paper); justify-content: flex-start; }
  .story-visual::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 2.5rem;   /* the text fades in under it */
                         background: linear-gradient(var(--paper), color-mix(in srgb, var(--paper) 0%, transparent)); pointer-events: none; }
  .story-hive { flex: 1; min-height: 0; height: auto; width: 100%; }
  .story-caption { font-size: .66rem; }
  .chapter { min-height: 66svh; padding: 6svh 0; }
  .story-apps li { min-height: 26svh; }
}
@media (prefers-reduced-motion: reduce) {
  .story .reveal { opacity: 1; transform: none; transition: none; }
  .story-hive .cell, .story-hive polygon, .story-apps li { transition: none; }
}
/* on its own page the story needs no page header to read it: the header stays, the footer follows */
.about-page .story-visual { top: 0; }

/* Full screen from the crest: the whole window, the story scrolling inside it, a round × at the top right */
dialog.story-sheet { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
                     background: var(--paper); color: var(--ink); overflow: hidden; }
dialog.story-sheet[open] { display: block; animation: story-in .45s cubic-bezier(.2,.7,.2,1); }
dialog.story-sheet::backdrop { background: rgb(34 30 27 / .4); }
@keyframes story-in { from { opacity: 0; transform: scale(.985); } }
.story-scroll { height: 100%; overflow-y: auto; overscroll-behavior: contain; outline: none; }
.story-progress { position: absolute; top: 0; left: 0; right: 0; height: 3px; z-index: 3; background: #E9A23B; transform-origin: 0 50%;
                  transform: scaleX(0); }
.story-close { position: absolute; top: max(.9rem, env(safe-area-inset-top)); right: max(.9rem, env(safe-area-inset-right)); z-index: 3;
               width: 2.9rem; height: 2.9rem; border-radius: 50%; border: 1px solid var(--line); background: var(--paper-raised);
               color: var(--ink); font: 400 1.6rem/1 var(--font-text); display: grid; place-items: center; cursor: pointer;
               box-shadow: 0 6px 18px -10px rgb(34 30 27 / .5); transition: border-color .15s, transform .2s; }
.story-close:hover { border-color: var(--ink); transform: rotate(90deg); }
.story-close:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { dialog.story-sheet[open] { animation: none; } .story-close:hover { transform: none; } }


/* ---------------------------------------------------------------------------------------------------------------
   The logo in the crest (16 Nov): inline SVG (lib/ui/brand/logo/studiolo-mobile-inline.svg, from make_logo.py) so it
   can be drawn in on load: each letter's outline is traced, then filled with ink, STUDIOLO then the rule then
   INTERACTIVE; then a glint of light crosses the gilded S. site.js sets each path's --d (its delay) and adds .drawing.
   Without JavaScript, or with reduced motion, the logo simply shows. */
.logo-draw { display: block; width: 100%; height: auto; overflow: visible;
             filter: drop-shadow(0 1.5px 0 rgb(255 255 255 / .8)) drop-shadow(0 -1px 0 rgb(0 0 0 / .1)); }   /* letterpress */
.logo-draw .ink path, .logo-draw .rule { fill: var(--ink); stroke: var(--ink); }
.logo-draw .red path { fill: var(--red); stroke: var(--red); }
.logo-draw .ink .initial { fill: var(--red); stroke: var(--red); }   /* the S in red, like INTERACTIVE (16 Nov: was gold leaf) */
.logo-draw .ink .sheen { fill: url(#sheen); stroke: none; pointer-events: none; }
.logo-draw path { stroke-width: 0; }
@media (prefers-color-scheme: dark) {
  .logo-draw { filter: drop-shadow(0 -1px 0 rgb(0 0 0 / .6)); }
}
@media (prefers-reduced-motion: no-preference) {
  .logo-draw.drawing path:not(.sheen) { stroke-width: 1.4px; vector-effect: non-scaling-stroke; stroke-dasharray: 1 1;
      animation: logo-trace 1.1s cubic-bezier(.45, .05, .35, 1) var(--d, 0ms) both,
                 logo-ink .55s ease-out calc(var(--d, 0ms) + 750ms) both; }
  .logo-draw.drawing .rule { transform-box: fill-box; transform-origin: 0 50%;
      animation: logo-rule .8s cubic-bezier(.2, .7, .2, 1) var(--d, 0ms) both; }
}
@keyframes logo-trace { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes logo-ink   { from { fill-opacity: 0; stroke-opacity: 1; } to { fill-opacity: 1; stroke-opacity: 0; } }
@keyframes logo-rule  { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* An app's name, inscribed as the camera arrives at its card (16 Nov): revealed left to right as its letters close
   up to their spacing; the title follows. */
@media (prefers-reduced-motion: no-preference) {
  .hive.arrived .hex.focused .hex-over .lockup .app-name { animation: inscribe-name .9s cubic-bezier(.2, .7, .2, 1) both; }
  .hive.arrived .hex.focused .hex-over .lockup .kind { animation: inscribe .8s cubic-bezier(.2, .7, .2, 1) .3s both; }
}
@keyframes inscribe-name {
  from { clip-path: inset(-30% 100% -30% -10%); letter-spacing: .3em; opacity: .3; }
  to   { clip-path: inset(-30% -10% -30% -10%); letter-spacing: var(--app-name-tracking); opacity: 1; }
}
@keyframes inscribe {
  from { clip-path: inset(-30% 100% -30% -10%); opacity: 0; }
  to   { clip-path: inset(-30% -10% -30% -10%); opacity: 1; }
}

/* ---------------------------------------------------------------------------------------------------------------
   App icons (16 Nov): the seven coming-soon apps get real marks (index.html), one shape in the app's accent with one
   gold detail, on the same cream tile as Tela's icon. Coming soon: a little smaller and quieter than Tela's. */
.hex-icon { background: #EDE7DC; color: var(--accent, var(--muted)); position: relative; }
:is(.hex-icon, .story-hive) .ico { width: 100%; height: 100%; display: block; fill: currentColor; overflow: visible; }
:is(.hex-icon, .story-hive) .ico .g { fill: #D29A36; }                  /* gold, like Tela's stripe and the crest */
:is(.hex-icon, .story-hive) .ico .c { fill: #EDE7DC; }                  /* cut-outs in the tile's cream */
:is(.hex-icon, .story-hive) .ico * { transform-box: fill-box; }
:is(.hex-icon, .story-hive) .ico-tela .wood { fill: #C5A289; }   /* Tela's palette: the light wood chosen on 16 Nov, now a fixed colour, so it stays wood whatever Tela's accent is */
:is(.hex-icon, .story-hive) .ico-tela .dabs .g { fill: #EBBA3B; }   /* its yellow paint a little brighter than the icons' gold (16 Nov) */
.hex:not(.live) .face .hex-icon { background: #EDE7DC; color: var(--accent);
                                  width: calc(var(--r) * .42); height: calc(var(--r) * .42); filter: saturate(.4); opacity: .6; }   /* muted more (16 Nov: was saturate .7, opacity .88) */
/* (at night the coming-soon icons are muted in "Night", below) */
.hex:not(.live) .face .hex-icon:has(.ico) { font-size: 0; }

/* Each icon's own small motion on hover (or keyboard focus), so every tile feels like its app */
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .hex[data-app] .face .hex-icon { transition: filter .3s, opacity .3s; }
  /* (16 Nov: a coming-soon icon keeps its muted colours while it moves; before, hovering brought them to full colour) */
  /* Mosaico: the tesserae turn over one by one */
  .hive:not(.zoomed) .hex[data-app="mosaico"]:is(:hover, :focus-visible) .tiles rect { animation: ico-tess .7s cubic-bezier(.3, .7, .3, 1) both; transform-origin: center; }
  /* (25 tesserae, 16 Nov: they turn over in a wave from the top-left corner) */
  .ico-mosaico .tiles rect:is(:nth-child(2), :nth-child(6)) { animation-delay: 0.035s !important; }
  .ico-mosaico .tiles rect:is(:nth-child(3), :nth-child(7), :nth-child(11)) { animation-delay: 0.070s !important; }
  .ico-mosaico .tiles rect:is(:nth-child(4), :nth-child(8), :nth-child(12), :nth-child(16)) { animation-delay: 0.105s !important; }
  .ico-mosaico .tiles rect:is(:nth-child(5), :nth-child(9), :nth-child(13), :nth-child(17), :nth-child(21)) { animation-delay: 0.140s !important; }
  .ico-mosaico .tiles rect:is(:nth-child(10), :nth-child(14), :nth-child(18), :nth-child(22)) { animation-delay: 0.175s !important; }
  .ico-mosaico .tiles rect:is(:nth-child(15), :nth-child(19), :nth-child(23)) { animation-delay: 0.210s !important; }
  .ico-mosaico .tiles rect:is(:nth-child(20), :nth-child(24)) { animation-delay: 0.245s !important; }
  .ico-mosaico .tiles rect:is(:nth-child(25)) { animation-delay: 0.280s !important; }
  /* Ripresa: the film runs */
  .hive:not(.zoomed) .hex[data-app="ripresa"]:is(:hover, :focus-visible) .sprockets { animation: ico-film .45s linear infinite; }
  .hive:not(.zoomed) .hex[data-app="ripresa"]:is(:hover, :focus-visible) .play { animation: ico-pulse .9s ease-in-out infinite alternate; transform-origin: center; }
  /* Rubato: the levels dance */
  .hive:not(.zoomed) .hex[data-app="rubato"]:is(:hover, :focus-visible) .bars rect { animation: ico-level .5s ease-in-out infinite alternate; transform-origin: center; }
  .ico-rubato .bars rect:nth-child(2) { animation-delay: -.2s !important; animation-duration: .42s !important; }
  .ico-rubato .bars rect:nth-child(3) { animation-delay: -.35s !important; animation-duration: .6s !important; }
  .ico-rubato .bars rect:nth-child(4) { animation-delay: -.1s !important; animation-duration: .46s !important; }
  .ico-rubato .bars rect:nth-child(5) { animation-delay: -.3s !important; animation-duration: .38s !important; }
  /* Lux (16 Nov): a moving head on its stand; its head tilts from side to side, and its beam changes colour */
  .hive:not(.zoomed) .hex[data-app="lux"]:is(:hover, :focus-visible) .head { animation: ico-tilt-head 1.8s ease-in-out infinite alternate; transform-box: view-box; transform-origin: 32px 33.6px; }
  .hive:not(.zoomed) .hex[data-app="lux"]:is(:hover, :focus-visible) .beam { animation: ico-beam 3.2s linear infinite; }
  /* Bottega: the cube lifts */
  .hive:not(.zoomed) .hex[data-app="bottega"]:is(:hover, :focus-visible) .cube { animation: ico-float 1.1s ease-in-out infinite alternate; }
  /* Gioco: the buttons are pressed in turn */
  .hive:not(.zoomed) .hex[data-app="gioco"]:is(:hover, :focus-visible) .btn { animation: ico-press .6s ease-in-out infinite; transform-origin: center; }
  .hive:not(.zoomed) .hex[data-app="gioco"]:is(:hover, :focus-visible) .btn-b { animation-delay: .3s; }
  .hive:not(.zoomed) .hex[data-app="gioco"]:is(:hover, :focus-visible) .pad { animation: ico-tilt 1.2s ease-in-out infinite; transform-origin: center; }
  /* Mostra: the picture swings on its nail */
  .hive:not(.zoomed) .hex[data-app="mostra"]:is(:hover, :focus-visible) .frame { animation: ico-swing 1.4s cubic-bezier(.3, 0, .3, 1) both; transform-box: view-box; transform-origin: 32px 10.5px; }
  /* Tela: the brush dabs the palette (16 Nov), and a stroke of light crosses the tile */
  .hive:not(.zoomed) .hex[data-app="tela"]:is(:hover, :focus-visible) .brush { animation: ico-dab .9s cubic-bezier(.3, .7, .3, 1) both; }
  .hex.live .face .hex-icon::after { content: ""; position: absolute; inset: 0; pointer-events: none;
      background: linear-gradient(105deg, transparent 35%, rgb(255 248 230 / .65) 50%, transparent 65%); transform: translateX(-120%); }
  .hive:not(.zoomed) .hex.live:is(:hover, :focus-visible) .face .hex-icon::after { transition: transform .8s cubic-bezier(.3, .7, .3, 1); transform: translateX(120%); }
}
@keyframes ico-tess  { 0% { transform: scale(1); } 40% { transform: scale(.55) rotate(45deg); } 100% { transform: scale(1); } }
@keyframes ico-film  { to { transform: translateX(-6.5px); } }
@keyframes ico-dab   { 0%, 100% { transform: translate(0, 0); } 30% { transform: translate(-2.2px, -2.2px); } 50% { transform: translate(0, 0); }
                       72% { transform: translate(-1.4px, -1.4px); } }
@keyframes ico-pulse { to { transform: scale(1.18); } }
@keyframes ico-level { from { transform: scaleY(1); } to { transform: scaleY(.45); } }
@keyframes ico-tilt-head { from { transform: rotate(-30deg); } to { transform: rotate(30deg); } }
@keyframes ico-beam  { 0%, 20% { fill: #E0447F; } 25%, 45% { fill: #3BB4E0; } 50%, 70% { fill: #5DC46F; } 75%, 95% { fill: #8B5CE6; } 100% { fill: #E0447F; } }
@keyframes ico-float { from { transform: translateY(1.5px); } to { transform: translateY(-3px); } }
@keyframes ico-press { 0%, 100% { transform: scale(1); } 25% { transform: scale(.72); } 50% { transform: scale(1); } }
@keyframes ico-tilt  { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-7deg); } 75% { transform: rotate(7deg); } }
@keyframes ico-swing { 0% { transform: rotate(0); } 20% { transform: rotate(7deg); } 45% { transform: rotate(-5deg); }
                       65% { transform: rotate(3deg); } 82% { transform: rotate(-1.5deg); } 100% { transform: rotate(0); } }

/* ---------------------------------------------------------------------------------------------------------------
   The honeycomb assembles on load (16 Nov): the crest first, then each app's tile settles into place around it, in
   reading order, while the logo draws itself in. site.js sets each tile's --d and adds .assembling for the first look
   only (not when the address opens a card, nor with reduced motion). */
@media (prefers-reduced-motion: no-preference) {
  .hive.assembling .hex { animation: hex-in .9s cubic-bezier(.2, .75, .25, 1) var(--d, 0ms) both; }
  .hive.assembling .hex.crest { animation-name: crest-in; animation-duration: .8s; }
}
@keyframes hex-in {
  from { opacity: 0; scale: .62; translate: calc(var(--x) * var(--step) * -.55) calc(var(--y) * var(--step) * -.55 - var(--step) * .25); }
}
@keyframes crest-in { from { opacity: 0; scale: .9; } }

/* ---------------------------------------------------------------------------------------------------------------
   Paper (16 Nov): a faint grain over every page, as if the site were printed on the same paper as the logo. */
body::after { content: ""; position: fixed; inset: 0; z-index: 40; pointer-events: none;
              background: url("/img/paper-grain.png") 0 0 / 240px 240px; mix-blend-mode: multiply; opacity: .32; }
@media (prefers-color-scheme: dark) { body::after { mix-blend-mode: soft-light; opacity: .5; } }
@media print { body::after { display: none; } }

/* ---------------------------------------------------------------------------------------------------------------
   The sheets unfold from a hexagon (16 Nov): About, Contact, Privacy and Terms open from the crest's centre as
   a growing hexagon, and fold back into one when closed (site.js adds .folding and closes it when that ends). */
@media (prefers-reduced-motion: no-preference) {
  dialog.story-sheet[open] { animation: hex-unfold .7s cubic-bezier(.65, 0, .25, 1); }
  dialog.sheet[open] { animation: hex-unfold-sheet .62s cubic-bezier(.6, 0, .3, 1); }
  dialog.sheet[open]::backdrop, dialog.story-sheet[open]::backdrop { animation: backdrop-in .5s ease both; }
  dialog.story-sheet.folding { animation: hex-fold .45s cubic-bezier(.6, 0, .4, 1) both; }
  dialog.sheet.folding { animation: hex-fold-sheet .4s cubic-bezier(.6, 0, .4, 1) both; }
  dialog.sheet.folding::backdrop, dialog.story-sheet.folding::backdrop { animation: backdrop-out .4s ease both; }
  dialog.sheet[open] .sheet-body, dialog.story-sheet[open] .story-scroll { animation: sheet-text-in .5s ease .3s both; }
}
/* (the fold has its own keyframes: reusing the unfold's name, reversed, would count as the same finished animation) */
@keyframes hex-unfold       { from { clip-path: polygon(50% calc(50% - 2vmax), calc(50% + 1.73vmax) calc(50% - 1.0vmax), calc(50% + 1.73vmax) calc(50% + 1.0vmax), 50% calc(50% + 2vmax), calc(50% - 1.73vmax) calc(50% + 1.0vmax), calc(50% - 1.73vmax) calc(50% - 1.0vmax)); } to { clip-path: polygon(50% calc(50% - 160vmax), calc(50% + 138.56vmax) calc(50% - 80.0vmax), calc(50% + 138.56vmax) calc(50% + 80.0vmax), 50% calc(50% + 160vmax), calc(50% - 138.56vmax) calc(50% + 80.0vmax), calc(50% - 138.56vmax) calc(50% - 80.0vmax)); } }
@keyframes hex-fold         { from { clip-path: polygon(50% calc(50% - 160vmax), calc(50% + 138.56vmax) calc(50% - 80.0vmax), calc(50% + 138.56vmax) calc(50% + 80.0vmax), 50% calc(50% + 160vmax), calc(50% - 138.56vmax) calc(50% + 80.0vmax), calc(50% - 138.56vmax) calc(50% - 80.0vmax)); } to { clip-path: polygon(50% calc(50% - 2vmax), calc(50% + 1.73vmax) calc(50% - 1.0vmax), calc(50% + 1.73vmax) calc(50% + 1.0vmax), 50% calc(50% + 2vmax), calc(50% - 1.73vmax) calc(50% + 1.0vmax), calc(50% - 1.73vmax) calc(50% - 1.0vmax)); } }
@keyframes hex-unfold-sheet { from { clip-path: polygon(50% calc(50% - 2vmax), calc(50% + 1.73vmax) calc(50% - 1.0vmax), calc(50% + 1.73vmax) calc(50% + 1.0vmax), 50% calc(50% + 2vmax), calc(50% - 1.73vmax) calc(50% + 1.0vmax), calc(50% - 1.73vmax) calc(50% - 1.0vmax)); } to { clip-path: polygon(50% calc(50% - 62vmax), calc(50% + 53.69vmax) calc(50% - 31.0vmax), calc(50% + 53.69vmax) calc(50% + 31.0vmax), 50% calc(50% + 62vmax), calc(50% - 53.69vmax) calc(50% + 31.0vmax), calc(50% - 53.69vmax) calc(50% - 31.0vmax)); } }
@keyframes hex-fold-sheet   { from { clip-path: polygon(50% calc(50% - 62vmax), calc(50% + 53.69vmax) calc(50% - 31.0vmax), calc(50% + 53.69vmax) calc(50% + 31.0vmax), 50% calc(50% + 62vmax), calc(50% - 53.69vmax) calc(50% + 31.0vmax), calc(50% - 53.69vmax) calc(50% - 31.0vmax)); } to { clip-path: polygon(50% calc(50% - 2vmax), calc(50% + 1.73vmax) calc(50% - 1.0vmax), calc(50% + 1.73vmax) calc(50% + 1.0vmax), 50% calc(50% + 2vmax), calc(50% - 1.73vmax) calc(50% + 1.0vmax), calc(50% - 1.73vmax) calc(50% - 1.0vmax)); } }
@keyframes backdrop-in  { from { opacity: 0; } }
@keyframes backdrop-out { to { opacity: 0; } }
@keyframes sheet-text-in { from { opacity: 0; translate: 0 10px; } }

/* ---------------------------------------------------------------------------------------------------------------
   The cursor (16 Nov), home page with a mouse or trackpad only: a small hexagon that follows the pointer, opens up
   over a tile (no words in it, 16 Nov), and shrinks to a red dot over links and buttons. Inside a sheet, and anywhere
   text is typed, the system cursor comes back. site.js (initCursor) makes it and adds .has-cursor. */
.cursor { position: fixed; left: 0; top: 0; z-index: 60; pointer-events: none; width: 0; height: 0; opacity: 0;
          transition: opacity .25s; }
.cursor.on { opacity: 1; }
/* It grows by size, not by scaling, so its line stays exactly as thin as the resting hexagon's (16 Nov) */
@property --cs { syntax: "<number>"; inherits: true; initial-value: 1; }
.cursor-hex { --cs: 1; position: absolute; left: calc(-14px * var(--cs)); top: calc(-16px * var(--cs));
              width: calc(28px * var(--cs)); height: calc(32px * var(--cs)); overflow: visible;
              transition: --cs .35s cubic-bezier(.2, .75, .25, 1); }
.cursor-hex polygon { fill: transparent; stroke: var(--ink); stroke-width: 1.4; vector-effect: non-scaling-stroke;
                      transition: fill .3s, stroke .3s; }
.cursor.is-open .cursor-hex { --cs: 1.4; }   /* 16 Nov: smaller again (was 1.92, before that 2.4), so it doesn't sit over a card's name */
.cursor.is-open .cursor-hex polygon { fill: transparent; stroke: color-mix(in srgb, var(--ink) 55%, transparent); }   /* an empty hexagon, its line lighter over a card so the words under it stay readable (16 Nov) */
.cursor.is-link .cursor-hex { --cs: .32; }
.cursor.is-link .cursor-hex polygon { fill: var(--red); stroke: var(--red); }
.cursor.is-down .cursor-hex { --cs: .8; }
.cursor.is-open.is-down .cursor-hex { --cs: 1.2; }
body.turned .cursor-hex { transform: rotate(30deg); }   /* landscape (16 Nov): flat on top, like the turned honeycomb's cards */
body.has-cursor, body.has-cursor a, body.has-cursor button, body.has-cursor [data-tap] { cursor: none; }
body.has-cursor dialog, body.has-cursor dialog * { cursor: auto; }
body.has-cursor dialog a, body.has-cursor dialog button { cursor: pointer; }

/* The About story's honeycomb on a landscape screen (16 Nov): a second drawing (about/index.html), turned 90°
   counterclockwise like the home page's honeycomb, with the same cards swapped; the portrait one is hidden. */
.story-hive.landscape { display: none; }
@media (orientation: landscape) {
  .story-hive.portrait { display: none; }
  .story-hive.landscape { display: block; width: min(100%, 36rem); }
}

/* ---------------------------------------------------------------------------------------------------------------
   Night (16 Nov): the dark theme as "the studiolo at night". The colours are in brand.css; here, on the home page, the
   crest glows like a lamp on the desk and the room darkens towards its corners. (The candlelight that followed the
   pointer was taken out, 16 Nov.) The icons' cream tiles are dimmed so they don't shine brighter than the lamp. */
@media (prefers-color-scheme: dark) {
  .hive::before { content: ""; position: absolute; left: 50%; top: calc(2 * var(--r)); z-index: -1; pointer-events: none;
                  width: calc(7 * var(--r)); height: calc(7 * var(--r)); translate: -50% -50%; border-radius: 50%;
                  background: radial-gradient(closest-side, rgb(233 162 59 / .2), rgb(233 162 59 / .07) 55%, transparent); }
  .home main::before { content: ""; position: fixed; inset: 0; z-index: 34; pointer-events: none;    /* the corners darken */
                       background: radial-gradient(ellipse 75% 70% at 50% 50%, transparent 50%, rgb(6 4 3 / .55)); }
  .hex .hex-icon { filter: brightness(.84); }
  /* The coming-soon cards at night, muted (16 Nov, evening; twice), so Tela's card is the one in colour. Contrast on
     the card in brackets.
     - icons nearly grey and dim (saturate .15, brightness .58, opacity .55; first saturate .7, brightness .78, .85)
     - names: 70% of the muted ink (3.8:1; was 80%, 4.6:1)
     - one-word titles: 15% red in the muted ink, at 85% (4.7:1; first 70% red at full, 6:1)
     - "Coming soon": the muted ink at 85% (5:1; was full, 6.4:1)
     - borders: 8% of the app's colour (was 24%), 5% when the card is opened (was 15%); the inlaid lines fainter */
  .hex:not(.live) .face .hex-icon { filter: saturate(.15) brightness(.58); opacity: .55; }
  .hex:not(.live) .face .app-name { color: color-mix(in srgb, var(--muted) 70%, var(--paper-raised)); }
  .hex:not(.live) .face .kind { color: color-mix(in srgb, color-mix(in srgb, var(--red) 15%, var(--muted)) 85%, var(--paper-raised)); }
  .hex:not(.live) .face .soon { color: color-mix(in srgb, var(--muted) 85%, var(--paper-raised)); }
  .hex[data-app]:not(.live) { --border: color-mix(in oklch, var(--accent-strong) 8%, var(--paper-raised));
                              --soon-grey: color-mix(in srgb, var(--muted) 32%, var(--paper-raised)); }
  .hive.zoomed .hex.focused[data-app]:not(.live) { --border: color-mix(in oklch, var(--accent-strong) 5%, var(--paper-raised));
                                                   --soon-grey: color-mix(in srgb, var(--muted) 20%, var(--paper-raised)); }
  .logo-draw .ink .initial { filter: drop-shadow(0 0 6px rgb(224 101 77 / .45)); }   /* the red S catches the light */
}
@media (prefers-color-scheme: dark) and (prefers-reduced-motion: no-preference) {
  .hive::before { animation: lamp 6s ease-in-out infinite; }
}
@keyframes lamp { 0%, 100% { opacity: 1; scale: 1; } 40% { opacity: .82; scale: .97; } 70% { opacity: .95; scale: 1.02; } }

/* ---------------------------------------------------------------------------------------------------------------
   16 Nov, three tidyings of the home page.
   Type: two faces only. Cinzel for names and labels (the app names, PAINT, the line under the logo); Work Sans for
   everything read or pressed (the cards' text, buttons, the "i" menu). Archivo is no longer used on this page. */
.hex[data-app="lux"] .app-name::first-letter { font-family: var(--font-logo); }   /* LUX with a plain L: the decorative one read as an I */
/* Icons: one family. A shape in the app's colour with one gold part, no small details (Lux lost its vents, display
   and pivots; Gioco is a little larger). Tela, the live one, keeps its colours, now the family's own: the brand's
   red, Mosaico's blue and Gioco's green. */
:is(.hex-icon, .story-hive) .ico-tela .p-red { fill: #B23A2A; }
:is(.hex-icon, .story-hive) .ico-tela .p-blue { fill: #406981; }
:is(.hex-icon, .story-hive) .ico-tela .p-green { fill: #35705D; }
/* Phones: larger words in the tiles. "Coming soon" becomes "Soon" on one line, which makes room for a larger name
   (13px, was 11) and label (10px, was 9). */
@media (max-width: 600px) {
  .face .soon .w1 { display: none; }
  .hex.crest .motto { font-size: max(10px, calc(var(--r) * .118)); letter-spacing: .2em; text-indent: .2em; }
  .face { gap: calc(var(--r) * .045); }
  .hex:not(.live) .face .app-name { font-size: max(13px, calc(var(--r) * .2)); }
  .lockup .kind { font-size: max(10px, calc(var(--r) * .1)); letter-spacing: .24em; margin-right: -.24em; }
  .face .soon { font-size: max(10px, calc(var(--r) * .075)); margin-top: 0; }
  .face .soon::before { margin-bottom: calc(var(--r) * .03); }
  .hex.live .face .app-name { font-size: max(16px, calc(var(--r) * .25)); }
  .hex.live .face .hex-icon { width: calc(var(--r) * .5); height: calc(var(--r) * .5); }
  .face .soon.try { font-size: max(9.5px, calc(var(--r) * .075)); letter-spacing: .08em; padding-left: .08em; }
}
/* The crest's middle line in its border's own yellow (16 Nov), as on Tela's card: .frame-mid draws it
   (img/hex-frame-crest-middle.svg), and ::after keeps only the inner, grey line (img/hex-frame-crest-inner.svg). */
.hex.crest::after { -webkit-mask-image: url(/img/hex-frame-crest-inner.svg); mask-image: url(/img/hex-frame-crest-inner.svg); }
.hex.crest .frame-mid { background: var(--sunset); -webkit-mask-image: url(/img/hex-frame-crest-middle.svg); mask-image: url(/img/hex-frame-crest-middle.svg); }
/* Bottega's icon (16 Nov): the cube at the origin of X, Y and Z, the three axes in gold (the cube's top was the gold part before) */
:is(.hex-icon, .story-hive) .ico-bottega .axes { stroke: #D29A36; stroke-width: 1.7; stroke-linecap: round; fill: none; }
/* A group placed by its own transform="…" (Tela's canvas, palette and brush, Gioco's pad) is measured from the
   drawing's origin, not from its own box as the animated parts are (.ico * above), or it lands off its place */
:is(.hex-icon, .story-hive) .ico g[transform] { transform-box: view-box; }
/* The logo in the crest (16 Nov): raised so the rule between STUDIOLO and INTERACTIVE lies on the hexagon's centre
   line, through its two side corners (on the desktop). The rule's middle is at 947.27 of the logo's 1468.22 height
   (lib/ui/brand/logo/studiolo-mobile-inline.svg): 14.52% below the logo's own middle. If the logo is made again,
   work this out again from its rule. */
.hex.crest { --rule-lift: -14.52%; }

/* Contact (16 Nov): each way to reach us on one line, its purpose, the address and a Copy button; on a narrow screen
   the purpose goes above. Used on /contact/ and in the home page's sheet. */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.prose .contact-list { list-style: none; padding: 0; margin: 1.8rem 0 2.2rem; border-top: 1px solid var(--line); }
.prose .contact-list li { display: grid; grid-template-columns: 10.5rem 1fr auto; align-items: center; gap: .35rem 1.2rem;
                          padding: .95rem 0; margin: 0; border-bottom: 1px solid var(--line); }
.contact-list .what { font-weight: 600; }
.contact-list .addr { overflow-wrap: normal; }   /* it breaks only after the @ (a <wbr> there), never mid-word */
.contact-list .note { grid-column: 2 / -1; color: var(--muted); font-size: .92rem; line-height: 1.5; }
.copy { font: 500 .88rem/1 var(--font-text); color: var(--ink); background: var(--paper-raised); border: 1px solid var(--line);
        border-radius: 999px; padding: 0 1.05em; min-height: 44px; min-width: 5.6em; cursor: pointer; transition: border-color .15s, color .15s; }
.copy:hover { border-color: var(--ink); }
.copy:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
.copy.done { color: var(--red); border-color: var(--red); }
@media (max-width: 560px) {
  .prose .contact-list li { grid-template-columns: 1fr auto; }
  .contact-list .what, .contact-list .note { grid-column: 1 / -1; }
  .contact-list .what { margin-bottom: -.15rem; }
  .contact-list .addr { font-size: .95rem; }
}

/* The About story's icons (16 Nov): the home page's, on the same cream tile. In the small honeycomb each app's tile
   sits in its cell (the cell's colour rings it when its line is read); in "The seven" each sits beside the name; and
   Mostra's opens its chapter. */
.story-hive .tile > rect { fill: #EDE7DC; stroke: none; }
.story-hive .cell[data-app] .ico { color: var(--accent); }
.story-apps li { display: grid; grid-template-columns: 4rem minmax(0, 1fr); column-gap: 1.25rem; align-content: center; }
.story-apps li > * { grid-column: 2; }
.story-apps li > .hex-icon { grid-column: 1; grid-row: 1 / span 3; align-self: start; }
.story .hex-icon { width: 4rem; height: 4rem; }
.chapter-icon { margin-bottom: 1rem; }
@media (max-width: 860px) {
  .story-apps li { grid-template-columns: 3rem minmax(0, 1fr); column-gap: 1rem; }
  .story .hex-icon { width: 3rem; height: 3rem; }
}
@media (prefers-color-scheme: dark) {
  .story .hex-icon, .story-hive .tile { filter: brightness(.84); }
}

/* The crest opened (16 Nov): a short introduction and "More about us", which opens the About story. The crest is
   twice a card's size, so its words are set in screen pixels (divided by the zoom), not by the hexagon's size.
   Turned (landscape), its box is twice a card's turned box. */
.hex.crest h1.crest-lockup { margin: 0; font: inherit; letter-spacing: normal; }
body.turned .hex.crest .over-face { width: calc(2 * var(--h)); height: calc(2 * var(--w)); }
.crest-intro { gap: calc(14px / var(--zoom)); padding: 0 19%; text-align: center; }
body.turned .crest-intro { padding: 0 21%; }
.crest-intro .crest-mark { font-family: var(--font-logo); font-weight: 600; text-transform: uppercase; letter-spacing: .2em;
                           padding-left: .2em; font-size: calc(13px / var(--zoom)); color: var(--red); }
.hex.crest .hex-over .tagline { font-size: calc(30px / var(--zoom)); margin: 0; }
.crest-intro .intro { font-size: calc(17px / var(--zoom)); line-height: 1.55; margin: 0; text-wrap: pretty; }
.crest-intro .intro.quiet { font-size: calc(14px / var(--zoom)); color: var(--muted); }
.crest-intro .intro.short { display: none; }   /* the phone's version (below) */
.hex.crest .get { font-size: calc(15px / var(--zoom)); }
.hex.crest .get-row { margin-top: calc(6px / var(--zoom)); }
@media (max-width: 600px), (max-height: 500px) {
  .crest-intro { gap: calc(10px / var(--zoom)); padding: 0 16%; }
  .hex.crest .hex-over .tagline { font-size: calc(21px / var(--zoom)); }
  .crest-intro .intro { font-size: calc(14px / var(--zoom)); line-height: 1.45; }
  /* a phone's hexagon is narrow at the top and bottom: the short version only, the name and the small line left out */
  .crest-intro .intro.full, .crest-intro .intro.quiet, .crest-intro .crest-mark { display: none; }
  .crest-intro .intro.short { display: block; }
  .hex.crest .get { font-size: calc(14px / var(--zoom)); }
}

/* ---------------------------------------------------------------- Tela's story (17 Nov)
   Tela's page, /tela/, reached from "More…" in Tela's card on the home page. The About story's layout, with a live
   canvas where its honeycomb is: js/tela-story.js paints it with Tela's own engine as the chapters go by. The canvas is
   the one loud thing here; the rest is the site's paper, ink and thin gold lines. */
.tela-story { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); max-width: 94rem; gap: clamp(1.5rem, 4vw, 4.5rem); }
.stage { margin: 0; width: 100%; display: flex; flex-direction: column; align-items: center; }
/* the painting: on the page like a sheet on a desk, inside a thin gold line (the cards' inlaid hexagons, squared) */
.stage-frame { position: relative; width: min(100%, calc((100svh - 12rem) * 1.6)); aspect-ratio: 16 / 10; background: var(--paper-raised);
               box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgb(34 30 27 / .18), 0 28px 60px -34px rgb(34 30 27 / .55); }
.stage-frame::after { content: ""; position: absolute; inset: -.6rem; border: 1px solid color-mix(in srgb, #D48C24 55%, var(--line));
                      pointer-events: none; }
.stage-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; opacity: 0; transition: opacity .6s ease; }
.tela-story[data-engine="ready"] .stage-canvas { opacity: 1; }
.stage-note { display: none; position: absolute; inset: 0; margin: 0; padding: 12%; place-content: center; text-align: center;
              color: var(--muted); font-size: .95rem; line-height: 1.5; }
.tela-story:not([data-engine]) .stage-note, .tela-story[data-engine="none"] .stage-note { display: grid; }
/* framed, in 3D: it's turned by dragging it (a touch across it turns it; up and down still scrolls the story) */
.tela-story[data-view="3d"] .stage-canvas { cursor: grab; touch-action: pan-y; }
.tela-story[data-view="3d"][data-turning] .stage-canvas { cursor: grabbing; }
.tela-story[data-view="3d"][data-turning] { user-select: none; }
/* how far through a chapter that the scroll drives */
.stage-meter { width: min(100%, calc((100svh - 12rem) * 1.6)); height: 2px; margin-top: 1.5rem; background: var(--line); }
.stage-meter span { display: block; height: 100%; background: #D48C24; transform-origin: 0 50%; transform: scaleX(0); }
.stage-label { width: min(100%, calc((100svh - 12rem) * 1.6)); display: flex; justify-content: space-between; align-items: baseline;
               gap: 1rem; margin-top: .7rem; min-height: 1.4em; }
.stage-label .story-caption { text-align: left; }
.stage-readout { font-family: var(--font-text); font-size: .82rem; font-variant-numeric: tabular-nums; color: var(--muted); white-space: nowrap; }
/* Tela's own bar, on its page (17 Nov): Studiolo at the left, Tela's mark and name in the middle over "Paint and draw",
   a close at the right (back to Tela's card on the home page). One row, lower than the site's header. */
.site-header.tela-bar .bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem;
                             padding: .55rem clamp(1rem, 3vw, 2rem); }
.site-header.tela-bar .logo { justify-self: start; }
.site-header.tela-bar .logo img { height: 2.1rem; }
.tela-lockup { display: flex; flex-direction: column; align-items: center; gap: .2rem; line-height: 1; }
.tela-lockup-name { display: inline-flex; align-items: center; gap: .45rem; }
.tela-lockup .app-name { font-size: 1.55rem; line-height: 1; }
.tela-lockup .kind { font-family: var(--font-logo); font-weight: 500; text-transform: uppercase; letter-spacing: .24em; font-size: .6rem;
                     color: var(--red); margin-right: -.24em; }
.tela-mark { width: 1.9rem; height: 1.9rem; flex: none; overflow: visible; }
.tela-mark .wood { fill: #C5A289; } .tela-mark .c { fill: #EDE7DC; } .tela-mark ellipse.c { fill: var(--paper); } .tela-mark .g { fill: #EBBA3B; }
.tela-mark .p-red { fill: #B23A2A; } .tela-mark .p-blue { fill: #406981; } .tela-mark .p-green { fill: #35705D; }
.tela-close { justify-self: end; width: 2.6rem; height: 2.6rem; border-radius: 50%; border: 1px solid var(--line); background: var(--paper-raised);
              color: var(--ink); font: 400 1.5rem/1 var(--font-text); display: grid; place-items: center; text-decoration: none;
              transition: border-color .15s, transform .2s; }
.tela-close:hover { border-color: var(--ink); transform: rotate(90deg); }
.tela-close:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
@media (max-width: 640px) {
  .site-header.tela-bar .bar { padding: .45rem .8rem; gap: .5rem; }
  .site-header.tela-bar .logo img { height: 2rem; }
  .tela-lockup .app-name { font-size: 1.3rem; }
  .tela-mark { width: 1.6rem; height: 1.6rem; }
  .tela-close { width: 2.3rem; height: 2.3rem; }
}
@media (prefers-reduced-motion: reduce) { .tela-close { transition: none; } .tela-close:hover { transform: none; } }
/* the text */
.tela-story .chapter .app-name { font-size: clamp(1.5rem, 1.2vw + 1rem, 2.1rem); line-height: 1; color: var(--red); margin: 0 0 .4rem; }
.tela-story .chapter h1 { font-size: clamp(2.5rem, 4.2vw + 1rem, 4.6rem); line-height: .98; letter-spacing: -.03em; }
.tela-story .chapter[data-chapter="open"] { min-height: 100svh; padding-bottom: 12svh; }
/* a chapter the scroll drives: tall, its text held in place while the painting moves */
.tela-story .chapter.scrub { min-height: 190svh; padding: 0; justify-content: flex-start; }
.tela-story .chapter.scrub.long { min-height: 280svh; }
.tela-story .pin { position: sticky; top: 0; min-height: 100svh; display: flex; flex-direction: column; justify-content: center; }
.tela-story .how { margin-top: 1.4rem; padding-left: .95rem; border-left: 2px solid #D48C24; color: var(--muted); font-size: .98rem; }
/* what people use it for */
.tela-story .chapter.uses, .tela-story .chapter.compare { max-width: none; }
.use-list { margin: 1rem 0 0; }
.use-list > div { display: grid; grid-template-columns: minmax(0, 11rem) minmax(0, 1fr); gap: .3rem 1.5rem; padding: 1.05rem 0;
                  border-top: 1px solid var(--line); }
.use-list > div:last-child { border-bottom: 1px solid var(--line); }
.use-list dt { font-family: var(--font-head); font-weight: 600; }
.use-list dd { margin: 0; color: var(--muted); }
/* free against the unlock: two columns, each row's name over the free one, the unlock's a raised band down the page */
.compare-table { display: block; margin: 1.6rem 0 1.2rem; font-size: .98rem; line-height: 1.4; }
.compare-table thead, .compare-table tbody { display: block; }
.compare-table tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.compare-table th, .compare-table td { text-align: left; font-weight: 400; }
.compare-table thead td { display: none; }
.compare-table thead th { padding: .9rem 1rem 1rem; font-family: var(--font-head); font-weight: 700; font-size: 1.25rem; line-height: 1.15; }
.compare-table thead th:first-of-type { padding-left: 0; }
.compare-table thead small { display: block; margin-top: .3rem; font-family: var(--font-text); font-weight: 400; font-size: .8rem; color: var(--muted); }
.compare-table tbody tr { border-top: 1px solid var(--line); }
.compare-table tbody tr:last-child { border-bottom: 1px solid var(--line); }
.compare-table tbody th { grid-column: 1; grid-row: 1; padding: .85rem 1rem 0 0; font-size: .8rem; line-height: 1.5rem; color: var(--muted); white-space: nowrap; }
.compare-table tbody td:first-of-type { grid-column: 1; grid-row: 2; padding: 0 1rem .95rem 0; }
.compare-table tbody td:last-child { grid-column: 2; grid-row: 1 / span 2; padding: calc(.85rem + 1.5rem) 1rem .95rem; }
.compare-table td:last-child, .compare-table thead th:last-child { background: var(--paper-raised); }
.compare-table thead th:last-child { box-shadow: inset 0 2px 0 #D48C24; }
.compare-table .none, .compare-table .same { color: var(--muted); }
/* "email me when Tela is on the App Store", on the story's paper (the form's own look is the dark band's, above) */
.tela-story .signup { background: var(--paper-raised); border-color: var(--line); max-width: 30rem; margin-top: 1.4rem; }
.tela-story .signup input[type=email] { border-color: var(--line); min-width: 0; flex: 1 1 12rem; width: auto; }
.notify-row { display: flex; flex-wrap: wrap; gap: .6rem; }
.signup .came-back { display: none; margin: 1rem 0 0; font-weight: 500; }
.signup .came-back:target { display: block; }
.story-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin: 1.6rem 0 1rem; }
.tela-story .chapter.last { min-height: 90svh; }
/* "More…" in Tela's card on the home page: the quiet button beside the red one */
.get.more { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 max(1px, calc(1.5px / var(--zoom))) var(--line); }
.get.more:hover { box-shadow: inset 0 0 0 max(1px, calc(1.5px / var(--zoom))) var(--ink); filter: none; }
@media (max-width: 860px) {
  .tela-story .story-visual { height: 46svh; padding: 1.3rem 0 .4rem; }
  .stage { height: 100%; justify-content: flex-start; }
  .stage-frame { width: min(100%, calc((46svh - 5.2rem) * 1.6)); }
  .stage-frame::after { inset: -.35rem; }
  .stage-meter, .stage-label { width: min(100%, calc((46svh - 5.2rem) * 1.6)); }
  .stage-meter { margin-top: .9rem; }
  .stage-label { margin-top: .4rem; }
  .stage-readout { font-size: .72rem; }
  .tela-story .chapter[data-chapter="open"] { min-height: 54svh; padding-top: 6svh; }
  .tela-story .pin { top: 46svh; min-height: 54svh; }
  .use-list > div { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { .stage-canvas { transition: none; } }
