:root {
  --bg-color: #c8c6c0;
  --panel-bg: rgba(235, 234, 230, 0.85);
  --border-color: rgba(0, 0, 0, 0.08);
  --text-primary: #1e1e1a;
  --text-secondary: #5e5e5a;
  --accent-color: #3b6fd4;
  --whale-accent: #ffffff;
  --success-color: #3b6fd4;
  --tracked-color: #00b0ff;
  --font-family-sans: 'Outfit', sans-serif;
  --font-family-mono: 'Space Mono', monospace;
}

body.charcoal-theme {
  --bg-color: #14140f;
  --panel-bg: rgba(30, 30, 25, 0.85);
  --border-color: rgba(255, 255, 255, 0.08);
  --text-primary: #e2e2da;
  --text-secondary: #8c8c85;
  --accent-color: #3b6fd4;
  --whale-accent: #ffffff;
  --success-color: #3b6fd4;
  --tracked-color: #00e5ff;
}

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

body {
  background-color: var(--bg-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  overflow: hidden;
  height: 100vh;
  width: 100vw;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: background-color 0.4s ease, color 0.4s ease;
}

/* Header & Control Groups */
.app-header {
  position: relative;
  z-index: 10;
  padding: 20px 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.brand-group {
  display: flex;
  flex-direction: column;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand h1 {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.35em;
  color: var(--text-primary);
  transition: color 0.4s ease;
}

.status-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--success-color);
  box-shadow: 0 0 6px var(--success-color);
}

.status-indicator.live {
  animation: blink 2s infinite ease-in-out;
}

.status-indicator.historical-mode {
  background-color: var(--text-secondary);
  box-shadow: none;
  animation: none;
}

@keyframes blink {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

.sub-brand {
  font-size: 0.72rem;
  color: var(--text-secondary);
  letter-spacing: 0.08em;
  margin-top: 2px;
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* Wallet Tracker Bar */
.tracker-bar {
  display: flex;
  align-items: center;
  background-color: rgba(0, 0, 0, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 2px 8px;
  width: 210px;
  transition: border-color 0.2s, background-color 0.2s;
}

body.charcoal-theme .tracker-bar {
  background-color: rgba(255, 255, 255, 0.02);
}

.tracker-bar:focus-within {
  border-color: var(--accent-color);
  background-color: rgba(0, 0, 0, 0.05);
}

#track-address-input {
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.8rem;
  padding: 6px 4px;
  width: 100%;
  outline: none;
}

#track-address-input::placeholder {
  color: var(--text-secondary);
  opacity: 0.7;
}

#clear-track-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 2px 6px;
  display: none;
}

#clear-track-btn:hover {
  color: var(--text-primary);
}

/* Stats Banner */
.stats-banner {
  display: flex;
  gap: 24px;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-item .label {
  font-size: 0.6rem;
  color: var(--text-secondary);
  letter-spacing: 0.12em;
  margin-bottom: 2px;
}

.stat-item .value {
  font-family: var(--font-family-mono);
  font-size: 0.9rem;
  color: var(--text-primary);
  font-weight: 600;
  transition: color 0.4s ease;
}

/* Palette Selector */
.palette-selector-container {
  display: flex;
  align-items: center;
}

.palette-select {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 7px 12px;
  border-radius: 6px;
  cursor: pointer;
  outline: none;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.palette-select:hover {
  border-color: var(--text-secondary);
}

.palette-select option {
  background: #2b2b28; /* Enforce solid dark option backgrounds for dropdown popups */
  color: #f3f3f0;
}

body.warmGray-theme .palette-select option {
  background: #dbdad5;
  color: #222220;
}

/* Ratio Bar inside stats banner */
.ratio-item {
  min-width: 150px;
  justify-content: center;
}

.ratio-bar {
  display: flex;
  height: 8px;
  border-radius: 4px;
  overflow: hidden;
  background-color: var(--border-color);
  margin-top: 4px;
  width: 100%;
}

.ratio-bar .bar-segment {
  height: 100%;
  transition: width 0.4s ease;
}

.ratio-bar .bar-segment.transfers {
  background-color: hsl(190, 80%, 50%);
}

.ratio-bar .bar-segment.swaps {
  background-color: hsl(320, 80%, 55%);
}

.ratio-bar .bar-segment.mints {
  background-color: hsl(145, 75%, 45%);
}

/* Buttons */
#archive-toggle-btn, #theme-toggle-btn {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.4s;
}

#archive-toggle-btn:hover, #theme-toggle-btn:hover {
  background-color: rgba(0, 0, 0, 0.05);
}

