/**
 * Radio Komal - Live Player Stylesheet (Redesigned)
 * Matches original website theme (Orange/Gradient)
 */

:root {
    --primary: #ff6b35;
    --secondary: #f7931e;
    --accent: #fdc830;
    --dark: #1a1a2e;
    --light: #ffffff;
    --gradient: linear-gradient(135deg, #ff6b35 0%, #f7931e 50%, #fdc830 100%);
    --glass-bg: rgba(255, 255, 255, 0.95);
    --shadow: 0 20px 50px rgba(0,0,0,0.2);
}

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

body {
    font-family: 'Jost', sans-serif; /* Matches Homepage */
    background: var(--gradient);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-x: hidden;
    position: relative;
}

/* Background Animated Shapes */
body::before, body::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    z-index: 0;
}

body::before {
    top: -100px;
    right: -100px;
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.1);
    animation: float 8s ease-in-out infinite;
}

body::after {
    bottom: -50px;
    left: -50px;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.15);
    animation: float 6s ease-in-out infinite reverse;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

/* ===========================
   MAIN CONTAINER
   =========================== */
.live-container {
    width: 100%;
    max-width: 400px;
    background: var(--glass-bg);
    border-radius: 30px;
    box-shadow: var(--shadow);
    overflow: hidden;
    position: relative;
    z-index: 1;
    border: 1px solid rgba(255,255,255,0.5);
    display: flex;
    flex-direction: column;
}

/* Live Badge */
.live-indicator {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #ff0000;
    color: white;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 20;
    box-shadow: 0 5px 15px rgba(255, 0, 0, 0.3);
    display: flex;
    align-items: center;
    gap: 6px;
}

.live-indicator i {
    font-size: 10px;
    animation: blink 1.5s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ===========================
   PHONE DISPLAY SECTION
   =========================== */
.phone-display {
    background: linear-gradient(to bottom, #f8f9fa, #fff);
    padding: 15px;
    position: relative;
    border-bottom: 1px solid #eee;
}

/* Slideshow Wrapper - Looks like a screen */
.slideshow-wrapper {
    width: 100%;
    height: 400px; /* Tall aspect ratio */
    background: #000;
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.slideshow {
    display: flex;
    height: 100%;
    transition: transform 0.5s ease-in-out;
}

.slideshow img {
    min-width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Loading Overlay */
.loading-overlay {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    z-index: 10;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255,255,255,0.3);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ===========================
   PLAYER SECTION
   =========================== */
.player-section {
    padding: 25px;
    text-align: center;
    background: white;
    flex: 1;
    position: relative;
}

/* Logo overlaying the meeting point of phone/player */
.radio-logo {
    width: 70px;
    height: 70px;
    background: white;
    border-radius: 15px;
    padding: 5px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    position: absolute;
    top: -35px; /* Pulls it up into the phone section */
    left: 50%;
    transform: translateX(-50%);
    z-index: 15;
}

.radio-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 10px;
}

/* Info */
.station-info {
    margin-top: 35px; /* Clear the logo */
    margin-bottom: 20px;
}

.station-name {
    font-size: 24px;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 5px;
    line-height: 1.2;
}

.station-tagline {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

/* Marquee */
.song-info {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 10px;
    margin-bottom: 25px;
    overflow: hidden;
    border: 1px solid #eee;
}

.song-marquee {
    display: inline-block;
    white-space: nowrap;
    animation: scroll 15s linear infinite;
    font-size: 14px;
    color: var(--primary);
    font-weight: 600;
}

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

/* Play Button */
.play-btn {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: var(--gradient);
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(255, 107, 53, 0.4);
    transition: all 0.3s ease;
    margin-bottom: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.play-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 35px rgba(255, 107, 53, 0.5);
}

.play-btn i {
    margin-left: 4px; /* Optical center adjustment */
}

.play-btn i.fa-pause {
    margin-left: 0;
}

/* Controls */
.controls-info {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding-top: 20px;
    border-top: 1px solid #f0f0f0;
}

.info-link {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #888;
    font-size: 12px;
    gap: 5px;
    transition: color 0.3s ease;
}

.info-link i {
    font-size: 18px;
    color: var(--dark);
    background: #f5f5f5;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.info-link:hover i {
    background: var(--primary);
    color: white;
    transform: translateY(-3px);
}

.info-link:hover span {
    color: var(--primary);
}

.hide {
    display: none !important;
}

/* Mobile Adjustments */
@media (max-width: 400px) {
    .live-container {
        height: 100vh;
        border-radius: 0;
        max-width: 100%;
    }
    
    .phone-display {
        flex: 1;
        display: flex;
        flex-direction: column;
    }
    
    .slideshow-wrapper {
        flex: 1;
        height: auto;
    }
}