:root {
  color-scheme: dark;
  font-family: "Times New Roman", Times, serif;
  color: #fff;
  background: #00003b;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html {
  min-width: 320px;
  background-color: #00003b;
  background-image:
    radial-gradient(#fff 0 1px, transparent 1px),
    radial-gradient(#66ffff 0 1px, transparent 1px);
  background-position: 4px 7px, 31px 36px;
  background-size: 47px 47px, 71px 71px;
}
body { margin: 0; min-width: 320px; }
a { color: #00ffff; }
.page-shell { width: min(900px, calc(100% - 24px)); margin: 0 auto; }

.site-header { padding: 25px 12px 12px; text-align: center; }
.tiny-stars { color: #ffff00; font-size: 13px; letter-spacing: 7px; }
.site-header h1 {
  margin: 8px 0 0;
  color: #ffff00;
  font: bold clamp(38px, 8vw, 70px)/1 Arial, Helvetica, sans-serif;
  letter-spacing: -.05em;
  text-shadow: 3px 3px #ff00ff, 6px 6px #00aaff;
}
.site-header h1 span { color: #00ffff; font-size: .55em; text-shadow: 2px 2px #ff00ff; }
.tagline { margin: 9px 0 17px; color: #00ff00; font: bold 18px "Comic Sans MS", "Comic Sans", cursive; }
.rainbow-rule { height: 8px; border: 2px outset #ddd; background: linear-gradient(90deg, red, #ff0, #00ff00, #00ffff, #003cff, #f0f); }
.welcome { margin: 18px 0 5px; color: #fff; font: bold 16px Arial, sans-serif; }
.local-clock { display: inline-block; min-width: 335px; margin: 3px 0; padding: 7px 12px; border: 2px inset #ddd; color: #00ff00; background: #000; font: bold 16px "Courier New", monospace; }
.utc-clock { margin: 5px 0 13px; color: #aaa; font: 11px "Courier New", monospace; }
.site-badges { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 9px; color: #fff; font: bold 11px Arial, sans-serif; }
.site-badges > span { padding: 4px 7px; border: 1px solid #888; background: #22227a; }
.site-badges .new-badge { color: #ffff00; background: #e00000; transform: rotate(-4deg); animation: blink .85s steps(2, jump-none) infinite; }
.online i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #00ff00; }

.intro { margin: 12px 0; padding: 13px; border: 3px ridge #c0c0c0; background: #000080; text-align: center; font: 17px "Comic Sans MS", "Comic Sans", cursive; }
.intro p { margin: 3px; }
.intro strong { color: #ffff00; }
.jump-links { padding: 8px; border: 1px dashed #00ffff; background: #000; text-align: center; font: 12px Arial, sans-serif; }
.jump-links span { color: #aaa; }
.jump-links a { margin-left: 12px; }

.republican { margin-top: 34px; overflow: hidden; border: 7px double #1d2551; color: #211a12; background-color: #ead9ad; background-image: repeating-linear-gradient(0deg, rgba(80,50,20,.025) 0, rgba(80,50,20,.025) 1px, transparent 1px, transparent 4px); box-shadow: 8px 8px 0 #000; }
.tricolor { display: grid; grid-template-columns: repeat(3, 1fr); height: 10px; }
.tricolor i:nth-child(1) { background: #183f8c; }
.tricolor i:nth-child(2) { background: #f6edce; }
.tricolor i:nth-child(3) { background: #a82727; }
.republican-header { display: grid; grid-template-columns: 75px 1fr 75px; align-items: center; gap: 14px; padding: 26px 24px 16px; text-align: center; }
.revolutionary-slogan { margin: 0 0 8px; color: #8f2020; font-size: 13px; font-weight: bold; letter-spacing: .14em; text-transform: uppercase; }
.republican h2 { margin: 0; font: bold clamp(34px, 7vw, 57px)/.95 Georgia, serif; text-transform: uppercase; letter-spacing: -.04em; }
.revolutionary-subtitle { margin: 11px 0 0; font-style: italic; }
.revolutionary-art { display: block; width: 75px; height: auto; margin: auto; image-rendering: pixelated; filter: saturate(.9) contrast(1.08) drop-shadow(2px 2px 0 rgba(55,35,15,.28)); }
.revolutionary-art-right { transform: scaleX(-1); }
.republican-ornament { text-align: center; color: #8f2020; font-size: 23px; }
.republican-reading { padding: 22px 40px 28px; text-align: center; }
.reading-label { margin: 0 0 9px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.decimal-time { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: baseline; max-width: 650px; margin: auto; color: #8f2020; font: bold clamp(48px, 10vw, 88px)/1 Georgia, serif; font-variant-numeric: tabular-nums; }
.decimal-time span { text-align: center; }
.decimal-time i { color: #55483a; font-style: normal; font-size: .6em; }
.unit-row { display: grid; grid-template-columns: repeat(3, 1fr); max-width: 650px; margin: 3px auto 0; font-size: 10px; font-weight: bold; letter-spacing: .14em; text-transform: uppercase; }
.day-progress { max-width: 650px; height: 8px; margin: 22px auto 0; border: 2px solid #211a12; }
.day-progress span { display: block; height: 100%; width: 0; background: #8f2020; }
.republican-date { margin: 0 30px; padding: 21px 10px; border-top: 3px double #211a12; border-bottom: 3px double #211a12; text-align: center; }
.republican-date p { margin: 4px; font-size: clamp(20px, 4vw, 29px); font-weight: bold; }
.republican-date p:last-child { color: #8f2020; font-size: 18px; font-variant: small-caps; letter-spacing: .06em; }
.flourish { margin: 6px; }
.republican details { margin: 20px 30px; border: 1px solid #766444; background: rgba(255,255,255,.18); }
.republican summary { padding: 9px; color: #211a12; cursor: pointer; text-align: center; font-weight: bold; font-style: italic; }
.explanation { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; padding: 2px 18px 13px; font-size: 14px; line-height: 1.4; }
.explanation p { margin: 5px 0; }
.republican-footer { padding: 5px 15px 16px; text-align: center; font-size: 10px; text-transform: uppercase; letter-spacing: .12em; }

.divider { padding: 31px 0 25px; color: #ffff00; text-align: center; font: 18px "Comic Sans MS", cursive; }

.internet { overflow: hidden; border: 5px outset #c0c0c0; color: #fff; background: #080822; box-shadow: 8px 8px 0 #000; font-family: Arial, Helvetica, sans-serif; }
.internet-header { min-height: 155px; padding: 26px 27px; display: flex; align-items: center; gap: 25px; background-color: #131376; background-image: linear-gradient(135deg, transparent 48%, rgba(0,255,255,.15) 49%, rgba(0,255,255,.15) 51%, transparent 52%); background-size: 19px 19px; }
.orbit-logo { flex: 0 0 105px; height: 105px; border: 3px solid #00ffff; border-radius: 50%; position: relative; display: grid; place-items: center; box-shadow: 0 0 15px #00ffff, inset 0 0 15px #00ffff; transform: rotate(-12deg); }
.orbit-logo::after { content: ""; position: absolute; width: 135px; height: 38px; border: 2px solid #ff00ff; border-radius: 50%; }
.orbit-logo span { color: #ffff00; font: bold 67px/1 Arial, sans-serif; text-shadow: 3px 3px #ff00ff; transform: rotate(12deg); }
.cyber-kicker { margin: 0 0 4px; color: #00ff00; font: bold 11px "Courier New", monospace; letter-spacing: .1em; }
.internet h2 { margin: 0; color: #fff; font: italic bold clamp(44px, 9vw, 75px)/.9 Arial, sans-serif; letter-spacing: -.07em; text-shadow: 3px 3px #008cff; }
.internet h2 span { color: #ffff00; }
.cyber-subtitle { margin: 12px 0 0; color: #00ffff; font: 10px "Courier New", monospace; }
.ticker { overflow: hidden; padding: 6px 0; border-block: 2px inset #ccc; color: #000; background: #ffff00; white-space: nowrap; font: bold 11px "Courier New", monospace; }
.ticker span { display: inline-block; min-width: 100%; animation: crawl 16s linear infinite; }
.internet-reading { padding: 34px; background-image: linear-gradient(#101033 1px, transparent 1px), linear-gradient(90deg, #101033 1px, transparent 1px); background-size: 16px 16px; }
.lcd-panel { max-width: 720px; margin: auto; padding: 20px 25px 31px; border: 5px ridge #bcbcbc; color: #00ff00; background: #00140c; box-shadow: inset 0 0 24px #000; }
.lcd-panel > p { margin: 0; color: #a8bcae; font: 11px "Courier New", monospace; }
.beat-time { color: #00ff64; font: bold clamp(58px, 12vw, 110px)/1 "Courier New", monospace; letter-spacing: -.1em; text-shadow: 0 0 8px #00ff64; font-variant-numeric: tabular-nums; }
.beat-meta { display: flex; justify-content: space-between; color: #a8bcae; font: 10px "Courier New", monospace; }
.beat-track { height: 11px; margin: 27px 0 13px; border: 2px inset #aaa; position: relative; background: #000; }
.beat-track i { position: absolute; width: 5px; height: 17px; top: -5px; left: 0; background: #ff00ff; box-shadow: 0 0 6px #ff00ff; }
.beat-track span { position: absolute; top: 15px; color: #a8bcae; font: 8px "Courier New", monospace; }
.tick-0 { left: 0; }.tick-1 { left: 25%; transform: translateX(-50%); }.tick-2 { left: 50%; transform: translateX(-50%); }.tick-3 { left: 75%; transform: translateX(-50%); }.tick-4 { right: 0; }
.cyber-info { display: grid; grid-template-columns: 2fr 1fr 1fr; border-top: 3px ridge #c0c0c0; border-bottom: 3px ridge #c0c0c0; background: #000080; }
.cyber-info div { min-height: 79px; padding: 15px; border-right: 2px groove #aaa; }
.cyber-info div:last-child { border: 0; }
.cyber-info span { display: block; margin-bottom: 8px; color: #00ffff; font: 9px "Courier New", monospace; }
.cyber-info strong { font-size: 13px; }
.cyber-info .connected { color: #00ff00; animation: blink 1.2s steps(2, jump-none) infinite; }
.internet details { margin: 18px; border: 2px outset #ccc; background: #202080; }
.internet summary { padding: 9px; cursor: pointer; color: #ffff00; text-align: center; font: bold 12px "Courier New", monospace; }
.internet .explanation { font: 13px/1.45 Arial, sans-serif; }
.internet-footer { padding: 10px; display: flex; justify-content: center; align-items: center; gap: 9px; border-top: 1px solid #555; color: #aaa; font: 9px "Courier New", monospace; }
.netscape { display: inline-grid; place-items: center; width: 23px; height: 23px; color: #fff; background: #14658a; font: bold 18px Georgia, serif; }

.medieval-divider { color: #f3c94d; }
.canonical { padding: 9px; border: 5px ridge #d8b73f; color: #33200e; background: #55206d; box-shadow: 8px 8px 0 #000; }
.manuscript-frame { border: 8px double #8b2626; outline: 3px solid #d8b73f; background-color: #eadcad; background-image: repeating-linear-gradient(0deg, rgba(70,40,10,.025) 0, rgba(70,40,10,.025) 1px, transparent 1px, transparent 5px); }
.canonical-header { padding: 27px 35px 18px; display: flex; align-items: center; justify-content: center; gap: 22px; text-align: center; }
.illuminated-letter { flex: 0 0 90px; height: 104px; display: grid; place-items: center; border: 5px double #e2bd39; color: #e7c64c; background: #254f83; font: bold 82px/1 Georgia, serif; text-shadow: 3px 3px #7e1f27; box-shadow: inset 0 0 0 4px #7e1f27; }
.canonical-header p { margin: 4px 0; color: #7e1f27; font-size: 12px; font-style: italic; }
.canonical-header h2 { margin: 3px 0; color: #33200e; font: bold clamp(35px, 7vw, 57px)/1 Georgia, serif; letter-spacing: -.04em; }
.manuscript-rule { margin: 0 30px; border-block: 2px solid #7e1f27; padding: 5px; color: #7e1f27; text-align: center; }
.canonical-reading { padding: 26px 20px 21px; text-align: center; }
.rubric { margin: 0; color: #7e1f27; font-size: 13px; font-style: italic; }
.canonical-hour { margin: 4px 0 0; color: #55206d; font: bold clamp(51px, 11vw, 96px)/1 Georgia, serif; letter-spacing: -.05em; }
.canonical-latin { margin: 2px 0 7px; color: #7e1f27; font: small-caps bold 18px Georgia, serif; letter-spacing: .14em; }
.canonical-description { margin: 0 0 17px; font-style: italic; }
#canonical-locate { padding: 8px 15px; border: 3px outset #d8b73f; color: #f8e9ae; background: #55206d; cursor: pointer; font: bold 14px Georgia, serif; }
#canonical-locate:hover { background: #702b8d; }
#canonical-locate:disabled { cursor: default; color: #d6c8a0; }
.location-status { min-height: 15px; margin: 9px 0 0; color: #725c3f; font-size: 10px; }
.canonical-table { margin: 0 30px; display: grid; grid-template-columns: repeat(4, 1fr); border-block: 3px double #7e1f27; }
.canonical-table div { padding: 15px 10px; text-align: center; border-right: 1px solid #a58e5e; }
.canonical-table div:last-child { border: 0; }
.canonical-table span { display: block; margin-bottom: 5px; color: #7e1f27; font-size: 9px; font-variant: small-caps; letter-spacing: .12em; }
.canonical-table strong { font-size: 17px; }
.canonical-next { margin: 20px 30px; text-align: center; font-style: italic; }
.canonical-next strong { color: #55206d; }
.canonical details { margin: 0 30px 20px; border: 1px solid #887044; background: rgba(255,255,255,.16); }
.canonical summary { padding: 9px; cursor: pointer; text-align: center; font-weight: bold; font-style: italic; }
.canonical-footer { padding: 4px 10px 15px; color: #7e1f27; text-align: center; font-size: 10px; text-transform: uppercase; letter-spacing: .1em; }

.unix-divider { color: #66ff66; font-family: "Courier New", monospace; }
.unix { overflow: hidden; border: 5px ridge #aaa; color: #8cff72; background: #1e211e; box-shadow: 8px 8px 0 #000; font-family: "Courier New", monospace; }
.terminal-titlebar { height: 30px; padding: 0 9px; display: flex; align-items: center; justify-content: space-between; border-bottom: 3px ridge #aaa; color: #111; background: #bcbcb5; font: bold 11px Arial, sans-serif; }
.terminal-lights { display: flex; gap: 4px; }
.terminal-lights i { width: 10px; height: 10px; border: 1px solid #444; background: #777; }
.terminal-screen { padding: 29px 36px 22px; position: relative; background-color: #061108; background-image: repeating-linear-gradient(0deg, rgba(0,0,0,.16) 0, rgba(0,0,0,.16) 1px, transparent 1px, transparent 3px); text-shadow: 0 0 5px rgba(91,255,91,.45); }
.terminal-screen::after { content: ""; position: absolute; inset: 0; pointer-events: none; box-shadow: inset 0 0 65px #000; }
.terminal-screen > * { position: relative; z-index: 1; }
.unix-header { display: flex; gap: 30px; align-items: center; padding-bottom: 18px; border-bottom: 1px dashed #3c8040; }
.unix-header pre { margin: 0; color: #62dc61; font: bold 11px/1.05 "Courier New", monospace; }
.unix h2 { margin: 0; color: #b8ff9f; font: bold clamp(34px, 7vw, 58px)/1 "Courier New", monospace; text-transform: uppercase; }
.unix-header p { margin: 7px 0 0; color: #64a76a; font-size: 11px; }
.unix-reading { padding: 24px 0; border-bottom: 1px dashed #3c8040; }
.unix-reading p, .terminal-output p { margin: 0 0 5px; color: #6caf70; font-size: 11px; }
.prompt { color: #b8ff9f; }
.unix-seconds { color: #b8ff9f; font: bold clamp(54px, 12vw, 105px)/1 "Courier New", monospace; letter-spacing: -.08em; }
.unix-milliseconds { color: #62dc61; font: bold clamp(27px, 6vw, 48px)/1 "Courier New", monospace; letter-spacing: -.05em; }
.terminal-output { display: grid; grid-template-columns: 1fr 1.5fr 1fr; border-bottom: 1px dashed #3c8040; }
.terminal-output > div { min-width: 0; padding: 18px 13px 18px 0; border-right: 1px dashed #285a2d; }
.terminal-output > div + div { padding-left: 13px; }
.terminal-output > div:last-child { border: 0; }
.terminal-output strong { display: block; overflow-wrap: anywhere; color: #b8ff9f; font-size: 14px; }
.y2038 { margin: 22px 0; padding: 15px; border: 1px solid #ffb000; color: #ffb000; background: #1c1300; text-align: center; text-shadow: 0 0 5px rgba(255,176,0,.4); }
.y2038 p { margin: 0 0 7px; font-size: 11px; animation: blink 1.4s steps(2, jump-none) infinite; }
.y2038 div { font: bold clamp(21px, 5vw, 36px)/1.15 "Courier New", monospace; }
.y2038 small { display: block; margin-top: 7px; color: #ba7f10; }
.unix details { border: 1px solid #3c8040; }
.unix summary { padding: 10px; cursor: pointer; color: #b8ff9f; font-size: 12px; }
.unix .explanation { color: #8bc18c; font-size: 12px; }
.unix-footer { padding-top: 17px; color: #4d8752; font-size: 10px; }
.cursor { animation: blink .9s steps(2, jump-none) infinite; }

.site-footer { padding: 35px 10px 45px; text-align: center; font: 12px Arial, sans-serif; }
.construction { display: inline-block; padding: 8px; border: 3px dashed #000; color: #000; background: repeating-linear-gradient(135deg, #ffcc00 0 12px, #222 12px 24px); font-weight: bold; text-shadow: 1px 1px #ffcc00; }
.construction span { color: #ff0; text-shadow: 1px 1px #000; }
.site-footer > p { margin: 13px 0 5px; }
.counter { display: inline-block; padding: 3px 6px; border: 3px inset #ccc; color: #ff3333; background: #000; font: bold 18px "Courier New", monospace; letter-spacing: 3px; }
.webring { padding: 8px; border: 1px solid #777; background: #000080; }
.copyright { color: #999; font-size: 9px; }

@keyframes blink { 50% { visibility: hidden; } }
@keyframes crawl { from { transform: translateX(100%); } to { transform: translateX(-100%); } }

@media (max-width: 620px) {
  .page-shell { width: min(100% - 12px, 900px); }
  .site-header { padding-inline: 3px; }
  .site-header h1 { font-size: clamp(36px, 12vw, 58px); }
  .local-clock { min-width: 0; width: 100%; font-size: 12px; }
  .jump-links { display: flex; flex-direction: column; gap: 7px; }
  .jump-links a { margin: 0; }
  .republican { border-width: 5px; }
  .republican-header { grid-template-columns: 1fr; padding-inline: 15px; }
  .revolutionary-art { width: 72px; }
  .republican-header { grid-template-columns: 72px 1fr; }
  .revolutionary-art-right { display: none; }
  .republican-reading { padding-inline: 12px; }
  .decimal-time { font-size: clamp(44px, 16vw, 68px); }
  .unit-row { font-size: 8px; }
  .republican-date { margin-inline: 12px; }
  .explanation { grid-template-columns: 1fr; gap: 6px; }
  .internet-header { padding: 22px 14px; gap: 14px; }
  .orbit-logo { flex-basis: 62px; width: 62px; height: 62px; }
  .orbit-logo::after { width: 78px; height: 24px; }
  .orbit-logo span { font-size: 40px; }
  .internet h2 { font-size: clamp(37px, 13vw, 58px); }
  .cyber-subtitle { font-size: 8px; }
  .internet-reading { padding: 17px 10px 24px; }
  .lcd-panel { padding: 15px 12px 29px; border-width: 4px; }
  .beat-time { font-size: clamp(48px, 17vw, 75px); }
  .cyber-info { grid-template-columns: 1fr; }
  .cyber-info div { min-height: auto; border-right: 0; border-bottom: 2px groove #aaa; }
  .internet-footer { flex-wrap: wrap; }
  .canonical { padding: 6px; }
  .manuscript-frame { border-width: 5px; }
  .canonical-header { padding: 21px 12px 15px; gap: 11px; }
  .illuminated-letter { flex-basis: 59px; height: 72px; font-size: 54px; }
  .canonical-header h2 { font-size: clamp(31px, 10vw, 44px); }
  .canonical-header p { font-size: 10px; }
  .manuscript-rule, .canonical-table, .canonical-next, .canonical details { margin-inline: 12px; }
  .canonical-table { grid-template-columns: 1fr 1fr; }
  .canonical-table div:nth-child(2) { border-right: 0; }
  .canonical-table div:nth-child(-n+2) { border-bottom: 1px solid #a58e5e; }
  .canonical-hour { font-size: clamp(47px, 17vw, 73px); }
  .terminal-screen { padding: 22px 14px 18px; }
  .unix-header { gap: 12px; }
  .unix-header pre { display: none; }
  .unix-seconds { font-size: clamp(43px, 15vw, 68px); }
  .unix-milliseconds { font-size: clamp(26px, 9vw, 40px); }
  .terminal-output { grid-template-columns: 1fr; }
  .terminal-output > div, .terminal-output > div + div { padding: 13px 0; border-right: 0; border-bottom: 1px dashed #285a2d; }
  .terminal-output > div:last-child { border-bottom: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .new-badge, .connected, .ticker span, .y2038 p, .cursor { animation: none; }
}
