/**
 * Tactical Engine Styles
 * Professional broadcast-quality UI
 */

/* Stage Container */
.tactical-stage {
    position: relative;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, #07111d 0%, #0b1622 100%);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}

.tactical-stage canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
    cursor: grab;
}

.tactical-stage canvas:active {
    cursor: grabbing;
}

.tactical-stage--free canvas {
    cursor: move;
}

/* Timeline Controls */
.tactical-timeline {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 48px;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.8) 100%);
    display: flex;
    align-items: center;
    padding: 0 16px;
    gap: 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.tactical-stage:hover .tactical-timeline {
    opacity: 1;
    pointer-events: auto;
}

/* Play/Pause Button */
.tactical-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.tactical-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.05);
}

.tactical-btn:active {
    transform: scale(0.95);
}

.tactical-btn svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

/* Timeline Slider */
.tactical-slider {
    flex: 1;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    position: relative;
    cursor: pointer;
}

.tactical-slider__progress {
    height: 100%;
    background: #4ade80;
    border-radius: 2px;
    width: 0%;
    transition: width 0.1s linear;
}

.tactical-slider__handle {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    left: 0%;
}

/* Time Display */
.tactical-time {
    font-family: 'SF Mono', Monaco, monospace;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    min-width: 80px;
    text-align: center;
}

/* Speed Control */
.tactical-speed {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
}

.tactical-speed__btn {
    background: none;
    border: none;
    color: white;
    font-size: 12px;
    cursor: pointer;
    padding: 2px 4px;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.tactical-speed__btn:hover {
    opacity: 1;
}

.tactical-speed__value {
    min-width: 32px;
    text-align: center;
}

/* Camera Controls */
.tactical-camera {
    position: absolute;
    top: 16px;
    right: 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tactical-stage:hover .tactical-camera {
    opacity: 1;
}

.tactical-camera__btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    background: rgba(0, 0, 0, 0.5);
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.tactical-camera__btn:hover {
    background: rgba(0, 0, 0, 0.7);
    color: white;
}

.tactical-camera__btn.active {
    background: #3b82f6;
    color: white;
}

.tactical-camera__btn svg {
    width: 16px;
    height: 16px;
}

/* Info Overlay */
.tactical-info {
    position: absolute;
    top: 16px;
    left: 16px;
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    border-radius: 8px;
    color: white;
    max-width: 280px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tactical-stage:hover .tactical-info {
    opacity: 1;
}

.tactical-info__title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.tactical-info__desc {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.4;
}

/* Loading State */
.tactical-loading {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #07111d;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
}

.tactical-loading::after {
    content: '';
    width: 24px;
    height: 24px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-top-color: #4ade80;
    border-radius: 50%;
    margin-left: 12px;
    animation: tactical-spin 0.8s linear infinite;
}

@keyframes tactical-spin {
    to {
        transform: rotate(360deg);
    }
}

/* Keyboard Shortcuts Help */
.tactical-help {
    position: absolute;
    bottom: 56px;
    right: 16px;
    padding: 12px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    border-radius: 8px;
    color: white;
    font-size: 11px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.tactical-stage:hover .tactical-help {
    opacity: 0.8;
}

.tactical-help kbd {
    display: inline-block;
    padding: 2px 6px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 3px;
    font-family: inherit;
    margin-right: 4px;
}

/* Responsive */
@media (max-width: 640px) {
    .tactical-timeline {
        padding: 0 8px;
        height: 40px;
    }
    
    .tactical-camera {
        top: 8px;
        right: 8px;
    }
    
    .tactical-info {
        top: 8px;
        left: 8px;
        max-width: 200px;
        padding: 8px 12px;
    }
    
    .tactical-help {
        display: none;
    }
}

/* Fullscreen Mode */
.tactical-stage.fullscreen {
    position: fixed;
    inset: 0;
    z-index: 1000;
    border-radius: 0;
}

.tactical-fullscreen-btn {
    position: absolute;
    top: 16px;
    right: 56px;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    background: rgba(0, 0, 0, 0.5);
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
    opacity: 0;
}

.tactical-stage:hover .tactical-fullscreen-btn {
    opacity: 1;
}

.tactical-fullscreen-btn:hover {
    background: rgba(0, 0, 0, 0.7);
    color: white;
}
