/* Soft Day: the living-sky page (soft-day.html). Self-contained like the Photo Keepers pages: no merano.css,
   no merano.js, nothing from another host. The bar is the studio's shared product bar (see photo-keepers.css)
   with the film strip replaced by a strip of sky. The page itself sits on one sky canvas, painted by
   js/soft-day.js from the app's own palette and keyed to the scroll: dawn at the top, midnight at the end. */

@font-face { font-family: "Instrument Serif"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/instrument-serif.woff2") format("woff2"); }
@font-face { font-family: "Instrument Serif"; font-style: italic; font-weight: 400; font-display: swap;
  src: url("../fonts/instrument-serif-italic.woff2") format("woff2"); }
@font-face { font-family: "Instrument Sans"; font-style: normal; font-weight: 400 600; font-display: swap;
  src: url("../fonts/instrument-sans.woff2") format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 400 500; font-display: swap;
  src: url("../fonts/jetbrains-mono.woff2") format("woff2"); }

:root {
  color-scheme: dark;
  --ground: #0d0c0b;     /* the bar, shared with the other product pages */
  --paper: #171513;
  --rule-bar: #2a2622;
  --rule-bar-2: #3a352f;
  --bar-ink: #ece6dc;
  --bar-ink-2: #c9c1b5;
  --bar-ink-3: #a59c90;
  --sky: #1c3050;        /* what shows before the canvas paints, a mid-morning blue from the palette */
  --ink: #ffffff;
  --ink-2: rgba(255, 255, 255, 0.84);
  --ink-3: rgba(255, 255, 255, 0.64);
  --glass: rgba(255, 255, 255, 0.10);
  --rule: rgba(255, 255, 255, 0.20);
  --dawn: #ffd9b8;       /* the twilight horizon, used for the one accent */
  --serif: "Instrument Serif", Georgia, serif;
  --sans: "Instrument Sans", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --page: 1240px;
  --gutter: 32px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 120px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; background: var(--sky); color: var(--ink); font-family: var(--sans); font-size: 17px; line-height: 1.55; }
img { max-width: 100%; }
a { color: var(--ink); text-decoration-thickness: 1px; text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--dawn); outline-offset: 3px; }
.vh { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.sd-skip { position: absolute; left: 16px; top: -100px; z-index: 50; padding: 10px 16px; background: var(--ink); color: var(--ground); font-weight: 600; }
.sd-skip:focus { top: 16px; }
.sd-wrap { max-width: var(--page); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.sd-label { font-family: var(--mono); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); }

/* ---------- The sky ---------- */

.sd-sky { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; }
.sd-page { position: relative; z-index: 1; }
.sd-clock { position: fixed; right: 24px; top: 76px; z-index: 15; display: flex; gap: 12px; padding: 10px 14px; border-radius: 999px;
  background: rgba(0, 0, 0, 0.35); border: 1px solid var(--rule); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  font-family: var(--mono); font-size: 13px; letter-spacing: 0.1em; font-variant-numeric: tabular-nums; }
.sd-clock b { font-weight: 500; color: var(--ink); }
.sd-clock span { color: var(--ink-3); }

/* ---------- The bar ---------- */

.sd-bar { position: sticky; top: 0; z-index: 20; background: rgba(13, 12, 11, 0.94); border-bottom: 1px solid var(--rule-bar);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); color: var(--bar-ink); }
.sd-bar::before { content: ""; display: block; height: 8px; opacity: 0.9;
  background: linear-gradient(90deg, #0a0f21, #29476f 30%, #5c8fc7 55%, #e08a6b 80%, #1b2a48); }
.sd-bar-inner { max-width: var(--page); margin: 0 auto; padding: 0 var(--gutter); min-height: 56px; display: flex; flex-wrap: wrap;
  align-items: center; justify-content: space-between; gap: 0 20px; font-family: var(--mono); font-size: 13px; letter-spacing: 0.08em; }
.sd-crumb { display: flex; align-items: center; gap: 10px; min-height: 44px; }
.sd-crumb a { color: var(--bar-ink-3); text-decoration: none; }
.sd-crumb a[aria-current="page"], .sd-crumb a:last-child { color: var(--bar-ink); }
.sd-crumb a:hover { color: var(--dawn); }
.sd-crumb-sep { color: #5c554c; }
.sd-nav { margin-left: auto; }
.sd-nav > ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 0 22px; }
.sd-nav a { color: var(--bar-ink-3); text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.sd-nav a:hover { color: var(--bar-ink); }
.sd-download { display: inline-flex; align-items: center; padding: 0 16px; min-height: 36px; background: var(--bar-ink); color: var(--ground);
  border-radius: 999px; text-decoration: none; font-family: var(--sans); font-weight: 600; font-size: 14px; letter-spacing: 0; }
.sd-download:hover { background: #fff; color: var(--ground); }

/* "Other apps": the same disclosure as the other product pages */
.sd-apps { position: relative; }
.sd-apps summary { list-style: none; cursor: pointer; color: var(--bar-ink); min-height: 44px; display: inline-flex; align-items: center; gap: 8px; }
.sd-apps summary::-webkit-details-marker { display: none; }
.sd-apps summary::after { content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: translateY(-2px) rotate(45deg); transition: transform 0.15s; }
.sd-apps[open] summary::after { transform: translateY(1px) rotate(-135deg); }
.sd-apps-list { position: absolute; left: -16px; top: 46px; width: 270px; margin: 0; padding: 8px 0; list-style: none;
  background: var(--paper); border: 1px solid var(--rule-bar-2); box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5); }
.sd-apps-list a { display: flex; align-items: center; gap: 14px; min-height: 40px; padding: 0 16px; color: var(--bar-ink-3); text-decoration: none; }
.sd-apps-list a:hover { color: var(--bar-ink); background: #1e1b18; }
.sd-apps-list a[aria-current="page"] { color: var(--bar-ink); background: #221f1b; }

@media (max-width: 760px) {
  :root { --gutter: 16px; }
  html { scroll-padding-top: 150px; }
  .sd-bar-inner { font-size: 12px; letter-spacing: 0.05em; gap: 0 12px; }
  .sd-download { margin-left: auto; }
  .sd-nav { order: 3; width: 100%; margin-left: 0; }
  .sd-nav > ul { gap: 0 16px; justify-content: space-between; }
  .sd-apps-list { left: 0; width: min(270px, calc(100vw - 32px)); }
  .sd-clock { right: 16px; top: 118px; }
}

/* ---------- Shared pieces ---------- */

.sd-phone { border-radius: 9.5% / 4.4%; overflow: hidden; background: #000; aspect-ratio: 1320 / 2868; width: 100%;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.12) inset; }
.sd-phone img { width: 100%; height: 100%; display: block; object-fit: cover; }
.sd-hero > *, .sd-words > *, .sd-days > *, .sd-plus > *, .sd-tiles > * { min-width: 0; }
.sd-watch { border-radius: 24%; overflow: hidden; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45); }
.sd-watch img { width: 100%; display: block; }
.sd-glass { background: var(--glass); border: 1px solid var(--rule); border-radius: 22px; -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); }
.sd-button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 0 24px; border-radius: 999px;
  background: var(--ink); color: #13223a; font-weight: 600; font-size: 16px; text-decoration: none; }
.sd-button:hover { background: #fff; color: #13223a; }
.sd-button svg { width: 18px; height: 18px; }
.sd-note { font-family: var(--mono); font-size: 13px; color: var(--ink-3); }
.sd-section { padding-top: 40px; padding-bottom: 96px; }
.sd-section h2 { margin: 0 0 14px; max-width: 820px; font-family: var(--serif); font-weight: 400; font-size: clamp(38px, 4.6vw, 60px); line-height: 1.04; text-wrap: balance; }
.sd-intro { margin: 0 0 40px; max-width: 640px; font-size: 19px; color: var(--ink-2); }

/* ---------- Hero ---------- */

.sd-hero { padding-top: 88px; padding-bottom: 64px; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: 48px; align-items: center; }
.sd-eyebrow { margin: 0 0 26px; display: flex; align-items: center; gap: 14px; }
.sd-eyebrow img { width: 48px; height: 48px; border-radius: 11px; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3); }
.sd-hero h1 { margin: 0 0 20px; font-family: var(--serif); font-weight: 400; font-size: clamp(50px, 7vw, 104px); line-height: 0.98; letter-spacing: -0.01em;
  text-wrap: balance; text-shadow: 0 2px 30px rgba(0, 0, 0, 0.25); }
.sd-hero h1 em { font-style: italic; color: var(--dawn); }
.sd-lede { margin: 0; max-width: 580px; font-size: 21px; line-height: 1.5; color: var(--ink-2); }
.sd-cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 20px; margin-top: 30px; }
.sd-hint { margin: 36px 0 0; display: flex; align-items: center; gap: 12px; }
.sd-hint::after { content: ""; width: 1px; height: 46px; background: linear-gradient(var(--ink), transparent); }
.sd-hero .sd-phone { max-width: 330px; margin: 0 auto; transform: rotate(-2deg); }

/* The forecaster's words */
.sd-words { margin: 0 0 96px; padding: 44px 48px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.sd-words blockquote { margin: 0; font-family: var(--serif); font-size: clamp(28px, 3.2vw, 40px); line-height: 1.22; }
.sd-words cite { display: block; margin-top: 18px; font-style: normal; }
.sd-words-side p { margin: 0 0 14px; font-size: 18px; color: var(--ink-2); }
.sd-words-side p:last-child { margin-bottom: 0; }

/* Why it is more accurate */
.sd-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.sd-tile { padding: 26px 26px 28px; display: flex; flex-direction: column; gap: 10px; }
.sd-tile .sd-big { font-family: var(--serif); font-size: 52px; line-height: 1; }
.sd-tile h3 { margin: 0; font-size: 17px; font-weight: 600; }
.sd-tile p { margin: 0; font-size: 16px; color: var(--ink-2); }

/* The sky, four times of day */
.sd-days { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; }
.sd-days figure { margin: 0; }
.sd-days figcaption { margin-top: 12px; display: flex; justify-content: space-between; gap: 8px; }

/* Widgets: the three surfaces, drawn on the page's own sky from the widgets' real layouts */
/* Two rows: the three surfaces share one row, centred on a common axis; their captions share the next, on one rule. */
.sd-surfaces { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.25fr) minmax(0, 0.9fr); grid-template-rows: 500px auto; gap: 28px 32px; }
.sd-surface { display: contents; }
.sd-surface > :first-child { grid-row: 1; align-self: center; justify-self: center; min-width: 0; max-width: 100%; }
.sd-surface > p { grid-row: 2; align-self: start; margin: 0; padding-top: 16px; border-top: 1px solid var(--rule); font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.sd-surface > p b { display: block; margin-bottom: 6px; font-family: var(--mono); font-weight: 500; font-size: 12px; letter-spacing: 0.14em; color: var(--ink-3); }
.sd-frame { border: 1px solid rgba(255, 255, 255, 0.4); background: rgba(0, 0, 0, 0.14); box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(0, 0, 0, 0.3); }
.sd-lock { height: 500px; width: auto; aspect-ratio: 1320 / 1900; border-radius: 9.5% / 6.6%; padding: 34px 18px;
  display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.sd-lock-date { margin-top: 16px; font-size: 15px; font-weight: 500; }
.sd-lock-time { font-size: 84px; font-weight: 400; line-height: 1; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; text-shadow: 0 2px 20px rgba(0, 0, 0, 0.25); }
.sd-w-row { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 8px; }
.sd-w { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; color: #fff; line-height: 1.1;
  background: rgba(255, 255, 255, 0.18); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); font-variant-numeric: tabular-nums; }
.sd-w b { font-weight: 600; font-size: 13px; }
.sd-w small { font-size: 9px; color: rgba(255, 255, 255, 0.85); }
.sd-w-circle { width: 58px; height: 58px; border-radius: 50%; position: relative; }
.sd-w-rect { height: 58px; padding: 0 12px; border-radius: 16px; flex-direction: row; gap: 8px; text-align: left; }
.sd-w-rect > span { display: flex; flex-direction: column; gap: 2px; }
.sd-w-inline { height: 26px; padding: 0 10px; border-radius: 13px; flex-direction: row; gap: 6px; font-size: 12px; font-weight: 500; }
.sd-i { width: 18px; height: 18px; fill: none; stroke: #fff; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.sd-i .sd-fill { fill: #fff; stroke: none; }
.sd-i .sd-sun { fill: #ffe6b8; stroke: #ffe6b8; }
.sd-hw-placerow { display: flex; justify-content: space-between; align-items: baseline; }
.sd-hw-placerow b { font-family: var(--sans); font-weight: 500; font-size: 12px; letter-spacing: 0; color: #fff; }
.sd-w-inline .sd-i { width: 15px; height: 15px; }
.sd-ring b { font-size: 15px; }
.sd-ring small { display: flex; justify-content: space-between; width: 36px; position: absolute; bottom: 7px; font-size: 8px; }
.sd-ring-svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(135deg); }
.sd-ring-svg circle { fill: none; stroke: rgba(255, 255, 255, 0.3); stroke-width: 3.5; stroke-dasharray: 75 100; stroke-linecap: round; }
.sd-ring-svg .sd-ring-arc { stroke: #fff; stroke-dasharray: 60 100; }
.sd-home { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; width: 100%; max-width: 360px; }
.sd-hw { aspect-ratio: 1; border-radius: 22px; padding: 14px 15px; display: flex; flex-direction: column; min-width: 0;
  background: linear-gradient(180deg, var(--sky-top, #2a5a9c), var(--sky-hor, #5a8bc1)); box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3); color: #fff; }
.sd-hw-wide { grid-column: 1 / -1; aspect-ratio: 2.12; }
.sd-hw-place { font-family: var(--mono); font-size: 10px; letter-spacing: 0.14em; color: rgba(255, 255, 255, 0.8); }
.sd-hw-icon { width: 22px; height: 22px; margin-top: 10px; }
.sd-hw-temp { margin-top: auto; font-size: 40px; line-height: 1; font-variant-numeric: tabular-nums; }
.sd-hw-cond { margin-top: 6px; font-size: 13px; }
.sd-hw-big { font-size: 24px; line-height: 1.1; margin-top: 2px; }
.sd-bars { margin-top: auto; display: flex; gap: 3px; align-items: flex-end; height: 14px; }
.sd-bars i { flex: 1; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, 0.55); }
.sd-bars i.h1 { height: 6px; background: rgba(255, 255, 255, 0.8); }
.sd-bars i.h2 { height: 10px; background: rgba(255, 255, 255, 0.85); }
.sd-bars i.h3 { height: 14px; background: #fff; }
.sd-hw-axis { display: flex; justify-content: space-between; margin-top: 5px; font-size: 9px; color: rgba(255, 255, 255, 0.8); font-variant-numeric: tabular-nums; }
.sd-hw-words { margin-top: 8px; font-size: 12.5px; line-height: 1.4; }
.sd-hw-credit { margin-top: auto; font-size: 10px; color: rgba(255, 255, 255, 0.75); }
.sd-watchface { width: 230px; max-width: 100%; aspect-ratio: 416 / 496; border-radius: 26%; padding: 22px 18px 18px;
  display: flex; flex-direction: column; align-items: center; gap: 14px; }
.sd-watch-time { align-self: flex-end; font-size: 22px; font-weight: 500; font-variant-numeric: tabular-nums; margin-bottom: 8px; }
.sd-watchface .sd-w-row { margin-top: 0; gap: 8px; }
.sd-w-watchrect { height: 52px; }
@media (max-width: 900px) {
  .sd-surfaces { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; gap: 20px; }
  .sd-surface > :first-child, .sd-surface > p { grid-row: auto; }
  .sd-surface > p { margin-bottom: 28px; }
  .sd-lock { height: auto; width: 100%; max-width: 300px; }
}

/* Soft Day Plus */
.sd-plus { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 48px; align-items: center; }
.sd-sentence { margin: 0 0 26px; font-family: var(--serif); font-size: clamp(28px, 3.4vw, 42px); line-height: 1.3; }
.sd-sentence u { text-decoration: none; border-bottom: 2px solid var(--dawn); padding-bottom: 2px; }
.sd-plus p { margin: 0 0 12px; max-width: 560px; color: var(--ink-2); }
.sd-plus p:last-child { margin-bottom: 0; }
.sd-plus .sd-phone { max-width: 300px; margin: 0 auto; }

/* Quiet by design, and the last download */
.sd-quiet { text-align: center; padding-top: 72px; padding-bottom: 110px; }
.sd-quiet h2 { max-width: none; margin: 0 auto 14px; }
.sd-quiet p { margin: 0 auto 28px; max-width: 560px; font-size: 19px; color: var(--ink-2); }

footer.sd-footer { border-top: 1px solid var(--rule); background: rgba(0, 0, 0, 0.3); font-size: 14px; color: var(--ink-3); }
.sd-footer .sd-wrap { padding-top: 36px; padding-bottom: 36px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; }
.sd-footer p { margin: 0; }
.sd-footer ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 22px; }
.sd-footer a { color: var(--ink-2); }
.sd-footer a:hover { color: var(--ink); }

@media (max-width: 900px) {
  .sd-hero, .sd-words, .sd-plus { grid-template-columns: minmax(0, 1fr); }
  .sd-hero { padding-top: 56px; padding-bottom: 40px; }
  .sd-hero .sd-phone { max-width: 260px; }
  .sd-words { padding: 28px 22px; }
  .sd-tiles { grid-template-columns: minmax(0, 1fr); }
  .sd-days { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sd-wlist li { grid-template-columns: 120px minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) { .sd-hero .sd-phone { transform: none; } }
