/* Linear, autumn 1998 — an unofficial period concept.
   One stylesheet, tokens first. See docs/art-direction.md. */

:root {
  --page: #FFFFFF;
  --ink: #000000;
  --ink-soft: #333333;
  --muted: #666666;
  --link: #333399;
  --visited: #663399;
  --link-hover: #CC0000;

  --rail: #666699;
  --rail-dark: #333366;
  --rail-ink: #FFFFFF;
  --rail-hi: #FFFFCC;

  --nav: #000000;
  --nav-ink: #FFFFFF;
  --nav-rule: #666666;

  --panel: #CCCCCC;
  --panel-soft: #DDDDDD;
  --zebra: #EEEEEE;
  --tint: #CCCCFF;
  --note: #FFFFCC;
  --new: #CC0000;
  --plus: #339933;
  --rule: #999999;

  --face: #C0C0C0;
  --bevel-hi: #FFFFFF;
  --bevel-mid: #DFDFDF;
  --bevel-lo: #808080;
  --bevel-dk: #000000;
  --title: #000080;
  --title-ink: #FFFFFF;

  --canvas: 760px;
  --rail-w: 150px;
  --news-w: 180px;
  --gap: 12px;

  --font-body: Verdana, Geneva, Tahoma, sans-serif;
  --font-head: Arial, Helvetica, sans-serif;
  --font-code: "Courier New", Courier, monospace;

  --bevel-out: inset -1px -1px var(--bevel-dk), inset 1px 1px var(--bevel-mid),
               inset -2px -2px var(--bevel-lo), inset 2px 2px var(--bevel-hi);
  --bevel-in: inset 1px 1px var(--bevel-lo), inset -1px -1px var(--bevel-hi),
              inset 2px 2px var(--bevel-dk), inset -2px -2px var(--bevel-mid);

  color-scheme: light;
}

/* ---------- base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html { background: var(--page); }

body {
  margin: 8px;
  background: var(--page);
  color: var(--ink);
  font: 13px/1.45 var(--font-body);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

img, svg { max-width: 100%; height: auto; }

a { color: var(--link); text-decoration: underline; }
a:visited { color: var(--visited); }
a:hover { color: var(--link-hover); }

:focus-visible {
  outline: 2px dotted currentColor;
  outline-offset: 2px;
}

h1, h2, h3, h4 { font-family: var(--font-head); margin: 0; line-height: 1.15; }

p { margin: 0 0 0.8em; }

ul { margin: 0; padding: 0; list-style: none; }

hr {
  border: 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--page);
  margin: 14px 0;
}

code, kbd, .mono { font-family: var(--font-code); font-size: 12px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip {
  position: absolute;
  left: 8px; top: -40px;
  background: var(--note);
  color: var(--ink);
  padding: 4px 8px;
  border: 1px solid var(--ink);
  z-index: 10;
}
.skip:focus { top: 8px; }

/* ---------- shell ---------- */

.canvas { width: var(--canvas); max-width: 100%; }

.masthead { margin-bottom: 0; }

.mast-top {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: end;
  gap: 4px 14px;
  padding: 2px 0 6px;
}

.wordmark {
  font: 900 54px/0.9 "Arial Black", "Arial Bold", Gadget, var(--font-head);
  letter-spacing: -2px;
  color: var(--ink);
  text-decoration: none;
}
.wordmark:visited, .wordmark:hover { color: var(--ink); }

.tagline {
  margin: 0 0 2px;
  font: bold 13px/1.2 var(--font-head);
  color: var(--rail-dark);
}

.dateline {
  margin: 0 0 2px;
  font: bold 12px/1.2 var(--font-head);
  text-align: right;
  white-space: nowrap;
}

