:root {
  color-scheme: dark;
  --bg: #121713;
  --panel: #1b211d;
  --ink: #f2ead9;
  --dim: #acb3a7;
  --accent: #ff905c;
  --line: #394039;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 20px;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font:
    16px/1.5 "Inter",
    "Arial",
    sans-serif;
}
header,
main {
  max-width: 1340px;
  margin: auto;
  padding: 0 5%;
}
header {
  height: 78px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-decoration: none;
}
.mark {
  color: var(--accent);
  font-size: 30px;
}
.operator,
.tag,
.eyebrow,
.coordinate,
.strip,
small,
footer,
#used {
  font:
    11px/1.6 "IBM Plex Mono",
    monospace;
  letter-spacing: 0.09em;
}
.operator,
small,
#used {
  color: var(--dim);
}
header button {
  margin-left: auto;
}
a {
  color: inherit;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
select,
input,
textarea {
  background: #242b25;
  color: var(--ink);
  border: 1px solid #4a5249;
  border-radius: 4px;
  padding: 9px 12px;
}
button,
select,
summary {
  cursor: pointer;
}
button:hover,
a:hover,
summary:hover {
  color: var(--accent);
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: #202a22;
  min-height: 310px;
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
}
canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}
.herotext {
  padding: 40px 5%;
}
.eyebrow,
.tag {
  color: var(--accent);
  font-weight: 700;
}
.eyebrow i {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: var(--accent);
  margin-right: 8px;
}
.hero h1 {
  font-size: clamp(55px, 8vw, 118px);
  letter-spacing: -0.085em;
  line-height: 0.95;
  margin: 20px 0;
}
.hero em {
  font-family: Georgia, serif;
  font-weight: 400;
  letter-spacing: -0.09em;
}
.hero p {
  color: #e0e1d3;
  margin: 0;
}
.coordinate {
  position: absolute;
  right: 2%;
  bottom: 4%;
  color: #d6d0ad;
}
.strip,
nav,
footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  gap: 10px;
}
.strip strong {
  color: var(--accent);
}
nav {
  justify-content: flex-start;
  gap: clamp(12px, 3vw, 45px);
  padding: 16px 0;
  flex-wrap: wrap;
}
nav a {
  font-size: 14px;
  text-decoration: none;
}
.grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 16px;
  margin: 22px 0;
}
.panel {
  grid-column: span 5;
  background: var(--panel);
  padding: clamp(18px, 2.5vw, 32px);
  border: 1px solid var(--line);
  min-width: 0;
}
.wide {
  grid-column: span 7;
}
.full {
  grid-column: span 12;
}
h2 {
  font-size: clamp(26px, 3vw, 42px);
  line-height: 1.12;
  letter-spacing: -0.055em;
  margin: 8px 0 18px;
}
.controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.controls button:first-of-type,
#submit {
  background: var(--ink);
  color: #192019;
  border-color: var(--ink);
}
.row,
.story {
  padding: 13px 0;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.row strong,
.story span {
  flex: 1;
  min-width: 0;
}
.row button {
  padding: 4px 8px;
  font-size: 13px;
}
.story {
  text-decoration: none;
}
.empty {
  color: var(--dim);
  font-size: 14px;
  margin: 20px 0;
}
#timer {
  font: clamp(42px, 5vw, 70px)/1.2 monospace;
  letter-spacing: -0.07em;
  color: var(--accent);
  margin-bottom: 12px;
}
details {
  border-top: 1px solid var(--line);
  margin-top: 18px;
  padding-top: 12px;
}
summary {
  font-size: 14px;
}
textarea {
  resize: vertical;
  width: 100%;
  min-height: 100px;
}
label {
  display: grid;
  gap: 5px;
  margin: 12px 0;
}
dialog {
  width: min(480px, 92vw);
  border: 1px solid #60695c;
  background: #202721;
  color: var(--ink);
  border-radius: 6px;
  padding: 28px;
}
dialog::backdrop {
  background: #080c09dc;
}
#error {
  color: #ffb49e;
}
#status:not(:empty) {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: #18211b;
  padding: 12px 18px;
  border-radius: 4px;
  z-index: 5;
}
footer {
  color: var(--dim);
  margin-bottom: 25px;
}
.panel > small {
  display: block;
  margin-top: 14px;
}
.row.done strong {
  text-decoration: line-through;
  color: var(--dim);
}
@media (max-width: 720px) {
  header,
  main {
    padding: 0 4%;
  }
  .operator {
    display: none;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .panel,
  .wide,
  .full {
    grid-column: 1;
  }
  .hero {
    min-height: 245px;
  }
  .herotext {
    padding: 24px;
  }
  .coordinate {
    font-size: 9px;
  }
  .strip {
    font-size: 10px;
  }
  .hero p {
    max-width: 68%;
  }
  .brand {
    font-size: 14px;
  }
  header {
    height: 64px;
    gap: 8px;
  }
  header button {
    font-size: 13px;
  }
  .row {
    flex-wrap: wrap;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
#fields img {
  display: block;
  max-width: 100%;
  max-height: 50vh;
  margin-top: 12px;
  object-fit: contain;
}
#fields pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  max-height: 45vh;
  overflow: auto;
}
dialog h2 {
  overflow-wrap: anywhere;
}
:root {
  --bg: #141a18;
  --panel: #1d2521;
  --ink: #eeeae1;
  --dim: #98a69d;
  --accent: #d9b886;
  --line: #344038;
}
body {
  font-family: "Inter", Arial, sans-serif;
  font-size: 14px;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 224px;
  padding: 34px 20px 20px;
  border-right: 1px solid var(--line);
  background: var(--bg);
  z-index: 4;
  display: flex;
  flex-direction: column;
}
.brand {
  font-size: 20px;
  line-height: 1.05;
  letter-spacing: 0.06em;
  align-items: flex-start;
}
.brandmark {
  font:
    italic 52px/0.85 Georgia,
    serif;
  color: var(--accent);
  letter-spacing: -0.12em;
  margin-right: 5px;
}
.brandcaption {
  display: block;
  color: var(--dim);
  font: 8px/1.6 monospace;
  letter-spacing: 0.16em;
  margin-top: 12px;
}
.navlabel {
  font: 9px monospace;
  letter-spacing: 0.16em;
  color: var(--dim);
  margin: 45px 12px 12px;
}
.sidebar nav {
  display: flex;
  flex-direction: column;
  gap: 5px;
  border: 0;
  align-items: stretch;
  padding: 0;
}
.sidebar nav a {
  padding: 12px 14px;
  border-radius: 5px;
  font-size: 13px;
  display: flex;
  gap: 14px;
  align-items: center;
  color: var(--dim);
}
.sidebar nav a.active {
  color: var(--ink);
  background: #303b31;
  border: 1px solid #47513d;
}
.navicon {
  width: 20px;
  font-size: 18px;
}
.sidebottom {
  margin-top: auto;
  display: flex;
  gap: 10px;
  align-items: center;
  border-top: 1px solid var(--line);
  padding-top: 20px;
}
.sidebottom small {
  display: block;
  font: 10px Arial;
  margin-top: 5px;
  letter-spacing: 0;
}
.avatar {
  border-radius: 50%;
  background: #d2b894;
  color: #253024;
  padding: 8px 13px;
  font-family: Georgia;
}
.online {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #a0bc88;
  margin-left: auto;
}
.shell {
  margin-left: 224px;
}
header {
  height: 76px;
  max-width: none;
  border-bottom: 1px solid var(--line);
  padding: 0 36px;
  gap: 10px;
}
.breadcrumb {
  font-size: 11px;
  color: var(--dim);
}
.breadcrumb span {
  margin: 0 12px;
  color: #59685d;
}
.breadcrumb b {
  font-weight: 400;
  color: var(--ink);
}
.headeractions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}
header button {
  font-size: 11px;
  padding: 8px 12px;
  margin: 0;
}
kbd {
  border: 1px solid var(--line);
  padding: 2px 3px;
  margin-left: 14px;
  font-size: 9px;
  color: var(--dim);
}
main {
  padding: 30px 36px;
  max-width: 1600px;
}
.page {
  display: none;
  animation: arrive 0.3s ease-out;
}
.page.active {
  display: block;
}
.pageintro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 28px;
}
.pageintro h1 {
  font:
    400 clamp(26px, 3.2vw, 42px)/1.2 Georgia,
    serif;
  letter-spacing: -0.045em;
  margin: 12px 0 10px;
}
.pageintro p,
.page > p,
.panel p {
  color: var(--dim);
  line-height: 1.7;
}
.tag {
  font-size: 9px;
  letter-spacing: 0.18em;
}
.datepill {
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 10px 15px;
  font: 9px monospace;
  white-space: nowrap;
  color: var(--dim);
}
.hero {
  min-height: 290px;
  border-radius: 7px;
  background: #202c24;
}
.herotext {
  padding: 32px 35px;
  width: 65%;
}
.hero h1 {
  font:
    400 clamp(35px, 4.2vw, 62px)/1.03 Georgia,
    serif;
  letter-spacing: -0.05em;
  max-width: 440px;
  margin: 21px 0 15px;
}
.hero p {
  font-size: 12px;
  line-height: 1.7;
  max-width: none;
  color: #d0d4c9;
}
.eyebrow {
  font-size: 8px;
  letter-spacing: 0.17em;
  color: #c7bb94;
}
.primary {
  display: inline-flex;
  gap: 30px;
  align-items: center;
  text-decoration: none;
  background: #e1c79e;
  color: #202a22;
  padding: 11px 15px;
  border-radius: 3px;
  margin-top: 20px;
  font-size: 11px;
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin: 22px 0;
}
.stats > a,
.stats > div {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  padding: 20px;
  background: var(--panel);
  border-radius: 5px;
  text-decoration: none;
}
.stats span {
  font-size: 11px;
  color: var(--dim);
}
.stats strong {
  font:
    32px/1.3 Georgia,
    serif;
  margin: 13px 0 8px;
}
.stats small {
  font-size: 9px;
  letter-spacing: 0;
}
.homegrid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 18px;
}
.panel {
  border-radius: 6px;
  padding: 24px;
}
.sectionhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 20px;
}
.sectionhead h2 {
  font-size: 20px;
  margin: 0;
  font-family: Georgia;
  font-weight: 400;
  letter-spacing: -0.02em;
}
.sectionhead a {
  font-size: 10px;
  color: var(--dim);
  text-decoration: none;
}
.homegrid + .sectionhead {
  margin-top: 30px;
}
.shortcuts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 20px;
}
.shortcuts > a,
.shortcuts > article {
  display: block;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 6px;
  text-decoration: none;
  min-width: 0;
  background: var(--panel);
}
.shortcuts > a > span {
  display: block;
  color: var(--accent);
  font-size: 24px;
  margin-bottom: 18px;
}
.shortcuts strong {
  display: block;
  font-size: 13px;
  font-weight: 500;
}
.shortcuts p {
  font-size: 11px;
  line-height: 1.7;
  color: var(--dim);
  margin-bottom: 0;
}
.page > h2 {
  font:
    400 43px Georgia,
    serif;
  margin: 12px 0 28px;
  letter-spacing: -0.05em;
}
.page > .controls {
  margin-bottom: 24px;
}
.page > .tag {
  margin-top: 10px;
}
.page > small {
  display: block;
  margin-top: 20px;
}
button,
input,
select,
textarea {
  font-size: 12px;
  border-color: var(--line);
  background: var(--panel);
  border-radius: 4px;
  padding: 11px 13px;
}
button:hover {
  border-color: var(--accent);
}
textarea {
  line-height: 1.6;
}
#quickNote {
  min-height: 102px;
  border: 0;
  padding: 0;
  background: transparent;
}
#saveQuick {
  margin-top: 8px;
}
h3 {
  font:
    400 22px Georgia,
    serif;
  margin: 0 0 16px;
}
.toolgrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-top: 28px;
}
.toolgrid .panel {
  grid-column: auto;
}
.toolgrid output {
  display: block;
  color: var(--accent);
  overflow-wrap: anywhere;
  padding: 12px 0;
  font: 15px/1.7 monospace;
}
.filterbar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 20px 0;
}
.filterbar input {
  flex: 1;
  min-width: 140px;
}
.week {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  margin-top: 25px;
}
.week button {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  padding: 16px 6px;
}
.week strong {
  font: 24px Georgia;
}
.week small {
  font-size: 9px;
}
.week button.selected {
  background: #d7bf98;
  color: #202a22;
  border-color: #d7bf98;
}
.week button.selected small {
  color: #374231;
}
.empty {
  border: 1px dashed var(--line);
  border-radius: 5px;
  padding: 30px 20px;
  text-align: center;
  color: var(--dim);
  font-size: 12px;
}
.row {
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 18px;
  border-radius: 5px;
  margin: 8px 0;
  gap: 15px;
}
.row strong {
  font-weight: 500;
}
.row small {
  font-size: 10px;
}
.row button {
  font-size: 10px;
  padding: 7px 9px;
}
.row.done {
  opacity: 0.65;
}
#noteList {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
#noteList .row {
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  margin: 0;
  padding: 22px;
  gap: 10px;
}
#noteList .row strong {
  flex-basis: 100%;
  font: 23px Georgia;
  margin: 10px 0;
}
.noteexcerpt {
  color: var(--dim);
  font-size: 12px;
  line-height: 1.7;
  white-space: pre-wrap;
  width: 100%;
  min-height: 70px;
  overflow-wrap: anywhere;
}
.note-category {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
}
.uploadzone {
  border: 1px dashed #5b6c5b;
  border-radius: 6px;
  padding: 42px 20px;
  text-align: center;
  background: var(--panel);
}
.uploadzone > span {
  display: block;
  font-size: 32px;
  color: var(--accent);
  margin-bottom: 16px;
}
.uploadzone strong {
  font: 24px Georgia;
}
.uploadzone p {
  color: var(--dim);
  font-size: 12px;
}
.uploadzone.dragover {
  background: #354338;
}
#news {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.story {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
  justify-content: space-between;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel);
  min-height: 160px;
}
.story > span {
  font:
    24px/1.3 Georgia,
    serif;
}
.story p {
  color: var(--dim);
  font-size: 12px;
  line-height: 1.7;
  margin: 0;
}
footer {
  border: 0;
  margin-top: 40px;
  font-size: 9px;
}
dialog {
  width: min(620px, 92vw);
  max-height: 85vh;
  box-shadow: 0 20px 100px #0008;
}
#fields input {
  min-width: 0;
}
#fields textarea {
  min-height: 220px;
}
#fields .searchresult {
  display: block;
  width: 100%;
  text-align: left;
  margin: 6px 0;
}
#fields img {
  max-width: 100%;
}
#worldClocks .row {
  padding: 12px;
  margin: 0;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
}
body.light {
  --bg: #eeeae1;
  --panel: #faf7f0;
  --ink: #26362d;
  --dim: #657366;
  --line: #d5dacd;
  --accent: #805d35;
  color-scheme: light;
}
body.light .sidebar nav a.active {
  background: #dce2d3;
  color: #26362d;
  border-color: #ccd4c2;
}
body.light dialog {
  background: var(--panel);
  color: var(--ink);
}
@keyframes arrive {
  from {
    opacity: 0;
    transform: translateY(7px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@media (min-width: 1600px) {
  main {
    padding-top: 45px;
  }
  .hero {
    min-height: 360px;
  }
}
@media (max-width: 1100px) {
  .sidebar {
    width: 190px;
    padding: 28px 16px;
  }
  .shell {
    margin-left: 190px;
  }
  main {
    padding: 25px;
  }
  .stats {
    gap: 8px;
  }
  .stats > a,
  .stats > div {
    padding: 14px;
  }
  .datepill {
    display: none;
  }
  #noteList {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 760px) {
  .sidebar {
    position: static;
    width: auto;
    padding: 18px 16px 0;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .brand {
    font-size: 14px;
    align-items: center;
  }
  .brandmark {
    font-size: 32px;
  }
  .brand br,
  .brandcaption,
  .navlabel,
  .sidebottom {
    display: none;
  }
  .sidebar nav {
    flex-direction: row;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding: 15px 0 10px;
    gap: 6px;
  }
  .sidebar nav a {
    white-space: nowrap;
    padding: 8px 10px;
    gap: 7px;
    font-size: 11px;
  }
  .navicon {
    font-size: 14px;
    width: auto;
  }
  .shell {
    margin: 0;
  }
  header {
    height: 62px;
    padding: 0 16px;
  }
  .breadcrumb {
    font-size: 9px;
  }
  .breadcrumb span {
    margin: 0 5px;
  }
  .headeractions {
    gap: 5px;
  }
  #searchOpen span,
  kbd {
    display: none;
  }
  header button {
    font-size: 10px;
    padding: 8px;
  }
  main {
    padding: 23px 16px;
  }
  .pageintro h1 {
    font-size: 30px;
  }
  .pageintro p {
    font-size: 12px;
  }
  .herotext {
    width: 80%;
    padding: 25px;
  }
  .hero h1 {
    font-size: 42px;
  }
  .hero {
    min-height: 300px;
  }
  .stats {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .homegrid,
  .toolgrid {
    grid-template-columns: 1fr;
  }
  .shortcuts {
    grid-template-columns: 1fr;
  }
  .shortcuts > a {
    padding: 18px;
  }
  .shortcuts > a > span {
    float: left;
    margin: 0 18px 20px 0;
  }
  .week {
    gap: 4px;
  }
  .week button {
    padding: 12px 2px;
  }
  .week small {
    font-size: 8px;
  }
  .week strong {
    font-size: 21px;
  }
  #noteList,
  #news {
    grid-template-columns: 1fr;
  }
  .page > h2 {
    font-size: 36px;
  }
  .panel {
    padding: 20px;
  }
  .row {
    gap: 8px;
  }
  .row strong {
    flex-basis: 65%;
  }
  .hero .coordinate {
    font-size: 8px;
  }
  .week button {
    min-width: 0;
  }
  .filterbar button {
    padding: 9px;
    font-size: 10px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .page {
    animation: none;
  }
}
.homegrid>.panel{grid-column:auto}
@media(max-width:760px){.hero:after{content:"";position:absolute;inset:0;background:linear-gradient(90deg,#18261daa,transparent);z-index:-1}}
