/* Dala - Royal African Board Game WebGL Presentation Styles */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700;800&family=Inter:wght@400;500;600&display=swap');

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

html, body {
  width: 100%;
  height: 100%;
  min-height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  background-color: #07090d;
  background: radial-gradient(circle at 50% 50%, #151b26 0%, #0c0f16 65%, #050609 100%);
  color: #f7d774;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  touch-action: none;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}

#unity-container {
  width: 100vw;
  height: 100vh;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: transparent;
  z-index: 1;
}

#unity-canvas {
  width: 100%;
  height: 100%;
  display: block;
  background-color: #0a0d14;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  -webkit-tap-highlight-color: transparent;
  cursor: default;
}

#unity-canvas:focus,
#unity-canvas:active,
#unity-canvas:focus-visible {
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
}

/* ── Royal Loading Overlay ── */
#dala-loading-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background-color: #07090d;
  background: radial-gradient(circle at 50% 50%, #1a2230 0%, #0c0f16 65%, #040508 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 999;
  transition: opacity 0.6s cubic-bezier(0.2, 0.8, 0.2, 1), visibility 0.6s;
  pointer-events: all;
}

#dala-loading-overlay.fade-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.dala-loader-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px;
  max-width: 440px;
  width: 90%;
}

.dala-crest-wrapper {
  position: relative;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.dala-crest-glow {
  position: absolute;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 215, 0, 0.28) 0%, rgba(212, 175, 55, 0.08) 50%, transparent 70%);
  animation: pulse-glow 2.4s ease-in-out infinite alternate;
}

@keyframes pulse-glow {
  0% { transform: scale(0.9); opacity: 0.6; }
  100% { transform: scale(1.18); opacity: 1; }
}

.dala-crown-icon {
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 4px 14px rgba(212, 175, 55, 0.45));
}

.dala-title {
  font-family: 'Cinzel', serif;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0.22em;
  background: linear-gradient(180deg, #fff2b2 0%, #ffd700 45%, #d4af37 75%, #aa7c11 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 2px 14px rgba(212, 175, 55, 0.35);
  margin-bottom: 6px;
}

.dala-subtitle {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.25em;
  color: rgba(247, 215, 116, 0.75);
  text-transform: uppercase;
  margin-bottom: 32px;
}

.dala-progress-container {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.dala-progress-track {
  width: 100%;
  height: 8px;
  background: rgba(18, 22, 31, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 999px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.7);
  position: relative;
}

.dala-progress-bar {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #aa7c11 0%, #d4af37 40%, #ffd700 80%, #fff2b2 100%);
  border-radius: 999px;
  box-shadow: 0 0 14px rgba(255, 215, 0, 0.75);
  transition: width 0.25s ease-out;
}

.dala-progress-stats {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  font-weight: 500;
  color: rgba(247, 215, 116, 0.85);
  letter-spacing: 0.05em;
  padding: 0 2px;
}

/* ── Floating Fullscreen Button ── */
#dala-fullscreen-btn {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 100;
  width: 44px;
  height: 44px;
  background: rgba(15, 19, 27, 0.68);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 12px;
  color: #ffd700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.22s ease-in-out;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.55);
}

#dala-fullscreen-btn:hover {
  background: rgba(25, 32, 45, 0.9);
  border-color: #ffd700;
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 6px 22px rgba(212, 175, 55, 0.35);
}

#dala-fullscreen-btn:active {
  transform: translateY(0) scale(0.96);
}

/* ── Error Banner ── */
#unity-warning {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  background: rgba(26, 12, 14, 0.92);
  border: 1px solid #e74c3c;
  color: #ffb3b8;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 13px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  display: none;
}
