* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: #111418;
    color: #d8d8d8;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
}

a {
    color: #76aee8;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

img {
    vertical-align: middle;
}

.site-header {
    background: #1a1f25;
    border-bottom: 1px solid #343b44;
}

.header-inner {
    max-width: 1180px;
    margin: auto;
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 28px;
}

.logo {
    color: #fff;
    font-size: 28px;
    font-weight: bold;
    letter-spacing: -1px;
    text-decoration: none;
    white-space: nowrap;
}

.logo:hover {
    text-decoration: none;
}

.logo span {
    font-style: italic;
    font-weight: normal;
    color: #b8c1cc;
}

.search-form {
    display: flex;
    flex: 1;
    max-width: 520px;
}

.search-form input {
    width: 100%;
    background: #0d1014;
    border: 1px solid #464e58;
    color: #fff;
    padding: 9px 10px;
    border-radius: 3px 0 0 3px;
}

.search-form button {
    background: #303741;
    border: 1px solid #464e58;
    color: #eee;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 0 3px 3px 0;
}

.search-form button:hover {
    background: #3b444f;
}

.account-links {
    margin-left: auto;
    display: flex;
    gap: 15px;
    white-space: nowrap;
}

.account-links img,
.main-nav img,
.section-heading img,
.sidebar-box h3 img {
    margin-right: 5px;
}

.main-nav {
    background: #222831;
    border-bottom: 1px solid #3a424d;
}

.nav-inner {
    max-width: 1180px;
    margin: auto;
    padding: 0 20px;
    display: flex;
}

.main-nav a {
    color: #ddd;
    padding: 11px 14px;
    border-right: 1px solid #343b44;
}

.main-nav a:first-child {
    border-left: 1px solid #343b44;
}

.main-nav a:hover {
    background: #303741;
    text-decoration: none;
}

.main-nav .upload-link {
    margin-left: auto;
    border-left: 1px solid #343b44;
}

.page {
    max-width: 1180px;
    margin: 22px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 24px;
}

.section-heading {
    border-bottom: 1px solid #343b44;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-heading h2 {
    margin: 0;
    padding-bottom: 8px;
    font-size: 18px;
    color: #eee;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 30px;
}

.video-card {
    background: #191e24;
    border: 1px solid #303740;
    padding: 8px;
}

.thumbnail {
    position: relative;
}

.thumbnail-placeholder {
    background: #292f37;
    aspect-ratio: 16 / 9;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #767f89;
    font-size: 12px;
}

.duration {
    position: absolute;
    right: 5px;
    bottom: 5px;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 2px 4px;
    font-size: 11px;
}

.video-info h3 {
    margin: 8px 0 5px;
    font-size: 14px;
}

.video-info p,
.video-info small {
    margin: 3px 0;
    color: #9ca3aa;
    font-size: 12px;
}

.video-list {
    background: #191e24;
    border: 1px solid #303740;
}

.list-item {
    padding: 10px;
    display: flex;
    gap: 12px;
    border-bottom: 1px solid #303740;
}

.list-item:last-child {
    border-bottom: 0;
}

.small-thumb {
    width: 140px;
    aspect-ratio: 16 / 9;
    background: #292f37;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #767f89;
    font-size: 11px;
    flex-shrink: 0;
}

.list-item h3 {
    margin: 3px 0;
    font-size: 14px;
}

.list-item p {
    margin: 5px 0;
}

.list-item small {
    color: #929aa3;
}

.sidebar-box {
    background: #191e24;
    border: 1px solid #303740;
    margin-bottom: 16px;
}

.sidebar-box h3 {
    margin: 0;
    padding: 9px 10px;
    background: #222831;
    border-bottom: 1px solid #343b44;
    color: #eee;
    font-size: 14px;
}

.sidebar-box > p {
    padding: 10px;
    margin: 0;
    line-height: 1.5;
    color: #aeb4ba;
}

.comment-preview {
    padding: 10px;
    border-bottom: 1px solid #303740;
}

.comment-preview:last-child {
    border-bottom: 0;
}

.comment-preview p {
    margin: 5px 0 0;
    color: #a5abb1;
    font-size: 12px;
    line-height: 1.4;
}

.stats {
    list-style: none;
    margin: 0;
    padding: 8px 10px;
}

.stats li {
    padding: 5px 0;
    border-bottom: 1px dotted #383f47;
}

.stats li:last-child {
    border-bottom: 0;
}

.site-footer {
    margin-top: 45px;
    background: #191e24;
    border-top: 1px solid #343b44;
    color: #9299a1;
}

.footer-inner {
    max-width: 1180px;
    margin: auto;
    padding: 22px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-inner strong {
    color: #ddd;
}

.footer-inner strong span {
    font-style: italic;
    font-weight: normal;
}

.footer-inner p {
    margin: 5px 0 0;
    font-size: 12px;
}

.footer-links {
    display: flex;
    gap: 16px;
}

@media (max-width: 850px) {

    .header-inner {
        flex-wrap: wrap;
    }

    .search-form {
        order: 3;
        max-width: none;
        width: 100%;
    }

    .page {
        grid-template-columns: 1fr;
    }

    .sidebar {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .sidebar-box {
        margin-bottom: 0;
    }

    .video-grid {
        grid-template-columns: repeat(2, 1fr);
    }

}

@media (max-width: 580px) {

    .logo {
        font-size: 23px;
    }

    .account-links {
        font-size: 12px;
    }

    .nav-inner {
        overflow-x: auto;
        padding: 0;
    }

    .main-nav a {
        white-space: nowrap;
    }

    .video-grid {
        grid-template-columns: 1fr;
    }

    .sidebar {
        display: block;
    }

    .sidebar-box {
        margin-bottom: 15px;
    }

    .small-thumb {
        width: 105px;
    }

    .footer-inner {
        display: block;
    }

    .footer-links {
        margin-top: 15px;
        flex-wrap: wrap;
    }

}

/* =========================================
   WATCH PAGE
   ========================================= */

.watch-page {
    max-width: 1180px;
    margin: 22px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 24px;
}

.watch-main {
    min-width: 0;
}


/* Player */

.video-player {
    background: #050607;
    border: 1px solid #343b44;
    padding: 8px;
}

.video-player video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}


/* Video title */

.watch-title {
    margin-top: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #343b44;
}

.watch-title h1 {
    margin: 0 0 7px;
    color: #eee;
    font-size: 21px;
}

.watch-stats {
    display: flex;
    gap: 15px;
    color: #949ca5;
    font-size: 12px;
}


/* Actions */

.video-actions {
    padding: 9px 0;
    border-bottom: 1px solid #343b44;
    display: flex;
    gap: 7px;
}

.video-actions button,
.profile-button,
.comment-form button {
    background: #292f37;
    border: 1px solid #424a54;
    color: #ddd;
    padding: 6px 9px;
    border-radius: 2px;
    cursor: pointer;
    font-size: 12px;
}

.video-actions button:hover,
.profile-button:hover {
    background: #343c46;
}

.video-actions img,
.profile-button img,
.comment-form button img {
    margin-right: 4px;
}

.video-actions .report-button {
    margin-left: auto;
}


/* Uploader */

.video-details {
    margin-top: 15px;
}

.uploader-card {
    background: #191e24;
    border: 1px solid #303740;
    padding: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.uploader-avatar {
    width: 52px;
    height: 52px;
    background: #292f37;
    border: 1px solid #3c444d;
    display: flex;
    align-items: center;
    justify-content: center;
}

.uploader-avatar img {
    width: 16px;
    height: 16px;
}

.uploader-info {
    flex: 1;
}

.uploader-name {
    margin-bottom: 4px;
    font-weight: bold;
    font-size: 14px;
}

.uploader-meta {
    color: #949ca5;
    font-size: 11px;
    margin-top: 2px;
}


/* Description + provenance */

.description-box,
.provenance-box {
    background: #191e24;
    border: 1px solid #303740;
    margin-top: 12px;
}

.description-box h3,
.provenance-box h3 {
    margin: 0;
    padding: 8px 10px;
    background: #222831;
    border-bottom: 1px solid #343b44;
    color: #eee;
    font-size: 13px;
}

.description-box h3 img,
.provenance-box h3 img {
    margin-right: 5px;
}

.description-box p {
    margin: 0;
    padding: 12px;
    line-height: 1.6;
    color: #b5bbc1;
}

.media-info {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.media-info th,
.media-info td {
    text-align: left;
    padding: 8px 10px;
    border-bottom: 1px solid #2c333b;
}

.media-info tr:last-child th,
.media-info tr:last-child td {
    border-bottom: 0;
}

.media-info th {
    width: 160px;
    color: #949ca5;
    font-weight: normal;
}

.verification-badge {
    display: inline-block;
    background: #202a22;
    border: 1px solid #354438;
    padding: 4px 6px;
    color: #c5d3c8;
}

.verification-badge img {
    margin-right: 4px;
}


/* Comments */

.comments-section {
    margin-top: 28px;
}

.comments-section .section-heading span {
    color: #929aa3;
    font-size: 12px;
}

.comment-form {
    background: #191e24;
    border: 1px solid #303740;
    padding: 10px;
    margin-bottom: 12px;
}

.comment-form textarea {
    width: 100%;
    min-height: 80px;
    resize: vertical;
    background: #101318;
    border: 1px solid #3b434d;
    color: #ddd;
    padding: 9px;
    font-family: Arial, Helvetica, sans-serif;
}

.comment-form button {
    margin-top: 8px;
}

.comment-form button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.comment {
    background: #191e24;
    border: 1px solid #303740;
    padding: 10px;
    margin-bottom: 8px;
    display: flex;
    gap: 10px;
}

.comment-avatar {
    width: 34px;
    height: 34px;
    background: #292f37;
    border: 1px solid #3b434c;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.comment-body {
    flex: 1;
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.comment-header span {
    color: #858e97;
    font-size: 11px;
}

.comment-body p {
    margin: 7px 0;
    color: #b8bec4;
    line-height: 1.5;
}

.comment-actions {
    display: flex;
    gap: 12px;
    font-size: 11px;
}

.comment-actions img {
    margin-right: 3px;
}


/* Related videos */

.related-video {
    display: flex;
    gap: 8px;
    padding: 9px;
    border-bottom: 1px solid #303740;
    color: inherit;
}

.related-video:hover {
    background: #20262d;
    text-decoration: none;
}

.related-video:last-child {
    border-bottom: 0;
}

.related-thumbnail {
    position: relative;
    width: 110px;
    aspect-ratio: 16 / 9;
    background: #292f37;
    color: #717b85;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    flex-shrink: 0;
}

.related-thumbnail span {
    position: absolute;
    right: 3px;
    bottom: 3px;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 1px 3px;
    font-size: 10px;
}

.related-info {
    min-width: 0;
}

.related-info strong {
    display: block;
    color: #76aee8;
    font-size: 12px;
    line-height: 1.3;
    margin-bottom: 5px;
}

.related-info small {
    display: block;
    color: #8c949d;
    font-size: 10px;
    margin-top: 2px;
}


/* Video details sidebar */

.video-detail-list {
    list-style: none;
    margin: 0;
    padding: 7px 10px;
    font-size: 12px;
}

.video-detail-list li {
    padding: 5px 0;
    border-bottom: 1px dotted #383f47;
}

.video-detail-list li:last-child {
    border-bottom: 0;
}

.video-detail-list strong {
    color: #b8bec4;
}


/* Tags */

.tag-list {
    padding: 9px;
}

.tag-list a {
    display: inline-block;
    background: #252c34;
    border: 1px solid #39424c;
    padding: 3px 6px;
    margin: 2px;
    font-size: 11px;
}


/* Mobile */

@media (max-width: 850px) {

    .watch-page {
        grid-template-columns: 1fr;
    }

    .watch-sidebar {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

}

@media (max-width: 580px) {

    .watch-page {
        padding: 0 10px;
        margin-top: 12px;
    }

    .video-player {
        padding: 4px;
    }

    .watch-title h1 {
        font-size: 18px;
    }

    .watch-stats {
        flex-direction: column;
        gap: 3px;
    }

    .video-actions {
        flex-wrap: wrap;
    }

    .video-actions .report-button {
        margin-left: 0;
    }

    .uploader-card {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .profile-button {
        width: 100%;
    }

    .media-info th {
        width: 120px;
    }

    .watch-sidebar {
        display: block;
    }

}

/* =========================================
   PROFILE PAGE
   ========================================= */

.profile-page {
    max-width: 1180px;
    margin: 22px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 24px;
}

.profile-main {
    min-width: 0;
}

.profile-header-card {
    background: #191e24;
    border: 1px solid #303740;
    padding: 16px;
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.profile-avatar-large {
    width: 96px;
    height: 96px;
    background: #292f37;
    border: 1px solid #424a54;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.profile-avatar-large img {
    width: 16px;
    height: 16px;
}

.profile-header-info {
    flex: 1;
}

.profile-header-info h1 {
    margin: 0 0 5px;
    color: #eee;
    font-size: 24px;
}

.profile-status {
    display: inline-block;
    background: #272c25;
    border: 1px solid #3d4738;
    color: #d0d6c9;
    padding: 4px 7px;
    font-size: 11px;
}

.profile-status img {
    margin-right: 4px;
}

.profile-bio {
    color: #b4bac0;
    line-height: 1.5;
    margin: 12px 0;
    max-width: 600px;
}

.profile-meta {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    color: #929aa3;
    font-size: 11px;
}

.profile-meta img {
    margin-right: 4px;
}

.profile-actions {
    display: flex;
    gap: 7px;
}

.profile-actions button {
    background: #292f37;
    border: 1px solid #424a54;
    color: #ddd;
    padding: 6px 9px;
    cursor: pointer;
    border-radius: 2px;
    white-space: nowrap;
}

.profile-actions button:hover {
    background: #343c46;
}

.profile-actions img {
    margin-right: 4px;
}

.profile-section {
    margin-top: 25px;
}

.activity-list {
    background: #191e24;
    border: 1px solid #303740;
}

.activity-item {
    display: flex;
    gap: 10px;
    padding: 11px;
    border-bottom: 1px solid #303740;
}

.activity-item:last-child {
    border-bottom: 0;
}

.activity-item > img {
    margin-top: 2px;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.activity-item p {
    margin: 6px 0;
    color: #afb5bb;
    line-height: 1.4;
}

.activity-item small {
    color: #858d96;
}

.profile-info-list {
    list-style: none;
    padding: 8px 10px;
    margin: 0;
    font-size: 12px;
}

.profile-info-list li {
    padding: 6px 0;
    border-bottom: 1px dotted #383f47;
}

.profile-info-list li:last-child {
    border-bottom: 0;
}

.profile-info-list strong {
    color: #b8bec4;
}

.badge-list {
    padding: 7px 10px;
}

.badge-item {
    padding: 6px 0;
    border-bottom: 1px dotted #383f47;
    font-size: 12px;
}

.badge-item:last-child {
    border-bottom: 0;
}

.badge-item img {
    margin-right: 6px;
}

@media (max-width: 850px) {

    .profile-page {
        grid-template-columns: 1fr;
    }

    .profile-sidebar {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

}

@media (max-width: 580px) {

    .profile-page {
        padding: 0 10px;
    }

    .profile-header-card {
        flex-wrap: wrap;
    }

    .profile-avatar-large {
        width: 72px;
        height: 72px;
    }

    .profile-actions {
        width: 100%;
    }

    .profile-actions button {
        flex: 1;
    }

    .profile-sidebar {
        display: block;
    }

}

/* =========================================
   UPLOAD PAGE
   ========================================= */

.upload-page {
    max-width: 1180px;
    margin: 22px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 24px;
}

.upload-main {
    min-width: 0;
}

.upload-header {
    margin-bottom: 18px;
}

.upload-header h1 {
    margin: 0 0 7px;
    color: #eee;
    font-size: 22px;
}

.upload-header h1 img {
    margin-right: 6px;
}

.upload-header p {
    margin: 0;
    color: #9ba3ab;
    line-height: 1.5;
}


/* Main upload sections */

.upload-section {
    background: #191e24;
    border: 1px solid #303740;
    margin-bottom: 15px;
}

.upload-section-title {
    background: #222831;
    border-bottom: 1px solid #343b44;
    padding: 10px 12px;
    display: flex;
    gap: 10px;
    align-items: center;
}

.upload-step {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #303842;
    border: 1px solid #46505b;
    color: #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    flex-shrink: 0;
}

.upload-section-title h2 {
    margin: 0;
    color: #eee;
    font-size: 15px;
}

.upload-section-title p {
    margin: 3px 0 0;
    color: #9099a2;
    font-size: 11px;
}

.upload-section-content {
    padding: 14px;
}


/* File selection */

.file-drop {
    min-height: 145px;
    border: 2px dashed #424b55;
    background: #12161b;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-align: center;
    padding: 20px;
}

.file-drop:hover {
    background: #171c22;
    border-color: #56616d;
}

.file-drop input {
    display: none;
}

.file-drop img {
    margin-bottom: 8px;
}

.file-drop strong {
    color: #76aee8;
    font-size: 14px;
}

.file-drop span {
    margin-top: 5px;
    color: #808993;
    font-size: 11px;
}

.upload-note {
    margin-top: 10px;
    background: #20262c;
    border: 1px solid #343d46;
    padding: 9px;
    display: flex;
    gap: 8px;
    align-items: flex-start;
}

.upload-note img {
    margin-top: 2px;
}

.upload-note p {
    margin: 0;
    color: #adb4bb;
    font-size: 12px;
    line-height: 1.4;
}


/* Fields */

.form-row {
    margin-bottom: 14px;
}

.form-row:last-child {
    margin-bottom: 0;
}

.form-row label {
    display: block;
    margin-bottom: 5px;
    color: #c4c9ce;
    font-size: 12px;
    font-weight: bold;
}

.required {
    color: #e27d7d;
}

.form-row input,
.form-row textarea,
.form-row select {
    width: 100%;
    background: #101318;
    border: 1px solid #3d4650;
    color: #ddd;
    padding: 8px 9px;
    border-radius: 2px;
    font-family: Arial, Helvetica, sans-serif;
}

.form-row input:focus,
.form-row textarea:focus,
.form-row select:focus {
    outline: none;
    border-color: #607487;
}

.form-row textarea {
    resize: vertical;
}

.form-row small {
    display: block;
    margin-top: 4px;
    color: #818a94;
    font-size: 10px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}


/* Checkboxes */

.checkbox-row {
    border-top: 1px solid #2d343c;
    padding: 10px 0;
}

.checkbox-row:first-of-type {
    border-top: 0;
}

.checkbox-row label {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    color: #b6bcc2;
    font-size: 12px;
    line-height: 1.4;
}

.checkbox-row input {
    margin-top: 2px;
}


/* Submit */

.upload-submit {
    background: #191e24;
    border: 1px solid #303740;
    padding: 12px;
    display: flex;
    justify-content: space-between;
    gap: 15px;
    align-items: center;
}

.upload-submit-info {
    display: flex;
    gap: 7px;
    align-items: center;
    color: #929ba4;
    font-size: 11px;
}

.upload-submit button {
    background: #34475a;
    border: 1px solid #506b84;
    color: #fff;
    padding: 8px 13px;
    cursor: pointer;
    border-radius: 2px;
    font-weight: bold;
}

.upload-submit button:hover {
    background: #3c5268;
}

.upload-submit button img {
    margin-right: 5px;
}


/* Sidebar */

.upload-help-list {
    list-style: none;
    margin: 0;
    padding: 7px 10px;
}

.upload-help-list li {
    padding: 6px 0;
    border-bottom: 1px dotted #383f47;
    color: #aeb5bc;
    font-size: 12px;
    line-height: 1.4;
}

.upload-help-list li:last-child {
    border-bottom: 0;
}

.upload-sidebar-text {
    margin: 0;
    padding: 10px;
    color: #adb4bb;
    font-size: 12px;
    line-height: 1.5;
}


/* Responsive */

@media (max-width: 850px) {

    .upload-page {
        grid-template-columns: 1fr;
    }

    .upload-sidebar {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

}

@media (max-width: 580px) {

    .upload-page {
        padding: 0 10px;
    }

    .form-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .upload-submit {
        flex-direction: column;
        align-items: stretch;
    }

    .upload-submit button {
        width: 100%;
    }

    .upload-sidebar {
        display: block;
    }

}