/* hesychia.studio: the homepage. Dark, one row of app icons, three short sections.
   Shared look with /legal/legal.css (privacy, terms, 404): keep the tokens in step. */
:root { color-scheme: dark; --bg: #0e0e11; --ink: #efeef5; --dim: #9a98a8; --rule: rgba(255,255,255,.09); --lav: #b9a9ff; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.5 Inter, system-ui, -apple-system, sans-serif; -webkit-font-smoothing: antialiased; min-height: 100dvh; display: flex; flex-direction: column; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 2px solid var(--lav); outline-offset: 4px; border-radius: 6px; }
ul { list-style: none; margin: 0; padding: 0; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 10; background: var(--ink); color: var(--bg); padding: 10px 14px; border-radius: 8px; }
.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: clamp(28px, 6vw, 56px) 24px 0; flex: 1; }
header { text-align: center; }

/* the mark, free on the page (no tile: the page is the tile's own near-black) + the wordmark;
   the moon's intro is /home/moon-intro.js */
.brand { display: inline-flex; align-items: center; gap: 8px; }
.tile { width: 46px; height: 46px; display: grid; place-items: center; flex: none; }
.tile svg { width: 46px; height: 46px; }
.wordmark { font: 500 1.3rem/1 Fraunces, Georgia, serif; letter-spacing: -.005em; }
.mark-live { overflow: visible; }
.mark-live .m-moon { transform-box: view-box; transform-origin: 20.5px 28px; }
.mark-live .m-glow { transform-box: view-box; transform-origin: 20.5px 17px; }
.moon-intro .mark-live .m-moon, .moon-intro .mark-live .m-r1, .moon-intro .mark-live .m-r2 { visibility: hidden; animation: m-failsafe 0s 4s forwards; }   /* if the script never runs */
@keyframes m-failsafe { to { visibility: visible; } }

h1 { font: 400 clamp(2.5rem, 7vw, 4.4rem)/1.04 Newsreader, Georgia, serif; letter-spacing: -.025em; margin: clamp(36px, 8vh, 80px) 0 18px; }
.lede { color: var(--dim); margin: 0 auto; font-size: 1.08rem; max-width: 34ch; }

/* the apps: one row of icons (three, then two, on phones) */
.apps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px; margin: clamp(48px, 9vh, 96px) 0; scroll-margin-top: 24px; }
.app { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 12px 4px; }
.icon { width: clamp(72px, 9vw, 112px); height: auto; aspect-ratio: 1; margin-bottom: 16px; border-radius: 22.5%; display: block; box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 10px 24px -12px rgba(0,0,0,.8); transition: transform .35s cubic-bezier(.2,.7,.2,1); }
.app:hover .icon { transform: translateY(-3px); }
.name { font-weight: 600; letter-spacing: -.01em; }
.tl, .pf { color: var(--dim); }
.tl { font-size: .95rem; }
.pf { font-size: .86rem; margin-top: 6px; }
@media (max-width: 760px) {
  .apps { grid-template-columns: repeat(6, 1fr); gap: 28px 12px; }
  .apps li { grid-column: span 2; }
  .apps li:nth-child(4) { grid-column: 2 / span 2; }
  .icon { width: 76px; }
  .tl { font-size: .86rem; }
}
@media (max-width: 600px) { .pf { display: none; } }

/* the studio, the bio, contact */
.sec { max-width: 560px; margin: 0 auto; padding: clamp(56px, 11vh, 112px) 0; border-top: 1px solid var(--rule); text-align: center; }
.sec:last-of-type { padding-bottom: clamp(64px, 12vh, 128px); }
.sec h2 { font: 400 clamp(1.9rem, 4.6vw, 2.7rem)/1.1 Newsreader, Georgia, serif; letter-spacing: -.02em; margin: 0 0 18px; }
.sec p { color: var(--dim); margin: 0 auto; font-size: 1.08rem; line-height: 1.6; text-wrap: pretty; }
.sec .links { margin-top: 14px; }
.links a { display: inline-block; padding: 8px 0; color: var(--lav); }
.links a:hover { text-decoration: underline; text-underline-offset: 3px; }
.me { width: 112px; height: 112px; border-radius: 50%; object-fit: cover; display: block; margin: 0 auto 28px; box-shadow: 0 0 0 1px rgba(255,255,255,.12); }
.mail { display: inline-block; margin-top: 26px; padding: 8px 0; font: 400 clamp(1.45rem, 6.2vw, 2.5rem)/1.2 Newsreader, Georgia, serif; letter-spacing: -.02em; color: var(--ink); border-bottom: 1px solid rgba(185,169,255,.5); transition: color .35s, border-color .35s; }
.mail:hover { color: var(--lav); border-color: var(--lav); }

.foot { width: 100%; max-width: 1080px; margin: 0 auto; padding: 24px; display: flex; justify-content: space-between; align-items: center; gap: 16px; color: var(--dim); font-size: .86rem; }
.foot a { margin-left: 20px; padding: 8px 0; display: inline-block; }
.foot a:hover { color: var(--ink); }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
