@font-face {
  font-family: 'Code39';
  src: url('fonts/Code39.woff') format('woff');
  font-weight: normal;
  font-style: normal;
}


.barcode-container {
  display: inline-flex;
  flex-direction: column;
  align-items: stretch;
  max-width: 100%;
  margin-top: 2rem;
  padding-top: 1rem;
}

.barcode {
  font-family: 'Code39', monospace;
  font-size: clamp(21px, 12vw, 55px);
  color: var(--text-color);
  font-weight: normal;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
}




@font-face {
  font-family: 'Merchant Copy';
  src: url('fonts/Merchant Copy.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}
@font-face {
  font-family: 'PPMondwest';
  src: url('fonts/PPMondwest-Regular.otf?v=1') format('opentype');
  font-weight: normal;
  font-style: normal;
}
@font-face {
  font-family: 'PPMondwest';
  src: url('fonts/PPMondwest-Regular.otf?v=1') format('opentype');
  font-weight: normal;
  font-style: italic;
}

/* Design Tokens - Receipt Aesthetic */
:root {
  --body-bg: #0b0c10;         /* Pitch Black Desk */
  --bg-color: #f4f4f4;        /* Off-white Thermal Paper */
  --text-color: #1a1a1a;      /* Faded Thermal Black Ink */
  --muted-color: #555555;     /* Faded text */
  --border-color: #1a1a1a;    /* Thermal Black Ink */
  --accent-color: #000000;    /* Pure Black */
  
  --font-monospace: 'Merchant Copy', monospace;
  --font-headings: 'PPMondwest', monospace;
}

/* Reset / Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  border-radius: 0 !important; /* Industrial Precision strict zero border-radius rule */
}

html, body {
  background-color: var(--body-bg);
  color: var(--text-color);
  font-family: var(--font-monospace);
  font-size: 21px; 
  line-height: 1.2;
  text-transform: uppercase;
}

/* Page Wrapper Layout */
.page-wrapper {
  max-width: 450px; 
  margin: 2rem auto;
  padding: 3rem 1.5rem 5rem 1.5rem;
  background-color: var(--bg-color);
  box-shadow: 0 10px 40px rgba(0,0,0,0.8);
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 4rem);
  position: relative;
  -webkit-mask: radial-gradient(6px at 50% 100%, #0000 98%, #000) 0 100% / 12px 12px repeat-x,
                radial-gradient(6px at 50% 0%, #0000 98%, #000) 0 0% / 12px 12px repeat-x,
                linear-gradient(#000 0 0) center/100% calc(100% - 24px) no-repeat;
  mask: radial-gradient(6px at 50% 100%, #0000 98%, #000) 0 100% / 12px 12px repeat-x,
        radial-gradient(6px at 50% 0%, #0000 98%, #000) 0 0% / 12px 12px repeat-x,
        linear-gradient(#000 0 0) center/100% calc(100% - 24px) no-repeat;
}

.page-wrapper::before {
  content: "";
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none;
  z-index: 10;
  opacity: 0.15;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* Dashed Borders Utility */
.dashed-border-bottom {
  border-bottom: 1px dashed var(--border-color);
  padding-bottom: 0.5rem;
  margin-bottom: 0.5rem;
}

.dashed-border-top {
  border-top: 1px dashed var(--border-color);
  padding-top: 0.5rem;
  margin-top: 0.5rem;
}

/* Massive Header Logo */
.massive-logo-container {
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  padding: 1rem 0;
  margin-bottom: 0.5rem;
  text-align: center;
}

.massive-logo {
  font-family: var(--font-headings);
  font-size: 89px; font-weight: bold;
  font-weight: normal;
  font-style: normal;
  text-transform: uppercase;
  letter-spacing: -0.06em;
  color: var(--text-color);
  line-height: 0.8;
  position: relative;
  transform: scaleY(1.4);
  margin: 1.5rem 0;
  white-space: nowrap;
}

.massive-logo::before {
  content: attr(data-text);
  position: absolute;
  left: 4px;
  top: 4px;
  color: transparent;
  -webkit-text-stroke: 1px var(--text-color);
  z-index: -1;
  white-space: nowrap;
}

.header-divider {
  text-align: center;
  font-size: 13px;
  margin: 0.5rem 0;
  overflow: hidden;
  white-space: nowrap;
  letter-spacing: 0.1em;
}

.header-subtitle {
  text-align: center;
  font-family: var(--font-headings);
  font-size: 21px;
  margin-bottom: 0.5rem;
}

/* Receipt Horizontal Nav */
.receipt-nav-horizontal {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-family: var(--font-headings);
  font-size: 21px; /* Fibonacci */
}

.receipt-nav-horizontal .nav-item {
  text-decoration: none;
  color: var(--text-color);
  transition: background-color 0.15s ease, color 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.5rem;
}

.receipt-nav-horizontal .nav-item:hover, .receipt-nav-horizontal .nav-item.active {
  background-color: var(--text-color);
  color: var(--bg-color);
  text-decoration: none;
}

.receipt-nav-horizontal .nav-num {
  font-size: 13px; /* Fibonacci */
  opacity: 0.8;
  font-weight: normal;
}

/* Theme Toggle Button (Integrated into nav) */
.theme-toggle-btn {
  display: none; /* Hide the theme toggle button for physical receipt aesthetic */
}

/* Main Content Area */
.main-content {
  flex: 1;
}

/* Site Footer */
.site-footer {
  margin-top: 5rem;
  padding-top: 1.5rem;
  border-top: 2px dashed var(--border-color);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  text-align: center;
  font-size: 13px;
  color: var(--muted-color);
}

.site-footer a {
  color: var(--muted-color);
  text-decoration: underline;
  transition: color 0.15s ease;
}

.site-footer a:hover {
  color: var(--text-color);
}

/* Responsive Header */
@media (max-width: 540px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .nav-container {
    width: 100%;
    justify-content: space-between;
  }
  
  .theme-toggle-btn {
    margin-left: auto;
  }
  
  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
}

/* Typography & Content styles */
h1 {
  font-family: var(--font-headings);
  font-size: 1.65rem;
  font-weight: normal;
  font-style: italic;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}

h2 {
  font-family: var(--font-headings);
  font-size: 21px;
  font-weight: normal;
  font-style: italic;
  margin-bottom: 0.75rem;
  letter-spacing: 0.08em;
  color: var(--text-color);
}

.max-w-prose {
  max-width: 62ch;
}

.text-foreground {
  color: var(--text-color);
}

.text-muted-foreground {
  color: var(--muted-color);
}

.text-xs {
  font-size: 13px;
}

.text-sm {
  font-size: 21px;
}

.leading-relaxed {
  line-height: 1.625;
}

.font-medium {
  font-weight: 500;
}

.font-light {
  font-weight: 300;
}

/* Links style inside main text */
main a.text-link, .prose a.text-link {
  color: var(--accent-color);
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: color 0.15s ease, opacity 0.15s ease;
}

main a.text-link:hover, .prose a.text-link:hover {
  opacity: 0.8;
}

/* Gap styles */
.flex-col-gap-4 {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.mt-10 {
  margin-top: 2.75rem;
}

.mb-6 {
  margin-bottom: 1.5rem;
}

.py-3 {
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

/* Works page styles */
.works-list {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.work-item {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.work-title-link {
  font-family: var(--font-headings);
  font-weight: normal;
  font-style: italic;
  font-size: 21px;
  color: var(--text-color);
  text-decoration: none;
  display: inline-block;
  align-self: flex-start;
  transition: color 0.15s ease;
  letter-spacing: -0.01em;
}

.work-title-link:hover {
  color: var(--accent-color);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.work-wip-badge {
  font-family: var(--font-headings);
  font-weight: normal;
  font-style: italic;
  font-size: 21px;
  color: var(--text-color);
  display: inline-block;
  align-self: flex-start;
}

.work-meta {
  font-size: 13px;
  color: var(--accent-color);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.15rem;
}

/* Blog list styles */
.divide-y > * + * {
  border-top: 2px dashed var(--border-color);
}

.blog-row {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

@media (min-width: 640px) {
  .blog-row {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 0.25rem;
  }
}

.blog-title-link {
  text-decoration: none;
  font-size: 21px;
  color: var(--text-color);
  transition: color 0.15s ease;
}

.blog-title-link:hover {
  color: var(--accent-color);
}

/* Blog Post Detail Styles */
.blog-post-header {
  margin-bottom: 2rem;
}

.blog-post-header p {
  margin-top: 0.75rem;
}

.prose {
  font-family: var(--font-monospace);
  font-size: 21px;
  line-height: 1.625;
}

.prose p {
  margin-bottom: 1.25rem;
}

.prose img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1.5rem auto;
  border: 1px solid var(--border-color);
}

.prose h2 {
  font-size: 1.35rem;
  margin-top: 2.25rem;
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
}

.prose ul {
  list-style-type: square;
  margin: 1.25rem 0 1.25rem 1.25rem;
}

.prose li {
  margin-bottom: 0.5rem;
}

.prose strong {
  font-weight: 700;
  color: var(--text-color);
}

.prose code {
  background-color: var(--border-color);
  padding: 0.125rem 0.25rem;
  font-family: var(--font-monospace);
  font-size: 13px;
  border: 1px solid rgba(0,0,0,0.05);
}

html.dark .prose code, body.dark .prose code {
  border: 1px solid rgba(255,255,255,0.05);
}

.prose pre {
  background-color: var(--border-color);
  padding: 1rem;
  overflow-x: auto;
  margin: 1.25rem 0;
  border-left: 3px solid var(--accent-color);
}

.prose pre code {
  background-color: transparent;
  padding: 0;
  border: none;
  font-family: var(--font-monospace);
  font-size: 13px;
}

.prose a {
  color: var(--accent-color);
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: opacity 0.15s ease;
}

.prose a:hover {
  opacity: 0.8;
}

/* Status Line — Terminal-like prompt under header */
.status-line {
  font-family: var(--font-monospace);
  font-size: 13px;
  background-color: var(--text-color);
  color: var(--bg-color);
  padding: 0.35rem 0.5rem;
  margin-top: -2rem;
  margin-bottom: 2.75rem;
  letter-spacing: 0.01em;
  display: inline-block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.status-line .prompt-char {
  color: var(--bg-color);
  font-weight: normal;
  margin-right: 0.35rem;
}

.status-line::after {
  content: "█";
  display: inline-block;
  margin-left: 0.25rem;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* /now page styles */
.now-section {
  margin-bottom: 2.5rem;
}

.now-section h2 {
  font-family: var(--font-headings);
  font-size: 21px;
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.08em;
  color: var(--text-color);
  margin-bottom: 0.75rem;
  text-transform: uppercase;
}

.now-section p,
.now-section li {
  color: var(--muted-color);
  font-size: 21px;
  line-height: 1.625;
}

.now-updated {
  font-size: 13px;
  color: var(--muted-color);
  opacity: 0.6;
  margin-bottom: 2.5rem;
  font-style: italic;
}

/* /uses page — Stack table */
.uses-category {
  margin-bottom: 2.5rem;
}

.uses-category h2 {
  font-family: var(--font-headings);
  font-size: 21px;
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.08em;
  color: var(--text-color);
  margin-bottom: 0.75rem;
  text-transform: uppercase;
}

.stack-table {
  width: 100%;
  border-collapse: collapse;
}

.stack-table tr {
  border-bottom: 1px dashed var(--border-color);
}

.stack-table tr:last-child {
  border-bottom: none;
}

.stack-table td {
  padding: 0.5rem 0;
  font-size: 13px;
  vertical-align: top;
}

.stack-table td:first-child {
  color: var(--text-color);
  font-weight: 500;
  white-space: nowrap;
  padding-right: 2rem;
  width: 35%;
}

.stack-table td:last-child {
  color: var(--muted-color);
}

/* Keyboard hint toast */
.kbd-hint {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  font-family: var(--font-monospace);
  font-size: 13px;
  color: var(--muted-color);
  background-color: var(--bg-color);
  border: 1px solid var(--border-color);
  padding: 0.5rem 0.75rem;
  opacity: 0;
  transform: translateY(0.5rem);
  transition: opacity 0.4s ease, transform 0.4s ease;
  pointer-events: none;
  z-index: 100;
}

.kbd-hint.visible {
  opacity: 0.8;
  transform: translateY(0);
}

.kbd-hint kbd {
  font-family: var(--font-monospace);
  font-size: 13px;
  padding: 0.1rem 0.35rem;
  border: 1px solid var(--border-color);
  background-color: var(--border-color);
  color: var(--text-color);
  margin: 0 0.1rem;
}

/* Featured Image Banner in Blog Posts */
.featured-image-banner {
  width: 100%;
  max-height: 25rem;
  object-fit: cover;
  border: 1px solid var(--border-color);
  margin-bottom: 2rem;
  display: block;
}

/* Dynamic Home Blocks styling */
#home-blocks h2 {
  margin-top: 2rem;
  text-transform: uppercase;
}
#home-blocks h2:first-child {
  margin-top: 0.5rem;
}
#home-blocks a {
  color: var(--accent-color);
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: color 0.15s ease, opacity 0.15s ease;
}
#home-blocks a:hover {
  opacity: 0.8;
}
