:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #14141f;
  --bg-tertiary: #1e1e2e;
  --text-primary: #ffffff;
  --text-secondary: #a0a0b0;
  --text-muted: #606070;
  --accent: #00d4ff;
  --accent-secondary: #00ff88;
  --danger: #ff4466;
  --focus-ring: #00d4ff;
  --focus-glow: rgba(0, 212, 255, 0.4);
  --radius-md: 12px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body {
  width: 600px; height: 600px; overflow: hidden;
  background: #000;
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
#app { width: 100%; height: 100%; position: relative; }
.screen { width: 100%; height: 100%; position: absolute; top: 0; left: 0; display: flex; flex-direction: column; }
.screen.hidden { display: none; }
.focusable { transition: all 0.15s ease; border: 2px solid transparent; cursor: pointer; outline: none; }
.focusable:focus { border-color: var(--focus-ring); box-shadow: 0 0 20px var(--focus-glow); }
.hidden { display: none !important; }

/* Header */
.hdr {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 22px;
  background: var(--bg-primary);
  border-bottom: 1px solid var(--bg-tertiary);
  flex-shrink: 0;
}
.hdr-title { font-size: 24px; font-weight: 700; letter-spacing: 0.3px; }
.hdr-date, .hdr-hint { font-size: 15px; color: var(--text-secondary); }

/* Moon canvas */
.moon-wrap { display: flex; justify-content: center; align-items: center; }
.moon-canvas {
  display: block;
  filter: drop-shadow(0 0 24px rgba(120, 130, 200, 0.35));
}

/* Home */
.home-body {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  padding: 14px 22px 18px; overflow: hidden;
}
.phase-name {
  font-size: 28px; font-weight: 700; margin-top: 10px; text-align: center;
}
.phase-sub {
  font-size: 17px; color: var(--text-secondary); margin-top: 4px; margin-bottom: 14px;
}
.cards { width: 100%; display: flex; flex-direction: column; gap: 12px; }

.card {
  display: flex; align-items: center; gap: 16px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  min-height: 70px;
}
.card-ico { width: 40px; height: 40px; flex-shrink: 0; }
.card-text { display: flex; flex-direction: column; gap: 3px; }
.card-label { font-size: 15px; color: var(--text-secondary); }
.card-val { font-size: 20px; font-weight: 600; color: var(--text-primary); }

.row2 { display: flex; gap: 12px; }
.btn {
  flex: 1;
  min-height: 60px;
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border-radius: var(--radius-md);
  font-size: 19px; font-weight: 600;
  font-family: inherit;
  display: flex; align-items: center; justify-content: center;
}
.btn.wide { width: 100%; margin-top: 8px; }

/* Detail */
.detail-body {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  padding: 20px 26px; gap: 6px;
}
.detail-count { font-size: 30px; font-weight: 700; margin-top: 14px; color: var(--accent); }
.detail-date { font-size: 20px; color: var(--text-primary); }
.detail-meta { font-size: 16px; color: var(--text-secondary); margin-bottom: auto; }
.detail-body .btn.wide { margin-top: 12px; }

/* Upcoming */
.up-body { flex: 1; display: flex; flex-direction: column; padding: 16px 22px; overflow: hidden; }
.up-list { list-style: none; flex: 1; overflow: hidden; }
.up-item {
  display: flex; align-items: center; gap: 14px;
  background: var(--bg-secondary);
  border-radius: 10px;
  padding: 10px 16px; margin-bottom: 9px;
  min-height: 56px;
}
.up-dot { width: 26px; height: 26px; flex-shrink: 0; }
.up-info { display: flex; flex-direction: column; }
.up-phase { font-size: 18px; font-weight: 600; }
.up-when { font-size: 14px; color: var(--text-secondary); }
.up-rel { margin-left: auto; font-size: 15px; color: var(--accent); white-space: nowrap; }

/* About */
.about-body { flex: 1; display: flex; flex-direction: column; padding: 22px 26px; gap: 16px; }
.about-p { font-size: 18px; line-height: 1.5; color: var(--text-primary); }
.about-note { font-size: 15px; line-height: 1.4; color: var(--text-muted); margin-top: auto; }
.about-body .card { min-height: 66px; }
