/* Reset and base */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #121212;
    color: #fff;
    line-height: 1.5;
}

a {
    color: inherit;
    text-decoration: none;
}

/* Navbar */
.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1.5rem;
    background: #1a1a1a;
    border-bottom: 1px solid #333;
}

.logo {
    font-size: 1.25rem;
    font-weight: 700;
    color: #3b82f6;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-links a {
    color: #888;
    transition: color 0.15s;
}

.nav-links a:hover {
    color: #fff;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.5rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s, opacity 0.15s;
    text-align: center;
}

.btn:hover {
    opacity: 0.9;
}

.btn-primary {
    background: #3b82f6;
    color: #fff;
}

.btn-secondary {
    background: #333;
    color: #fff;
}

.btn-danger {
    background: #ef4444;
    color: #fff;
}

/* Browse page */
.browse-page h1 {
    margin: 0 0 0.25rem;
    font-size: 2rem;
}

.subtitle {
    color: #888;
    margin: 0 0 2rem;
}

.section {
    margin-bottom: 2.5rem;
}

.section h2 {
    font-size: 1.25rem;
    margin: 0 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #333;
}

.section-subtitle {
    color: #888;
    margin: -0.5rem 0 1rem;
    font-size: 0.9rem;
}

/* Search */
.search-box {
    margin-bottom: 1rem;
}

.search-box input {
    width: 100%;
    max-width: 400px;
    padding: 0.6rem 1rem;
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 8px;
    color: #fff;
    font-size: 1rem;
}

.search-box input:focus {
    outline: none;
    border-color: #3b82f6;
}

/* Video grid */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.25rem;
}

.video-card {
    background: #1a1a1a;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.15s, box-shadow 0.15s;
}

.video-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.thumb-wrapper {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #252525;
}

.thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.duration {
    position: absolute;
    bottom: 4px;
    right: 4px;
    background: rgba(0, 0, 0, 0.8);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
}

.instrument-badge {
    position: absolute;
    top: 4px;
    left: 4px;
    background: #3b82f6;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
}

.video-card .video-info {
    padding: 0.75rem;
}

.video-card h3 {
    margin: 0 0 0.25rem;
    font-size: 0.9rem;
    font-weight: 500;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-card .channel {
    margin: 0;
    font-size: 0.8rem;
    color: #888;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #1a1a1a;
}

::-webkit-scrollbar-thumb {
    background: #444;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}
