/* ============================================================
   CALVUSREX — small-web outpost
   Shared stylesheet. No JavaScript anywhere.
   Fonts via bunny.net (privacy-friendly, no Google).
   ============================================================ */

@import url("https://fonts.bunny.net/css?family=silkscreen:400,700|special-elite:400");

:root {
  --teal-bg:     #3a9d8b;   /* sea-green page background          */
  --teal-deep:   #2f8576;   /* slightly darker teal (footer band) */
  --nav-green:   #0f3a2d;   /* near-black green nav bar           */
  --mint:        #7fc9ab;   /* nav link text                      */
  --mint-hi:     #a7ddc7;   /* nav hover                          */
  --mint-bar:    #57c1a3;   /* teal rules in sidebar headers      */
  --band-gray:   #e8e8e8;   /* textured masthead band             */
  --box-border:  #c7c7c7;   /* thin box outlines                  */
  --ink:         #3b3b3b;   /* body copy                          */
  --ink-strong:  #262626;   /* bold time / strong                 */
  --ink-soft:    #8c8c8c;   /* tagline gray                       */
  --heading-accent: #2f7f72; /* journal/prose heading accents       */
  --link-accent:    #2f6f9e; /* lake-blue inline links/highlights   */
  --link-green:  #5fa477;   /* green inline links                 */
  --footer-ink:  #103f34;   /* dark teal footer text              */

  --frame-w: 880px;
  --avatar-col: 196px;
  --band-green: #c3d0c5;     /* distressed sage-green band base     */

  --tw: "Special Elite", "Courier New", monospace; /* typewriter caps */
  --body: Verdana, Geneva, "DejaVu Sans", sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--teal-bg);
  font-family: var(--body);
  color: var(--ink);
  padding: 62px 16px 8px;
  min-height: 100vh;
}

/* ---- centred card --------------------------------------- */
.frame {
  width: 100%;
  max-width: var(--frame-w);
  margin: 0 auto;
  background: #fff;
  border: 4px solid #000;
  box-shadow: 6px 7px 0 rgba(0, 0, 0, 0.28);
  position: relative;
}

/* ============================================================
   MASTHEAD  (avatar column + nav + textured band)
   ============================================================ */
.masthead {
  position: relative;
}

.avatar-fig {
  position: absolute;
  left: 4px;
  bottom: 0;
  width: 208px;
  height: auto;
  display: block;
  z-index: 3;
  pointer-events: none;
  filter: drop-shadow(2px 3px 2px rgba(0,0,0,.18));
}

/* nav + band span the full masthead; the avatar overlaps them on the left */
.masthead-right {
  margin-left: 0;
}

/* ---- top navigation ------------------------------------- */
.topnav {
  background: var(--nav-green);
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  padding: 0 18px 0 224px;
}

.topnav a {
  font-family: var(--body);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--mint);
  text-decoration: none;
  padding: 4px 2px;
  border-bottom: 2px solid transparent;
  transition: color .12s, border-color .12s;
}
.topnav a:hover { color: var(--mint-hi); }
.topnav a[aria-current="page"] {
  color: #fff;
  border-bottom-color: var(--mint-bar);
}

/* ---- textured band -------------------------------------- */
.band {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  height: 200px;
  padding: 0 16px 0 224px;
  background-color: var(--band-green);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)' opacity='0.5'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='440' height='240'%3E%3Cfilter id='m'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.014' numOctaves='3' seed='7' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23m)' opacity='0.6'/%3E%3C/svg%3E");
  background-size: 120px 120px, 440px 240px;
  background-repeat: repeat, repeat;
  background-blend-mode: multiply, multiply;
  border-top: 1px solid #93a998;
}

.tagline {
  background: #eef0ec;
  border: 1px solid #9fb1a3;
  box-shadow: 1px 1px 0 rgba(0,0,0,.12);
  padding: 10px 20px;
  font-family: var(--tw);
  font-size: 13px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #6f7d72;
  white-space: nowrap;
  text-align: center;
}

.logo-box {
  background: #fff;
  border: 3px solid #000;
  box-shadow: 4px 5px 0 rgba(0, 0, 0, 0.30);
  padding: 6px 26px 12px;
}

