:root {
  --accent: #1f7a43;
  --accent-soft: rgba(31, 122, 67, 0.22);
  --ink: #f4f8f2;
  --hud-bg: rgba(10, 19, 15, 0.68);
  --hud-line: rgba(255, 255, 255, 0.12);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

/* ---------- 隧道容器（铺满整个视口） ---------- */
.eye-stage {
  position: relative;
  height: 100vh;
  overflow: hidden;
  border-radius: 0;
  background: #0b1214;
  color: var(--ink);
  font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}

#tunnel {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
}

.veil {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 50% 50%, rgba(0, 0, 0, 0) 52%, rgba(0, 0, 0, 0.14) 100%);
}

/* ---------- 控制面板 ---------- */
.hud {
  position: absolute;
  left: 30px;
  bottom: 30px;
  z-index: 2;
  width: 308px;
  display: grid;
  gap: 14px;
  padding: 18px 18px 16px;
  border: 1px solid var(--hud-line);
  border-radius: var(--radius);
  background: var(--hud-bg);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
  transition: opacity 0.5s ease, transform 0.5s ease;
  animation: rise 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.2s backwards;
}

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

.hud__label {
  flex: none;
  width: 34px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.62);
}

.hud__range {
  flex: 1;
  height: 4px;
  margin: 0;
  border-radius: 99px;
  -webkit-appearance: none;
  appearance: none;
  background: linear-gradient(
    to right,
    var(--accent) 0 var(--fill, 28.6%),
    rgba(255, 255, 255, 0.18) var(--fill, 28.6%) 100%
  );
  outline: none;
  cursor: pointer;
}

.hud__range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.hud__range::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border: 0;
  border-radius: 50%;
  background: #fff;
}

.hud__value {
  flex: none;
  width: 40px;
  text-align: right;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: rgba(255, 255, 255, 0.8);
}

.hud__group {
  display: flex;
  gap: 6px;
}

.chip {
  padding: 5px 12px;
  border: 1px solid transparent;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.72);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.chip:hover {
  background: rgba(255, 255, 255, 0.13);
  color: #fff;
}

.chip.is-active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: #fff;
}

.swatch {
  width: 20px;
  height: 20px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 7px;
  background: var(--swatch);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.swatch:hover {
  transform: translateY(-2px);
}

.swatch.is-active {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85);
}

.hud__row--actions {
  gap: 8px;
}

.btn {
  flex: 1;
  padding: 8px 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.82);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease;
}

.btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.hud__timer {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

.hud__timer-value {
  margin-left: auto;
  font-variant-numeric: tabular-nums;
  color: rgba(255, 255, 255, 0.85);
}

.hud__timer-bar {
  flex: none;
  width: 62px;
  height: 3px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.14);
  overflow: hidden;
}

.hud__timer-bar i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
  transition: width 1s linear;
}

/* ---------- 右下角快捷键 ---------- */
.hint {
  position: absolute;
  right: 30px;
  bottom: 30px;
  z-index: 2;
  margin: 0;
  padding: 7px 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 99px;
  background: rgba(10, 19, 15, 0.42);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.62);
  transition: opacity 0.5s ease;
  animation: rise 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.3s backwards;
}

/* ---------- 休息遮罩 ---------- */
.break {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  text-align: center;
  background: rgba(7, 15, 13, 0.82);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s ease, visibility 0.6s;
}

.break.is-open {
  opacity: 1;
  visibility: visible;
}

.break__title {
  margin: 0 0 10px;
  font-size: 26px;
  font-weight: 500;
  letter-spacing: 0.06em;
}

.break__desc {
  margin: 0 0 26px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
}

.break__count {
  margin: 0;
  font-size: 64px;
  font-weight: 200;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
}

/* ---------- 静默 / 沉浸状态 ---------- */
.eye-stage.is-idle,
.eye-stage.is-focus {
  cursor: none;
}

.eye-stage.is-idle .hud,
.eye-stage.is-focus .hud,
.eye-stage.is-idle .hint,
.eye-stage.is-focus .hint {
  opacity: 0;
  pointer-events: none;
}

.eye-stage.is-idle .hud,
.eye-stage.is-focus .hud {
  transform: translateY(8px);
}

/* ---------- 入场动画 ---------- */
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 720px) {
  .hud {
    left: 14px;
    right: 14px;
    bottom: 14px;
    width: auto;
  }
}

/* ---------- 全屏铺满布局（覆盖共享外壳 tools-page.css） ---------- */
html,
body {
  height: 100%;
  overflow: hidden;
}

.ot_app {
  height: 100vh;
  overflow: hidden;
}

.ot_page {
  max-width: none;
  padding: 0;
}

.ot_workspace__inner {
  height: 100%;
}

/* 标题、使用说明与页脚在全屏模式下隐藏 */
.ot_workspace__title,
.ot_usage,
.ot_copyright {
  display: none;
}

/* ---------- 顶部导航：悬停固定，几秒后自动消失 ---------- */
.ot_page_nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  padding: 16px 20px 26px;
  background: linear-gradient(to bottom, rgba(5, 10, 9, 0.72), rgba(5, 10, 9, 0.32) 60%, rgba(5, 10, 9, 0));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent);
  mask-image: linear-gradient(to bottom, #000 62%, transparent);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

/* 隐藏状态：整体滑出视口 */
.ot_page_nav.is-hidden {
  opacity: 0;
  transform: translateY(-100%);
  pointer-events: none;
}

/* 深色背景下的导航配色（覆盖外壳的浅色文字）；面包屑脱离居中容器，贴屏幕左侧 */
.ot_page_nav__inner {
  max-width: none;
  padding: 0;
  justify-content: flex-start;
  color: rgba(255, 255, 255, 0.55);
}

.ot_page_nav__inner a {
  color: rgba(255, 255, 255, 0.78);
}

.ot_page_nav__inner a:hover {
  color: #fff;
}

.ot_page_nav__sep {
  color: rgba(255, 255, 255, 0.32);
}

.ot_page_nav__current {
  color: #fff;
}

/* 静默 / 沉浸状态下导航一并隐藏（由 JS 控制，避免残留遮挡画面） */