/* banded "256-colour" strip under the wordmark */
.strip {
  height: 10px;
  background: linear-gradient(90deg,
    #000000 0 10%, #000033 10% 20%, #333366 20% 30%, #333399 30% 40%,
    #666699 40% 50%, #6666CC 50% 60%, #9999CC 60% 70%, #9999FF 70% 80%,
    #CCCCFF 80% 90%, #FFFFFF 90% 100%);
}

/* black button bar */
.navbar {
  display: flex;
  justify-content: space-between;
  background: var(--nav);
  border-top: 2px solid var(--page);
}
.navbar ul { display: flex; }
.navbar li + li { border-left: 1px solid var(--nav-rule); }
.navbar a {
  display: block;
  padding: 4px 10px 3px;
  color: var(--nav-ink);
  font: bold 11px/1.3 var(--font-head);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
}
.navbar a:visited { color: var(--nav-ink); }
.navbar a:hover { color: var(--rail-hi); text-decoration: underline; }
.navbar a[aria-current="page"] { background: var(--rail); }
.navbar .account { border-left: 1px solid var(--nav-rule); }
.navbar .signup { background: var(--new); }

/* columns */
.layout {
  display: grid;
  grid-template-columns: var(--rail-w) minmax(0, 1fr);
  align-items: start;
}

.content { padding: 14px 0 0 var(--gap); min-width: 0; }

.cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--news-w);
  gap: var(--gap);
  align-items: start;
}

/* ---------- left rail ---------- */

.rail {
  background: var(--rail);
  color: var(--rail-ink);
  padding-bottom: 14px;
  border-bottom-right-radius: 14px;
  align-self: stretch;
}

.rail a { color: var(--rail-ink); }
.rail a:visited { color: var(--rail-ink); }
.rail a:hover { color: var(--rail-hi); }

.rail-buttons { padding-top: 2px; }
.rail-buttons li { margin-top: 2px; }
.rail-buttons a {
  display: block;
  background: var(--nav);
  padding: 2px 8px 2px 6px;
  text-align: right;
  font: bold 11px/1.5 var(--font-head);
  text-decoration: none;
}
.rail-buttons a:hover { text-decoration: underline; }

.rail h2 {
  margin: 14px 8px 4px;
  font: bold 11px/1.2 var(--font-head);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  color: var(--rail-hi);
}

.rail-list { padding: 0 8px; }
.rail-list li { margin: 0 0 3px; }
.rail-list a { font-size: 12px; text-decoration: none; }
.rail-list a:hover { text-decoration: underline; }

.hot {
  margin: 0 8px;
  padding: 6px 7px;
  background: var(--rail-dark);
  border: 1px solid var(--rail-hi);
  font-size: 12px;
}
.hot p { margin: 0; }

.jump { margin: 14px 8px 0; font-size: 11px; }
.jump label { display: block; margin-bottom: 3px; font-weight: bold; }
.jump select {
  width: 100%;
  font: 11px var(--font-body);
  margin-bottom: 4px;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-block;
  padding: 4px 12px 5px;
  font: bold 12px/1.2 var(--font-head);
  text-decoration: none;
  white-space: nowrap;
  border: 0;
  cursor: pointer;
}
.btn-primary,
.btn-primary:visited { background: var(--nav); color: var(--nav-ink); box-shadow: 2px 2px 0 var(--bevel-lo); }
.btn-primary:hover { background: var(--rail-dark); color: var(--rail-hi); }
.btn-plain,
.btn-plain:visited { background: var(--face); color: var(--ink); box-shadow: var(--bevel-out); }
.btn-plain:hover { color: var(--ink); text-decoration: underline; }
.btn-plain:active { box-shadow: var(--bevel-in); }

.new {
  display: inline-block;
  padding: 0 3px;
  background: var(--new);
  color: var(--page);
  font: bold 10px/1.4 var(--font-head);
  letter-spacing: 0.05em;
  vertical-align: 1px;
}

/* ---------- headline block ---------- */

.hero h1 {
  font-size: 27px;
  letter-spacing: -0.5px;
  max-width: 34ch;
}
.lede { margin: 8px 0 6px; font-size: 14px; color: var(--ink-soft); }
.flag { font-weight: bold; margin-bottom: 12px; }

/* ---------- application "screenshot" in NT4 chrome ---------- */

.shot { margin: 0 0 6px; }
.shot figcaption,
.fig-caption {
  font: 11px/1.3 var(--font-body);
  color: var(--muted);
  margin-top: 4px;
}

.win {
  background: var(--face);
  padding: 3px;
  box-shadow: var(--bevel-out);
  font: 11px/1.35 var(--font-body);
  color: var(--ink);
}

