/* phonix2you | Phoenix Fire Theme */

/* Base & Reset */
:root {
    --app-height: 100vh;
}

body {
    -webkit-tap-highlight-color: transparent;
    font-feature-settings: "cv11", "ss01";
    /* Phoenix Backgrounds */
    background-color: #fff7ed;
    /* orange-50 */
    color: #431407;
    /* orange-950 */
    height: 100vh;
    /* Fallback */
    height: 100dvh;
    overflow: hidden;
    /* Prevent bounce */
}

/* Mobile Safe Areas */
.safe-bottom {
    padding-bottom: env(safe-area-inset-bottom, 20px);
}

.no-select {
    -webkit-user-select: none;
    user-select: none;
}

.dark body {
    background-color: #0f0502;
    /* Very dark burnt orange/black */
    color: #fff7ed;
}

/* Typography Enhancements */
[dir="rtl"] {
    font-family: 'IBM Plex Sans Arabic', sans-serif;
}

/* Custom Scrollbar - Fiery */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background-color: rgba(249, 115, 22, 0.3);
    /* Orange-500 low opacity */
    border-radius: 99px;
    transition: background-color 0.2s;
}

.dark ::-webkit-scrollbar-thumb {
    background-color: rgba(234, 88, 12, 0.4);
    /* Orange-600 */
}

::-webkit-scrollbar-thumb:hover {
    background-color: rgba(249, 115, 22, 0.8);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.fade-in {
    animation: fadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Fire Pulse - Enhanced for Logo Compatibility */
@keyframes fire-pulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(249, 115, 22, 0);
        transform: scale(1);
    }

    50% {
        box-shadow: 0 0 20px 4px rgba(249, 115, 22, 0.2);
        transform: scale(1.02);
    }
}

.animate-pulse-fire {
    animation: fire-pulse 2.5s infinite cubic-bezier(0.4, 0, 0.6, 1);
}

/* Phoenix Glow Effect */
.phoenix-glow {
    filter: drop-shadow(0 0 8px rgba(249, 115, 22, 0.4));
}

.dark .phoenix-glow {
    filter: drop-shadow(0 0 12px rgba(249, 115, 22, 0.6));
}

/* Glassmorphism Utilities - Warm Tint */
.glass {
    background: rgba(255, 247, 237, 0.8);
    /* Warm White */
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(253, 186, 116, 0.2);
}

/* Mobile Performance: Reduce blur */
@media (max-width: 768px) {
    .glass {
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
    }
}

.dark .glass {
    background: rgba(25, 8, 5, 0.8);
    /* Dark amber/black */
    border-bottom: 1px solid rgba(234, 88, 12, 0.1);
}

.glass-panel {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(251, 146, 60, 0.1);
}

.dark .glass-panel {
    background: rgba(67, 20, 7, 0.4);
    border: 1px solid rgba(234, 88, 12, 0.1);
}

/* Text Gradients - Matched to Phoenix Logo */
.text-gradient-fire {
    background: linear-gradient(135deg, #fbbf24 0%, #f97316 50%, #dc2626 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Loading Spinner - Fire Color */
.loader {
    border: 3px solid rgba(249, 115, 22, 0.1);
    border-radius: 50%;
    border-top: 3px solid #f97316;
    width: 28px;
    height: 28px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Video Call UI */
#call-container {
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

#remote-video {
    background: #0f172a;
}

#local-video {
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.1);
    transform: translateZ(0);
    z-index: 10;
}

/* Incoming Call Phoenix Fire Animation */
@keyframes call-glow {

    0%,
    100% {
        box-shadow: 0 0 20px rgba(249, 115, 22, 0.4);
    }

    50% {
        box-shadow: 0 0 40px rgba(234, 88, 12, 0.7);
    }
}

.animate-pulse-fire {
    animation: call-glow 2s infinite ease-in-out;
}

/* Picture in Picture placeholder style if unsupported */
.pip-unsupported {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Mobile optimizations for call UI */
@media (max-width: 768px) {
    #local-video {
        width: 100px;
        height: 140px;
        top: 1rem;
        right: 1rem;
    }
}