@import url("https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;700&display=swap");


/* src/style.css — All styles for the terminal website */
/* Colors use CSS custom properties for theme switching */
/* ── Theme variables (defaults, overridden by themes.js) ── */
:root {
  --bg: #0a0e14;
  --fg: #b3b1ad;
  --terminal-bg: rgba(13, 17, 23, 0.75);
  --border: #21262d;
  --prompt: #7ee787;
  --command: #e6edf3;
  --highlight: #79c0ff;
  --accent: #d2a8ff;
  --warn: #d29922;
  --separator: #30363d;
  --cursor-color: #58a6ff;
  --bar-bg: #0d1117;
  --bar-accent: #58a6ff;
  --tmux-session-bg: #7ee787;
  --tmux-session-fg: #0d1117;
  --tmux-win-bg: #21262d;
  --tmux-win-fg: #8b949e;
  --tmux-win-active-bg: #30363d;
  --tmux-win-active-fg: #e6edf3;
  --tmux-host-bg: #58a6ff;
  --tmux-host-fg: #0d1117;
  --tmux-info-bg: #21262d;
  --tmux-hl: #d2a8ff;
}
/* ── Scrollbar ── */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.15);
}
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.08) transparent;
}
/* ── Reset ── */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
/* ── Body ── */
body {
  background: var(--bg);
  color: var(--fg);
  font-family: "Fira Code", monospace;
  font-size: 15px;
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  overflow: hidden;
}
/* ── Background canvas ── */
#bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 0;
}
/* ── Terminal container ── */
.terminal {
  background: var(--terminal-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  max-width: 880px;
  width: 100%;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.4);
  overflow: hidden;
  position: relative;
  z-index: 1;
  backdrop-filter: blur(8px);
}
/* ── i3 top bar ── */
.i3-bar {
  background: var(--bar-bg);
  padding: 0;
  display: flex;
  align-items: stretch;
  border-bottom: 2px solid var(--bar-accent);
  font-family: "Fira Code", monospace;
  font-size: 12px;
}
.i3-left {
  display: flex;
  align-items: center;
}
.i3-ws {
  background: var(--bar-accent);
  color: var(--bar-bg);
  padding: 6px 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
}
.i3-mode {
  color: var(--prompt);
  padding: 6px 10px;
  border-right: 1px solid var(--border);
}
.i3-title {
  color: var(--tmux-win-fg);
  padding: 6px 12px;
  font-size: 12px;
}
.i3-right {
  margin-left: auto;
  display: flex;
  align-items: center;
}
.i3-stat {
  padding: 6px 10px;
  border-left: 1px solid var(--border);
  color: var(--tmux-win-fg);
}
.i3-stat .val {
  color: var(--accent);
}
.i3-theme-picker {
  padding: 0 6px;
  display: flex;
  align-items: center;
}
#theme-select {
  background: var(--bar-bg);
  color: var(--accent);
  border: 1px solid var(--border);
  border-radius: 3px;
  font-family: "Fira Code", monospace;
  font-size: 11px;
  padding: 2px 4px;
  cursor: pointer;
  outline: none;
}
#theme-select:hover,
#theme-select:focus {
  border-color: var(--bar-accent);
}
/* ── Terminal body ── */
.terminal-body {
  position: relative;
  height: 620px;
}
.terminal-pane {
  padding: 24px;
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
}
.line {
  white-space: pre-wrap;
  word-break: break-all;
}
.input-line {
  display: flex;
  flex-wrap: wrap;
}
/* ── Text colors ── */
.prompt {
  color: var(--prompt);
}
.command {
  color: var(--command);
}
.output {
  color: var(--fg);
}
.highlight {
  color: var(--highlight);
}
.accent {
  color: var(--accent);
}
.warn {
  color: var(--warn);
}
.separator {
  color: var(--separator);
}
/* ── Cursor ── */
.cursor {
  display: inline-block;
  width: 0.6em;
  background: var(--cursor-color);
  animation: blink 1s step-end infinite;
}
/* In flex input-line, match text height */
.input-line .cursor {
  height: 1.4em;
  margin-top: -4px;
  align-self: center;
}
/* In non-flex context (typewriter), size to match text */
.line:not(.input-line) .cursor {
  height: 1.25em;
  vertical-align: text-top;
}
@keyframes blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0;
  }
}
.typed-text {
  display: inline;
}
.input-text {
  white-space: pre;
}
/* ── ANSI art (tight line spacing) ── */
.ansi-art .line {
  line-height: 1.1;
}
/* ── Skill links (clickable in ls output) ── */
.skill-link {
  cursor: pointer;
}
.skill-link:hover .accent {
  text-decoration: underline;
}
/* ── cmatrix canvas ── */
.cmatrix-canvas {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}
/* ── Hidden input (for keystroke capture) ── */
#hidden-input {
  position: fixed;
  top: 0;
  left: 0;
  width: 1px;
  height: 1px;
  opacity: 0;
  border: none;
  outline: none;
  padding: 0;
  font-size: 16px; /* prevents iOS zoom */
}
/* ── Tmux bottom bar ── */
.tmux-bar {
  background: var(--bar-bg);
  border-top: 1px solid var(--border);
  padding: 0;
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  font-family: "Fira Code", monospace;
  font-size: 11px;
  color: var(--separator);
  overflow: hidden;
}
.tmux-left {
  display: flex;
  align-items: stretch;
}
.tmux-right {
  display: flex;
  align-items: stretch;
}
/* ── Tmux session badge ── */
.tmux-session {
  background: var(--tmux-session-bg);
  color: var(--tmux-session-fg);
  padding: 3px 18px 3px 10px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  position: relative;
}
.tmux-session::after {
  content: "";
  position: absolute;
  right: -10px;
  top: 0;
  bottom: 0;
  width: 11px;
  background: var(--tmux-session-bg);
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}
/* ── Tmux windows ── */
.tmux-win {
  padding: 3px 18px;
  color: var(--tmux-win-fg);
  background: var(--tmux-win-bg);
  display: inline-flex;
  align-items: center;
  position: relative;
  cursor: pointer;
  transition: background 0.15s;
}
.tmux-win::after {
  content: "";
  position: absolute;
  right: -10px;
  top: 0;
  bottom: 0;
  width: 11px;
  background: var(--tmux-win-bg);
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}
.tmux-win.active {
  color: var(--tmux-win-active-fg);
  background: var(--tmux-win-active-bg);
}
.tmux-win.active::after {
  background: var(--tmux-win-active-bg);
}
.tmux-win-idx {
  color: var(--bar-accent);
}
/* ── Tmux info (clock) ── */
.tmux-info {
  padding: 3px 18px;
  color: var(--tmux-win-fg);
  background: var(--tmux-info-bg);
  display: inline-flex;
  align-items: center;
  position: relative;
}
.tmux-info::before {
  content: "";
  position: absolute;
  left: -10px;
  top: 0;
  bottom: 0;
  width: 11px;
  background: var(--tmux-info-bg);
  clip-path: polygon(100% 0, 0 50%, 100% 100%);
}
.tmux-hl {
  color: var(--tmux-hl);
}
/* ── Tmux host badge ── */
.tmux-host {
  background: var(--tmux-host-bg);
  color: var(--tmux-host-fg);
  padding: 3px 10px 3px 18px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  position: relative;
}
.tmux-host::before {
  content: "";
  position: absolute;
  left: -10px;
  top: 0;
  bottom: 0;
  width: 11px;
  background: var(--tmux-host-bg);
  clip-path: polygon(100% 0, 0 50%, 100% 100%);
}
/* ── Responsive ── */
@media (max-width: 600px) {
  body {
    padding: 1rem;
    font-size: 13px;
  }

  .terminal-body {
    height: 400px;
  }

  .terminal-pane {
    padding: 16px;
  }

  .tmux-bar {
    font-size: 10px;
  }
}
