@font-face {
    font-family: 'Vazir';
    src: url('../font/Vazir-Bold.ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
}

* {
    font-family: 'Poppins', sans-serif;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    background: #0F0F0F;
}

.main_nav {
    width: 100%;
    display: flex;
    padding: 10px 2%;
    align-items: center;
    position: fixed;
    z-index: 20;
    top: 0;
    left: 0;
}
.main_nav.active_nav{
    background: #0f0f0fe2;
    backdrop-filter: blur(30px);
}
.nav_left {
    display: flex;
    align-items: center;
}

.nav_left .logo {
    width: 110px;
}

.ytSearchboxComponentInputContainer {
    display: flex;
    align-items: center;
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.ytSearchboxComponentInputBox {
    flex: 1;
}

.ytSearchboxComponentInputBoxDark {
    background: none;
}

.ytSearchboxComponentSearchForm {
    margin: 0;
}

.ytSearchboxComponentInput {
    background: none;
    height: 46px;
    color: white;
    padding: 0 50px 0 16px;
    font-size: 15px;
    width: 100%;
    border: 1.5px solid rgba(192, 192, 192, 0.25);
    border-radius: 30px;
    outline: none;
    box-sizing: border-box;
    text-align: right;
    direction: rtl;
}

.ytSearchboxComponentInput::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.ytSearchboxComponentSearchButton {
    background: none;
    border: none;
    width: 46px;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 100%;
    cursor: pointer;
    position: absolute;
    left: 2px;
    top: 0;
    z-index: 1;
    transition: background .2s;
    flex-shrink: 0;
    color: #fff;
}

.ytSearchboxComponentSearchButton::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 24px;
    width: 1px;
    background: rgba(255, 255, 255, 0.2);
}

.ytSearchboxComponentSearchButton:hover {
    background: rgba(255, 255, 255, 0.12);
}

.ytSearchboxComponentSearchButtonDark {
}

.ytIconWrapperHost,
.ytSpecIconShapeHost {
    display: flex;
    align-items: center;
    justify-content: center;
}

.ytIconWrapperHost svg,
.ytSpecIconShapeHost svg {
    width: 20px;
    height: 20px;
}

@media (max-width: 768px) {
    .ytSearchboxComponentInputContainer {
        max-width: 300px;
    }
}

@media (max-width: 480px) {
    .ytSearchboxComponentInput {
        font-size: 13px;
        padding: 0 12px 0 40px;
    }
    .ytSearchboxComponentSearchButton {
        width: 36px;
        height: 36px;
        left: 1px;
    }
    .ytSearchboxComponentInputContainer {
        max-width: 200px;
    }
}

.nav_right {
    justify-content: space-between;
    display: flex;
    align-items: center;
}

.nav_right_logo {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    overflow: hidden;
    width: 80px;
    height: 44px;
    border: 2px solid rgba(255, 255, 255, 0.15);
    flex-shrink: 0;
}

.nav_right_logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.nav_right .create {
    background: none;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    border-radius: 100%;
    border: none;
}

.nav_right .profile {
    width: 50px;
    height: 50px;
}

.nav_right .profile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nav_right .create:hover {
    background: rgba(192, 192, 192, 0.158);
}

.nav_right .create:active {
    background: rgba(192, 192, 192, 0.258);
}

.nav_right .notifications:hover {
    background: rgba(192, 192, 192, 0.158);
}

.nav_right .notifications:active {
    background: rgba(192, 192, 192, 0.258);
}

.nav_right .notifications {
    background: none;
    border: none;
    width: 40px;
    margin-right: 15px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 100%;
}

.nav_right .profile {
    border: 1px solid rgba(192, 192, 192, 0.379);
    background: none;
    width: 40px;
    height: 40px;
    border-radius: 100%;
    overflow: hidden;
}


/* Main Content Styles */
main {
    width: 100%;
}

.content {
    padding: 100px 40px 40px 40px;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.video_card {
    color: white;
}

.video_card img {
    border-radius: 15px;
    width: 100%;
}

.channel_infos {
    padding-top: 5px;
    display: flex;
    align-items: center;
}

.channel_profile {
    width: 40px;
    aspect-ratio: 1;
    box-sizing: border-box;
    overflow: hidden;
    border-radius: 100%;
    margin-right: 3%;
    background: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-size: 14px;
    font-weight: 600;
    flex-shrink: 0;
}

.channel_profile img {
    width: 100%;
    height: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    object-position: center;
}

.video_card a {
    color: white;
}

.channel_infos h1 {
    color: white;
    font-size: 15px;
    margin-top: 5px;
    font-weight: 500;
}

.channel_infos p {
    font-size: 13px;
    margin-top: 5px;
    display: flex;
    align-items: center;
    color: rgb(204, 204, 204);
}

.channel_infos p svg {
    margin-left: 3%;
}

.channel_infos span {
    margin-top: 5px;
    display: block;
    font-size: 13px;
    color: rgb(204, 204, 204);
}

.sidebar {
    display: block;
    width: 330px;
    user-select: none;
    box-sizing: border-box;
    height: 100vh;
    padding-left: 30px;
    overflow-y: scroll;
    position: sticky;
    top: 0;
}

.sidebar::-webkit-scrollbar {
    width: 0;
}

main {
    position: relative;
    display: flex;
}

.sidebar_links {
    margin-top: 80px;
}

.sidebar_links li {
    margin-top: 10px;
    list-style-type: none;
}

.sidebar_links li a {
    display: block;
    width: 100%;
    font-size: 14px;
    border-radius: 7px;
    padding: 10px 15px;
    color: white;
    display: flex;
    align-items: center;
}

.sidebar_links li a:hover {
    background: rgba(192, 192, 192, 0.096);
}

.sidebar_links li a svg {
    margin-right: 20px;
}

.line {
    width: 100%;
    margin-bottom: 20px;
    height: 1px;
    margin-top: 20px;
    background: rgba(192, 192, 192, 0.187);
}

.subscibtions {
    width: 100%;
}

.subscibtions h1 {
    color: rgb(192, 192, 192);
    font-size: 14px;
    font-weight: 500;
}

.subscibtions li {
    list-style: none;
}
.subscibtions li ion-icon{
    color: red;
}
.subscibtions ul li a div img {
    width: 28px;
    border-radius: 100%;
    height: 28px;
    object-fit: cover;
}

.subscibtions ul li:nth-child(1) {
    margin-top: 20px;
}

.subscibtions ul li a {
    color: white;
    font-size: 14px;
    padding: 3px 8px;
    border-radius: 7px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.subscibtions ul li a:hover {
    background: rgba(192, 192, 192, 0.096);
}

.subscibtions ul li a div {
    display: flex;
    align-items: center;
}

.subscibtions ul li a div p {
    margin-left: 20px;
}

.subscibtions ul li {
    margin-top: 10px;
}






/* Media Querry Styles ---> Responsive Design (mobile , tablet) */

@media (max-width: 576px) {
    * {
        font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    }

    .content {
        padding-top: 60px;
        padding-left: 0;
        padding-right: 0;
        padding-bottom: 0;
        width: 100%;
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
        gap: 0px;
    }

    .video_card {
        padding: 10px;
        margin-top: 20px;
    }

    .video_card img {
        border-radius: 10px;
    }

    .nav_right .create {
        display: none;
    }

    .main_nav {
        background: #0F0F0F;
        padding: 10px;
    }
}

@media (max-width: 768px) {

}

@media (max-width: 992px)  {
    .sidebar {
        width: 280px;
        padding: 0 30px;
    }
    .subscibtions ul li a {
        color: white;
        width: 80%;
        font-size: 14px;
        padding: 3px 12px;
    }
}

@media (max-width: 1200px) {
    .sidebar{
        display: none;
        position: fixed;
        left: 0;
        top: 0;
        z-index: 21;
        background: #0F0F0F;
        padding-top: 60px;
    }
}

.sidebar.sidebar--open {
    display: block !important;
}

.sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    z-index: 20;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s;
}
.sidebar-overlay--active {
    opacity: 1;
    pointer-events: auto;
}

/* ===== Search Results / Dynamic Content Styles ===== */
.video_card {
    color: white;
    margin-bottom: 0;
    animation: fadeUp .4s ease both;
}
.video_card a {
    text-decoration: none;
    color: white;
    display: block;
}
.thumb-wrap {
    position: relative;
    width: 100%;
    border-radius: 14px;
    overflow: hidden;
    background: #222;
}
.thumb-wrap img {
    width: 100%;
    display: block;
    border-radius: 14px;
    aspect-ratio: 16/9;
    object-fit: cover;
    transition: transform .4s ease;
}
.video_card:hover .thumb-wrap img {
    transform: scale(1.04);
}
.play-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,.35);
    opacity: 0;
    transition: opacity .3s;
}
.video_card:hover .play-overlay {
    opacity: 1;
}
.play-overlay svg {
    width: 48px;
    height: 48px;
    filter: drop-shadow(0 2px 12px rgba(0,0,0,.6));
}

