:root {
  --bg-color: #1d2021;       /* Gruvbox Dark 0 */
  --bg-panel: #282828;       /* Gruvbox Dark 1 */
  --bg-sidebar: #151718;     /* Deep slate black (industrial) */
  
  --border-color: #3c3836;   /* Gruvbox Dark 3 */
  --border-color-hover: #fabd2f; /* Gruvbox Gold */
  
  --text-main: #ebdbb2;      /* Gruvbox FG 1 (Cream) */
  --text-title: #fbf1c7;     /* Gruvbox FG 0 (Light Cream) */
  --text-muted: #a89984;     /* Gruvbox Gray */
  
  /* Log Type Colors (Gruvbox Accent palette) */
  --color-meeting: #83a598;    /* Gruvbox Blue */
  --color-decision: #b8bb26;   /* Gruvbox Green */
  --color-shift: #fe8019;      /* Gruvbox Orange */
  --color-experiment: #8ec07c;  /* Gruvbox Aqua */
  --color-thought: #d3869b;     /* Gruvbox Purple */
  
  --accent-gold: #fabd2f;      /* Logo Gold */
  --accent-red: #fb4934;       /* Gruvbox Red */
}

/* Reset & Brutalist Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: var(--bg-color);
  color: var(--text-main);
  font-family: 'Space Grotesk', -apple-system, sans-serif;
  height: 100vh;
  overflow: hidden;
  position: relative;
}

/* Gritty scanline grid background */
body::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 0, 0, 0.08) 0px,
    rgba(0, 0, 0, 0.08) 1px,
    transparent 1px,
    transparent 3px
  );
  pointer-events: none;
  z-index: 1;
}

/* App Layout */
.app-container {
  display: flex;
  height: 100vh;
  width: 100vw;
  position: relative;
  z-index: 2;
}

/* Sidebar Styling - Industrial & Sharp */
.sidebar {
  width: 270px;
  background: var(--bg-sidebar);
  border-right: 2px solid var(--border-color);
  display: flex;
  flex-direction: column;
  padding: 24px;
  flex-shrink: 0;
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 40px;
}

/* Responsive custom logo */
.brand-logo-container {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  box-shadow: 2px 2px 0px #000000;
  border-radius: 8px;
  overflow: hidden;
}

.brand-logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.brand-text h1 {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--text-title);
  line-height: 1.1;
}

.brand-text span {
  font-family: 'VT323', monospace;
  font-size: 14px;
  letter-spacing: 3px;
  color: var(--accent-gold);
}

.nav-menu {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-grow: 1;
}

/* Neo-Brutalist Nav Buttons */
.nav-btn {
  background: var(--bg-panel);
  border: 2px solid var(--border-color);
  color: var(--text-main);
  padding: 12px 16px;
  border-radius: 0; /* Strict 90deg corners */
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  text-align: left;
  box-shadow: 3px 3px 0px #000000;
  transform: translate(0, 0);
  transition: all 0.2s cubic-bezier(0.19, 1, 0.22, 1);
}

.nav-btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0px var(--accent-gold);
  border-color: var(--accent-gold);
  color: var(--text-title);
}

.nav-btn.active {
  background: var(--accent-gold);
  color: #151718;
  border-color: #000000;
  box-shadow: 3px 3px 0px #000000;
  transform: translate(1px, 1px);
}

.nav-btn.active:hover {
  transform: translate(0px, 0px);
  box-shadow: 2px 2px 0px #000000;
}

.nav-btn .icon {
  font-size: 16px;
  display: inline-block;
  width: 20px;
}

.system-status {
  padding-top: 20px;
  border-top: 2px solid var(--border-color);
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Fira Code', monospace;
  font-size: 11px;
  font-weight: bold;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 0; /* Boxy status dot */
  display: inline-block;
}

.status-dot.green {
  background: var(--color-decision);
  box-shadow: 0 0 6px var(--color-decision);
}

.status-text {
  color: var(--text-title);
}

.last-synced-txt {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Main Content Area */
.main-content {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  padding: 32px 40px;
  overflow-y: auto;
  position: relative;
}

.top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  flex-shrink: 0;
  border-bottom: 2px dashed var(--border-color);
  padding-bottom: 16px;
}