.logo-box .logo {
  font-family: "Silkscreen", monospace;
  font-weight: 700;
  font-size: 60px;
  line-height: 1;
  letter-spacing: 2px;
  color: #9fcbb8;
  text-shadow:
     2px 0   0 #4f7d6b,
     4px 2px 0 #3b6151,
     6px 4px 0 #2c4a3e,
     8px 6px 0 rgba(0,0,0,.35);
  white-space: nowrap;
  display: block;
}

/* ============================================================
   MAIN  (sidebar + content)
   ============================================================ */
.main {
  display: flex;
  align-items: flex-start;
  gap: 34px;
  padding: 40px 34px 60px;
}

/* ---- sidebar -------------------------------------------- */
.sidebar {
  flex: 0 0 252px;
  width: 252px;
  display: flex;
  flex-direction: column;
  gap: 26px;
}

.panel {
  border: 1px solid var(--box-border);
  background: #fff;
  padding: 0 0 16px;
}

/* section header: long teal rule, spaced caps label, short rule */
.panel-head {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 13px 14px 10px;
}
.panel-head .rule {
  height: 4px;
  background: var(--mint-bar);
  flex: 1 1 auto;
}
.panel-head .rule.short { flex: 0 0 18px; }
.panel-head h2 {
  margin: 0;
  font-family: var(--tw);
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--ink-strong);
  white-space: nowrap;
}

.panel-body { padding: 4px 16px 0; }

/* what's new -> twtxt feed */
.twtxt { margin: 0; }
.twt {
  font-family: "Courier New", monospace;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--ink);
  padding: 9px 0;
  border-bottom: 1px dotted #d8d8d8;
}
.twt:last-child { border-bottom: 0; }
.twt time {
  display: block;
  color: var(--link-green);
  font-size: 11px;
  letter-spacing: .5px;
  margin-bottom: 3px;
}
.twt a { color: var(--link-accent); }
.panel-foot {
  margin-top: 10px;
  padding-top: 8px;
  font-family: "Courier New", monospace;
  font-size: 11px;
}
.panel-foot a { color: var(--ink-soft); text-decoration: none; }
.panel-foot a:hover { color: var(--link-accent); }

/* archives list */
.archive-list { list-style: none; margin: 0; padding: 0; }
.archive-list li { margin: 0; }
.archive-list a {
  display: block;
  padding: 7px 4px;
  font-size: 12.5px;
  color: var(--link-accent);
  text-decoration: none;
  border-bottom: 1px dotted #e0e0e0;
}
.archive-list a:hover { color: var(--ink-strong); background: #f1f6f4; }
.archive-list .yr {
  font-family: var(--tw);
  letter-spacing: 2px;
  color: var(--ink-soft);
  font-size: 11px;
  padding: 10px 4px 3px;
  border: 0;
}

/* connect block (markdown-ish) */
.connect { font-size: 13px; line-height: 1.62; }
.connect p { margin: 0 0 11px; }
.connect a { color: var(--link-accent); text-decoration: none; }
.connect a:hover { text-decoration: underline; }
.connect .row {
  display: block;
  font-size: 12.5px;
  padding: 7px 0;
  border-top: 1px dotted #e0e0e0;
}
.connect .row .k {
  display: block;
  font-family: var(--tw);
  letter-spacing: 1px;
  color: var(--link-green);
  text-transform: uppercase;
  font-size: 11px;
  line-height: 1.2;
  margin-bottom: 2px;
}
.connect .row a {
  display: block;
  overflow-wrap: anywhere;
}

/* ---- content area --------------------------------------- */
.content { flex: 1 1 auto; min-width: 0; }

/* "MY JOURNAL" header styled like the sidebar headers */
.content-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 22px;
}
.content-head .rule {
  height: 4px;
  background: var(--mint-bar);
  flex: 1 1 auto;
}
.content-head .rule.short { flex: 0 0 26px; }
.content-head h1 {
  margin: 0;
  font-family: var(--tw);
  font-size: 19px;
  font-weight: 400;
  letter-spacing: 6px;
  text-transform: uppercase;
  color: var(--ink-strong);
  white-space: nowrap;
}

