html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html, body {
    height: 100%;
    margin: 0;
}

body {
    display: flex;
    flex-direction: column;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}





/* GLOBAL */

.dark-body {
    background-color: #0f1115;
    color: #e4e6eb;
    margin: 0;
    font-family: Segoe UI, sans-serif;
}

.app-wrapper {
    display: flex;
    flex: 1;
    overflow: hidden;
}


/* SIDEBAR */

.sidebar {
    width: 200px;
    flex-shrink: 0;
    background: linear-gradient(180deg, #1a1d24, #0f1115);
    padding: 20px;
    display: flex;
    flex-direction: column;
}

.welcome-text {
    display: block;
    align-content: center;
    text-align: center;
}

.profile-pic {
    background-color: #464c59;
    border-radius: 35px;
}

.sidebar-header {
    display: block;
}

.logo {
    font-weight: bold;
    margin-bottom: 30px;
    text-align: center;
    font-size: 28px;
    font-weight: 700;
    background-image: linear-gradient(286deg, #2193b0, #6dd5ed);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.sidebar-link {
    display: block;
    color: #cfd3dc;
    padding: 10px;
    border-radius: 8px;
    text-decoration: none;
    margin-bottom: 5px;
}

    .sidebar-link:hover {
        background: #2a2f3a;
        color: white;
    }

.logout-btn {
    background: none;
    border: none;
    width: 100%;
    text-align: left;
    color: #cfd3dc;
}

.sidebar-footer {
    margin-bottom: 0;
    margin-top: auto;
    bottom: 5%;
}

.tour {
    top: 100%;
}

.admin-button {
    background-color: #315c34;
}

admin-button:hover {
    background: #48874c;
}

/* MAIN */
.main-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}


/* TOPBAR */

.topbar {
    height: 60px;
    min-height: 60px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    background: #1a1d24;
    border-bottom: 1px solid #222;
}

.search-input {
    background: #0f1115;
    border: 1px solid #333;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
}

.vr-mode {
    font-size: 18px;
    font-weight: bold;
}


/* CONTENT */

.content-wrapper {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 30px;
}


/* VIDEO GRID */

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}


/* VIDEO CARD */

.video-card {
    background: #1a1d24;
    border-radius: 12px;
    overflow: hidden;
    transition: 0.2s;
}

    .video-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 0 15px rgba(0,0,0,0.5);
    }

.thumbnail {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.video-info {
    padding: 15px;
}

.video-title {
    font-weight: 600;
}

.video-author a {
    color: #8ab4ff;
    text-decoration: none;
}


/* BUTTON */

.btn-upload {
    background: #5865f2;
    color: white;
    padding: 8px 16px;
    border-radius: 8px;
}


/* FOOTER */

.footer-dark {
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 20px;
    background: linear-gradient(180deg, #0f1115, #1a1d24);
    color: #777;
    width: 100%;
}



/*  CUSTOM SCROLLBAR  */

/* Chrome, Edge, Safari */
.content-wrapper::-webkit-scrollbar {
    width: 10px;
}

.content-wrapper::-webkit-scrollbar-track {
    background: #0f1115;
}

.content-wrapper::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #2193b0, #6dd5ed);
    border-radius: 10px;
    border: 2px solid #0f1115;
}

    .content-wrapper::-webkit-scrollbar-thumb:hover {
        background: linear-gradient(180deg, #1b7f99, #57c5df);
    }


/* Firefox */
.content-wrapper {
    scrollbar-width: thin;
    scrollbar-color: #2193b0 #0f1115;
}



/*  WATCH VIEW  */

.watch-container {
    max-width: 1100px;
    margin: 0 auto;
}

.video-wrapper {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: black;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 0 30px rgba(0,0,0,0.6);
}

.video-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-top: 20px;
}

.video-title-watch {
    font-size: 28px;
    font-weight: 700;
    margin: 0;
}

.like-btn {
    font-size: 16px;
    padding: 6px 14px;
}

.description {
    margin-top: 20px;
    padding: 20px;
    background: #161a22;
    border-radius: 12px;
    line-height: 1.6;
    color: #ddd;
}

/*  COMMENT INPUT  */

.comment-input-card {
    background: #161a22;
    border-radius: 14px;
    padding: 18px;
    margin-bottom: 25px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.4);
}