body.charcoal-theme #archive-toggle-btn:hover,
body.charcoal-theme #theme-toggle-btn:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

/* Historical View Banner */
.historical-banner {
  position: absolute;
  top: 90px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  display: none;
}

.historical-banner.active {
  display: block;
}

.banner-content {
  background: var(--panel-bg);
  border: 1px solid var(--border-color);
  padding: 10px 20px;
  border-radius: 30px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  font-size: 0.85rem;
}

body.charcoal-theme .banner-content {
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

#return-live-btn {
  background-color: var(--accent-color);
  color: #fff;
  border: none;
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: opacity 0.2s;
}

#return-live-btn:hover {
  opacity: 0.9;
}

/* Sliding Settings & Archive Drawer */
.archive-drawer {
  position: fixed;
  top: 0;
  right: -380px;
  width: 360px;
  height: 100vh;
  background: var(--panel-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-left: 1px solid var(--border-color);
  box-shadow: -10px 0 40px rgba(0, 0, 0, 0.08);
  z-index: 100;
  padding: 30px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
}

.archive-drawer.open {
  right: 0;
}

.drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.drawer-header h2 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

#close-drawer-btn {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  color: var(--text-secondary);
  cursor: pointer;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background-color 0.2s;
}

#close-drawer-btn:hover {
  background-color: rgba(0, 0, 0, 0.05);
  color: var(--text-primary);
}

body.charcoal-theme #close-drawer-btn:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

/* Calendar styling */
.calendar-container {
  display: flex;
  flex-direction: column;
}

.calendar-header {
  margin-bottom: 16px;
  text-align: center;
}

.month-label {
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
}

.calendar-grid-labels {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 0.7rem;
  color: var(--text-secondary);
  font-weight: 600;
  margin-bottom: 8px;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.calendar-day {
  aspect-ratio: 1;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  position: relative;
  background-color: rgba(0, 0, 0, 0.01);
  transition: transform 0.2s, border-color 0.2s, background-color 0.2s;
}

body.charcoal-theme .calendar-day {
  background-color: rgba(255, 255, 255, 0.01);
}

.calendar-day:hover {
  transform: scale(1.05);
  border-color: var(--text-primary);
}

.calendar-day.empty-day {
  cursor: default;
  opacity: 0.15;
  border-style: dashed;
}

.calendar-day.empty-day:hover {
  transform: none;
  border-color: var(--border-color);
}

.calendar-day.active-selected {
  border-color: var(--accent-color);
  background-color: rgba(59, 111, 212, 0.06);
  font-weight: 700;
}

/* Day Mood Dots */
.day-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  position: absolute;
  bottom: 4px;
}