/* Streak Banner Brutalist Card */
.streak-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-panel);
  border: 2px solid var(--border-color);
  padding: 6px 14px;
  border-radius: 0;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  box-shadow: 3px 3px 0px #000000;
}

.streak-count {
  font-family: 'VT323', monospace;
  font-size: 24px;
  color: var(--accent-gold);
}

.date-display {
  font-family: 'Fira Code', monospace;
  font-size: 14px;
  color: var(--text-muted);
}

/* Tab panes styling */
.tab-pane {
  display: none;
  flex-direction: column;
  gap: 32px;
  animation: pane-fade 0.25s ease-in-out forwards;
}

.tab-pane.active {
  display: flex;
}

/* Brutalist Panel - Hard outlines, offset solid shadow */
.dashboard-panel {
  background: var(--bg-panel);
  border: 2px solid var(--border-color);
  border-radius: 0;
  padding: 24px;
  box-shadow: 4px 4px 0px #000000;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.dashboard-panel:hover {
  border-color: rgba(250, 189, 47, 0.4);
  box-shadow: 6px 6px 0px #000000;
}

.panel-header {
  margin-bottom: 20px;
  border-left: 4px solid var(--accent-gold);
  padding-left: 12px;
}

.panel-header h2 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-title);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.panel-subtitle {
  font-size: 11px;
  color: var(--text-muted);
}

.flex-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  flex-shrink: 0;
}

/* Brutalist Stat Card */
.stat-card {
  background: var(--bg-panel);
  border: 2px solid var(--border-color);
  border-radius: 0;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 3px 3px 0px #000000;
  transition: all 0.2s cubic-bezier(0.19, 1, 0.22, 1);
}

.stat-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent-gold);
  box-shadow: 5px 5px 0px #000000;
}

