/* =================================================================
   STREAMTV - ESTILOS PRINCIPALES
   ================================================================= */

/* Reset y Variables CSS */
:root {
    --color-black: #000000;
    --color-slate-950: rgb(2, 6, 23);
    --color-slate-900: rgb(15, 23, 42);
    --color-slate-800: rgb(30, 41, 59);
    --color-slate-700: rgb(51, 65, 85);
    --color-slate-600: rgb(71, 85, 105);
    --color-slate-400: rgb(148, 163, 184);
    --color-slate-300: rgb(203, 213, 225);
    --color-white: #ffffff;
    --color-blue-600: #2563eb;
    --color-blue-500: #3b82f6;
    --color-red-600: #dc2626;
    --color-red-500: #ef4444;
    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

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

body {
    font-family: var(--font-family);
    background-color: var(--color-black);
    color: var(--color-white);
    overflow: hidden;
    width: 100vw;
    height: 100vh;
}

/* =================================================================
   SPLASH SCREEN
   ================================================================= */

.splash-screen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--color-slate-950), var(--color-slate-900), var(--color-slate-950));
    animation: fadeIn 0.5s ease;
}

.splash-screen.fade-out {
    animation: fadeOut 0.5s ease forwards;
}

.splash-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    animation: scaleIn 0.6s ease;
}

.splash-spinner-container {
    position: relative;
    width: 12rem;
    height: 5rem;
}

.splash-spinner {
    position: absolute;
    inset: 0;
    border: 4px solid rgba(37, 99, 235, 0.3);
    border-top-color: var(--color-blue-600);
    border-radius: 50%;
    animation: spin 2s linear infinite;
}

.splash-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

.splash-logo {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    z-index: 1;
}

.splash-text {
    text-align: center;
}

