/* a62.store — the studio's front door.
   Frame borrowed from the Sleepy Eyes shop: light cards with 24px corners on a
   dark ground, 16px from the screen edge and 8px apart, a floating top bar,
   things told apart by shade rather than outlines. Colours are a62's own. */

@font-face { font-family: "Eudoxus Sans"; src: url("fonts/eudoxus-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Eudoxus Sans"; src: url("fonts/eudoxus-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "KARA"; src: url("fonts/kara.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --night: #0e0023;       /* a62 deep night: the page ground */
  --night-2: #1a0c33;     /* footer and dark panels */
  --mist: #f9f2fc;        /* a62 mist: the cards */
  --mist-2: #efe4f4;      /* a quieter fill on a card */
  --plum: #570970;        /* a62 plum: logo and accent on mist */
  --lilac: #c9a6dc;       /* plum lifted to read on night */
  --ink: #1c1029;         /* text on mist */
  --ink-soft: #5e5268;    /* muted text on mist */
  --fog: #b8aac6;         /* muted text on night */

  --head: "Eudoxus Sans", "Lexend", system-ui, sans-serif;
  --sans: "Lexend", system-ui, -apple-system, "Segoe UI", sans-serif;

  --r: 16px; --r-lg: 24px; --edge: 16px; --gap: 8px;
  --shadow: 0 1px 2px rgba(14, 0, 35, .18), 0 22px 44px -26px rgba(14, 0, 35, .65);
  --ease: cubic-bezier(.3, .7, .2, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { background: var(--night); scroll-behavior: smooth; scroll-padding-top: 84px; }
body::before { /* the a62 topographic pattern, fixed behind everything */
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: var(--night) url("topo.svg") center / cover no-repeat;
}
body {
  margin: 0; min-height: 100vh; min-height: 100dvh;
  background: transparent; color: var(--mist);
  font: 300 16px/1.5 var(--sans);
  padding-inline: var(--edge); padding-block: 0 var(--edge);
  display: flex; flex-direction: column; gap: var(--gap);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-family: var(--head); font-weight: 800; letter-spacing: -.015em; text-wrap: balance; }
a { color: inherit; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 2px solid var(--lilac); outline-offset: 3px; }

/* Single-colour artwork drawn from an SVG file, painted in currentColor. */
.mark {
  display: block; background: currentColor;
  -webkit-mask: var(--src) center / contain no-repeat; mask: var(--src) center / contain no-repeat;
}
.m-sleepy { --src: url("marks/sleepy-eyes.svg"); aspect-ratio: 1; }
.m-mara   { --src: url("marks/mara.svg"); aspect-ratio: 442 / 499; }
.m-cobloc { --src: url("marks/cobloc.svg"); aspect-ratio: 250 / 350; }
.l-lockup { --src: url("logo/a62-lockup.svg"); aspect-ratio: 1280 / 386; }
.l-short  { --src: url("logo/a62-short.svg"); aspect-ratio: 900 / 386; }
.l-vertical { --src: url("logo/a62-vertical.svg"); aspect-ratio: 262 / 600; }

/* Icons: line icons from Lucide, brand marks from Simple Icons (see icons/LICENSE.txt). */
.ic {
  display: inline-block; flex: none; width: 1.15em; height: 1.15em; background: currentColor;
  -webkit-mask: var(--i) center / contain no-repeat; mask: var(--i) center / contain no-repeat;
}
.i-arrow { --i: url("icons/arrow-right.svg"); }
.i-out { --i: url("icons/arrow-up-right.svg"); }
.i-mail { --i: url("icons/mail.svg"); }
.i-bell { --i: url("icons/bell.svg"); }
.i-instagram { --i: url("icons/instagram.svg"); }
.i-facebook { --i: url("icons/facebook.svg"); }
.i-linkedin { --i: url("icons/linkedin.svg"); }
.i-apple { --i: url("icons/apple.svg"); }
.i-android { --i: url("icons/android.svg"); }
.i-book { --i: url("icons/book-open.svg"); }
.i-palette { --i: url("icons/palette.svg"); }
.i-hand { --i: url("icons/hand.svg"); }
.i-cash { --i: url("icons/banknote.svg"); }
.i-zap { --i: url("icons/zap.svg"); }
.i-users { --i: url("icons/users.svg"); }
.i-camera { --i: url("icons/camera.svg"); }
.i-offline { --i: url("icons/wifi-off.svg"); }
.i-grid { --i: url("icons/layout-grid.svg"); }
.i-receipt { --i: url("icons/receipt.svg"); }
.i-wrench { --i: url("icons/wrench.svg"); }
.i-megaphone { --i: url("icons/megaphone.svg"); }

/* ---------- top rail ---------- */
.rail {
  position: sticky; top: calc(env(safe-area-inset-top, 0px) + 12px); z-index: 10;
  margin-top: calc(env(safe-area-inset-top, 0px) + 12px);
  display: flex; align-items: center; gap: 16px;
  height: 60px; padding: 0 12px 0 20px; border-radius: var(--r);
  background: rgba(26, 12, 51, .78); color: var(--mist);
  backdrop-filter: blur(16px) saturate(1.3); -webkit-backdrop-filter: blur(16px) saturate(1.3);
  box-shadow: var(--shadow);
}
.rail .home { display: block; height: 34px; }
.rail .home .rail-logo { height: 100%; width: auto; display: block; overflow: visible; }
/* "a62" waits behind the triangle and slides out when the logo is pointed at */
.rail-logo .slide { transform: translateX(-500px); transition: transform .45s var(--ease); }
.rail .home:hover .slide, .rail .home:focus-visible .slide { transform: none; }
.rail nav { margin-inline-start: auto; display: flex; gap: 4px; }
.rail nav a {
  font: 500 14px/1 var(--sans); text-decoration: none; color: var(--mist);
  padding: 12px 14px; border-radius: 999px; transition: background .15s;
}
.rail nav a:hover { background: rgba(249, 242, 252, .1); }
.rail nav a[aria-current="page"] { background: var(--lilac); color: var(--night); }
@media (max-width: 640px) {
  .rail { height: 54px; padding-inline: 16px 8px; }
  .rail .home { height: 28px; }
}

/* ---------- home: three panels ---------- */
/* One panel stands open at a time; together they fill the screen under the rail. */
.panels {
  --closed: 104px;
  /* everything below the rail: 12px above it, 60px rail, 8px gap, 16px edge */
  height: max(480px, calc(100vh - 96px)); height: max(480px, calc(100dvh - 96px - env(safe-area-inset-top, 0px)));
  display: flex; gap: var(--gap); container-type: size;
}
.panel {
  position: relative; display: block; flex: 0 0 var(--closed); min-width: 0; overflow: hidden;
  border-radius: var(--r-lg); background: var(--bg); color: var(--fg); text-decoration: none;
  transition: flex-grow .6s var(--ease);
}
.panel.is-open { flex-grow: 1; }

.panel .closed { position: absolute; inset: 0; transition: opacity .25s; }
.panel .closed .mark { position: absolute; left: 50%; top: 28px; width: 44px; transform: translateX(-50%); }
.panel .closed .name {
  position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%) rotate(180deg);
  writing-mode: vertical-rl; white-space: nowrap; font: var(--name-w) 40px/1 var(--font);
}
.panel .open {
  position: absolute; top: 0; bottom: 0; left: 0; width: calc(100cqw - 2 * var(--closed) - 2 * var(--gap)); padding: clamp(28px, 4vw, 56px);
  display: flex; flex-direction: column; justify-content: flex-end; align-items: flex-start; gap: 16px;
  opacity: 0; visibility: hidden; transition: opacity .3s .12s, visibility 0s .42s;
}
.panel .open .mark { width: clamp(72px, 9vw, 128px); margin-bottom: auto; }
.panel .open h2 { font: var(--name-w) clamp(48px, 7vw, 104px)/.92 var(--font); letter-spacing: -.01em; color: var(--title); }
.panel .open p { max-width: 28ch; font-size: clamp(16px, 1.6vw, 20px); color: var(--text); }
.panel .open .row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 6px; }
.panel.is-open .closed { opacity: 0; }
.panel.is-open .open { opacity: 1; visibility: visible; transition: opacity .3s .15s, visibility 0s; }

.pill {
  display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 22px;
  border-radius: 999px; font: 500 15px/1 var(--sans); text-decoration: none; white-space: nowrap;
  background: var(--btn-bg); color: var(--btn-fg); transition: transform .12s, filter .15s;
}
a.pill:hover, .panel:hover .pill { filter: brightness(1.08); }
a.pill:active { transform: translateY(1px); }
.pill.off { background: rgba(127, 127, 127, .22); color: currentColor; opacity: .75; cursor: not-allowed; }
.tag {
  font: 500 12px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase;
  padding: 8px 12px; border-radius: 999px; background: var(--tag-bg); color: var(--tag-fg);
}

/* Each product wears its own colours and its own title face. */
.p-sleepy { --font: "KARA", Georgia, serif; --name-w: 700; --bg: #221c33; --fg: #c6a3d1; --title: #f1ebe2; --text: #d9cfe0; --btn-bg: #c6a3d1; --btn-fg: #221c33; --tag-bg: rgba(198, 163, 209, .16); --tag-fg: #e3cfea; }
.p-mara   { --font: var(--head); --name-w: 800; --bg: #0f1f1b; --fg: #f5b32e; --title: #f7f5ef; --text: #c9d8d1; --btn-bg: #f5b32e; --btn-fg: #0f1f1b; --tag-bg: rgba(245, 179, 46, .16); --tag-fg: #f7d48a; }
.p-cobloc { --font: var(--head); --name-w: 800; --bg: #2152a3; --fg: #eef1f0; --title: #ffffff; --text: #dce6f6; --btn-bg: #eef1f0; --btn-fg: #182226; --tag-bg: rgba(255, 255, 255, .16); --tag-fg: #ffffff; }

@media (max-width: 640px) {
  /* On a phone the panels stack: closed ones are bands, the open one takes the rest. */
  .panels { --closed: 76px; flex-direction: column; height: max(460px, calc(100dvh - 90px - env(safe-area-inset-top, 0px))); }
  .panel .open { right: 0; width: auto; bottom: auto; height: calc(100cqh - 2 * var(--closed) - 2 * var(--gap)); }
  .panel .closed .mark { left: 24px; top: 50%; width: 34px; transform: translateY(-50%); }
  .panel .closed .name { writing-mode: horizontal-tb; transform: translateY(-50%); left: 74px; top: 50%; bottom: auto; font-size: 30px; }
  .panel .open { padding: 24px; gap: 12px; }
  .panel .open .mark { width: 64px; }
  .panel .open p { font-size: 15px; }
  .pill { height: 40px; padding: 0 18px; font-size: 14px; }
}

/* ---------- about ---------- */
.about {
  position: relative; overflow: hidden; background: var(--mist); color: var(--ink); border-radius: var(--r-lg);
  min-height: max(480px, calc(100dvh - 96px));
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); align-items: center;
  padding: clamp(28px, 5vw, 72px);
}
.about .txt { display: flex; flex-direction: column; gap: 20px; max-width: 34em; position: relative; z-index: 1; }
.about h2 { font-size: clamp(48px, 7vw, 96px); line-height: .95; color: var(--plum); }
.about p { font-size: clamp(17px, 1.6vw, 20px); color: var(--ink-soft); max-width: 28ch; }
.about p a { color: var(--plum); }
.about .sign { position: absolute; left: clamp(28px, 5vw, 72px); bottom: clamp(24px, 4vw, 48px); display: flex; align-items: center; gap: 16px; color: var(--plum); font-size: 14px; z-index: 1; }
.about .sign .mark { height: 40px; }
.about { padding-bottom: clamp(110px, 12vw, 140px); }
/* the vertical logo, zoomed in and cropped by the card's edge */
.about .big { position: absolute; right: 4%; top: -5%; height: 110%; color: var(--plum); }
@media (max-width: 760px) {
  .about { grid-template-columns: 1fr; align-items: end; padding-top: 340px; }
  .about .big { right: auto; left: 24px; top: -90px; height: 420px; }
}

/* ---------- product pages ---------- */
.hero {
  border-radius: var(--r-lg); background: var(--bg); color: var(--title); overflow: hidden; position: relative;
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 32px; align-items: center;
  padding: clamp(28px, 5vw, 64px); min-height: min(560px, calc(100dvh - 160px));
}
.hero::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 18px; background: linear-gradient(90deg, rgba(0, 0, 0, .3), transparent); }
.hero .txt { display: flex; flex-direction: column; align-items: flex-start; gap: 18px; position: relative; }
.hero h1 { font: var(--name-w) clamp(52px, 9vw, 112px)/.92 var(--font); }
.hero .lead { font-size: clamp(18px, 2vw, 22px); color: var(--text); max-width: 30ch; }
.hero .art { color: var(--fg); display: grid; place-items: center; }
.hero .art .mark { width: min(100%, 300px); }
.hero .art img.icon { width: min(100%, 300px); }
@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; min-height: 0; }
  .hero .art { order: -1; justify-items: start; }
  .hero .art .mark, .hero .art img.icon { width: 96px; }
}

.sec { background: var(--mist); color: var(--ink); border-radius: var(--r-lg); padding: clamp(24px, 4vw, 44px); display: flex; flex-direction: column; gap: 24px; }
.sec h2 { font-size: clamp(28px, 3.6vw, 40px); }
.feats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
@media (max-width: 960px) { .feats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .feats { grid-template-columns: 1fr; } }
.feat { background: var(--mist-2); border-radius: var(--r); padding: 20px; display: flex; flex-direction: column; gap: 8px; }
.feat h3 { font-size: 19px; font-weight: 700; line-height: 1.25; }
.feat p { color: var(--ink-soft); font-size: 15px; }

.pics { display: flex; gap: var(--gap); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 4px; }
.pics img { flex: 0 0 auto; height: clamp(300px, 46vw, 480px); width: auto; border-radius: var(--r); scroll-snap-align: start; background: var(--mist-2); }

.others { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); }
@media (max-width: 560px) { .others { grid-template-columns: 1fr; } }
.other {
  display: flex; align-items: center; gap: 16px; padding: 18px 22px; border-radius: var(--r);
  background: var(--bg); color: var(--title); text-decoration: none; transition: transform .2s var(--ease);
}
.other:hover { transform: translateY(-3px); }
.other .mark { width: 40px; color: var(--fg); flex: none; }
.other b { font: var(--name-w) 24px/1 var(--font); }
.other span { color: var(--text); font-size: 14px; }
.other .go { margin-inline-start: auto; font-size: 22px; }