.stat-icon {
  font-size: 24px;
  width: 44px;
  height: 44px;
  background: var(--bg-color);
  border: 2px solid var(--border-color);
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stat-icon.purple { color: var(--color-shift); }
.stat-icon.violet { color: var(--accent-gold); }
.stat-icon.magenta { color: var(--color-thought); }
.stat-icon.blue { color: var(--color-meeting); }

.stat-info h3 {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.stat-info p {
  font-family: 'Fira Code', monospace;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-title);
  margin-top: 2px;
}

/* Activity Matrix Heatmap */
.activity-matrix-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.activity-grid {
  display: grid;
  grid-template-columns: repeat(15, 1fr);
  gap: 8px;
  max-width: 900px;
}

.matrix-cell {
  aspect-ratio: 1;
  border-radius: 0;
  position: relative;
  cursor: pointer;
  border: 1px dashed var(--border-color);
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.matrix-cell:hover {
  transform: scale(1.1);
  z-index: 2;
  border: 2px solid var(--accent-gold);
}

/* Matrix cell levels (Gruvbox Gold theme) */
.matrix-cell.level-0 { background: #202224; }
.matrix-cell.level-1 { background: #504945; border: 1px solid var(--border-color); }
.matrix-cell.level-2 { background: #d79921; border: 1px solid #111; }
.matrix-cell.level-3 { background: #fabd2f; border: 1px solid #000; box-shadow: 0 0 8px rgba(250, 189, 47, 0.4); }

/* Missed day indicator */
.matrix-cell.missed::after {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--accent-red);
  position: absolute;
  top: 3px;
  right: 3px;
  box-shadow: 0 0 4px var(--accent-red);
}

.activity-legend {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: var(--text-muted);
}

.legend-cell {
  width: 14px;
  height: 14px;
  border-radius: 0;
  border: 1px solid var(--border-color);
}

/* Intake buttons - Boxy & Industrial */
.logging-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 16px;
}

.log-trigger-btn {
  background: var(--bg-panel);
  border: 2px solid var(--border-color);
  border-radius: 0;
  padding: 16px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  box-shadow: 3px 3px 0px #000000;
  transform: translate(0, 0);
  transition: all 0.2s cubic-bezier(0.19, 1, 0.22, 1);
}

.log-trigger-btn:hover {
  background: var(--bg-sidebar);
  border-color: var(--accent-gold);
  transform: translate(-3px, -3px);
  box-shadow: 6px 6px 0px #000000;
}

.log-trigger-btn:active {
  transform: translate(1px, 1px);
  box-shadow: 2px 2px 0px #000000;
}

.log-trigger-btn .btn-icon {
  font-size: 22px;
}

.log-trigger-btn .btn-lbl {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-title);
  letter-spacing: 0.5px;
}

/* Timeline Feed */
.timeline-feed {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.feed-item {
  background: var(--bg-panel);
  border: 2px solid var(--border-color);
  border-left-width: 6px;
  border-radius: 0;
  padding: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  box-shadow: 3px 3px 0px #000000;
  transform: translate(0, 0);
  transition: all 0.2s cubic-bezier(0.19, 1, 0.22, 1);
}

.feed-item:hover {
  background: var(--bg-sidebar);
  border-color: var(--accent-gold);
  transform: translateX(4px);
  box-shadow: 4px 4px 0px #000000;
}

.feed-item.meeting { border-left-color: var(--color-meeting); }
.feed-item.decision { border-left-color: var(--color-decision); }
.feed-item.shift { border-left-color: var(--color-shift); }
.feed-item.experiment { border-left-color: var(--color-experiment); }
.feed-item.thought { border-left-color: var(--color-thought); }

.item-main {
  display: flex;
  align-items: center;
  gap: 16px;
}

.item-icon {
  font-size: 18px;
}

.item-meta h3 {
  font-size: 14px;
  color: var(--text-title);
  font-weight: 700;
  text-transform: uppercase;
}

.item-meta span {
  font-family: 'Fira Code', monospace;
  font-size: 11px;
  color: var(--text-muted);
}

.type-pill {
  font-family: 'VT323', monospace;
  font-size: 12px;
  letter-spacing: 1px;
  padding: 1px 8px;
  border-radius: 0;
  text-transform: uppercase;
  border: 1px solid transparent;
}

.type-pill.meeting { background: rgba(131, 165, 152, 0.1); color: var(--color-meeting); border-color: rgba(131, 165, 152, 0.2); }
.type-pill.decision { background: rgba(184, 187, 38, 0.1); color: var(--color-decision); border-color: rgba(184, 187, 38, 0.2); }
.type-pill.shift { background: rgba(254, 128, 25, 0.1); color: var(--color-shift); border-color: rgba(254, 128, 25, 0.2); }
.type-pill.experiment { background: rgba(142, 192, 124, 0.1); color: var(--color-experiment); border-color: rgba(142, 192, 124, 0.2); }
.type-pill.thought { background: rgba(211, 134, 155, 0.1); color: var(--color-thought); border-color: rgba(211, 134, 155, 0.2); }

.form-control-search {
  background: var(--bg-sidebar);
  border: 2px solid var(--border-color);
  color: var(--text-main);
  padding: 8px 16px;
  border-radius: 0;
  font-family: inherit;
  font-size: 13px;
  width: 200px;
  outline: none;
}

.form-control-search:focus {
  border-color: var(--accent-gold);
  box-shadow: 2px 2px 0px #000000;
}

.form-control-select {
  background: var(--bg-sidebar);
  border: 2px solid var(--border-color);
  color: var(--text-main);
  padding: 8px 12px;
  border-radius: 0;
  font-family: inherit;
  font-size: 13px;
  outline: none;
}

.form-control-select:focus {
  border-color: var(--accent-gold);
}

.feed-controls {
  display: flex;
  gap: 12px;
}

/* Decisions Tab Feed */
.decision-feed {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.decision-block {
  border: 2px solid var(--border-color);
  background: var(--bg-sidebar);
  border-radius: 0;
  padding: 20px;
  box-shadow: 3px 3px 0px #000000;
}

.decision-block-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px dashed var(--border-color);
  padding-bottom: 12px;
  margin-bottom: 16px;
}

.decision-summary {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-title);
  text-transform: uppercase;
}

.decision-date {
  font-family: 'Fira Code', monospace;
  font-size: 12px;
  color: var(--text-muted);
}

.decision-details {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 13.5px;
}

.detail-row strong {
  color: var(--accent-gold);
  display: inline-block;
  width: 120px;
  font-size: 11px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.certainty-badge {
  font-family: 'VT323', monospace;
  font-size: 13px;
  letter-spacing: 1px;
  padding: 1px 8px;
  border-radius: 0;
  text-transform: uppercase;
  border: 1px solid transparent;
}
.certainty-badge.high { background: rgba(184, 187, 38, 0.1); color: var(--color-decision); border-color: rgba(184, 187, 38, 0.2); }
.certainty-badge.medium { background: rgba(131, 165, 152, 0.1); color: var(--color-meeting); border-color: rgba(131, 165, 152, 0.2); }
.certainty-badge.low { background: rgba(251, 73, 52, 0.1); color: var(--accent-red); border-color: rgba(251, 73, 52, 0.2); }

/* Philosophy Split Layout */
.philosophy-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: stretch;
}

.philosophy-panel {
  display: flex;
  flex-direction: column;
  height: 60vh;
}

.philosophy-content {
  flex-grow: 1;
  overflow-y: auto;
  padding-right: 8px;
}

/* Markdown styling inside Philosophy */
.markdown-body h3 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-title);
  margin-top: 24px;
  margin-bottom: 8px;
  border-left: 4px solid var(--accent-gold);
  padding-left: 8px;
  text-transform: uppercase;
}

.retired .markdown-body h3 {
  border-left-color: var(--accent-red);
}

.markdown-body p {
  font-size: 13px;
  line-height: 1.6;
  margin-bottom: 12px;
  color: var(--text-main);
}

.markdown-body blockquote {
  background: var(--bg-sidebar);
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--border-color-hover);
  padding: 10px 14px;
  margin: 12px 0;
  border-radius: 0;
}

