/* style.css — 密铺博客样式 */

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

html, body {
  width: 100%; height: 100%;
  overflow: hidden;
  background: #0a0a0a;
  font-family: -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  touch-action: manipulation;
}

/* ---- 全屏 canvas ---- */
#tiling-canvas {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  touch-action: none;
}

/* ---- feature 浮层 ---- */
#feature-overlay {
  position: fixed; inset: 0;
  z-index: 100;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s;
}
#feature-overlay.active {
  pointer-events: auto;
  opacity: 1;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(4px);
}

#feature-overlay .panel {
  background: #1e1e1e;
  color: #e0e0e0;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  max-width: 820px;
  width: 92vw;
  max-height: 88vh;
  overflow-y: auto;
  padding: 28px 32px;
  box-shadow: 0 16px 48px rgba(0,0,0,0.5);
}

#feature-overlay .panel h2 {
  font-size: 20px; font-weight: 600;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  color: #fff;
}

#feature-overlay .panel textarea,
#feature-overlay .panel input[type="text"],
#feature-overlay .panel input[type="number"] {
  background: #2a2a2a;
  color: #e0e0e0;
  border: 1px solid #444;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
}
#feature-overlay .panel textarea:focus,
#feature-overlay .panel input:focus {
  border-color: #6af;
}

#feature-overlay .panel button {
  background: #3a3a3a;
  color: #e0e0e0;
  border: 1px solid #555;
  border-radius: 6px;
  padding: 7px 16px;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
}
#feature-overlay .panel button:hover { background: #4a4a4a; border-color: #777; }
#feature-overlay .panel button.danger { color: #f66; }
#feature-overlay .panel button.danger:hover { background: #522; }

/* ---- 翻转动画 tile ---- */
.flip-tile {
  position: fixed;
  z-index: 50;
  pointer-events: none;
  border-radius: 2px;
  transform-origin: center center;
  transition: transform 0.5s ease-in-out;
  backface-visibility: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

/* ---- 底部提示 ---- */
#hint-bar {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  padding: 6px 18px;
  background: rgba(20,20,20,0.78);
  color: #999;
  font-size: 12px;
  border-radius: 20px;
  backdrop-filter: blur(4px);
  pointer-events: none;
  animation: hintFade 6s forwards;
}
@keyframes hintFade {
  0%, 60% { opacity: 1; }
  100% { opacity: 0; }
}

/* ---- 按键提示 toast ---- */
#toast {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 300;
  padding: 5px 16px;
  background: rgba(180,180,180,0.18);
  color: #aaa;
  font-size: 13px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.08);
  backdrop-filter: blur(6px);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.18s;
}
#toast.show {
  opacity: 1;
  transition: opacity 0.08s;
}