.splash-text h1 {
    font-size: 1.875rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.splash-loading {
    color: var(--color-slate-400);
    animation: pulse 1.5s ease infinite;
}

/* =================================================================
   APP CONTAINER
   ================================================================= */

.app-container {
    width: 100%;
    height: 100%;
    position: relative;
    background-color: var(--color-black);
}

/* =================================================================
   VIDEO PLAYER
   ================================================================= */

.video-container {
    position: relative;
    width: 100%;
    height: 100%;
    background-color: var(--color-black);
    overflow: hidden;
}

.video-player {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* =================================================================
   LOADING INDICATOR
   ================================================================= */

.loading-indicator {
    position: absolute;
    inset: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
}

.loading-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    animation: scaleIn 0.3s ease;
}

.loading-spinner-container {
    position: relative;
    width: 6rem;
    height: 6rem;
}

.loading-spinner {
    position: absolute;
    inset: 0;
    border: 4px solid rgba(37, 99, 235, 0.3);
    border-top-color: var(--color-blue-600);
    border-radius: 50%;
    animation: spin 2s linear infinite;
}

.loading-logo {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

.loading-text {
    text-align: center;
}

.loading-text h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.loading-text p {
    color: var(--color-slate-400);
    animation: pulse 1.5s ease infinite;
}

/* =================================================================
   ERROR STATE
   ================================================================= */

.error-state {
    position: absolute;
    inset: 0;
    z-index: 20;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
}

.error-icon {
    width: 4rem;
    height: 4rem;
    color: var(--color-red-500);
    margin-bottom: 1rem;
}

.error-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.error-message {
    color: var(--color-slate-400);
    margin-bottom: 1.5rem;
}

.retry-button {
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    background-color: var(--color-blue-600);
    color: var(--color-white);
    font-size: 1rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.retry-button:hover {
    background-color: var(--color-blue-500);
    transform: scale(1.05);
}

.retry-button:focus {
    outline: none;
}

/* =================================================================
   PLAYER CONTROLS
   ================================================================= */

.player-controls {
    position: absolute;
    inset: 0;
    z-index: 30;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    pointer-events: none;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.player-controls.hidden {
    opacity: 0;
}

.controls-top,
.controls-bottom {
    pointer-events: auto;
}

.controls-top {
    padding: 1.5rem;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.channel-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.channel-logo-display {
    width: 3rem;
    height: 3rem;
    border-radius: 0.5rem;
    background-color: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    overflow: hidden;
}
.channel-logo-display .channel-logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.channel-details h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.channel-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.live-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    background-color: var(--color-red-600);
    font-size: 0.75rem;
    font-weight: 500;
}

.live-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background-color: var(--color-white);
    animation: pulse 2s ease infinite;
}

.channel-category {
    color: var(--color-slate-300);
    font-size: 0.875rem;
}

.current-time {
    font-size: 1.25rem;
    font-weight: 600;
}

.controls-bottom {
    padding: 1.5rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
}

.controls-container {
    background-color: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(24px);
    border: 1px solid rgba(71, 85, 105, 0.5);
    border-radius: 1rem;
    padding: 1rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.controls-left,
.controls-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.control-btn {
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border-radius: 50%;
    outline: none;
    -webkit-tap-highlight-color: transparent;
    box-shadow: none;
}
.control-btn:focus,
.control-btn:active {
    outline: none;
    box-shadow: none;
}

.primary-btn {
    width: 3rem;
    height: 3rem;
    background-color: var(--color-blue-600);
    color: var(--color-white);
}

.primary-btn:hover {
    background-color: var(--color-blue-500);
    transform: scale(1.05);
}

.secondary-btn {
    width: 2.5rem;
    height: 2.5rem;
    background-color: rgba(30, 41, 59, 0.5);
    color: var(--color-white);
}

.secondary-btn:hover {
    background-color: rgba(51, 65, 85, 0.5);
    transform: scale(1.05);
}

.icon {
    width: 1.25rem;
    height: 1.25rem;
}

.icon-md {
    width: 1.5rem;
    height: 1.5rem;
}

.icon-lg {
    width: 2rem;
    height: 2rem;
}

.icon-xl {
    width: 3rem;
    height: 3rem;
}

/* Volume Controls */
.volume-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
}

.volume-slider {
    overflow: hidden;
    animation: expandWidth 0.3s ease;
}

@keyframes expandWidth {
    from {
        width: 0;
        opacity: 0;
    }
    to {
        width: 7.5rem;
        opacity: 1;
    }
}

.volume-slider input[type="range"] {
    width: 7.5rem;
    height: 0.25rem;
    background: var(--color-slate-700);
    border-radius: 0.25rem;
    outline: none;
    cursor: pointer;
}

.volume-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 1rem;
    height: 1rem;
    background: var(--color-white);
    border: 2px solid var(--color-blue-600);
    border-radius: 50%;
    cursor: pointer;
}

.volume-slider input[type="range"]::-moz-range-thumb {
    width: 1rem;
    height: 1rem;
    background: var(--color-white);
    border: 2px solid var(--color-blue-600);
    border-radius: 50%;
    cursor: pointer;
}

/* =================================================================
   AUTOPLAY OVERLAY
   ================================================================= */

.autoplay-overlay {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.55);
    animation: fadeIn 0.3s ease;
}

.autoplay-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    padding: 2.5rem 3rem;
    border-radius: 1.5rem;
    background: linear-gradient(135deg, var(--color-blue-600), #1d4ed8);
    border: none;
    cursor: pointer;
    box-shadow: 0 25px 50px -12px rgba(37, 99, 235, 0.5);
    transition: all 0.3s ease;
    animation: scaleIn 0.4s ease;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}
.autoplay-button:focus,
.autoplay-button:active {
    outline: none;
    box-shadow: 0 25px 50px -12px rgba(37, 99, 235, 0.5);
}

.autoplay-button:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, var(--color-blue-500), var(--color-blue-600));
}

.autoplay-icon {
    width: 6rem;
    height: 6rem;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    transition: background-color 0.3s ease;
}

.autoplay-button:hover .autoplay-icon {
    background-color: rgba(255, 255, 255, 0.3);
}

.autoplay-text {
    text-align: center;
}

.autoplay-text h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-white);
    margin-bottom: 0.5rem;
}

.autoplay-text p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.875rem;
}

/* =================================================================
   GESTURE HINTS
   ================================================================= */

.gesture-hint {
    position: fixed;
    inset: 0;
    z-index: 10;
    pointer-events: none;
    animation: fadeIn 1s ease;
}

.gesture-hint-up {
    position: absolute;
    bottom: 5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    opacity: 0.6;
}

.gesture-hint-up span {
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.gesture-hint-left {
    position: absolute;
    top: 50%;
    left: 1rem;
    transform: translateY(-50%);
    opacity: 0.4;
}

.gesture-hint-right {
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translateY(-50%);
    opacity: 0.4;
}

/* =================================================================
   CHANNEL DRAWER (Desktop/TV)
   ================================================================= */

.channel-drawer {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: none;
}

.channel-drawer.open {
    display: block;
}

.drawer-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
    cursor: pointer;
}

.drawer-content {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 100%;
    max-width: 32.5rem;
    background-color: rgba(2, 6, 23, 0.95);
    backdrop-filter: blur(24px);
    border-left: 1px solid rgba(71, 85, 105, 0.5);
    box-shadow: -25px 0 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    animation: slideInRight 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid rgba(71, 85, 105, 0.5);
}