.markdown-body ul {
  padding-left: 20px;
  margin-bottom: 12px;
  font-size: 13px;
}

.markdown-body li {
  margin-bottom: 4px;
}

.markdown-body hr {
  border: none;
  border-top: 2px dashed var(--border-color);
  margin: 20px 0;
}

/* Backup Tab Layout */
.backup-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.backup-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: stretch;
}

.backup-action-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 20px;
  gap: 20px;
  flex-grow: 1;
  justify-content: center;
}

.backup-status-graphic {
  font-size: 64px;
  color: var(--accent-gold);
  filter: drop-shadow(2px 2px 0px #000);
}

.backup-action-body p {
  font-size: 13px;
  color: var(--text-muted);
  max-width: 300px;
  line-height: 1.5;
}

/* Brutalist Buttons */
.action-btn {
  background: var(--accent-gold);
  border: 2px solid #000000;
  color: #151718;
  padding: 12px 24px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  border-radius: 0;
  cursor: pointer;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 3px 3px 0px #000000;
  text-transform: uppercase;
  transition: all 0.15s cubic-bezier(0.19, 1, 0.22, 1);
}

.action-btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0px #000000;
  background: #fcd34d;
}

.action-btn:active {
  transform: translate(1px, 1px);
  box-shadow: 2px 2px 0px #000000;
}

.action-btn-outline {
  background: var(--bg-panel);
  border: 2px solid var(--border-color);
  color: var(--text-title);
  padding: 12px 24px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  border-radius: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 3px 3px 0px #000000;
  text-transform: uppercase;
  transition: all 0.15s cubic-bezier(0.19, 1, 0.22, 1);
}

.action-btn-outline:hover {
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0px var(--accent-gold);
  border-color: var(--accent-gold);
}

.git-sync-body {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 20px 0;
}

.git-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.git-status-message {
  font-family: 'Fira Code', monospace;
  font-size: 11px;
  padding: 12px;
  border-radius: 0;
  background: rgba(0, 0, 0, 0.4);
  border: 2px solid var(--border-color);
  display: none;
}

/* Forms & Inputs */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.form-group label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.form-control {
  background: var(--bg-sidebar);
  border: 2px solid var(--border-color);
  color: var(--text-main);
  padding: 10px 14px;
  border-radius: 0;
  font-family: inherit;
  font-size: 13.5px;
  outline: none;
}

.form-control:focus {
  border-color: var(--accent-gold);
  box-shadow: 3px 3px 0px #000000;
}

.text-area-tall {
  height: 120px;
  resize: vertical;
}

/* Dialog Modals - Heavy Outlines, Flat Shadow backdrop */
.premium-dialog {
  margin: auto;
  border: 3px solid var(--accent-gold);
  background: var(--bg-panel);
  border-radius: 0;
  width: 90%;
  max-width: 600px;
  color: var(--text-main);
  box-shadow: 8px 8px 0px #000000;
  padding: 24px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  max-height: 85vh;
  outline: none;
  opacity: 0;
  transform: translateY(15px);
  transition: all 0.2s cubic-bezier(0.19, 1, 0.22, 1);
}