.day-dot.calm { background-color: #3b6fd4; }
.day-dot.active { background-color: #10b981; }
.day-dot.congested { background-color: #ef4444; }

/* Drawer Info */
.drawer-info {
  margin-top: auto;
  border-top: 1px solid var(--border-color);
  padding-top: 20px;
}

.legend-title {
  font-size: 0.72rem;
  color: var(--text-secondary);
  font-weight: 600;
  margin-bottom: 10px;
}

.legend-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.l-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.l-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.l-dot.l-calm { background-color: #3b6fd4; }
.l-dot.l-active { background-color: #10b981; }
.l-dot.l-congested { background-color: #ef4444; }

/* Canvas Area */
.canvas-container {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 5;
  padding: 10px 20px;
  transition: padding-right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.canvas-container.sidebar-open {
  padding-right: 360px;
}

#mosaic-canvas {
  max-width: 100%;
  max-height: 100%;
  display: block;
  border-radius: 4px;
  cursor: crosshair;
}

/* Footer & Legends */
.app-footer {
  position: relative;
  z-index: 10;
  padding: 20px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.legend {
  display: flex;
  gap: 20px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.color-dot {
  width: 10px;
  height: 10px;
  border-radius: 2px;
}

.color-dot.cool { background-color: rgba(59, 111, 212, 0.45); border: 1px solid var(--border-color); box-shadow: 0 1px 2px rgba(0,0,0,0.15); }
.color-dot.hot { background-color: rgba(59, 111, 212, 1); box-shadow: 0 1px 2px rgba(0,0,0,0.15); }
.color-dot.neon-whale {
  background-color: var(--whale-accent);
  border: 1px solid var(--text-secondary);
  box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}
.color-dot.dot-tracked {
  background-color: var(--tracked-color);
  border: 1px solid rgba(0, 0, 0, 0.15);
  box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}

.guide-text {
  font-size: 0.72rem;
  color: var(--text-secondary);
}

/* Hover Tooltip Styling */
.hover-tooltip {
  position: absolute;
  pointer-events: none;
  background: var(--panel-bg);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 10px 14px;
  font-family: var(--font-family-sans);
  color: var(--text-primary);
  font-size: 11px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  opacity: 0;
  transform: translate(-50%, -100%) translateY(-10px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  min-width: 165px;
}

body.charcoal-theme .hover-tooltip {
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.hover-tooltip.visible {
  opacity: 1;
  transform: translate(-50%, -100%) translateY(-15px);
}

.hover-tooltip .tooltip-header {
  font-size: 12px;
  font-weight: 700;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 6px;
  margin-bottom: 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.hover-tooltip .tooltip-header .block-num {
  font-family: var(--font-family-sans);
}

.hover-tooltip .tooltip-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 5px;
}

.hover-tooltip .tooltip-row:last-child {
  margin-bottom: 0;
}

.hover-tooltip .tooltip-row .label {
  opacity: 0.6;
  font-weight: 400;
}

.hover-tooltip .tooltip-row .value {
  font-weight: 600;
}

/* Popover details card styling */
/* Details Sidebar Drawer */
.details-sidebar {
  position: fixed;
  top: 0;
  right: -360px;
  width: 350px;
  height: 100vh;
  background: var(--panel-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-left: 1px solid var(--border-color);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.12);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  z-index: 100;
  display: flex;
  flex-direction: column;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
}

body.charcoal-theme .details-sidebar {
  box-shadow: -10px 0 45px rgba(0, 0, 0, 0.45);
}

.details-sidebar.open {
  right: 0;
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 24px 16px 24px;
  border-bottom: 1px solid var(--border-color);
}

.sidebar-header .header-main {
  display: flex;
  gap: 10px;
  align-items: center;
}

.close-sidebar-btn {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  color: var(--text-secondary);
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background-color 0.2s, color 0.2s;
}

.close-sidebar-btn:hover {
  background-color: rgba(0, 0, 0, 0.05);
  color: var(--text-primary);
}

body.charcoal-theme .close-sidebar-btn:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

/* Visual Subpixel Interactive Bar styling */
.subpixel-inspect-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 20px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 8px;
}

body.charcoal-theme .subpixel-inspect-section {
  background: rgba(255, 255, 255, 0.01);
}

.subpixel-inspect-section .label {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
}

.subpixel-inspect-grid {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  padding: 4px 0;
}

.subpixel-inspect-cell {
  width: 18px;
  height: 18px;
  border-radius: 3px;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.04);
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.subpixel-inspect-cell:hover {
  transform: translateY(-2px) scale(1.15);
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

.sidebar-content {
  flex: 1;
  padding: 24px;
  display: flex;
  flex-direction: column;
}


/* Settings inside Archive Drawer */
.drawer-settings-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-color);
}

.drawer-settings-section h3, .calendar-container h3 {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-top: 0;
  margin-bottom: 12px;
}

.setting-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.setting-item label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.setting-buttons-row {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}

.setting-buttons-row button {
  flex: 1;
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.75rem;
  font-weight: 500;
  padding: 8px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s;
  white-space: nowrap;
}

.setting-buttons-row button:hover {
  border-color: var(--text-secondary);
  background-color: rgba(0, 0, 0, 0.02);
}

body.charcoal-theme .setting-buttons-row button:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

.setting-buttons-row button.active {
  background: var(--text-primary);
  color: var(--bg-color);
  border-color: var(--text-primary);
}

.close-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  background: transparent;
  border: none;
  font-size: 1.3rem;
  color: var(--text-secondary);
  cursor: pointer;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background-color 0.2s, color 0.2s;
}

.close-btn:hover {
  background-color: rgba(0, 0, 0, 0.05);
  color: var(--text-primary);
}

body.charcoal-theme .close-btn:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

/* Card Header */
.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.block-tag {
  font-family: var(--font-family-mono);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-primary);
  background-color: rgba(0, 0, 0, 0.03);
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
}

body.charcoal-theme .block-tag {
  background-color: rgba(255, 255, 255, 0.03);
}

.mood-badge {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 4px 10px;
  border-radius: 20px;
  background-color: rgba(59, 111, 212, 0.12);
  color: var(--accent-color);
}

/* Popover Tab Headers */
.tabs-header {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 16px;
}

.tab-btn {
  flex: 1;
  background: transparent;
  border: none;
  padding: 10px 0;
  font-family: var(--font-family-sans);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  position: relative;
  transition: color 0.2s;
}

.tab-btn:hover {
  color: var(--text-primary);
}

.tab-btn.active {
  color: var(--accent-color);
  font-weight: 600;
}

.tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--accent-color);
}

/* Tab Panes */
.tab-pane {
  display: none;
}

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

.main-stats {
  margin-bottom: 16px;
}

.main-stat .label {
  display: block;
  font-size: 0.7rem;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.main-stat .value-large {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

/* Details Grid */
.details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--border-color);
}

.details-grid.no-border {
  border-top: none;
  padding-top: 0;
}

.detail-cell {
  display: flex;
  flex-direction: column;
}

.detail-cell.full-width {
  grid-column: span 2;
}

.detail-cell .label {
  font-size: 0.65rem;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.detail-cell .value {
  font-size: 0.82rem;
  color: var(--text-primary);
  font-weight: 600;
}

.detail-cell .value.text-success {
  color: #10b981;
}

.hash-text-short {
  font-family: var(--font-family-mono);
  font-size: 0.78rem;
  color: var(--text-primary);
  background-color: rgba(0, 0, 0, 0.02);
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  word-break: break-all;
}

body.charcoal-theme .hash-text-short {
  background-color: rgba(255, 255, 255, 0.02);
}

/* Analyst Graph styling */
.graph-wrapper {
  margin-bottom: 16px;
}

.graph-wrapper .label {
  display: block;
  font-size: 0.65rem;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
  margin-bottom: 6px;
}

#network-canvas {
  background-color: rgba(0, 0, 0, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  display: block;
  width: 100%;
  height: 150px;
}

body.charcoal-theme #network-canvas {
  background-color: rgba(0, 0, 0, 0.2);
}

.compact-grid {
  gap: 10px;
}

/* Copy Hash Block Footer */
.hash-footer {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--border-color);
}

.hash-footer .label {
  display: block;
  font-size: 0.65rem;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.hash-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: rgba(0, 0, 0, 0.02);
  border: 1px solid var(--border-color);
  padding: 6px 10px;
  border-radius: 6px;
}

body.charcoal-theme .hash-container {
  background-color: rgba(0, 0, 0, 0.2);
}

.hash-text {
  font-family: var(--font-family-mono);
  font-size: 0.72rem !important;
  color: var(--text-secondary) !important;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 220px;
}

.copy-btn {
  background: transparent;
  border: none;
  color: var(--accent-color);
  font-size: 0.7rem;
  font-weight: 600;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  transition: background-color 0.2s, color 0.2s;
}

.copy-btn:hover {
  background-color: rgba(59, 111, 212, 0.08);
}

/* Card Footer Link */
.card-footer {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border-color);
}

.explorer-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background-color: rgba(0, 0, 0, 0.02);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  padding: 10px;
  border-radius: 8px;
  transition: background-color 0.2s, border-color 0.2s;
}

body.charcoal-theme .explorer-link {
  background-color: rgba(255, 255, 255, 0.03);
}

.explorer-link:hover {
  background-color: rgba(0, 0, 0, 0.05);
  border-color: rgba(0, 0, 0, 0.15);
}

body.charcoal-theme .explorer-link:hover {
  background-color: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.15);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .app-header {
    padding: 12px 16px;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  
  .brand-group {
    align-items: center;
    text-align: center;
  }
  
  .header-controls {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    width: 100%;
  }
  
  .tracker-bar {
    width: 100%;
  }
  
  .stats-banner {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    width: 100%;
  }
  
  .stat-item {
    background: rgba(0, 0, 0, 0.02);
    border: 1px solid var(--border-color);
    padding: 6px 10px;
    border-radius: 6px;
  }
  
  body.charcoal-theme .stat-item {
    background: rgba(255, 255, 255, 0.02);
  }
  
  .ratio-item {
    grid-column: span 2;
    min-width: 0;
  }
  
  /* Sidebar Drawer adjustments */
  .details-sidebar {
    width: 100% !important;
    height: 50vh !important;
    top: auto !important;
    bottom: 0 !important;
    border-left: none !important;
    border-top: 1px solid var(--border-color) !important;
    transform: translateY(100%);
  }
  
  .details-sidebar.open {
    transform: translateY(0) !important;
  }
  
  .canvas-container.sidebar-open {
    padding-right: 20px !important;
    padding-bottom: 50vh !important;
  }
  
  /* Settings & Archive Drawer */
  .archive-drawer {
    width: 100% !important;
  }
  
  /* Footer adjustments */
  .app-footer {
    flex-direction: column;
    gap: 12px;
    padding: 16px 20px;
    text-align: center;
  }
  
  .legend {
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px 16px;
  }
}

@media (max-width: 480px) {
  .stats-banner {
    grid-template-columns: 1fr;
  }
  
  .ratio-item {
    grid-column: span 1;
  }
  
  .brand h1 {
    font-size: 1.1rem;
    letter-spacing: 0.2em;
  }
  
  .app-header button {
    font-size: 0.68rem;
    padding: 6px 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #details-popover {
    transform: translate(-50%, -50%);
    transition-duration: 0.1s;
  }
  #details-popover:popover-open {
    transform: translate(-50%, -50%);
  }
  .status-indicator.live {
    animation: none;
  }
}