.win-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: var(--title);
  color: var(--title-ink);
  font: bold 11px/1 var(--font-head);
  padding: 3px 3px 3px 5px;
}
.win-controls { display: flex; gap: 2px; }
.win-controls span {
  width: 16px; height: 14px;
  background: var(--face);
  box-shadow: var(--bevel-out);
  color: var(--ink);
  font: bold 9px/14px var(--font-body);
  text-align: center;
}
.win-controls span:last-child { margin-left: 2px; }

.win-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 3px 4px;
  border-bottom: 1px solid var(--bevel-lo);
  box-shadow: 0 1px 0 var(--bevel-hi);
  margin-bottom: 3px;
}
.win-toolbar .id { font-family: var(--font-code); font-weight: bold; }

.win-body {
  display: grid;
  grid-template-columns: 124px minmax(0, 1fr) 140px;
  gap: 3px;
}

.pane {
  background: var(--page);
  box-shadow: var(--bevel-in);
  padding: 6px 7px;
  min-width: 0;
}

.pane-label {
  margin: 8px 0 2px;
  color: var(--muted);
  font-size: 10px;
}
.pane-label:first-child { margin-top: 0; }

.tree li { padding: 0 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tree .sel { background: var(--title); color: var(--title-ink); }

.issue p { margin-bottom: 4px; }
.issue .issue-title { font: bold 14px/1.2 var(--font-head); }
.issue code { background: var(--zebra); border: 1px solid var(--panel); padding: 0 2px; font-size: 11px; }
.issue .issue-sub { font: bold 12px/1.2 var(--font-head); margin: 8px 0 3px; }
.pane-props > div + div { margin-top: 8px; }

.activity li { padding: 2px 0; color: var(--ink-soft); }
.activity .who { font-weight: bold; color: var(--ink); }
.activity .when { color: var(--muted); }
.comment {
  margin: 3px 0;
  padding: 3px 5px;
  border: 1px solid var(--rule);
  background: var(--zebra);
  color: var(--ink);
}
.cursor {
  display: inline-block;
  width: 6px; height: 11px;
  background: var(--ink);
  vertical-align: -1px;
  animation: blink 1.06s steps(1) infinite;
}
@keyframes blink { 50% { visibility: hidden; } }

.props li { padding: 1px 0; }
.dot {
  display: inline-block;
  width: 8px; height: 8px;
  border: 1px solid var(--ink);
  margin-right: 4px;
  vertical-align: 0;
}
.dot-progress { background: linear-gradient(90deg, #FFCC00 50%, #FFFFFF 50%); border-radius: 50%; }
.dot-medium { background: var(--rail); }
.tag {
  display: inline-block;
  border: 1px solid var(--ink-soft);
  padding: 0 3px;
  margin: 0 2px 2px 0;
  font-size: 10px;
  background: var(--note);
}

.win-status {
  display: flex;
  gap: 3px;
  margin-top: 3px;
}
.win-status span { box-shadow: inset 1px 1px var(--bevel-lo), inset -1px -1px var(--bevel-hi); padding: 1px 5px; }
.win-status span:first-child { flex: 1; }

/* ---------- customers line ---------- */

.powering {
  margin: 14px 0 0;
  padding: 7px 10px;
  background: var(--panel-soft);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.powering p { margin: 0; font-size: 11px; color: var(--ink-soft); }
.powering ul { display: flex; flex-wrap: wrap; gap: 2px 14px; margin-top: 3px; }
.powering li { font: bold 13px/1.4 var(--font-head); font-variant: small-caps; letter-spacing: 0.04em; }

/* ---------- main column sections ---------- */

.section { margin: 18px 0 0; }
.section-title {
  font-size: 18px;
  color: var(--rail-dark);
  padding-bottom: 3px;
  border-bottom: 2px solid var(--rail);
  margin-bottom: 8px;
}
.section-title .soft { color: var(--muted); font-weight: normal; }

.figs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  margin-top: 10px;
}
.figs > div { padding: 8px 8px 6px; }
.figs > div + div { border-left: 1px solid var(--rule); }
.figs .fig-no { font: 10px/1 var(--font-code); color: var(--muted); letter-spacing: 0.1em; }
.figs img { display: block; margin: 6px auto 6px; height: 72px; width: auto; image-rendering: pixelated; }
.figs h3 { font-size: 13px; margin-bottom: 3px; }
.figs p { font-size: 11px; margin: 0; color: var(--ink-soft); }

/* gray feature panel (Sun, 1998) */
.panel {
  background: var(--panel);
  padding: 10px 12px 4px;
  margin-top: 18px;
}
.panel > h2 {
  font: bold 11px/1 var(--font-head);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 8px;
}

.feature { padding: 4px 0 12px; }
.feature + .feature { border-top: 1px solid var(--bevel-lo); box-shadow: inset 0 1px 0 var(--bevel-mid); padding-top: 12px; }
.feature-head { display: flex; gap: 10px; align-items: flex-start; }
.feature-head img { flex: none; width: 32px; height: 32px; image-rendering: pixelated; }
.feature h3 { font-size: 16px; margin-bottom: 4px; }
.feature p { margin-bottom: 6px; }
.feature .list { font-size: 11px; color: var(--ink-soft); margin-bottom: 8px; }
.feature .list b { color: var(--ink); }
.feature .more { font-weight: bold; }

/* small framed exhibits inside the feature panel */
.exhibit {
  background: var(--page);
  border: 1px solid var(--ink);
  box-shadow: 2px 2px 0 var(--bevel-lo);
  font-size: 11px;
  margin: 0 0 8px;
}
.exhibit-head {
  background: var(--rail-dark);
  color: var(--rail-ink);
  font: bold 11px/1 var(--font-head);
  padding: 3px 6px;
}
.exhibit-body { padding: 6px 8px; }
.exhibit .line { margin: 0 0 4px; }
.exhibit .who { font-weight: bold; }
.exhibit .t { color: var(--muted); font-size: 10px; }
.exhibit .mention { background: var(--tint); }
.exhibit .prompt { font-family: var(--font-code); font-size: 12px; }
.exhibit .reply { margin-top: 4px; padding-left: 12px; }
.exhibit .reply li::before { content: "\25AA\00A0"; }

.gantt { width: 100%; border-collapse: collapse; font-size: 10px; table-layout: fixed; }
.gantt th { font-weight: normal; color: var(--muted); text-align: left; padding: 0 0 3px; border-bottom: 1px solid var(--rule); }
.gantt th:first-child { width: 36%; }
.gantt td { padding: 3px 0; border-bottom: 1px dotted var(--panel); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gantt .bar { position: relative; height: 15px; }
.gantt .bar span {
  position: absolute; top: 2px; height: 11px;
  background: var(--rail); color: var(--page);
  font-size: 9px; line-height: 11px; padding: 0 3px;
  white-space: nowrap; overflow: hidden;
  border: 1px solid var(--ink);
}
.gantt .bar span.alt { background: var(--new); }

.diff {
  margin: 0;
  font: 11px/1.45 var(--font-code);
  white-space: pre-wrap;
  overflow-wrap: break-word;
}
/* one block per source line; wrapped continuations hang under the code, not the +/- */
.diff > span { display: block; padding-left: 4ch; text-indent: -4ch; }
.diff .del { background: #FFCCCC; }
.diff .add { background: #CCFFCC; }
.diff .file { color: var(--muted); padding-left: 0; text-indent: 0; margin-bottom: 2px; }

/* ---------- right news column ---------- */

.news { font-size: 11px; }
.news-head {
  background: var(--nav);
  color: var(--nav-ink);
  font: bold 11px/1 var(--font-head);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 6px;
  margin: 0 0 8px;
}
.news-head + .news-head, .news-block + .news-head { margin-top: 16px; }
.news article { margin-bottom: 10px; }
.news h3 { font-size: 12px; margin-bottom: 2px; }
.news time { display: block; color: var(--muted); font-size: 10px; margin-bottom: 1px; }
.news p { margin: 0; }
.news .all { font-weight: bold; }

.quote { margin: 0 0 12px; padding: 0 0 0 10px; }
.quote blockquote { margin: 0; }
.quote p { font: italic 12px/1.4 Georgia, "Times New Roman", serif; margin-bottom: 3px; }
.quote figcaption { font-size: 10px; color: var(--ink-soft); }
.quote cite { font-style: normal; font-weight: bold; color: var(--ink); }

.note {
  background: var(--note);
  border: 1px solid var(--rule);
  padding: 6px 7px;
}

/* ---------- closing call to action ---------- */

.closer {
  margin: 20px 0 0;
  padding: 12px;
  background: var(--face);
  box-shadow: var(--bevel-out);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.closer h2 { font-size: 18px; }
.closer .actions { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- footer ---------- */

.site-footer {
  margin-top: 22px;
  padding-top: 8px;
  border-top: 1px solid var(--rule);
  text-align: center;
  font-size: 11px;
}
.site-footer p { margin: 0 0 5px; }
.brackets a { white-space: nowrap; }
.footer-group b { color: var(--ink-soft); }
.disclaimer {
  margin: 12px auto 0;
  max-width: 64ch;
  color: var(--muted);
  font-size: 10px;
}

/* ---------- responsive: keep the 1998 canvas, reflow on small screens ---------- */

@media (max-width: 780px) {
  :root { --rail-w: 132px; --news-w: 160px; }
  .canvas { width: auto; }
  .win-body { grid-template-columns: minmax(0, 1fr) 130px; }
  .win-body .pane-tree { display: none; }
}

@media (max-width: 640px) {
  body { margin: 0; }
  .masthead { padding: 6px 8px 0; }
  .mast-top { grid-template-columns: 1fr auto; }
  .tagline { grid-column: 1 / -1; grid-row: 2; }
  .wordmark { font-size: 44px; }

  .navbar { flex-direction: column; margin: 0 -8px; }
  .navbar ul { display: grid; grid-template-columns: repeat(4, 1fr); }
  .navbar .account { grid-template-columns: 1fr 1fr; border-left: 0; border-top: 1px solid var(--nav-rule); }
  .navbar li { border-top: 1px solid var(--nav-rule); }
  .navbar li + li { border-left: 0; }
  .navbar li:not(:nth-child(4n + 1)) { border-left: 1px solid var(--nav-rule); }
  .navbar .account li:nth-child(2) { border-left: 1px solid var(--nav-rule); }
  .navbar a { padding: 8px 4px; text-align: center; }

  .layout { grid-template-columns: minmax(0, 1fr); }
  .content { padding: 12px 12px 0; order: 1; }
  .rail { order: 2; margin-top: 20px; border-radius: 0; padding: 4px 0 14px; }
  .rail-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; padding: 2px; }
  .rail-buttons li { margin: 0; }
  .rail-buttons a { text-align: center; padding: 8px 4px; }
  .rail-list { display: flex; flex-wrap: wrap; gap: 4px 14px; padding: 0 12px; }
  .rail h2 { text-align: left; margin-left: 12px; }
  .hot, .jump { margin-left: 12px; margin-right: 12px; }
  .jump { max-width: 280px; }

  .cols { grid-template-columns: minmax(0, 1fr); }
  .news { border-top: 2px solid var(--ink); padding-top: 12px; }

  .hero h1 { font-size: 23px; }
  .win-body { grid-template-columns: minmax(0, 1fr); }
  .win-body .pane-props { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; }
  .pane-props > div + div { margin-top: 0; }
  .navbar a { letter-spacing: 0.02em; }
  .win-toolbar .count { display: none; }

  .figs { grid-template-columns: minmax(0, 1fr); }
  .figs > div + div { border-left: 0; border-top: 1px solid var(--rule); }
  .figs > div { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 0 10px; align-items: center; }
  .figs img { grid-column: 1; grid-row: 1 / span 3; margin: 0; height: 64px; }
  .figs > div > :not(img) { grid-column: 2; }

  .closer { flex-direction: column; align-items: flex-start; }

  .site-footer { padding: 8px 12px 16px; }
}

@media (max-width: 400px) {
  .navbar a { font-size: 10px; padding: 9px 2px; }
}

@media (prefers-reduced-motion: reduce) {
  .cursor { animation: none; }
}

@media print {
  .navbar, .rail, .jump { display: none; }
  .layout { display: block; }
}

/* gallery notice: unofficial concept */
.concept-bar {
  margin: -8px -8px 8px;
  padding: 3px 8px;
  background: var(--note);
  border-bottom: 1px solid var(--rule);
  font: 11px/1.4 var(--font-body);
  color: var(--ink);
}
.concept-bar a { font-weight: bold; margin-left: 6px; }
@media (max-width: 640px) { .concept-bar { margin: 0 0 6px; } }