.results-bar {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0 16px;
    flex-wrap: wrap;
    gap: 8px;
    color: white;
}
.results-bar .stat {
    font-size: 14px;
    color: #aaa;
    display: flex;
    align-items: center;
    gap: 8px;
}
.results-bar .badge {
    font-size: 11px;
    background: #ff0033;
    color: #fff;
    padding: 4px 14px;
    border-radius: 30px;
    font-weight: 600;
}

.search-hint {
    grid-column: 1 / -1;
    text-align: center;
    padding: 80px 20px;
    color: #666;
}
.search-hint svg {
    width: 56px;
    height: 56px;
    opacity: .15;
    margin-bottom: 16px;
}
.search-hint h2 {
    font-size: 18px;
    font-weight: 400;
    color: #888;
    margin-bottom: 6px;
}
.search-hint p {
    font-size: 13px;
    color: #555;
}

.error-box {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
}
.error-box p {
    color: #ff4444;
    font-size: 14px;
}
.retry-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 14px;
    padding: 8px 20px;
    border-radius: 30px;
    background: #222;
    border: 1px solid #333;
    color: #fff;
    cursor: pointer;
    font-size: 13px;
    text-decoration: none;
    transition: .2s;
}
.retry-btn:hover {
    background: #2a2a2a;
}

