* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    background-color: #09090c;
    color: #e1e1e6;
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* Sidebar Navigation */
sidebar {
    width: 260px;
    background-color: #111116;
    border-right: 1px solid #1c1c24;
    display: flex;
    flex-direction: column;
    padding: 20px 14px;
    flex-shrink: 0;
}

.app-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 10px 20px 10px;
    border-bottom: 1px solid #1c1c24;
    margin-bottom: 16px;
    text-decoration: none;
    color: #fff;
}

.app-icon {
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    font-size: 20px;
    box-shadow: 0 4px 14px rgba(139, 92, 246, 0.4);
}

.app-name {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: #fff;
}

.nav-section-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: #525266;
    letter-spacing: 1px;
    padding: 12px 10px 6px 10px;
}

.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 12px;
}

.nav-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    color: #8f8f9d;
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.15s ease;
    cursor: pointer;
}

.nav-item-link {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-item:hover {
    color: #ffffff;
    background-color: #1a1a22;
}

.nav-item.active {
    background-color: #8b5cf620;
    color: #a78bfa;
    font-weight: 600;
}

.nav-badge {
    background-color: #22222e;
    color: #8f8f9d;
    font-size: 11px;
    padding: 2px 7px;
    border-radius: 10px;
}

.nav-item.active .nav-badge {
    background-color: #8b5cf633;
    color: #a78bfa;
}

.user-account-btn {
    margin-top: auto;
    background-color: #16161e;
    border: 1px solid #22222e;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: #fff;
    transition: border-color 0.2s, background-color 0.2s;
}

.user-account-btn:hover {
    border-color: #8b5cf688;
    background-color: #1c1c28;
}

.user-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, #06b6d4, #3b82f6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #fff;
    font-size: 13px;
}

.user-info {
    flex: 1;
    overflow: hidden;
}

.user-name {
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-status {
    font-size: 11px;
    color: #a78bfa;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Main Content Area */
.content-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    background-color: #09090c;
}

topbar {
    height: 64px;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #16161e;
    position: sticky;
    top: 0;
    background-color: rgba(9, 9, 12, 0.88);
    backdrop-filter: blur(12px);
    z-index: 50;
}

.search-input-wrapper {
    position: relative;
    width: 360px;
}

.search-input-wrapper input {
    width: 100%;
    padding: 9px 14px 9px 38px;
    background-color: #14141a;
    border: 1px solid #22222e;
    border-radius: 20px;
    color: #fff;
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
}

.search-input-wrapper input:focus {
    border-color: #8b5cf6;
}

.search-input-wrapper .search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #626273;
    font-size: 13px;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-primary {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    border: none;
    padding: 9px 18px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(139, 92, 246, 0.3);
    transition: transform 0.15s, box-shadow 0.15s, opacity 0.2s;
    text-decoration: none;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(139, 92, 246, 0.4);
    opacity: 0.95;
}

.btn-secondary {
    background: #181822;
    color: #e1e1e6;
    border: 1px solid #262636;
    padding: 9px 16px;
    border-radius: 20px;
    font-weight: 500;
    font-size: 13px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background-color 0.2s, color 0.2s;
}

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

main {
    padding: 32px;
    flex: 1;
}

.page-header {
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.page-title {
    font-size: 26px;
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.5px;
}

/* Feature Banners */
.hero-banner {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.15));
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 16px;
    padding: 24px 28px;
    margin-bottom: 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-content {
    max-width: 620px;
}

.hero-title {
    font-size: 20px;
    font-weight: 800;
    color: #fff;
    margin-bottom: 8px;
}

.hero-text {
    font-size: 13.5px;
    color: #b4b4c7;
    line-height: 1.5;
}

.hero-badge {
    background: #8b5cf6;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    text-transform: uppercase;
    display: inline-block;
    margin-bottom: 8px;
}

/* Media Grid */
.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 24px 20px;
    margin-bottom: 40px;
}

.media-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    position: relative;
    cursor: pointer;
}

.poster-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 2 / 3;
    border-radius: 12px;
    overflow: hidden;
    background-color: #181820;
    margin-bottom: 10px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.4);
    border: 1px solid #22222e;
    transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.25s, border-color 0.25s;
}

.media-card:hover .poster-wrapper {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 14px 28px rgba(0,0,0,0.6);
    border-color: #8b5cf688;
}