.premium-dialog[open] {
  opacity: 1;
  transform: translateY(0);
  display: flex;
}

.premium-dialog::backdrop {
  background: rgba(21, 23, 24, 0.85);
}

.dialog-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px dashed var(--border-color);
  padding-bottom: 16px;
  margin-bottom: 20px;
  flex-shrink: 0;
}

.dialog-header h2 {
  font-size: 16px;
  color: var(--text-title);
  font-weight: 700;
  text-transform: uppercase;
}

.close-dialog-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 22px;
  cursor: pointer;
  line-height: 1;
}

.close-dialog-btn:hover {
  color: var(--accent-gold);
}

.dialog-form {
  overflow-y: auto;
  flex-grow: 1;
  padding-right: 6px;
}

.dialog-footer {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 2px dashed var(--border-color);
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.form-err-msg {
  color: var(--accent-red);
  font-size: 12px;
  flex-grow: 1;
}

.form-type-fields {
  display: none;
}

.form-type-fields.active {
  display: block;
}

/* Sub-form Checkboxes */
.sub-form-container {
  background: var(--bg-sidebar);
  border: 2px solid var(--border-color);
  padding: 16px;
  border-radius: 0;
  margin-top: 16px;
  margin-bottom: 16px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-title);
}

.checkbox-label input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent-gold);
  border-radius: 0;
}

.hidden-fields {
  display: none;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 2px dashed var(--border-color);
}

.hidden-fields.active {
  display: block;
}

/* Reader dialog specific */
.reader-dialog {
  max-width: 700px;
}

.reader-body {
  overflow-y: auto;
  flex-grow: 1;
}

.reader-meta {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 20px;
}

.reader-content {
  border-top: 2px dashed var(--border-color);
  padding-top: 20px;
  font-size: 14px;
  line-height: 1.7;
}

.type-badge {
  font-family: 'VT323', monospace;
  font-size: 13px;
  letter-spacing: 1px;
  padding: 2px 10px;
  border-radius: 0;
  text-transform: uppercase;
  font-weight: bold;
  border: 1px solid transparent;
}
.type-badge.meeting { background: rgba(131, 165, 152, 0.1); color: var(--color-meeting); border-color: rgba(131, 165, 152, 0.2); }
.type-badge.decision { background: rgba(184, 187, 38, 0.1); color: var(--color-decision); border-color: rgba(184, 187, 38, 0.2); }
.type-badge.shift { background: rgba(254, 128, 25, 0.1); color: var(--color-shift); border-color: rgba(254, 128, 25, 0.2); }
.type-badge.experiment { background: rgba(142, 192, 124, 0.1); color: var(--color-experiment); border-color: rgba(142, 192, 124, 0.2); }
.type-badge.thought { background: rgba(211, 134, 155, 0.1); color: var(--color-thought); border-color: rgba(211, 134, 155, 0.2); }

.meta-date {
  font-family: 'Fira Code', monospace;
  font-size: 12px;
  color: var(--text-muted);
}

/* Custom Scrollbars */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-sidebar);
}

::-webkit-scrollbar-thumb {
  background: var(--border-color);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-gold);
}

/* Global fullpage noise overlay */
.noise-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.045; /* subtle zine paper grain */
  background: 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.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/svg%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* Animations */
@keyframes pane-fade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Empty placeholder messages */
.empty-msg {
  font-family: 'Fira Code', monospace;
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  padding: 24px;
  border: 2px dashed var(--border-color);
}

/* Responsive adjustments */
@media (max-width: 868px) {
  .app-container {
    flex-direction: column;
  }
  .sidebar {
    width: 100%;
    height: auto;
    border-right: none;
    border-bottom: 2px solid var(--border-color);
    padding: 16px;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
  .brand {
    margin-bottom: 0;
  }
  .nav-menu {
    flex-direction: row;
    flex-grow: 0;
    gap: 8px;
  }
  .nav-btn {
    padding: 8px 12px;
    font-size: 13px;
    box-shadow: 2px 2px 0px #000000;
  }
  .system-status {
    display: none;
  }
  .main-content {
    padding: 20px;
  }
  .philosophy-layout, .backup-layout {
    grid-template-columns: 1fr;
  }
}