/* Chain Selector */
.chain-selector-container {
  display: flex;
  align-items: center;
}

.chain-select, .sound-profile-select, .ambient-profile-select {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 7px 12px;
  border-radius: 6px;
  cursor: pointer;
  outline: none;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: border-color 0.2s, background-color 0.2s;
}

.chain-select:hover, .sound-profile-select:hover, .ambient-profile-select:hover {
  border-color: var(--text-secondary);
}

.chain-select option, .sound-profile-select option, .ambient-profile-select option {
  background: #2b2b28;
  color: #f3f3f0;
}

body.warmGray-theme .chain-select option, body.warmGray-theme .sound-profile-select option, body.warmGray-theme .ambient-profile-select option {
  background: #dbdad5;
  color: #222220;
}

.chain-select {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 7px 12px;
  border-radius: 6px;
  cursor: pointer;
  outline: none;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: border-color 0.2s, background-color 0.2s;
}

.chain-select:hover {
  border-color: var(--text-secondary);
}

.chain-select option {
  background: #2b2b28;
  color: #f3f3f0;
}

body.warmGray-theme .chain-select option {
  background: #dbdad5;
  color: #222220;
}

/* Export SVG Button */
.export-svg-btn {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: border-color 0.2s, background-color 0.2s;
  white-space: nowrap;
}

