/* DigitalSignage.css - Module-specific styles for Digital Signage content management */
/* Uses design tokens exclusively - no hardcoded values */

/* Hotel panels container */
.signage-hotels {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
    padding: var(--space-2) 0;
}

/* Location panels within a hotel */
.signage-locations {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
    padding: var(--space-2) 0;
}

/* Content area within an expanded location */
.signage-location-content {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    padding: var(--space-3) 0;
}

/* =============================================
   SLIDE GRID
   Horizontal thumbnail strip with numbering
   ============================================= */

.signage-slides {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.signage-slide-grid {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
}

.signage-slide-thumb {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-1);
    padding: var(--space-2);
    border: var(--border-width-1) solid var(--border-default);
    border-radius: var(--border-radius-md);
    background: var(--bg-layer-4);
    width: 200px;
}

.signage-slide-thumb img {
    width: 100%;
    height: 112px;
    object-fit: cover;
    border-radius: var(--border-radius-sm);
}

.signage-slide-empty {
    width: 100%;
    height: 112px;
    background: var(--bg-layer-2);
    border-radius: var(--border-radius-sm);
}

.signage-slide-number {
    position: absolute;
    top: var(--space-1);
    left: var(--space-1);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-layer-1);
    border-radius: var(--border-radius-full);
    font-size: var(--text-xs);
    font-weight: var(--font-weight-semibold);
    color: var(--text-muted);
    border: var(--border-width-1) solid var(--border-subtle);
}

.signage-slide-name {
    font-size: var(--text-xs);
    color: var(--text-muted);
    text-align: center;
    word-break: break-all;
}

/* =============================================
   SETTINGS
   ============================================= */

.signage-settings {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
    padding-top: var(--space-2);
    border-top: var(--border-width-1) solid var(--border-subtle);
}

.signage-settings-title {
    font-size: var(--text-sm);
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
    margin: 0;
}

.signage-settings-fields {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--space-3);
}

/* Save button alignment */
.signage-save {
    display: flex;
    justify-content: flex-end;
    padding-top: var(--space-2);
}

/* Compact upload zone inside location content */
.signage-location-content .file-upload-zone .upload-zone-label {
    padding: var(--space-3);
    min-height: auto;
}

/* =============================================
   ADD LOCATION MODAL
   ============================================= */

.signage-add-location-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.signage-form-hint {
    font-size: var(--text-xs);
    color: var(--text-muted);
    margin: 0;
}

/* =============================================
   TV PREVIEW OVERLAY
   ============================================= */

.signage-preview-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.signage-preview-overlay.active {
    display: flex;
}

/* Close button - top right of viewport */
.signage-preview-close {
    position: absolute;
    top: var(--space-4);
    right: var(--space-4);
    z-index: 1;
    background: none;
    border: none;
    padding: 0;
}

/* =============================================
   TV FRAME
   Landscape display bezel
   ============================================= */

.signage-tv-frame {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.signage-tv-screen {
    height: 80vh;
    max-height: 700px;
    aspect-ratio: 9 / 16;
    background: #1a1a1a;
    border-radius: 8px;
    padding: 8px;
    box-shadow:
        0 0 0 2px #333,
        0 20px 60px rgba(0, 0, 0, 0.5),
        inset 0 0 0 1px #2a2a2a;
    overflow: hidden;
}

.signage-tv-screen iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 4px;
    background: #000;
}

/* Stand beneath the screen */
.signage-tv-stand {
    width: 120px;
    height: 24px;
    background: linear-gradient(to bottom, #333, #222);
    border-radius: 0 0 6px 6px;
    margin-top: -2px;
}