@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* rail: see-through once the page scrolls */
.rail { transition: background .3s, box-shadow .3s, backdrop-filter .3s, -webkit-backdrop-filter .3s; }
.rail.is-scrolled { background: transparent; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
/* Once the rail goes see-through, a round lens sits behind the triangle:
   it blurs what passes under it and makes it shimmer like heat (the
   shimmer is the #a62-heat filter in the logo; browsers that can't use
   it get the blur alone). */
.rail .home { position: relative; --h: 34px; }
.rail .home::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  /* a circle centred on the triangle; it stretches into a pill around "a62" on hover */
  --d: calc(var(--h) * 1.9);
  width: var(--d); height: var(--d); border-radius: 999px;
  left: calc(var(--h) * .52 - var(--d) / 2); top: calc(var(--h) * .5 - var(--d) / 2);
  transform-origin: calc(var(--d) / 2) 50%; transform: scale(.6);
  background: rgba(14, 0, 35, .32); /* a touch of night so the light logo still reads over light cards */
  box-shadow: inset 0 0 0 1px rgba(249, 242, 252, .14), 0 8px 24px -10px rgba(14, 0, 35, .6);
  -webkit-backdrop-filter: blur(6px) saturate(1.3);
  backdrop-filter: blur(6px) saturate(1.3);
  backdrop-filter: url(#a62-heat) blur(3px) saturate(1.3);
  opacity: 0; transition: opacity .35s, transform .45s var(--ease), width .45s var(--ease);
}
.rail.is-scrolled .home::before { opacity: 1; transform: none; }
.rail .home:hover::before, .rail .home:focus-visible::before { width: calc(var(--h) * 3.1); }
@media (max-width: 640px) { .rail .home { --h: 28px; } }

/* ---------- product pages: additions ---------- */
.pics figure { margin: 0; flex: 0 0 auto; display: flex; flex-direction: column; gap: 10px; scroll-snap-align: start; }
.pics figcaption { font-size: 14px; color: var(--ink-soft); }

.hero .meta { font: 500 12px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--text); opacity: .75; }
.notify { display: flex; flex-wrap: wrap; gap: 8px; width: 100%; max-width: 440px; }
.notify input[type="email"] {
  flex: 1 1 200px; min-width: 0; height: 44px; padding: 0 20px; border: 0; border-radius: 999px;
  font: 400 15px/1 var(--sans); color: var(--title); background: rgba(255, 255, 255, .1);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18);
}
.notify input[type="email"]::placeholder { color: var(--text); opacity: .7; }
.notify input[type="email"]:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; }
.notify button.pill { border: 0; cursor: pointer; }
.notify button.pill:disabled { opacity: .6; cursor: wait; }
.notify .msg { flex-basis: 100%; min-height: 1.5em; font-size: 14px; color: var(--text); }
.notify.is-bad .msg { color: var(--fg); }
.notify .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

