:root {
  --future-bg: #080b0f;
  --future-panel: rgba(13, 19, 25, 0.96);
  --future-line: rgba(127, 174, 224, 0.24);
  --future-blue: #7faee0;
  --future-text: #f5f8fb;
  --future-muted: #94a3b2;
}

body.future-lock { overflow: hidden; }

/* Projects dropdown */
.main-nav li.future-nav-parent { position: relative; display: flex; align-items: center; }
.future-nav-toggle {
  display: grid;
  width: 26px;
  height: 26px;
  margin-left: -7px;
  padding: 0;
  place-items: center;
  color: currentColor;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.future-nav-toggle i { font-size: 0.72rem; transition: transform 180ms ease; }
.future-nav-parent.is-open .future-nav-toggle i { transform: rotate(180deg); }
.future-nav-menu {
  position: absolute;
  z-index: 1000;
  top: calc(100% + 16px);
  left: 50%;
  width: 270px;
  padding: 10px;
  border: 1px solid var(--future-line);
  border-radius: 16px;
  background: var(--future-panel);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, -8px);
  transition: opacity 180ms ease, transform 180ms ease, visibility 180ms;
  backdrop-filter: blur(18px);
}
.future-nav-menu::before {
  content: '';
  position: absolute;
  right: 0;
  bottom: 100%;
  left: 0;
  height: 18px;
}
.future-nav-parent:hover .future-nav-menu,
.future-nav-parent:focus-within .future-nav-menu,
.future-nav-parent.is-open .future-nav-menu {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}
.main-nav .future-nav-menu a {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 10px;
  align-items: center;
  padding: 10px 11px;
  color: var(--future-text);
  border-radius: 10px;
  line-height: 1.2;
}
.main-nav .future-nav-menu a:hover,
.main-nav .future-nav-menu a:focus-visible { color: #fff; background: rgba(127, 174, 224, 0.12); }
.future-nav-menu i { display: grid; width: 30px; height: 30px; place-items: center; color: var(--future-blue); background: rgba(127, 174, 224, 0.1); border-radius: 8px; }
.future-nav-menu small { display: block; margin-top: 3px; color: var(--future-muted); font-size: 0.65rem; }

/* Command launcher */
.future-launcher {
  position: fixed;
  z-index: 890;
  left: 24px;
  bottom: 24px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 13px;
  color: var(--future-text);
  border: 1px solid var(--future-line);
  border-radius: 999px;
  background: rgba(7, 10, 14, 0.88);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.24);
  font: 600 0.72rem/1 var(--font-mono, monospace);
  cursor: pointer;
  backdrop-filter: blur(15px);
  transition: transform 180ms ease, border-color 180ms ease;
}
.future-launcher:hover { transform: translateY(-3px); border-color: var(--future-blue); }
.future-launcher kbd { padding: 3px 6px; color: var(--future-blue); border: 1px solid var(--future-line); border-radius: 5px; background: rgba(127, 174, 224, 0.08); }

