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

body {
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(135deg, #fdf2f8 0%, #e0f2fe 50%, #f0f9ff 100%); /* Pastel pink to light blue gradient */
    color: #333333; /* Dark text for contrast */
    line-height: 1.6;
    min-height: 100vh;
}

a {
    color: #a78bfa; /* Soft lavender */
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
}

a:hover {
    color: #8b5cf6; /* Brighter lavender on hover */
    text-shadow: 0 0 5px rgba(139, 92, 246, 0.3);
}

h1, h2, h3 {
    font-weight: 400; /* Lighter weight for airy feel */
    margin-bottom: 1rem;
    color: #1e293b; /* Soft navy */
    text-align: center;
}

ul {
    list-style: none;
    padding: 0;
}

li {
    margin-bottom: 0.5rem;
}

button, input[type="submit"] {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%); /* Pastel yellow-orange */
    border: none;
    color: #1e293b;
    padding: 0.75rem 1.5rem;
    border-radius: 12px; /* Softer corners */
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(251, 191, 36, 0.2);
    position: relative;
    overflow: hidden;
}

button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

button:hover::before {
    left: 100%;
}

button:hover, input[type="submit"]:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 6px 20px rgba(251, 191, 36, 0.3);
}

button:active {
    transform: translateY(0);
}

/* Forms and Inputs - Comprehensive Styling */
form {
    max-width: 400px;
    margin: 2rem auto;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.8); /* Soft white glass */
    border-radius: 20px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(165, 243, 252, 0.5); /* Pastel cyan border */
}

input[type="text"], 
input[type="password"], 
input[type="file"],
select {
    width: 100%;
    padding: 0.875rem;
    margin-bottom: 1rem;
    border: 2px solid rgba(165, 243, 252, 0.3); /* Pastel cyan */
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    font-size: 1rem;
    transition: all 0.3s ease;
}

input[type="text"]:focus, 
input[type="password"]:focus,
select:focus {
    outline: none;
    border-color: #a78bfa; /* Lavender focus */
    box-shadow: 0 0 0 4px rgba(167, 139, 250, 0.2);
    transform: scale(1.02);
}

input[type="file"] {
    cursor: pointer;
}

/* Flash Messages */
ul[style*="background"] { /* Target flashed messages */
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%); /* Pastel yellow */
    border-left: 4px solid #f59e0b;
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 0 12px 12px 0;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.1);
}

ul[style*="background"] li {
    color: #92400e; /* Warm brown text */
}

/* Container and Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 16px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* Selectors and Filters */
.category-selector, .letter-filters {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 16px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.category-selector h3, .letter-filters h3 {
    margin-bottom: 1rem;
    color: #64748b; /* Soft gray */
}

.category-selector select {
    width: 100%;
    max-width: 300px;
    padding: 0.875rem;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(165, 243, 252, 0.3);
    color: #333;
    border-radius: 12px;
    font-size: 1rem;
    cursor: pointer;
}

.letter-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.letter-filters a {
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #a7f3d0 0%, #6ee7b7 100%); /* Pastel mint */
    border-radius: 20px;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(110, 231, 183, 0.2);
}

.letter-filters a:hover {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%); /* Brighter mint */
    color: white;
    transform: scale(1.05);
}

/* Channel Grids and Cards - Enhanced */
.channel-grid, .channel-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
}

.channel-card {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.4s ease;
    border: 2px solid rgba(167, 139, 250, 0.2); /* Lavender border */
    backdrop-filter: blur(5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

.channel-card:hover {
    transform: translateY(-8px) rotate(1deg); /* Playful hover */
    box-shadow: 0 15px 40px rgba(167, 139, 250, 0.3);
    border-color: #a78bfa;
}

.channel-card img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.channel-card img:hover {
    transform: scale(1.05);
}

.channel-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: #1e293b;
}

.channel-card p {
    color: #64748b;
    font-size: 0.9rem;
    font-style: italic;
}

/* Player Page - Full Coverage */
.player-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.player-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 1rem;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%); /* Pastel yellow header */
    border-radius: 16px;
}

.player-header h1 {
    text-align: left;
    color: #92400e;
}

.player-logo {
    max-width: 200px;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.player-logo:hover {
    transform: rotate(5deg);
}

#video {
    width: 100%;
    max-width: 800px;
    height: auto;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    background: #000; /* Black fallback for video */
}

/* Admin Pages - Tailored Styling (Updated for Alignment) */
.admin-nav {
    background: linear-gradient(135deg, #e0f2fe 0%, #f0f9ff 100%); /* Pastel blue */
    padding: 1rem;
    margin-bottom: 2rem;
    border-radius: 12px;
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(165, 243, 252, 0.5);
}

.admin-nav p {
    color: #475569;
    margin: 0;
}

.admin-section {
    margin-bottom: 3rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 16px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.channel-admin-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1rem;
}

.channel-admin-item {
    background: rgba(255, 255, 255, 0.9);
    padding: 1.5rem;
    border-radius: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: 4px solid #fbbf24; /* Pastel yellow for on-air */
    box-shadow: 0 4px 12px rgba(251, 191, 36, 0.1);
    transition: all 0.3s ease;
    height: 80px; /* Fixed height for uniformity */
    gap: 1rem; /* Space between text and button */
}

.channel-admin-item .text-content {
    flex: 1;
    min-width: 0; /* Allow shrinking */
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden; /* Hide overflow for long names */
}

.channel-admin-item .text-content a {
    white-space: nowrap; /* Prevent wrapping for preview link */
    overflow: hidden;
    text-overflow: ellipsis; /* Ellipsis for long names */
    margin-bottom: 0.25rem;
    font-size: 0.95rem;
}

.channel-admin-item .text-content p {
    font-size: 0.85rem;
    color: #64748b;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.channel-admin-item .button-container {
    flex-shrink: 0; /* Button doesn't shrink */
    display: flex;
    align-items: center;
}

.channel-admin-item form {
    margin: 0;
}

.channel-admin-item button {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    margin: 0;
    white-space: nowrap;
    min-width: 120px; /* Fixed min-width for buttons */
    text-align: center;
}

.channel-admin-item:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 20px rgba(251, 191, 36, 0.2);
}

.channel-admin-item.off-air {
    border-left-color: #fca5a5; /* Pastel red */
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    box-shadow: 0 4px 12px rgba(252, 165, 165, 0.1);
}

.off-air-indicator {
    color: #dc2626;
    font-weight: 500;
    padding: 0.25rem 0.75rem;
    background: rgba(252, 165, 165, 0.3);
    border-radius: 20px;
    font-size: 0.875rem;
    box-shadow: 0 2px 8px rgba(220, 38, 38, 0.1);
    margin-left: 0.5rem;
    flex-shrink: 0;
}
/* Animations - Playful Pastel */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.channel-card, .channel-admin-item {
    animation: fadeInUp 0.6s ease-out forwards;
}

button:hover {
    animation: pulse 0.6s ease-in-out;
}

/* Additional Element Coverage */
p {
    margin-bottom: 1rem;
    color: #475569;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto 1rem;
}

video {
    display: block;
    margin: 0 auto;
}

/* Scrollbar Styling for Modern Touch */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #a78bfa, #fbbf24);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #8b5cf6, #f59e0b);
}