.outro {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: clamp(24px, 4vw, 44px); border-radius: var(--r-lg); background: var(--bg); color: var(--title); text-decoration: none;
}
.outro .addr { font: var(--name-w) clamp(28px, 4.4vw, 56px)/1 var(--font); }
.outro:hover .pill { filter: brightness(1.08); }

.about p.line { color: var(--ink); }
.about .links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.about .links a {
  display: inline-flex; align-items: center; height: 38px; padding: 0 16px; border-radius: 999px;
  font: 500 14px/1 var(--sans); text-decoration: none; color: var(--plum); background: var(--mist-2); transition: background .15s;
}
.about .links a:hover { background: #e4d3ec; }
.about .links a { gap: 8px; }
.about .links a.sq { width: 38px; padding: 0; justify-content: center; }
.about .links .ic { font-size: 17px; }
.about .links li:last-child { flex-basis: 100%; } /* the email sits on its own line, under the icons */

/* ---------- icons in place ---------- */
.pill .ic { font-size: 17px; transition: transform .2s var(--ease); }
a.pill:hover .i-arrow, .panel:hover .pill .i-arrow { transform: translateX(2px); }
a.pill:hover .i-out, .outro:hover .i-out { transform: translate(2px, -2px); }
.tag { display: inline-flex; align-items: center; gap: 8px; }
.tag.live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.feat .ic { font-size: 24px; color: var(--bg); margin-bottom: 6px; }
.hero .meta { display: flex; align-items: center; gap: 10px; }
.hero .meta .ic { font-size: 15px; }
.hero .meta a { color: inherit; text-underline-offset: 3px; }
.other .go { font-size: 22px; color: var(--title); }
