/* Tizen Signage Player - Fullscreen Kiosk Styles */

:root {
  --bg: #000000;
}

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

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--bg);
  color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  /* Hide cursor completely for signage mode */
  cursor: none !important;
}

body {
  position: relative;
}

/* Portal-specific cursor override (player uses none for TV kiosk) */
.upload-container, .portal-container {
  cursor: default !important;
}

/* Player container - takes full viewport */
#player {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

/* Media elements */
#media-container {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

#current-video,
#current-image {
  max-width: 100%;
  max-height: 100%;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
  display: none;
}

/* When visible */
#current-video.visible,
#current-image.visible {
  display: block;
}

/* Simple crossfade / transition support */
#current-video,
#current-image {
  transition: opacity 300ms ease;
  opacity: 0;
}

#current-video.visible,
#current-image.visible {
  opacity: 1;
}

/* Status / debug overlay - hidden in normal operation */
#status {
  position: fixed;
  bottom: 16px;
  right: 12px;
  background: rgba(0, 0, 0, 0.75);
  color: #aaa;
  font-size: 11px;
  padding: 4px 8px;
  border-radius: 3px;
  z-index: 9999;
  pointer-events: none;
  font-family: monospace;
  display: block; /* visible for localhost demo */
  opacity: 0.75;
}

/* Error banner */
#error-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: #b00;
  color: white;
  padding: 8px 16px;
  font-size: 14px;
  text-align: center;
  z-index: 10000;
  display: none;
}

/* Upload portal styles (used only in upload.html) */
.upload-container {
  max-width: 720px;
  margin: 40px auto;
  padding: 20px;
  background: #111;
  color: #ddd;
  border-radius: 8px;
}

.upload-container h1 {
  margin-bottom: 8px;
  color: #fff;
}

.upload-container p {
  color: #888;
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  color: #aaa;
}

input[type="text"],
input[type="url"],
select {
  width: 100%;
  padding: 10px;
  background: #1a1a1a;
  border: 1px solid #333;
  color: #eee;
  border-radius: 4px;
  font-size: 14px;
}

button {
  background: #0066ff;
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 4px;
  font-size: 15px;
  cursor: pointer;
  margin-right: 8px;
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

button.secondary {
  background: #333;
}

#upload-progress {
  height: 6px;
  background: #222;
  border-radius: 3px;
  margin: 12px 0;
  overflow: hidden;
  display: none;
}

#upload-progress-bar {
  height: 100%;
  width: 0%;
  background: #0f0;
  transition: width 120ms linear;
}

#result {
  margin-top: 16px;
  padding: 12px;
  background: #1a1a1a;
  border-radius: 4px;
  font-family: monospace;
  font-size: 13px;
  white-space: pre-wrap;
  word-break: break-all;
  display: none;
}

.file-list {
  margin-top: 20px;
}

.file-list ul {
  list-style: none;
}

.file-list li {
  padding: 6px 0;
  border-bottom: 1px solid #222;
  font-size: 13px;
}

.info-box {
  font-size: 12px;
  background: #222;
  padding: 12px;
  margin: 20px 0;
  border-radius: 4px;
  color: #999;
}

.warning {
  color: #ffaa00;
  font-size: 12px;
}