/* Dialog shell */
.future-dialog {
  width: min(680px, calc(100vw - 32px));
  max-height: min(760px, calc(100vh - 40px));
  margin: auto;
  padding: 0;
  overflow: hidden;
  color: var(--future-text);
  border: 1px solid var(--future-line);
  border-radius: 22px;
  background: var(--future-bg);
  box-shadow: 0 36px 120px rgba(0, 0, 0, 0.58);
}
.future-dialog::backdrop { background: rgba(2, 5, 8, 0.78); backdrop-filter: blur(9px); }
.future-dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 20px; border-bottom: 1px solid var(--future-line); }
.future-dialog-head strong { font: 700 0.8rem/1 var(--font-mono, monospace); letter-spacing: 0.08em; text-transform: uppercase; }
.future-dialog-close { display: grid; width: 34px; height: 34px; padding: 0; place-items: center; color: var(--future-muted); border: 1px solid var(--future-line); border-radius: 50%; background: transparent; cursor: pointer; }
.future-dialog-close:hover { color: #fff; border-color: var(--future-blue); }

/* Command palette */
.future-command-search { position: relative; padding: 18px 20px 10px; }
.future-command-search i { position: absolute; top: 32px; left: 36px; color: var(--future-blue); }
.future-command-input {
  width: 100%;
  min-height: 52px;
  padding: 0 45px;
  color: var(--future-text);
  border: 1px solid var(--future-line);
  border-radius: 13px;
  outline: none;
  background: rgba(255, 255, 255, 0.04);
  font: 500 0.95rem/1 var(--font-mono, monospace);
}
.future-command-input:focus { border-color: var(--future-blue); box-shadow: 0 0 0 4px rgba(127, 174, 224, 0.1); }
.future-command-results { max-height: 430px; padding: 8px 12px 16px; overflow-y: auto; }
.future-command-item {
  display: grid;
  width: 100%;
  grid-template-columns: 42px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 11px 12px;
  color: var(--future-text);
  border: 0;
  border-radius: 12px;
  background: transparent;
  text-align: left;
  cursor: pointer;
}
.future-command-item:hover,
.future-command-item.is-active { background: rgba(127, 174, 224, 0.12); }
.future-command-icon { display: grid; width: 38px; height: 38px; place-items: center; color: var(--future-blue); border: 1px solid var(--future-line); border-radius: 10px; }
.future-command-copy strong,
.future-command-copy small { display: block; }
.future-command-copy strong { font-size: 0.88rem; }
.future-command-copy small { margin-top: 4px; color: var(--future-muted); font-size: 0.72rem; }
.future-command-key { color: var(--future-muted); font: 500 0.66rem/1 var(--font-mono, monospace); }
.future-command-empty { padding: 28px; color: var(--future-muted); text-align: center; }
.future-command-foot { padding: 11px 20px; color: var(--future-muted); border-top: 1px solid var(--future-line); font: 500 0.65rem/1.5 var(--font-mono, monospace); }

/* Resume preview */
.future-resume-dialog { width: min(1040px, calc(100vw - 28px)); height: min(850px, calc(100vh - 28px)); }
.future-resume-frame { width: 100%; height: calc(100% - 71px); border: 0; background: #e9edf1; }
.future-dialog-actions { display: flex; gap: 9px; margin-left: auto; }
.future-dialog-action { padding: 8px 12px; color: var(--future-text); border: 1px solid var(--future-line); border-radius: 9px; background: rgba(127, 174, 224, 0.09); font: 600 0.7rem/1 var(--font-mono, monospace); }

/* Terminal */
.future-terminal-dialog { width: min(820px, calc(100vw - 28px)); }
.future-terminal-bar { display: flex; gap: 6px; }
.future-terminal-bar span { width: 9px; height: 9px; border-radius: 50%; background: #42505d; }
.future-terminal-bar span:first-child { background: #e36a6a; }
.future-terminal-bar span:nth-child(2) { background: #e9b85b; }
.future-terminal-bar span:nth-child(3) { background: #63c68a; }
.future-terminal-output { min-height: 310px; max-height: 52vh; padding: 20px; overflow-y: auto; color: #c6d5e2; background: #05080b; font: 500 0.82rem/1.65 var(--font-mono, monospace); white-space: pre-wrap; }
.future-terminal-line { margin-bottom: 9px; }
.future-terminal-line.is-command { color: var(--future-blue); }
.future-terminal-form { display: grid; grid-template-columns: auto 1fr; gap: 9px; align-items: center; padding: 14px 20px 18px; background: #05080b; }
.future-terminal-prompt { color: #63c68a; font: 700 0.82rem/1 var(--font-mono, monospace); }
.future-terminal-input { width: 100%; padding: 8px 0; color: #fff; border: 0; outline: 0; background: transparent; font: 500 0.84rem/1 var(--font-mono, monospace); }

/* Projects explorer */
.future-project-tools { position: sticky; z-index: 20; top: 86px; padding: 14px 0; border-bottom: 1px solid #d8e2ea; background: rgba(245, 248, 250, 0.9); backdrop-filter: blur(16px); }
.future-project-tools-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.future-filters { display: flex; flex-wrap: wrap; gap: 8px; }
.future-filter,
.future-arrange {
  min-height: 38px;
  padding: 0 13px;
  color: #35424d;
  border: 1px solid #ccd9e2;
  border-radius: 999px;
  background: #fff;
  font: 650 0.7rem/1 var(--font-mono, monospace);
  cursor: pointer;
}
.future-filter:hover,
.future-filter.is-active,
.future-arrange.is-active { color: #fff; border-color: #163a55; background: #163a55; }
.future-project-status { color: #64727e; font: 500 0.68rem/1.4 var(--font-mono, monospace); white-space: nowrap; }
.future-card-hidden { display: none !important; }
.future-filter-section-hidden { display: none !important; }
.future-drag-mode .tile,
.future-drag-mode .card { cursor: grab; }
.future-drag-mode .tile:active,
.future-drag-mode .card:active { cursor: grabbing; }
.future-drag-mode .future-draggable { outline: 1px dashed rgba(52, 125, 175, 0.38); outline-offset: -7px; }
.future-dragging { opacity: 0.42; transform: scale(0.98) !important; }

@media (max-width: 900px) {
  .future-nav-toggle, .future-nav-menu { display: none; }
  .future-launcher { left: 14px; bottom: 14px; }
  .future-project-tools { top: 76px; overflow: hidden; }
  .future-project-tools-inner { align-items: flex-start; flex-direction: column; gap: 10px; }
  .future-filters { width: 100%; min-width: 0; }
  .future-project-status { white-space: normal; }
  .future-arrange { display: none; }
}

@media (max-width: 560px) {
  .future-launcher span, .future-launcher kbd { display: none; }
  .future-launcher { width: 44px; height: 44px; padding: 0; justify-content: center; }
  .future-dialog { width: calc(100vw - 18px); max-height: calc(100vh - 18px); border-radius: 16px; }
  .future-dialog-head { padding: 14px; }
  .future-command-search { padding: 14px 14px 8px; }
  .future-command-search i { top: 28px; left: 30px; }
  .future-command-results { padding-inline: 8px; }
  .future-command-key { display: none; }
  .future-resume-frame { height: calc(100% - 63px); }
  .future-dialog-action { display: none; }
  .future-filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .future-filter { width: 100%; min-height: 34px; padding-inline: 8px; font-size: 0.64rem; }
}

@media (prefers-reduced-motion: reduce) {
  .future-nav-menu,
  .future-nav-toggle i,
  .future-launcher { transition: none !important; }
}