/* Skeleton */
.skel-grid {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    padding: 10px 0;
    width: 100%;
}
.skel-card {
    background: #1a1a1a;
    border-radius: 14px;
    overflow: hidden;
}
.skel-thumb {
    aspect-ratio: 16/9;
    background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
    background-size: 200% 100%;
    animation: shimmer 1.4s infinite;
}
.skel-row {
    display: flex;
    gap: 12px;
    padding: 14px;
}
.skel-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
    background-size: 200% 100%;
    animation: shimmer 1.4s infinite;
    flex-shrink: 0;
}
.skel-lines {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 2px;
}
.skel-line {
    height: 14px;
    border-radius: 6px;
    background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
    background-size: 200% 100%;
    animation: shimmer 1.4s infinite;
}
.skel-line:nth-child(2) {
    width: 55%;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Pagination */
.pagination {
    grid-column: 1 / -1;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    padding: 20px 0 40px;
    flex-wrap: wrap;
}
.pagination a,
.pagination span {
    padding: 7px 14px;
    border-radius: 30px;
    text-decoration: none;
    font-size: 13px;
    min-width: 36px;
    text-align: center;
    transition: .2s;
}
.pagination a {
    background: #222;
    color: #aaa;
    border: 1px solid #333;
}
.pagination a:hover {
    background: #2a2a2a;
    color: #fff;
    border-color: #555;
}
.pagination .current {
    background: #ff0033;
    color: #fff;
    font-weight: 600;
    border-color: #ff0033;
}
.pagination .disabled {
    color: #555;
    padding: 7px 5px;
}
/* 
@media(prefers-color-scheme: light) {
    body{
        background: white;
    }
    .video_card p{
        color: black;
    }
   .video_card span{
        color: black;
    }
    .video_titles h1{
        color: black;
    }
    .main_nav{
        background: white;
    }
    .nav_left .burger_btn {
        background: gray;
    }
}
@media(prefers-color-scheme: black) {
    body{
        background: #0F0F0F;
    }
    .sidebar_links li a{
        color: black;
    }
} */