.poster-svg {
    width: 100%;
    height: 100%;
    display: block;
}

.play-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s;
}

.media-card:hover .play-overlay {
    opacity: 1;
}

.play-circle {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 20px;
    padding-left: 3px;
    box-shadow: 0 4px 18px rgba(139, 92, 246, 0.6);
    transform: scale(0.85);
    transition: transform 0.2s;
}

.media-card:hover .play-circle {
    transform: scale(1);
}

.badge-quality {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0,0,0,0.82);
    backdrop-filter: blur(4px);
    color: #a78bfa;
    font-size: 10px;
    font-weight: 800;
    padding: 3px 6px;
    border-radius: 4px;
    border: 1px solid rgba(139, 92, 246, 0.3);
}

.badge-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,0.8);
    color: #ddd;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
}

.media-title {
    font-size: 14.5px;
    font-weight: 700;
    color: #f1f1f6;
    line-height: 1.3;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.media-desc {
    font-size: 12px;
    color: #9393a5;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 6px;
}

.media-info {
    font-size: 11.5px;
    color: #626275;
    display: flex;
    gap: 8px;
    align-items: center;
    font-weight: 500;
}

/* Settings & Form Layouts */
.settings-container {
    max-width: 900px;
}

.settings-section {
    background-color: #121218;
    border: 1px solid #1c1c26;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.section-title {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.form-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid #1a1a24;
}

.form-group:last-child {
    border-bottom: none;
}

.form-label {
    font-size: 14px;
    font-weight: 500;
    color: #e1e1e6;
}

.form-desc {
    font-size: 12px;
    color: #626273;
    margin-top: 2px;
}

.form-control-select, .form-control-input {
    background-color: #1a1a24;
    border: 1px solid #262636;
    color: #fff;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 13px;
    outline: none;
}

.form-control-select:focus, .form-control-input:focus {
    border-color: #8b5cf6;
}

/* Protocols Card Grid */
.protocol-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.protocol-card {
    background: #121218;
    border: 1px solid #1c1c26;
    border-radius: 12px;
    padding: 20px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
    cursor: pointer;
}

.protocol-card:hover {
    border-color: #8b5cf688;
    transform: translateY(-2px);
    background: #161620;
}

.protocol-icon {
    width: 44px;
    height: 44px;
    background: #1a1a26;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.protocol-title {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}

.protocol-desc {
    font-size: 12px;
    color: #8f8f9d;
    line-height: 1.4;
    margin-bottom: 8px;
}

.protocol-status {
    font-size: 11px;
    color: #a78bfa;
    font-weight: 600;
}

/* News List */
.news-item {
    background-color: #121218;
    border: 1px solid #1c1c26;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    display: flex;
    gap: 20px;
}

.news-date {
    background: #1a1a26;
    padding: 8px 12px;
    border-radius: 8px;
    text-align: center;
    height: fit-content;
    min-width: 80px;
}

.news-day {
    font-size: 16px;
    font-weight: 800;
    color: #8b5cf6;
}

.news-month {
    font-size: 11px;
    text-transform: uppercase;
    color: #727285;
}

.news-content {
    flex: 1;
}

.news-title {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
}

.news-text {
    font-size: 13.5px;
    color: #a0a0b2;
    line-height: 1.5;
}

.news-tag {
    display: inline-block;
    background: #8b5cf622;
    color: #a78bfa;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    margin-bottom: 8px;
}

/* Player Screen Overlay */
.video-player-modal {
    position: fixed;
    inset: 0;
    background: #000;
    z-index: 1000;
    display: none;
    flex-direction: column;
}

.video-player-modal.active {
    display: flex;
}

.player-view {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle, #1a1a2e 0%, #050508 100%);
    position: relative;
}

.player-center-icon {
    font-size: 80px;
    color: rgba(255,255,255,0.2);
}

.player-controls-bar {
    height: 80px;
    background: rgba(10, 10, 14, 0.95);
    border-top: 1px solid #1c1c28;
    padding: 0 24px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.player-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
}

.player-btn:hover {
    background: #ffffff20;
}

.player-timeline {
    flex: 1;
    height: 6px;
    background: #222230;
    border-radius: 3px;
    position: relative;
    cursor: pointer;
}

.player-timeline-fill {
    width: 35%;
    height: 100%;
    background: linear-gradient(90deg, #6366f1, #8b5cf6);
    border-radius: 3px;
}