.drawer-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
}

.close-btn {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background-color: rgba(30, 41, 59, 0.5);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-slate-300);
    cursor: pointer;
    transition: all 0.3s ease;
}

.close-btn:hover {
    background-color: rgba(51, 65, 85, 0.5);
}

.close-btn:focus {
    outline: none;
}

/* =================================================================
   PANEL DE CONFIGURACIÓN
   ================================================================= */

.settings-panel {
    position: fixed;
    inset: 0;
    z-index: 45;
    display: none;
}
.settings-panel.open {
    display: block;
}

.settings-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
    cursor: pointer;
}

.settings-content {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 100%;
    max-width: 28rem;
    background-color: rgba(2, 6, 23, 0.98);
    backdrop-filter: blur(24px);
    border-left: 1px solid rgba(71, 85, 105, 0.5);
    box-shadow: -25px 0 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    animation: slideInRight 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.settings-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid rgba(71, 85, 105, 0.5);
}
.settings-header h2 {
    font-size: 1.25rem;
    font-weight: 700;
}

.settings-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
}

.settings-section {
    margin-bottom: 1.5rem;
}
.settings-section h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--color-slate-300);
}
.settings-description {
    font-size: 0.875rem;
    color: var(--color-slate-400);
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.settings-url-box {
    display: flex;
    gap: 0.5rem;
    align-items: stretch;
}
.settings-url-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    background-color: rgba(15, 23, 42, 0.5);
    border: 1px solid rgba(71, 85, 105, 0.5);
    color: var(--color-slate-300);
    font-size: 0.8125rem;
    font-family: inherit;
}
.settings-url-input:focus {
    outline: none;
    border-color: var(--color-blue-500);
}
.copy-url-btn {
    padding: 0.75rem 1.25rem;
    border-radius: 0.5rem;
    background-color: var(--color-blue-600);
    color: var(--color-white);
    font-size: 0.875rem;
    font-weight: 500;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    transition: background-color 0.2s ease;
}
.copy-url-btn:hover {
    background-color: var(--color-blue-500);
}
.copy-url-btn:focus {
    outline: none;
}

.settings-footer {
    padding: 1.5rem;
    border-top: 1px solid rgba(71, 85, 105, 0.5);
    text-align: center;
}
.settings-signature {
    font-size: 0.875rem;
    color: var(--color-slate-400);
    text-decoration: none;
    transition: color 0.2s ease;
}
.settings-signature:hover {
    color: var(--color-blue-400);
}

.drawer-search {
    position: relative;
    padding: 1.5rem;
    padding-bottom: 1rem;
}

.search-icon {
    position: absolute;
    left: 2.5rem;
    top: 50%;
    transform: translateY(-50%);
    width: 1.25rem;
    height: 1.25rem;
    color: var(--color-slate-400);
}

.search-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    border-radius: 0.5rem;
    background-color: rgba(15, 23, 42, 0.5);
    border: 1px solid rgba(71, 85, 105, 0.5);
    color: var(--color-white);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-input::placeholder {
    color: var(--color-slate-400);
}