.comment-textarea {
    width: 100%;
    background: #0f1115;
    border: 1px solid #2a2f3a;
    border-radius: 10px;
    padding: 12px;
    color: #e4e6eb;
    resize: vertical;
    transition: 0.2s;
}

    .comment-textarea:focus {
        outline: none;
        border-color: #2193b0;
        box-shadow: 0 0 10px rgba(33,147,176,0.3);
    }

.comment-submit {
    margin-top: 12px;
    text-align: right;
}

/*  COMMENT CARDS  */

.list-group {
    background: transparent;
    border: none;
}

.comment-item {
    background: #161a22 !important;
    border: 1px solid #222 !important;
    border-radius: 14px !important;
    margin-bottom: 15px;
    padding: 18px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.4);
    color: #ddd;
}

.comment-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.comment-author strong {
    color: #6dd5ed;
    font-weight: 600;
}

.comment-date {
    font-size: 13px;
    color: #777;
    margin-left: 10px;
}

.comment-body {
    margin-top: 10px;
    line-height: 1.6;
    color: #ddd;
}

.comment-actions button {
    margin-right: 8px;
}

.comment-delete {
    margin-top: 10px;
}



/*  CHANNEL VIEW  */

/*  UPLOAD CARD  */
.upload-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
    border: 2px dashed #2a2f3a;
    background: #141821;
}

    .upload-card:hover {
        border-color: #2193b0;
        transform: translateY(-4px);
        box-shadow: 0 0 20px rgba(33,147,176,0.2);
    }

.upload-link {
    text-decoration: none;
    color: inherit;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.upload-thumbnail {
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #0f1115;
}

.upload-plus {
    font-size: 60px;
    font-weight: 300;
    color: #444;
    transition: 0.2s;
}

.upload-card:hover .upload-plus {
    color: #6dd5ed;
    transform: scale(1.1);
}



/*  EDIT BUTTON   */
.edit-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    font-size: 13px;
    font-weight: 500;
    border-radius: 8px;
    background: #141821;
    border: 1px solid #2a2f3a;
    color: #cfd3dc;
    text-decoration: none;
    transition: 0.2s ease;
}

    .edit-btn:hover {
        background: #1d2330;
        border-color: #2193b0;
        color: #6dd5ed;
    }

.edit-icon {
    fill: currentColor;
    transition: 0.2s ease;
}

.edit-btn:hover .edit-icon {
    transform: scale(1.1);
}



/*  GLOBAL ACTION BUTTONS  */

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    font-size: 14px;
    border-radius: 8px;
    border: 1px solid #2a2f3a;
    background: #141821;
    color: #cfd3dc;
    cursor: pointer;
    transition: 0.2s ease;
    text-decoration: none;
}

    .action-btn:hover {
        background: #1d2330;
        border-color: #2193b0;
        color: #6dd5ed;
    }

/*  VIDEO LIKE  */

.like-main svg {
    fill: currentColor;
}

.like-main.active {
    background: #1d2b36;
    border-color: #2193b0;
    color: #6dd5ed;
}

/*  COMMENT LIKE  */

.like-btn.active-like {
    background: #1e3a2f;
    border-color: #2ecc71;
    color: #2ecc71;
}

.dislike-btn.active-dislike {
    background: #3a1e23;
    border-color: #e74c3c;
    color: #e74c3c;
}


