/* CliniSys - Estilos da TV Sala de Espera */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --gradient-bg: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --call-gradient: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    --success-gradient: linear-gradient(135deg, #00b894 0%, #00a085 100%);
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--gradient-bg);
    color: white;
    overflow: hidden;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

.container-fluid {
    height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 0;
}

/* Header */
.tv-header {
    background: rgba(0, 0, 0, 0.8);
    padding: 20px 40px;
    border-bottom: 3px solid var(--primary-color);
    backdrop-filter: blur(10px);
}

.clinic-name {
    font-size: 2.5rem;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    margin: 0;
    color: white;
}

.clock {
    font-size: 2rem;
    font-weight: bold;
    text-align: right;
    color: var(--info-color);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

/* Main Content */
.tv-main {
    flex: 1;
    padding: 30px 40px;
    overflow: hidden;
}

.section-title {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 20px;
    text-align: center;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    color: white;
}

/* Calls Container */
.calls-container {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.calls-list {
    flex: 1;
    overflow-y: auto;
    padding-right: 20px;
}

.call-item {
    background: var(--call-gradient);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    animation: slideInLeft 0.8s ease-out, pulse 2s infinite;
    border: 3px solid rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.call-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shine 3s infinite;
}

.call-item.urgent {
    background: var(--danger-color);
    animation: slideInLeft 0.8s ease-out, urgentPulse 1s infinite;
}

.call-item.preferential {
    background: var(--warning-color);
    color: #000;
}

.call-number {
    font-size: 4rem;
    font-weight: bold;
    text-align: center;
    margin-bottom: 15px;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.5);
}

.call-patient {
    font-size: 2.5rem;
    font-weight: bold;
    text-align: center;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.call-doctor {
    font-size: 1.8rem;
    text-align: center;
    margin-bottom: 10px;
    opacity: 0.9;
}

.call-location {
    font-size: 1.5rem;
    text-align: center;
    font-weight: bold;
    background: rgba(255, 255, 255, 0.2);
    padding: 10px;
    border-radius: 8px;
    backdrop-filter: blur(5px);
}

.call-type {
    position: absolute;
    top: 10px;
    right: 15px;
    background: rgba(255, 255, 255, 0.3);
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.9rem;
    font-weight: bold;
}

/* Info Container */
.info-container {
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.info-box {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.3s ease;
}

.info-box:hover {
    transform: translateY(-5px);
}

.info-box h4 {
    margin: 10px 0;
    font-size: 1.3rem;
}

.info-box p {
    margin: 5px 0;
    font-size: 1rem;
}

.video-placeholder {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    padding: 20px;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px dashed rgba(255, 255, 255, 0.3);
}

/* Footer */
.tv-footer {
    background: rgba(0, 0, 0, 0.8);
    padding: 15px 40px;
    border-top: 3px solid var(--primary-color);
    backdrop-filter: blur(10px);
}

#tv-ticker {
    font-size: 1.2rem;
    text-align: center;
    margin: 0;
    animation: ticker 20s linear infinite;
    white-space: nowrap;
}

/* Animations */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
    }
}

@keyframes urgentPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 10px 30px rgba(220, 53, 69, 0.5);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 20px 50px rgba(220, 53, 69, 0.7);
    }
}

@keyframes shine {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

@keyframes ticker {
    0% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(-100%);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Empty State */
.empty-calls {
    text-align: center;
    padding: 60px 20px;
    opacity: 0.7;
}

.empty-calls i {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-calls h3 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.empty-calls p {
    font-size: 1.2rem;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .clinic-name {
        font-size: 2rem;
    }
    
    .clock {
        font-size: 1.5rem;
    }
    
    .call-number {
        font-size: 3rem;
    }
    
    .call-patient {
        font-size: 2rem;
    }
    
    .call-doctor {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .tv-header,
    .tv-main,
    .tv-footer {
        padding: 15px 20px;
    }
    
    .clinic-name {
        font-size: 1.5rem;
    }
    
    .clock {
        font-size: 1.2rem;
    }
    
    .call-number {
        font-size: 2.5rem;
    }
    
    .call-patient {
        font-size: 1.5rem;
    }
    
    .call-doctor {
        font-size: 1.2rem;
    }
    
    .call-location {
        font-size: 1.2rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .call-item {
        border: 3px solid white;
    }
    
    .info-box {
        border: 2px solid white;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .call-item {
        animation: none;
    }
    
    #tv-ticker {
        animation: none;
    }
    
    .info-box {
        transition: none;
    }
}

/* Print Styles */
@media print {
    body {
        background: white;
        color: black;
    }
    
    .tv-header,
    .tv-footer {
        background: #f8f9fa;
        color: black;
    }
    
    .call-item {
        background: #e9ecef;
        color: black;
        box-shadow: none;
        border: 1px solid #dee2e6;
    }
}

/* Custom Scrollbar */
.calls-list::-webkit-scrollbar {
    width: 8px;
}

.calls-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.calls-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
}

.calls-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Special Effects */
.call-item.new-call {
    animation: bounceIn 1s ease-out;
}

.call-item.removing {
    animation: slideOutRight 0.5s ease-in forwards;
}

@keyframes slideOutRight {
    to {
        opacity: 0;
        transform: translateX(100px);
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus Styles */
.call-item:focus {
    outline: 3px solid var(--info-color);
    outline-offset: 2px;
}

