@font-face {
  font-family: 'Satoshi';
  src: url('./fonts/Satoshi-Variable.woff2') format('woff2');
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Erode';
  src: url('./fonts/Erode-Variable.woff2') format('woff2');
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

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

:root {
  --pad: 52px;
  --accent: #88481E;
  --bg: #FAF6F0;
  --surface: #F0EDE7;
  --surface-hover: color-mix(in srgb, #F0EDE7 72%, #D1AB92);
  --text: #542A1B;
  --text-soft: #88481E;
  --text-muted: color-mix(in srgb, #542A1B 68%, #D1AB92);
  --text-faint: color-mix(in srgb, #542A1B 46%, #F0EDE7);
  --border: color-mix(in srgb, #D1AB92 62%, #FAF6F0);
  --border-hover: #D1AB92;
  --selection: color-mix(in srgb, #D1AB92 54%, transparent);
  --header-bg-strong: color-mix(in srgb, var(--bg) 96%, transparent);
  --header-bg-mid: color-mix(in srgb, var(--bg) 76%, transparent);
  --page-w: 1180px;
  --h1: 60px;
  --label: 12px;
  --body-lg: 18px;
  --body: 15px;
  --meta: 13px;
  --footer-bg: #241A12;
  --footer-text: #cfc6ba;
  --footer-text-soft: #f3ede4;
  --footer-text-faint: #8c8177;
  --footer-border: rgba(243, 237, 228, 0.12);
}

html {
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: 'Erode', Georgia, serif;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--selection);
}

.site-header {
  position: static;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 38px var(--pad) 22px;
  background: transparent;
}

.site-nav a,
.page-title,
.entry-title,
.section-label,
.entry-date,
.entry-meta {
  font-family: 'Satoshi', sans-serif;
  letter-spacing: 0;
}

.site-nav {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 28px;
}

.site-nav a {
  position: relative;
  color: #5b5852;
  font-size: 15px;
  font-weight: 400;
  text-decoration: none;
  transition: color 0.18s ease;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 1.5px;
  background: #fff;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s ease;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: #a5a39d;
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after,
.site-nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

.site-nav a:focus-visible,
.back-link:focus-visible,
.text-link:focus-visible {
  outline: none;
  color: #c8c6c0;
}

/* ---------- motion ---------- */
@media (prefers-reduced-motion: no-preference) {
  .page-shell {
    animation: page-in 0.6s cubic-bezier(.22,1,.36,1) both;
  }

  @keyframes page-in {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  /* scroll reveal (reveal.js tags targets with .rv, then .in on entry) */
  html.js-reveal .rv {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.6s ease, transform 0.6s cubic-bezier(.22,1,.36,1);
  }

  html.js-reveal .rv.in {
    opacity: 1;
    transform: none;
  }
}

.page-shell {
  flex: 1 0 auto;
  width: 100%;
  max-width: var(--page-w);
  margin: 0 auto;
  padding: 80px var(--pad) 72px;
}

.page-title {
  max-width: 720px;
  margin-bottom: 24px;
  color: var(--text);
  font-size: var(--h1);
  font-weight: 300;
  line-height: 1.03;
}

.page-title strong {
  font-weight: 700;
}

.page-title--calc {
  max-width: 1000px;
  white-space: nowrap;
}

@media (max-width: 980px) {
  .page-title--calc {
    max-width: 720px;
    white-space: normal;
  }
}

.page-intro {
  max-width: 560px;
  margin-bottom: 44px;
  color: #aaa7a0;
  font-size: var(--body-lg);
  line-height: 1.58;
  text-wrap: pretty;
}

.section-label {
  color: #787570;
  font-size: var(--label);
  font-weight: 500;
  line-height: 1.2;
  text-transform: uppercase;
  user-select: none;
}

.entry {
  max-width: 720px;
  border: 1px solid #181816;
  border-radius: 8px;
  background: #050505;
  padding: 22px;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.entry:hover {
  border-color: #24211e;
  background: #070707;
}

.entry + .entry {
  margin-top: 18px;
}

.entry-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 8px;
}

.entry-title {
  color: #c8c6c0;
  font-size: 17px;
  font-weight: 550;
  line-height: 1.25;
}

.entry-date {
  flex-shrink: 0;
  color: #4a4741;
  font-size: 12px;
  font-weight: 400;
  white-space: nowrap;
}

.entry-meta {
  margin-bottom: 10px;
  color: #68635b;
  font-size: var(--meta);
  line-height: 1.45;
}

.entry-copy,
.note-copy {
  color: #918d85;
  font-size: var(--body);
  line-height: 1.58;
  text-wrap: pretty;
}

.site-footer {
  position: static;
  width: 100%;
  margin-top: 64px;
  padding: 0;
  background: var(--footer-bg);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 32px;
  max-width: var(--page-w);
  margin: 0 auto;
  padding: 56px var(--pad) 0;
}

.footer-brand-name {
  color: var(--footer-text-soft);
  font-family: 'Satoshi', sans-serif;
  font-size: 19px;
  font-weight: 650;
}

.footer-brand-tag {
  max-width: 340px;
  margin-top: 10px;
  color: var(--footer-text-faint);
  font-size: 14px;
  line-height: 1.55;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
}

.footer-nav a {
  color: var(--footer-text);
  font-family: 'Satoshi', sans-serif;
  font-size: 14px;
  font-weight: 400;
  text-decoration: none;
  transition: color 0.18s ease;
}

.footer-nav a:hover,
.footer-nav a:focus-visible,
.footer-nav a[aria-current="page"] {
  color: var(--footer-text-soft);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  max-width: var(--page-w);
  margin: 40px auto 0;
  padding: 20px var(--pad) 30px;
  border-top: 1px solid var(--footer-border);
  color: var(--footer-text-faint);
  font-size: 12px;
  font-weight: 400;
}

@media (max-width: 560px) {
  .footer-inner {
    flex-direction: column;
    gap: 26px;
    padding-top: 44px;
  }
}

/* ---------- books list ---------- */
.book-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-width: 1000px;
}

.book-card {
  display: flex;
  gap: 30px;
  align-items: center;
  border: 1px solid #181816;
  border-radius: 12px;
  background: #050505;
  padding: 26px 32px;
  text-decoration: none;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.book-card:hover,
.book-card:focus-visible {
  border-color: #2c2620;
  background: #080706;
  transform: translateY(-2px);
  outline: none;
}

.book-card:focus-visible {
  border-color: var(--accent);
}

.book-cover {
  flex-shrink: 0;
  width: 116px;
  height: 174px;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: -4px 7px 22px -7px rgba(0,0,0,0.8);
}

.book-info {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 0;
}

.book-name {
  font-family: 'Satoshi', sans-serif;
  font-size: 26px;
  font-weight: 650;
  line-height: 1.16;
  color: #d8d5cf;
}

.book-card:hover .book-name { color: #f1eee8; }

.book-author {
  font-family: 'Satoshi', sans-serif;
  font-size: 15px;
  color: #6c675f;
}

.book-author .yr { color: #4a4741; }

.book-teaser {
  margin-top: 5px;
  color: #837e76;
  font-size: 17px;
  line-height: 1.55;
  text-wrap: pretty;
}

/* dot rating */
.rating {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
}

.rating .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
}

.rating .dot.off {
  background: transparent;
  box-shadow: inset 0 0 0 1px #3a342c;
}

.rating .rnum {
  margin-left: 5px;
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
  color: #5b5750;
}

/* currently-reading pill */
.reading-now {
  display: inline-flex;
  align-items: center;
  margin-top: 6px;
  padding: 6px 13px;
  border: 1px solid rgba(195,149,91,0.32);
  border-radius: 999px;
  background: rgba(195,149,91,0.07);
  font-family: 'Satoshi', sans-serif;
  font-size: 12px;
  font-weight: 550;
  letter-spacing: 0.3px;
  color: #d3ac76;
  width: fit-content;
}

/* did I enjoy this? */
.enjoy {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-top: 6px;
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
}

.enjoy .q { color: #6c675f; }

.enjoy .a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 13px;
  border: 1px solid rgba(195,149,91,0.32);
  border-radius: 999px;
  background: rgba(195,149,91,0.07);
  color: #d3ac76;
  font-weight: 600;
  letter-spacing: 0.3px;
}

.enjoy .a::before {
  content: "✓";
  font-size: 11px;
  opacity: 0.85;
}

/* ---------- single review page ---------- */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 30px;
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
  color: #6c675f;
  text-decoration: none;
  transition: color 0.18s ease;
}

.back-link:hover { color: #c8c6c0; }

.review-hero {
  display: flex;
  gap: 34px;
  align-items: flex-start;
  max-width: 760px;
  margin-bottom: 40px;
  padding-bottom: 36px;
  border-bottom: 1px solid #181816;
}

.review-cover {
  flex-shrink: 0;
  width: 184px;
  height: auto;
  border-radius: 4px;
  box-shadow: -8px 12px 34px -10px rgba(0,0,0,0.85);
  cursor: zoom-in;
  transition: transform 0.18s ease;
}

.review-cover:hover,
.review-cover:focus-visible {
  transform: translateY(-2px);
  outline: none;
}

.review-cover:focus-visible {
  box-shadow: -8px 12px 34px -10px rgba(0,0,0,0.85), 0 0 0 2px var(--accent);
}

/* cover lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5vh 5vw;
  background: rgba(0,0,0,0.86);
  backdrop-filter: blur(7px);
  cursor: zoom-out;
  opacity: 0;
  transition: opacity 0.22s ease;
}

.lightbox.open { opacity: 1; }

.lightbox img {
  max-width: min(560px, 92vw);
  max-height: 90vh;
  width: auto;
  height: auto;
  border-radius: 6px;
  box-shadow: 0 40px 90px -25px rgba(0,0,0,0.9);
  transform: scale(0.94);
  transition: transform 0.26s cubic-bezier(.22,1,.36,1);
}

.lightbox.open img { transform: scale(1); }

.review-meta { padding-top: 6px; }

.review-name {
  font-family: 'Satoshi', sans-serif;
  font-size: 34px;
  font-weight: 700;
  line-height: 1.05;
  color: var(--text);
  margin-bottom: 10px;
}

.review-byline {
  font-family: 'Satoshi', sans-serif;
  font-size: 15px;
  color: #837e76;
  margin-bottom: 18px;
}

.review-byline .yr { color: #57534c; }

.review-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 20px;
}

.review-tags span {
  border: 1px solid #292723;
  color: #827e76;
  font-family: 'Satoshi', sans-serif;
  font-size: 11px;
  line-height: 1;
  padding: 6px 9px;
  border-radius: 4px;
}

.review-body {
  max-width: 640px;
  color: #b4b0a8;
  font-size: 18px;
  line-height: 1.72;
  text-wrap: pretty;
}

.review-body p + p { margin-top: 18px; }

.review-body .pull {
  margin: 26px 0;
  padding-left: 18px;
  border-left: 2px solid var(--accent);
  color: #d4d0c8;
  font-size: 21px;
  font-style: italic;
  line-height: 1.5;
}

/* ---------- inline text links ---------- */
/* Gold is reserved for links that leave the site; internal links use the
   neutral variant below. */
.text-link {
  position: relative;
  display: inline-block;
  margin-top: 14px;
  color: var(--accent);
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.text-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 1.5px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s ease;
}

.text-link:hover::after,
.text-link:focus-visible::after { transform: scaleX(1); }

.text-link.internal {
  color: #a5a39d;
  font-weight: 500;
}

/* ---------- dictionary definition block (inflection page) ---------- */
.define {
  max-width: 560px;
  margin-bottom: 60px;
}

.define-word {
  font-family: 'Erode', Georgia, serif;
  font-size: 62px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.5px;
  color: var(--text);
}

.define-pos {
  margin-top: 8px;
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
  color: #787570;
}

.define-rule {
  width: 92px;
  margin: 18px 0 20px;
  border: none;
  border-top: 2px solid #c8c6c0;
}

.define-sense {
  color: #b4b0a8;
  font-size: 17px;
  line-height: 1.6;
  text-wrap: pretty;
}

.define-sense + .define-sense { margin-top: 8px; }

.define-sense .field {
  color: #787570;
  font-style: italic;
}

.define-eg {
  margin-top: 16px;
  font-size: 15px;
  font-style: italic;
  color: #837e76;
}

@media (max-width: 560px) {
  .define-word { font-size: 44px; }
}

/* ---------- composites index ---------- */
.comp-index {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 1000px;
}

.comp-card {
  display: flex;
  flex-direction: column;
  border: 1px solid #181816;
  border-radius: 12px;
  background: #050505;
  overflow: hidden;
  text-decoration: none;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.comp-card:hover,
.comp-card:focus-visible {
  border-color: #2c2620;
  background: #080706;
  transform: translateY(-2px);
  outline: none;
}

.comp-card:focus-visible {
  border-color: var(--accent);
}

.comp-card-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4 / 3;
  border-bottom: 1px dashed var(--border);
  color: #4a4741;
  font-family: 'Satoshi', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  text-align: center;
  padding: 12px;
  user-select: none;
}

.comp-card-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px 22px 24px;
}

.comp-card-name {
  font-family: 'Satoshi', sans-serif;
  font-size: 19px;
  font-weight: 650;
  line-height: 1.2;
  color: #d8d5cf;
}

.comp-card:hover .comp-card-name { color: #f1eee8; }

.comp-card-desc {
  color: #837e76;
  font-size: 14px;
  line-height: 1.5;
  text-wrap: pretty;
}

@media (max-width: 980px) {
  .comp-index { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .comp-index { grid-template-columns: 1fr; }
}

/* ---------- composites page ---------- */
.comp-section {
  max-width: 760px;
  margin-top: 40px;
  padding-top: 34px;
  border-top: 1px solid #181816;
}

.comp-title {
  font-family: 'Satoshi', sans-serif;
  font-size: 22px;
  font-weight: 650;
  line-height: 1.2;
  color: #d8d5cf;
  margin: 8px 0 14px;
}

.comp-copy {
  max-width: 640px;
  color: #b4b0a8;
  font-size: 16px;
  line-height: 1.7;
  text-wrap: pretty;
}

.comp-copy p + p { margin-top: 14px; }

.photo-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 24px;
}

.photo-slot { margin: 0; }

.photo-slot .frame {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4 / 3;
  border: 1px dashed #24211e;
  border-radius: 8px;
  background: #030303;
  color: #4a4741;
  font-family: 'Satoshi', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  text-align: center;
  padding: 12px;
  user-select: none;
}

.photo-slot img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 8px;
}

.photo-slot figcaption {
  margin-top: 9px;
  color: #57534c;
  font-family: 'Satoshi', sans-serif;
  font-size: 12px;
}

@media (max-width: 560px) {
  .photo-grid { grid-template-columns: 1fr; }
}

/* ---------- reading log (notes.js) ----------
   Right rail beside the review: the centre column stays reserved for the
   finished review, the log reads like marginalia on a quiet timeline. */
.review-layout {
  display: grid;
  grid-template-columns: minmax(0, 640px) minmax(230px, 300px);
  gap: 72px;
  align-items: start;
}

.review-layout .review-body { max-width: none; }

.reading-log .section-label { margin-bottom: 20px; }

.log-entries {
  border-left: 1px solid #1a1917;
}

.log-entry {
  position: relative;
  padding-left: 22px;
}

.log-entry::before {
  content: "";
  position: absolute;
  left: -3px;
  top: 4px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #3d382f;
  transition: background 0.3s ease;
}

.log-entry:hover::before { background: var(--accent); }

.log-entry + .log-entry { margin-top: 30px; }

.log-meta {
  margin-bottom: 8px;
  color: #68635b;
  font-family: 'Satoshi', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.log-body {
  color: #96928a;
  font-size: 14px;
  line-height: 1.62;
  text-wrap: pretty;
}

.log-body p + p { margin-top: 10px; }

@media (max-width: 980px) {
  .review-layout {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .reading-log {
    max-width: 640px;
    padding-top: 36px;
    border-top: 1px solid #181816;
  }
}

@media (max-width: 560px) {
  .book-card { gap: 16px; padding: 14px 16px; }
  .book-cover { width: 62px; height: 93px; }
  .book-name { font-size: 17px; }
  .review-hero { flex-direction: column; gap: 22px; }
  .review-cover { width: 150px; }
  .review-name { font-size: 27px; }
  .review-body { font-size: 16px; }
}

@media (max-height: 780px) and (min-width: 981px) {
  :root {
    --h1: 52px;
    --body-lg: 16px;
    --body: 14px;
    --meta: 12px;
  }

  .page-shell {
    padding-top: 56px;
    padding-bottom: 52px;
  }

  .page-intro {
    margin-bottom: 30px;
    line-height: 1.48;
  }

  .entry {
    padding: 18px;
  }

  .entry-copy,
  .note-copy {
    line-height: 1.5;
  }
}

@media (max-width: 980px) {
  :root {
    --pad: 30px;
    --h1: 48px;
    --body-lg: 17px;
  }

  .page-shell {
    padding-top: 64px;
  }
}

@media (max-width: 560px) {
  :root {
    --pad: 18px;
    --h1: 34px;
    --body-lg: 16px;
    --body: 14px;
  }

  .site-header {
    padding: 24px var(--pad) 18px;
  }

  .site-nav {
    gap: 16px;
  }

  .site-nav a {
    font-size: 13px;
  }

  .page-shell {
    padding-top: 40px;
    padding-bottom: 44px;
  }

  .entry-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .entry {
    padding: 18px;
  }
}

.site-nav a {
  color: var(--text-faint);
}

.site-nav a::after {
  background: var(--accent);
}

.site-nav a:hover,
.site-nav a[aria-current="page"],
.site-nav a:focus-visible,
.back-link:hover,
.back-link:focus-visible,
.text-link.internal {
  color: var(--text-soft);
}

.page-title,
.review-name,
.define-word,
.entry-title,
.book-name,
.book-card:hover .book-name,
.comp-title,
.comp-card-name,
.comp-card:hover .comp-card-name,
.review-body .pull {
  color: var(--text);
}

.page-intro,
.entry-copy,
.note-copy,
.book-teaser,
.review-body,
.define-sense,
.comp-copy,
.comp-card-desc,
.log-body {
  color: var(--text-muted);
}

.section-label,
.entry-date,
.entry-meta,
.book-author,
.book-author .yr,
.rating .rnum,
.enjoy .q,
.back-link,
.review-byline,
.review-byline .yr,
.review-tags span,
.define-pos,
.define-sense .field,
.define-eg,
.photo-slot figcaption,
.comp-card-frame,
.log-meta {
  color: var(--text-faint);
}

.entry,
.book-card,
.comp-card,
.photo-slot .frame {
  border-color: var(--border);
  background: var(--surface);
}

.entry:hover,
.book-card:hover,
.book-card:focus-visible,
.comp-card:hover,
.comp-card:focus-visible {
  border-color: var(--border-hover);
  background: var(--surface-hover);
}

.review-hero,
.comp-section,
.reading-log,
.log-entries,
.item + .item {
  border-color: var(--border);
}

.review-tags span {
  border-color: var(--border-hover);
}

.rating .dot {
  background: var(--accent);
}

.rating .dot.off {
  background: transparent;
  box-shadow: inset 0 0 0 1px var(--border-hover);
}

.reading-now,
.enjoy .a {
  border-color: color-mix(in srgb, var(--accent) 34%, #D1AB92);
  background: color-mix(in srgb, #D1AB92 28%, transparent);
  color: var(--accent);
}

.define-rule {
  border-top-color: var(--accent);
}

.log-entry::before {
  background: var(--border-hover);
}

.log-entry:hover::before {
  background: var(--accent);
}

.photo-slot .frame {
  color: var(--text-faint);
}

/* ---------- resin calculator ---------- */
.calc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.calc-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  padding: 22px;
}

.calc-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.calc-card-title {
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.3px;
  color: var(--text-soft);
  text-transform: uppercase;
}

.calc-remove-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: transparent;
  color: var(--text-faint);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.18s ease, color 0.18s ease;
}

.calc-remove-btn:hover,
.calc-remove-btn:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  outline: none;
}

.calc-layer-output {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
  color: var(--text-muted);
}

.calc-layer-output strong {
  color: var(--text);
  font-weight: 600;
}

.calc-add-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 16px;
  border: 1px dashed var(--border-hover);
  border-radius: 8px;
  background: transparent;
  color: var(--text-soft);
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 16px;
  cursor: pointer;
  transition: border-color 0.18s ease, color 0.18s ease, background 0.18s ease;
}

.calc-add-btn:hover,
.calc-add-btn:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  outline: none;
}

.calc-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.calc-field + .calc-field {
  margin-top: 14px;
}

.calc-field label {
  font-family: 'Satoshi', sans-serif;
  font-size: 13px;
  color: var(--text-muted);
}

.calc-field input {
  font-family: 'Satoshi', sans-serif;
  font-size: 15px;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 9px 11px;
  transition: border-color 0.18s ease;
}

.calc-field input:focus {
  outline: none;
  border-color: var(--accent);
}

.calc-results {
  margin-top: 24px;
  border-top: 1px solid var(--border);
  padding-top: 24px;
}

.calc-results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px 24px;
  margin-bottom: 22px;
}

.calc-stat-label {
  font-family: 'Satoshi', sans-serif;
  font-size: var(--label);
  font-weight: 500;
  color: var(--text-faint);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.calc-stat-value {
  font-family: 'Erode', Georgia, serif;
  font-size: 22px;
  color: var(--text);
}

.calc-final {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.calc-final-card {
  border: 1px solid color-mix(in srgb, var(--accent) 34%, var(--border));
  border-radius: 10px;
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
  padding: 16px 20px;
}

.calc-final-label {
  font-family: 'Satoshi', sans-serif;
  font-size: var(--label);
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 6px;
}

.calc-final-value {
  font-family: 'Erode', Georgia, serif;
  font-size: 30px;
  color: var(--text);
}

.calc-final-value span {
  font-size: 16px;
  color: var(--text-muted);
}

.calc-note {
  margin-top: 18px;
  color: var(--text-faint);
  font-size: 13px;
  line-height: 1.6;
}

@media (max-width: 640px) {
  .calc-grid,
  .calc-final {
    grid-template-columns: 1fr;
  }
}