.export-svg-btn:hover {
  border-color: var(--text-secondary);
  background-color: rgba(0, 0, 0, 0.02);
}

body.charcoal-theme .export-svg-btn:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

/* Sound Toggler Button */
.sound-toggle-btn {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: border-color 0.2s, background-color 0.2s;
  white-space: nowrap;
}

.sound-toggle-btn:hover {
  border-color: var(--text-secondary);
  background-color: rgba(0, 0, 0, 0.02);
}

body.charcoal-theme .sound-toggle-btn:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

.sound-toggle-btn.active {
  background-color: var(--text-primary);
  color: var(--bg-color);
  border-color: var(--text-primary);
}

/* Timeline Playback Controls Overlay */
.playback-controls {
  display: none;
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  align-items: center;
  gap: 16px;
  background: var(--panel-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: 30px;
  padding: 10px 24px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  z-index: 20;
  width: 480px;
  max-width: 90%;
}

body.charcoal-theme .playback-controls {
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.playback-controls.active {
  display: flex;
}

.playback-btn {
  background-color: var(--text-primary);
  color: var(--bg-color);
  border: none;
  border-radius: 20px;
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 6px 16px;
  cursor: pointer;
  transition: transform 0.2s, opacity 0.2s;
  min-width: 65px;
}

.playback-btn:hover {
  opacity: 0.9;
  transform: scale(1.02);
}

.playback-slider {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  border-radius: 3px;
  background: var(--border-color);
  outline: none;
  cursor: pointer;
}

.playback-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--text-primary);
  border: 2px solid var(--panel-bg);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  transition: transform 0.15s ease;
}

.playback-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

.playback-counter {
  font-family: var(--font-family-mono);
  font-size: 0.72rem;
  color: var(--text-secondary);
  white-space: nowrap;
}