.search-input:focus {
    outline: none;
    border-color: var(--color-blue-500);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

.drawer-categories {
    padding: 0 1.5rem 1rem;
}

.categories-scroll {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
}

.categories-scroll::-webkit-scrollbar {
    height: 4px;
}

.categories-scroll::-webkit-scrollbar-track {
    background: rgba(30, 41, 59, 0.5);
    border-radius: 2px;
}

.categories-scroll::-webkit-scrollbar-thumb {
    background: var(--color-slate-600);
    border-radius: 2px;
}

.category-chip {
    padding: 0.625rem 1.25rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
    white-space: nowrap;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-chip.active {
    background-color: var(--color-blue-600);
    color: var(--color-white);
    box-shadow: 0 10px 15px -3px rgba(37, 99, 235, 0.3);
}

.category-chip:not(.active) {
    background-color: rgba(30, 41, 59, 0.5);
    color: var(--color-slate-300);
}

.category-chip:not(.active):hover {
    background-color: rgba(51, 65, 85, 0.5);
}

.category-chip:focus {
    outline: none;
}

.drawer-channels {
    flex: 1;
    overflow-y: auto;
    padding: 0 1.5rem 1.5rem;
}

.channels-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.channel-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border-radius: 0.75rem;
    border: none;
    width: 100%;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.channel-item.active {
    background-color: var(--color-blue-600);
    color: var(--color-white);
    box-shadow: 0 10px 15px -3px rgba(37, 99, 235, 0.3);
}

.channel-item:not(.active) {
    background-color: rgba(30, 41, 59, 0.5);
    color: var(--color-slate-200);
}

.channel-item:not(.active):hover {
    background-color: rgba(51, 65, 85, 0.5);
}

.channel-item:focus {
    outline: none;
}

.channel-item-logo {
    width: 4rem;
    height: 4rem;
    border-radius: 0.5rem;
    background-color: rgba(15, 23, 42, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    flex-shrink: 0;
}

.channel-item-info {
    flex: 1;
    min-width: 0;
}

.channel-item-name {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.channel-item-category {
    font-size: 0.875rem;
    opacity: 0.8;
}

.channel-item.active .channel-item-category {
    color: rgba(255, 255, 255, 0.9);
}

.channel-item:not(.active) .channel-item-category {
    color: var(--color-slate-400);
}

.channel-item-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    flex-shrink: 0;
}

.channel-item.active .channel-item-badge {
    background-color: rgba(255, 255, 255, 0.2);
    color: var(--color-white);
}

.channel-item:not(.active) .channel-item-badge {
    background-color: var(--color-red-600);
    color: var(--color-white);
}

.badge-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background-color: var(--color-red-500);
    animation: pulse 2s ease infinite;
}

/* =================================================================
   MOBILE SHEET
   ================================================================= */

.mobile-sheet {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: none;
}

.mobile-sheet.open {
    display: block;
}

.sheet-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
    cursor: pointer;
}

.sheet-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    max-height: 85vh;
    background-color: rgba(2, 6, 23, 0.95);
    backdrop-filter: blur(24px);
    border-top: 1px solid rgba(71, 85, 85, 0.5);
    border-radius: 1.5rem 1.5rem 0 0;
    box-shadow: 0 -25px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    animation: slideInUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.sheet-handle {
    display: flex;
    justify-content: center;
    padding: 0.75rem 0 0.5rem;
}

.sheet-handle::before {
    content: '';
    width: 3rem;
    height: 0.375rem;
    border-radius: 9999px;
    background-color: var(--color-slate-700);
}

.sheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem 1rem;
}

.sheet-header h2 {
    font-size: 1.25rem;
    font-weight: 700;
}

.sheet-search {
    position: relative;
    padding: 0 1.5rem 1rem;
}

.sheet-categories {
    padding: 0 1.5rem 1rem;
}

.sheet-channels {
    flex: 1;
    overflow-y: auto;
    padding: 0 1.5rem 1.5rem;
}

/* =================================================================
   TOAST NOTIFICATIONS
   ================================================================= */

.toast-container {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 60;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    pointer-events: none;
}

.toast {
    padding: 1rem 1.5rem;
    border-radius: 0.75rem;
    background-color: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(71, 85, 105, 0.5);
    color: var(--color-white);
    font-size: 0.875rem;
    font-weight: 500;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    animation: slideInUp 0.3s ease;
    pointer-events: auto;
}

.toast.fade-out {
    animation: fadeOut 0.3s ease forwards;
}

/* Botón Instalar PWA */
.install-pwa-btn {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 55;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.25rem;
    background: linear-gradient(135deg, var(--color-blue-600), #1d4ed8);
    color: var(--color-white);
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.4);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.install-pwa-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 15px 30px -5px rgba(37, 99, 235, 0.5);
}

/* =================================================================
   ANIMATIONS
   ================================================================= */

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

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

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

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-25%);
    }
}

.bounce {
    animation: bounce 1s ease infinite;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
    }
    to {
        transform: translateX(0);
    }
}

@keyframes slideInUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

/* =================================================================
   RESPONSIVE DESIGN
   ================================================================= */

/* Mobile */
@media (max-width: 767px) {
    .channel-drawer {
        display: none !important;
    }
    
    .controls-container {
        padding: 0.75rem;
    }
    
    .primary-btn {
        width: 2.5rem;
        height: 2.5rem;
    }
    
    .secondary-btn {
        width: 2rem;
        height: 2rem;
    }
    
    .icon {
        width: 1rem;
        height: 1rem;
    }
}

/* Desktop */
@media (min-width: 768px) {
    .mobile-sheet {
        display: none !important;
    }
}

/* TV/4K */
@media (min-width: 1920px) {
    :root {
        font-size: 20px;
    }
    
    .control-btn {
        min-width: 3.5rem;
        min-height: 3.5rem;
    }
    
    .control-btn:focus {
        outline: none;
    }
}

/* Focus visible for keyboard navigation */
*:focus,
*:focus-visible {
    outline: none;
}
