/* Mẫu trang web Kỷ Nguyên Yêu Quái (Kế hoạch Web, Giai đoạn 1). Màu theo bảng chàm tối / giấy dó / son đỏ của game. */
html, body {
  margin: 0; padding: 0; width: 100%; height: 100%;
  background: #0b0a12; color: #ece7da; overflow: hidden;
  font-family: "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif;
  overscroll-behavior: none; -webkit-user-select: none; user-select: none;
}
#game-root {
  position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; background: #000;
}
#unity-canvas { display: block; background: #000; outline: none; touch-action: none; }

.overlay {
  position: fixed; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 14px; padding: 24px; box-sizing: border-box; text-align: center; background: rgba(11, 10, 18, 0.96); z-index: 10;
}
.hidden { display: none !important; }
.title { font-size: 26px; letter-spacing: 4px; color: #e8c676; font-weight: 600; }
.bar { width: min(420px, 80vw); height: 10px; border: 1px solid #6b5a3a; border-radius: 6px; overflow: hidden; background: #1c1a2a; }
#bar-full { width: 0; height: 100%; background: linear-gradient(90deg, #c0392b, #e8c676); transition: width 0.2s; }
#loading-text { font-size: 15px; }
.hint { font-size: 12px; color: #9e98b2; max-width: 420px; }
#message-text { font-size: 16px; line-height: 1.5; max-width: 520px; }
#message-text small { color: #9e98b2; }

button { font: inherit; cursor: pointer; }
button.big {
  padding: 14px 28px; font-size: 18px; color: #ece7da; background: #c0392b; border: 1px solid #e8c676; border-radius: 8px;
}
button.link { background: none; border: none; color: #9e98b2; text-decoration: underline; font-size: 14px; }

#fullscreen-btn {
  position: fixed; right: 8px; bottom: 8px; z-index: 5; padding: 6px 10px; font-size: 13px;
  color: #ece7da; background: rgba(34, 31, 52, 0.75); border: 1px solid #6b5a3a; border-radius: 6px; opacity: 0.55;
}
#fullscreen-btn:hover { opacity: 1; }
#diag-btn { position: fixed; left: 8px; bottom: 8px; z-index: 5; padding: 4px 8px; font-size: 12px; opacity: 0.6; }

#rotate { font-size: 18px; z-index: 20; }
.rotate-icon { font-size: 54px; animation: spin 2s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

#warning { position: fixed; left: 50%; top: 8px; transform: translateX(-50%); z-index: 30; max-width: 90vw; }
#warning div { padding: 8px 12px; margin-bottom: 4px; border-radius: 6px; font-size: 13px; }
#warning .warn { background: #6b5a1a; }
#warning .err { background: #8b1414; }