/* Focus Mode / Art Mode Styles */
body.focus-mode .app-header,
body.focus-mode .app-footer,
body.focus-mode #historical-banner,
body.focus-mode .archive-drawer,
body.focus-mode .details-sidebar {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}




.exit-focus-btn {
  display: none;
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(0, 0, 0, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.9);
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 10px 22px;
  border-radius: 30px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  z-index: 9999;
  cursor: pointer;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  align-items: center;
  gap: 8px;
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
              opacity 0.4s ease,
              background-color 0.2s, 
              color 0.2s;
}

body.focus-mode .exit-focus-btn {
  display: flex !important;
  opacity: 1 !important;
  transform: translateX(-50%) translateY(0) !important;
}

.exit-focus-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.4);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(255, 255, 255, 0.05);
}

.exit-focus-btn:active {
  transform: translateX(-50%) scale(0.97) !important;
}

.exit-focus-esc {
  display: inline-block;
  font-size: 0.6rem;
  font-family: var(--font-family-mono);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.6);
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 8px;
  letter-spacing: 0.05em;
}

/* Learn More Section inside settings drawer */
.drawer-learn-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 10px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
}

.learn-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.learn-title {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.learn-desc {
  font-size: 0.7rem;
  line-height: 1.4;
  color: var(--text-secondary);
  margin: 0;
}

/* ═══════════════════════════════════════════════
   GUIDE OPEN BUTTON (in header)
═══════════════════════════════════════════════ */
.guide-open-btn {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.4s;
  white-space: nowrap;
  display: flex;
  align-items: center;
}

/* ═══════════════════════════════════════════════
   TRANSACTION INSPECTOR OVERLAY MODAL
═══════════════════════════════════════════════ */
.tx-inspector-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.tx-inspector-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.tx-inspector-content {
  background: var(--panel-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  width: min(420px, 90vw);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  transform: scale(0.95) translateY(10px);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

body.charcoal-theme .tx-inspector-content {
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6);
}

.tx-inspector-overlay.open .tx-inspector-content {
  transform: scale(1) translateY(0);
}

.tx-inspector-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
}

.tx-inspector-title {
  font-family: var(--font-family-sans);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-primary);
}

.close-tx-inspector {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 1.4rem;
  cursor: pointer;
  line-height: 1;
}

.close-tx-inspector:hover {
  color: var(--text-primary);
}

.tx-inspector-body {
  padding: 20px;
}

.tx-stat-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
  padding: 14px;
  background: rgba(0, 0, 0, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 8px;
}

body.charcoal-theme .tx-stat-row {
  background: rgba(255, 255, 255, 0.01);
}

.tx-stat-row .tx-stat-label {
  font-size: 0.6rem;
  margin-bottom: 4px;
}

.tx-stat-value.val-emphasis {
  font-family: var(--font-family-mono);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--accent-color);
}

.tx-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.tx-detail-cell {
  display: flex;
  flex-direction: column;
  padding: 8px;
  border-bottom: 1px solid var(--border-color);
}

.tx-detail-cell.full-width {
  grid-column: span 2;
}

.tx-stat-label {
  font-size: 0.58rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.tx-stat-value {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-primary);
}

.tx-stat-value.hash-value {
  font-family: var(--font-family-mono);
  font-size: 0.7rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}


.guide-open-btn:hover {
  background-color: var(--accent-color);
  border-color: var(--accent-color);
  color: #ffffff;
}

body.charcoal-theme .guide-open-btn:hover {
  background-color: var(--accent-color);
  border-color: var(--accent-color);
  color: #ffffff;
}

/* ═══════════════════════════════════════════════
   GUIDE OVERLAY — Full-screen backdrop
═══════════════════════════════════════════════ */
.guide-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  justify-content: flex-end;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.guide-overlay.open {
  opacity: 1;
  pointer-events: all;
}

/* ═══════════════════════════════════════════════
   GUIDE PANEL — slides in from right
═══════════════════════════════════════════════ */
.guide-panel {
  width: min(680px, 95vw);
  height: 100vh;
  background: var(--panel-bg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-left: 1px solid var(--border-color);
  box-shadow: -20px 0 60px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  transform: translateX(40px);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

body.charcoal-theme .guide-panel {
  box-shadow: -20px 0 80px rgba(0, 0, 0, 0.55);
}

.guide-overlay.open .guide-panel {
  transform: translateX(0);
}

/* Panel Header */
.guide-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 32px;
  border-bottom: 1px solid var(--border-color);
  flex-shrink: 0;
  background: var(--panel-bg);
  position: sticky;
  top: 0;
  z-index: 2;
}

.guide-panel-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  gap: 10px;
}

