:root {
  --bg-color: #0D1117;
  --fg-color: #C9D1D9;
  --success: #3FB950;
  --info: #38DDF8;
  --warning: #D29922;
  --border: #30363D;
  
  --font-body: 'IBM Plex Mono', monospace;
  --font-heading: 'Clash Display', sans-serif;

  --unit: 4px;
  --gutter: calc(var(--unit) * 4);
}

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

body {
  background-color: var(--bg-color);
  color: var(--fg-color);
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.5;
  overflow-x: hidden;
  height: 100vh;
  display: flex;
  flex-direction: column;
}

/* CRT Scanline Overlay */
.crt-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 9999;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%),
              linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 100, 0.06));
  background-size: 100% 2px, 3px 100%;
  opacity: 0.15;
}

/* Shell Layout */
.shell-window {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  position: relative;
}

.shell-header {
  display: flex;
  justify-content: space-between;
  padding: var(--gutter);
  border-bottom: 1px solid var(--border);
  font-weight: 500;
  color: var(--warning);
}

.shell-body {
  flex-grow: 1;
  padding: calc(var(--gutter) * 2);
  overflow-y: auto;
  position: relative;
}

/* Typography & Colors Utilities */
.text-green-500 { color: var(--success); }
.text-cyan-400 { color: var(--info); }
.text-amber-500 { color: var(--warning); }
.mt-4 { margin-top: 1rem; }
.mt-8 { margin-top: 2rem; }

/* ASCII Banner */
.ascii-banner {
  font-family: var(--font-body);
  font-size: 12px;
  line-height: 1.2;
  white-space: pre;
  margin-bottom: 2rem;
  /* Prevent horizontal scroll on small screens for art */
  overflow-x: hidden; 
}

/* System Status */
.system-status {
  margin-bottom: 3rem;
  color: var(--info);
}

/* Content Blocks */
.content-block {
  margin-bottom: 2rem;
}
.block-title {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--fg-color);
}

p {
  margin-bottom: 0.5rem;
}

/* Links (Directory, Files) */
.directory-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.directory-list a {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  font-family: var(--font-body);
  transition: all 0.2s;
  padding: 4px 8px;
  margin-left: -8px; /* Counter-padding align */
}

.directory-list a.dir-link { color: var(--info); }
.directory-list a.file-link { color: var(--fg-color); }
.directory-list a.sym-link { color: var(--success); }

.directory-list a:hover {
  background-color: var(--info);
  color: var(--bg-color) !important;
}

/* Log Entries (Works list) */
.log-entries {
  display: flex;
  flex-direction: column;
}
.log-entry {
  display: grid;
  grid-template-columns: 100px 80px 120px 1fr;
  padding: 8px 0;
  border-bottom: 1px dotted var(--border);
}
.log-entry:hover {
  background-color: var(--info);
  color: var(--bg-color);
  cursor: pointer;
}
.log-entry:hover .text-cyan-400 {
  color: var(--bg-color);
}

/* Interactive Prompt */
.prompt-line {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.prompt-symbol {
  color: var(--success);
  font-weight: bold;
}
.cmd-input {
  background: transparent;
  border: none;
  color: var(--fg-color);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
  width: 100%;
  caret-color: var(--info);
}

/* Ensure caret looks like a block if possible, webkits standard */
.cmd-input::selection {
  background-color: var(--info);
  color: var(--bg-color);
}

/* Status Bar Footer */
.status-bar {
  display: flex;
  justify-content: space-between;
  padding: 8px var(--gutter);
  border-top: 1px solid var(--border);
  background-color: var(--fg-color);
  color: var(--bg-color);
  font-weight: bold;
  font-size: 12px;
}

/* Boot Sequence Animation Container */
#boot-sequence {
  color: var(--success);
  margin-bottom: 2rem;
}

/* Responsive adjustments */
@media (max-width: 640px) {
  body {
    font-size: 12px;
  }
  .ascii-banner {
    font-size: 8px; /* Shrink ASCII art */
  }
  .shell-window {
    border-left: none;
    border-right: none;
  }
  .log-entry {
     grid-template-columns: 1fr;
     gap: 4px;
     padding: 12px 0;
  }
  .log-entry span::before {
     content: attr(class) ": ";
     color: var(--border);
     font-size: 10px;
  }
}