/* journal entries */
.entry { margin: 0 0 30px; }
.entry-date {
  font-family: var(--body);
  font-weight: 700;
  font-size: 15px;
  color: var(--heading-accent);
  margin: 0 0 12px;
}
.entry .time {
  font-weight: 700;
  color: var(--ink-strong);
  font-size: 14px;
  display: block;
  margin-bottom: 4px;
}
.entry-title {
  margin: 0 0 12px;
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.35;
  color: var(--ink-strong);
}
.entry-title a { color: var(--ink-strong); }
.entry p {
  font-size: 14px;
  line-height: 1.62;
  color: var(--ink);
  margin: 0 0 15px;
  max-width: 62ch;
  text-wrap: pretty;
}
.entry p:last-child { margin-bottom: 0; }
.entry a { color: var(--link-accent); text-decoration: none; }
.entry a:hover { text-decoration: underline; }
.entry a.g { color: var(--link-green); }
.entry em { font-style: italic; }

.next-week {
  display: inline-block;
  margin-top: 6px;
  color: var(--link-accent);
  text-decoration: none;
  font-size: 14px;
}
.next-week:hover { text-decoration: underline; }

/* generic prose used on About / Projects / etc. */
.prose { max-width: 64ch; }
.prose p, .prose li {
  font-size: 14px;
  line-height: 1.64;
  color: var(--ink);
  text-wrap: pretty;
}
.prose p { margin: 0 0 15px; }
.prose h3 {
  font-family: var(--body);
  font-weight: 700;
  font-size: 15px;
  color: var(--heading-accent);
  margin: 26px 0 10px;
}
.prose a { color: var(--link-accent); text-decoration: none; }
.prose a:hover { text-decoration: underline; }
.prose ul { margin: 0 0 16px; padding-left: 20px; }
.prose li { margin-bottom: 7px; }
.prose hr { border: 0; border-top: 1px dotted #cfcfcf; margin: 22px 0; }
.lede { color: var(--ink-strong); }

/* project / link cards */
.cards { display: flex; flex-direction: column; gap: 16px; }
.card {
  border: 1px solid var(--box-border);
  padding: 14px 16px;
  background: #fff;
}
.card h3 { margin: 0 0 5px; font-size: 14px; color: var(--ink-strong); }
.card h3 a { color: var(--link-accent); text-decoration: none; }
.card h3 a:hover { text-decoration: underline; }
.card p { margin: 0; font-size: 13px; line-height: 1.55; color: var(--ink); }
.card .meta {
  font-family: "Courier New", monospace;
  font-size: 11px;
  color: var(--link-green);
  letter-spacing: .5px;
  margin-top: 7px;
}

/* ============================================================
   FOOTER  (outside the card, on teal)
   ============================================================ */
.site-foot {
  width: 100%;
  max-width: var(--frame-w);
  margin: 22px auto 0;
  position: relative;
  text-align: center;
  padding: 6px 0 40px;
}
.site-foot .copy {
  font-family: var(--tw);
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--footer-ink);
  font-size: 15px;
  margin: 0 0 10px;
}
.site-foot .fine {
  font-family: var(--tw);
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--footer-ink);
  font-size: 11px;
  opacity: .85;
  margin: 0;
}
.foot-badge {
  position: absolute;
  right: 26px;
  top: -82px;
  width: 122px;
  height: auto;
  z-index: 5;
}

/* ============================================================
   RESPONSIVE  (graceful, not part of the faithful desktop look)
   ============================================================ */
@media (max-width: 760px) {
  .topnav { gap: 14px; flex-wrap: wrap; height: auto; padding: 8px 12px 8px 132px; }
  .topnav a { font-size: 13px; letter-spacing: 1.5px; }
  .avatar-fig { width: 124px; }
  .band { height: auto; padding: 18px 14px 22px 132px; }
  .tagline { position: static; white-space: normal; display: inline-block; margin-bottom: 18px; font-size: 12px; }
  .logo-box { position: static; display: inline-block; }
  .logo-box .logo { font-size: 38px; }
  .main { flex-direction: column; padding: 26px 18px 48px; }
  .sidebar { width: 100%; flex: none; }
  .foot-badge { width: 66px; top: -40px; }
}