.guide-close-btn {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 1.3rem;
  line-height: 1;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}

.guide-close-btn:hover {
  background-color: var(--text-primary);
  color: var(--bg-color);
  border-color: var(--text-primary);
}

/* Panel Body — scrollable */
.guide-body {
  overflow-y: auto;
  flex: 1;
  padding: 0 32px 48px 32px;
  scrollbar-width: thin;
  scrollbar-color: var(--border-color) transparent;
}

.guide-body::-webkit-scrollbar {
  width: 4px;
}
.guide-body::-webkit-scrollbar-track { background: transparent; }
.guide-body::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

/* ═══════════════════════════════════════════════
   GUIDE SECTIONS
═══════════════════════════════════════════════ */
.guide-section {
  padding: 32px 0;
  border-bottom: 1px solid var(--border-color);
}

.guide-section:last-child {
  border-bottom: none;
}

.guide-section-badge {
  display: inline-block;
  font-family: var(--font-family-mono);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-color);
  background: rgba(59, 111, 212, 0.1);
  border: 1px solid rgba(59, 111, 212, 0.2);
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 10px;
}

.guide-section-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 14px;
  line-height: 1.3;
}

.guide-text {
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.guide-text strong { color: var(--text-primary); }
.guide-text em { font-style: italic; }

/* Callout Box */
.guide-callout {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: rgba(59, 111, 212, 0.06);
  border: 1px solid rgba(59, 111, 212, 0.15);
  border-left: 3px solid var(--accent-color);
  border-radius: 8px;
  padding: 14px 16px;
  margin: 16px 0;
  font-size: 0.82rem;
  line-height: 1.55;
  color: var(--text-secondary);
}

.guide-callout strong { color: var(--text-primary); }

.guide-callout-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ═══════════════════════════════════════════════
   GLOSSARY TERMS
═══════════════════════════════════════════════ */
.guide-term {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 8px 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-color);
  align-items: baseline;
}

.guide-term:last-child { border-bottom: none; }

.guide-term-label {
  font-family: var(--font-family-mono);
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding-top: 1px;
}

.guide-term-def {
  font-size: 0.8rem;
  line-height: 1.55;
  color: var(--text-secondary);
}

/* ═══════════════════════════════════════════════
   VISUAL DEMOS — Tile swatches
═══════════════════════════════════════════════ */
.guide-visual-row {
  display: flex;
  gap: 16px;
  margin: 18px 0;
  flex-wrap: wrap;
}

.guide-visual-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-size: 0.72rem;
  color: var(--text-secondary);
  text-align: center;
  flex: 1;
  min-width: 90px;
}

.guide-visual-item small {
  font-size: 0.65rem;
  opacity: 0.7;
  display: block;
  margin-top: 2px;
}

.guide-tile-demo {
  width: 52px;
  height: 52px;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.08);
}

/* Fee Cards */
.guide-fee-card {
  flex: 1;
  border-radius: 10px;
  padding: 16px;
  min-width: 130px;
}

.guide-fee-card.low {
  background: rgba(59, 111, 212, 0.08);
  border: 1px solid rgba(59, 111, 212, 0.2);
}

.guide-fee-card.high {
  background: rgba(220, 60, 60, 0.07);
  border: 1px solid rgba(220, 60, 60, 0.2);
}

.guide-fee-label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.guide-fee-gwei {
  font-family: var(--font-family-mono);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.guide-fee-card p {
  font-size: 0.75rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0;
}

/* ═══════════════════════════════════════════════
   TX TYPE ROWS (Transactions section)
═══════════════════════════════════════════════ */
.guide-tx-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 16px 0;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  overflow: hidden;
}

.guide-tx-row {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-color);
  transition: background-color 0.15s;
}

.guide-tx-row:last-child { border-bottom: none; }

.guide-tx-row:hover {
  background: rgba(0, 0, 0, 0.03);
}

body.charcoal-theme .guide-tx-row:hover {
  background: rgba(255, 255, 255, 0.03);
}

.guide-tx-dot {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  flex-shrink: 0;
  margin-top: 3px;
}