.primary-btn {
    background: linear-gradient(135deg, #2193b0, #6dd5ed);
    border: none;
    color: white;
}

    .primary-btn:hover {
        opacity: 0.9;
        transform: translateY(-2px);
    }

/*  DELETE BUTTON  */

.delete-btn {
    background: #2a1618;
    border: 1px solid #3a1f23;
    color: #ff6b6b;
}

    .delete-btn:hover {
        background: #3a1f23;
        border-color: #e74c3c;
        color: #ff4d4d;
    }


/*  TAGS  */

.tags-section {
    margin-top: 20px;
}

.tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-item {
    padding: 6px 14px;
    font-size: 13px;
    border-radius: 999px;
    background: #141821;
    border: 1px solid #2a2f3a;
    color: #9ecfff;
    cursor: pointer;
    transition: 0.2s ease;
    text-decoration: none;
}

    .tag-item:hover {
        background: #1d2330;
        border-color: #2193b0;
        color: #6dd5ed;
        transform: translateY(-2px);
        box-shadow: 0 0 12px rgba(33,147,176,0.3);
    }


.comment-like,
.comment-dislike {
    background: #1d2330;
    border: 1px solid #8ab4ff;
    color: #8ab4ff;
}



    .comment-like svg,
    .comment-dislike svg {
        fill: currentColor;
    }

    .comment-like:hover,
    .comment-dislike:hover {
        background: #1d2330;
        border-color: #2193b0;
        color: #6dd5ed;
    }

/* ACTIVE LIKE */
.like-btn.active-like {
    background: #1e3a2f;
    border-color: #2ecc71;
    color: #2ecc71;
}

/* ACTIVE DISLIKE */
.dislike-btn.active-dislike {
    background: #3a1e23;
    border-color: #e74c3c;
    color: #e74c3c;
}

/* DISABLED (GOŚĆ) */

.comment-like:disabled,
.comment-dislike:disabled {
    background: #141821;
    border: 1px solid #2a2f3a;
    color: #cfd3dc;
    opacity: 0.9; 
    cursor: not-allowed;
}


    .comment-like:disabled:hover,
    .comment-dislike:disabled:hover {
        background: #141821;
        border: 1px solid #2a2f3a;
        color: #cfd3dc;
        transform: none;
        box-shadow: none;
    }


/*  EDIT VIEW  */

.edit-container {
    max-width: 900px;
    margin: 0 auto;
}

.edit-card {
    background: #161a22;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
}

.edit-title {
    margin-bottom: 25px;
    font-size: 28px;
    font-weight: 700;
}

/* ERROR BOX */
.edit-error-box {
    background: #3a1e23;
    border: 1px solid #e74c3c;
    color: #ffb3b3;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
}

/* FORM */

.edit-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group-dark {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-control-dark {
    background: #0f1115;
    border: 1px solid #2a2f3a;
    border-radius: 10px;
    padding: 10px 14px;
    color: #e4e6eb;
    transition: 0.2s;
}

    .form-control-dark:focus {
        outline: none;
        border-color: #2193b0;
        box-shadow: 0 0 12px rgba(33,147,176,0.3);
    }

.textarea-dark {
    min-height: 120px;
    resize: vertical;
}

.validation-error {
    color: #ff6b6b;
    font-size: 13px;
}

/* THUMBNAILS */

.thumbnail-section {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

.thumbnail-box h5 {
    margin-bottom: 10px;
    font-size: 15px;
    color: #aaa;
}

.thumbnail-preview {
    max-width: 220px;
    border-radius: 12px;
    border: 1px solid #2a2f3a;
}

.new-thumb {
    border: 2px solid #2ecc71;
}

/* FILE INPUT */

.file-input-dark {
    padding: 6px;
}

/* ACTIONS */

.edit-actions {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}

/* DELETE */

.delete-section {
    margin-top: 30px;
}


/*  CUSTOM FILE UPLOAD  */

.file-upload-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.file-input-hidden {
    display: none;
}

.file-upload-btn {
    padding: 8px 16px;
    border-radius: 8px;
    background: #141821;
    border: 1px solid #2a2f3a;
    color: #cfd3dc;
    cursor: pointer;
    transition: 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

    .file-upload-btn:hover {
        background: #1d2330;
        border-color: #2193b0;
        color: #6dd5ed;
        transform: translateY(-2px);
        box-shadow: 0 0 12px rgba(33,147,176,0.3);
    }

.file-name {
    font-size: 14px;
    color: #888;
}


/*  EDIT TAGS  */

.edit-tags {
    margin-top: 10px;
}

.tag-add-btn {
    background: #141821;
    border: 1px dashed #2a2f3a;
    color: #aaa;
    cursor: pointer;
    transition: 0.2s ease;
}

    .tag-add-btn:hover {
        background: #1d2330;
        border-color: #2193b0;
        color: #6dd5ed;
        transform: translateY(-2px);
        box-shadow: 0 0 12px rgba(33,147,176,0.25);
    }


/*  CANCEL BUTTON*/

.cancel-btn {
    border: 1px solid #3a1f23;
    color: #ff8a8a;
    background: #141821;
    transition: 0.2s ease;
}



    .cancel-btn:hover {
        background: #1d1517; 
        border-color: #e74c3c;
        color: #ff6b6b;
        box-shadow: 0 0 12px rgba(231,76,60,0.35);
        transform: translateY(-2px);
    }



/* Hamburger ukryty na pc */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 22px;
}

/* _______________________ */
/* --- MOBILE VERSION --- */
/* ---------------------- */

@media (max-width: 992px) {

    /* Layout na kolumnowy */
    .app-wrapper {
        flex-direction: column;
    }

    .menu-toggle {
        display: block;
        margin-right: 22px;
    }

    /* Sidebar jako topbar */
    .sidebar {
        width: 100%;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 0px 15px;
        position: relative;
    }

    .sidebar-header {
        margin-bottom: 0;
    }

    .logo {
        font-size: 18px;
        margin-bottom: 0;
        margin-left: 5px;
        text-align: left;
        justify-content: center;
    }

  
    .welcome-text {
        display: none;
    }

    /* Sidebar-nav w poziomie */
    .sidebar-nav {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(26, 29, 36, 0.95);
        backdrop-filter: blur(10px);
        padding: 15px;
        border-bottom-left-radius: 16px;
        border-bottom-right-radius: 16px;
        box-shadow: 0 15px 40px rgba(0,0,0,0.6);
        display: flex;
        flex-direction: column;
        gap: 8px;
        /* animacja */
        opacity: 0;
        transform: translateY(-10px);
        pointer-events: none;
        transition: all 0.25s ease;
    }

        .sidebar-nav.active {
            opacity: 1;
            transform: translateY(0);
            pointer-events: auto;
        }

    .sidebar-link {
        display: inline-flex; 
        align-items: center;
        gap: 6px;
        width: auto; 
        margin-bottom: 0;
        white-space: nowrap;
    }

    .sidebar-footer {
        display: block;
        margin-top: 0;
    }


    .main-wrapper {
        width: 100%;
    }
}

@media (max-width: 768px) {

    .topbar {
        flex-direction: column;
        align-items: flex-start;
        height: auto;
        padding: 0px 15px;
        gap: 0px;
    }

    .vr-mode {
        margin-bottom: 7px;
    }

    .topbar-right {
        width: 100%;
        display: flex;
        gap: 10px;
    }

    .search-input {
        width: 100%;
    }

    .vr-mode {
        font-size: 14px;
    }

    .page-title {
        font-size: 18px;
    }
}

@media (max-width: 576px) {

    .video-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .thumbnail {
        height: 200px;
    }

    .content-wrapper {
        padding: 15px;
    }
}


/*  VirtualWalk containter */

iframe {
    width: 100%;
    height: calc(100vh - 210px);
    border: none;
    margin-top: -20px;
}
