:root {
  --fondo: #ffffff;
  --carta: #ffffff;
  --testo: #16161a;
  --testo-2: #5e5c66;
  --testo-3: #a4a2ab;
  --linea: #ecebef;
  --pillola: #16161a;        /* the ink pill */
  --pillola-su: #26262c;
  --accento: #13865f;        /* the single accent: a deep green, on the tick and the time of the save */
  --ombra: 22, 22, 30;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
html { font-size: clamp(12px, min(3.6vw, 3.2vh), 17px); }
body {
  background: var(--fondo);
  color: var(--testo);
  font-family: "Mona Sans Variable", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
}
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.stage { min-height: 100vh; display: grid; place-items: center; padding: 1em; }

.editor {
  width: min(22em, 92vw);
  background: var(--carta);
  border: 1px solid var(--linea);
  border-radius: 1.2em;
  box-shadow: 0 1px 2px rgba(var(--ombra), .04), 0 24px 50px -32px rgba(var(--ombra), .34);
  overflow: hidden;
}

.editor__head {
  display: flex; align-items: center; justify-content: space-between; gap: 1em;
  padding: .85em 1.15em;
  border-bottom: 1px solid var(--linea);
  font-size: .72em; color: var(--testo-3);
  white-space: nowrap;
}
.app { font-weight: 640; color: var(--testo); letter-spacing: -.01em; }
.path { overflow: hidden; text-overflow: ellipsis; }
.path strong { font-weight: 520; color: var(--testo-2); }

.page { padding: 1.15em 1.15em 1.25em; }
.page__title {
  font-family: "Newsreader Variable", Georgia, serif;
  font-weight: 520; font-size: 1.42em; letter-spacing: -.015em; line-height: 1.1;
  margin-bottom: .45em;
}
.page__text {
  font-family: "Newsreader Variable", Georgia, serif;
  font-size: .98em; line-height: 1.5; color: var(--testo-2);
}
.caret {
  display: inline-block; width: 1.5px; height: 1.05em; margin-left: 1px;
  background: var(--testo); vertical-align: -.16em;
}

.bar {
  display: flex; align-items: center; justify-content: space-between; gap: .8em;
  padding: .7em .75em .7em 1.15em;
  border-top: 1px solid var(--linea);
  background: #fbfbfc;
}

/* the status: two rows in the same cell, only one visible; out of the flow so the hidden one never widens anything */
.status {
  position: relative; flex: 1 1 auto; min-width: 0;
  height: 1.3em; overflow: hidden;
  font-size: .74em; color: var(--testo-3);
}
.status__row { position: absolute; left: 0; top: 0; line-height: 1.3em; white-space: nowrap; }
.sep { color: var(--testo-3); }
.time { display: inline-flex; color: var(--accento); font-weight: 560; font-variant-numeric: tabular-nums; }
.time i {
  position: relative; display: inline-block; font-style: normal;
  overflow: hidden; height: 1.3em; vertical-align: top;
}
.time i b { display: block; font-weight: inherit; }

/* the pill */
.pill {
  position: relative; flex: none;
  height: 2.6em; padding: 0 1em;
  border-radius: 999px;
  background: var(--pillola); color: #fff;
  box-shadow: 0 8px 18px -10px rgba(var(--ombra), .6), inset 0 1px 0 rgba(255,255,255,.14);
  overflow: hidden;
  outline: none;
}
.pill:focus-visible { box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--pillola); }
.pill::after {
  /* a soft top light on the ink */
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(180deg, rgba(255,255,255,.09), rgba(255,255,255,0) 55%);
}
.pill__face { position: relative; display: flex; align-items: center; gap: .5em; height: 100%; }

.cloud { width: 1.25em; height: 1.25em; flex: none; overflow: visible; }
.cloud path { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.cloud__tick { stroke: #7fe0b8 !important; stroke-dasharray: 1; stroke-dashoffset: 1; }
.cloud__shape { stroke-dasharray: 1; stroke-dashoffset: 0; }

/* the words: all three stacked in one box whose width follows the visible word with a spring */
.pill__words { position: relative; display: block; height: 1.3em; clip-path: inset(0 -3em); font-size: .9em; font-weight: 560; letter-spacing: -.005em; }
.word { position: absolute; left: 0; top: 0; line-height: 1.3em; white-space: nowrap; }

.pill__work { position: absolute; left: 1.1em; right: 1.1em; bottom: .42em; height: 1.5px; overflow: hidden; opacity: 0; border-radius: 2px; background: rgba(255,255,255,.12); }
.pill__work span { position: absolute; left: 0; top: 0; bottom: 0; width: 34%; border-radius: inherit; background: rgba(255,255,255,.85); }

@media (hover: hover) {
  .pill:hover { background: var(--pillola-su); }
}