.guide-tx-info {
  flex: 1;
}

.guide-tx-info strong {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-primary);
  display: block;
  margin-bottom: 4px;
}

.guide-tx-info p {
  font-size: 0.77rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0 0 6px 0;
}

.guide-tx-example {
  font-size: 0.7rem;
  font-style: italic;
  color: var(--accent-color);
  opacity: 0.85;
  display: block;
}

/* ═══════════════════════════════════════════════
   WALLET TRACKING DEMO
═══════════════════════════════════════════════ */
.guide-wallet-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  text-align: center;
  flex: 1;
}

.guide-wallet-demo {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  background: rgba(59, 111, 212, 0.1);
}

.guide-wallet-demo.sent {
  border: 3px solid rgba(255, 160, 0, 0.9);
  box-shadow: 0 0 14px rgba(255, 160, 0, 0.4);
}

.guide-wallet-demo.received {
  border: 3px solid rgba(0, 229, 255, 0.9);
  box-shadow: 0 0 14px rgba(0, 229, 255, 0.35);
}

/* ═══════════════════════════════════════════════
   KEYBOARD SHORTCUTS
═══════════════════════════════════════════════ */
.guide-shortcuts {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  overflow: hidden;
  margin-top: 4px;
}

.guide-shortcut-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.8rem;
  color: var(--text-secondary);
  transition: background-color 0.15s;
}

.guide-shortcut-row:last-child { border-bottom: none; }

.guide-shortcut-row:hover {
  background: rgba(0, 0, 0, 0.02);
}

body.charcoal-theme .guide-shortcut-row:hover {
  background: rgba(255, 255, 255, 0.02);
}

kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-family-mono);
  font-size: 0.65rem;
  font-weight: 700;
  color: #ffffff;
  background: var(--accent-color);
  border: 1px solid var(--accent-color);
  border-bottom: 2px solid rgba(0,0,0,0.2);
  border-radius: 5px;
  padding: 3px 8px;
  min-width: 36px;
  text-align: center;
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.04em;
  box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}

.guide-section-badge {
  display: inline-block;
  font-family: var(--font-family-mono);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ffffff;
  background: var(--accent-color);
  border: 1px solid var(--accent-color);
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 10px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* Video Containers and fitting rules */
.guide-video-container {
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
  border: 1px solid var(--border-color);
  margin: 16px 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.guide-video-container.large-video {
  aspect-ratio: 16 / 9;
}

.guide-video-container.small-video {
  aspect-ratio: 4 / 3;
}

.guide-video {
  width: 100%;
  height: 100%;
  object-fit: contain; /* fill container, adjusted accordingly, don't crop */
  display: block;
}

/* Focus mode hides guide too */
body.focus-mode .guide-overlay {
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Hourly Analysis CSS Modules */
.hourly-breakdown-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 8px 0;
}

.hourly-metrics-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 480px;
  overflow-y: auto;
  padding-right: 4px;
}

.hourly-metric-item {
  background: rgba(0, 0, 0, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: transform 0.2s, background-color 0.2s;
}

body.charcoal-theme .hourly-metric-item {
  background: rgba(255, 255, 255, 0.01);
}

.hourly-metric-item:hover {
  transform: translateY(-1px);
  background: rgba(0, 0, 0, 0.04);
}

body.charcoal-theme .hourly-metric-item:hover {
  background: rgba(255, 255, 255, 0.03);
}

.hourly-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.hourly-time-label {
  font-family: var(--font-family-sans);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.hourly-fee-badge {
  font-family: var(--font-family-mono);
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.05);
  color: var(--text-secondary);
}

body.charcoal-theme .hourly-fee-badge {
  background: rgba(255, 255, 255, 0.05);
}

.hourly-split-bar {
  display: flex;
  height: 4px;
  width: 100%;
  border-radius: 2px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.05);
}

body.charcoal-theme .hourly-split-bar {
  background: rgba(255, 255, 255, 0.05);
}

.hourly-split-bar .segment {
  height: 100%;
}

.hourly-split-bar .transfers { background-color: hsl(190, 80%, 50%); }
.hourly-split-bar .swaps { background-color: hsl(320, 80%, 55%); }
.hourly-split-bar .mints { background-color: hsl(145, 75%, 45%); }

.hourly-details-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.62rem;
  color: var(--text-secondary);
  font-family: var(--font-family-sans);
}

.hourly-details-row span {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}



