/*
Theme Name: FaithStream
Theme URI: https://faithstream.com
Author: FaithStream Team
Author URI: https://faithstream.com
Description: A modern Christian streaming platform theme with sidebar navigation, video grids, and channel profiles.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: faithstream
Tags: custom-menu, featured-images, full-width-template, sticky-post, theme-options, threaded-comments, translation-ready
*/

/* =====================================================
   BASE RESET & BODY
   ===================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Work Sans', sans-serif;
    background-color: #fff8f7;
    color: #2a1614;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* =====================================================
   LINE CLAMP UTILITY
   ===================================================== */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* =====================================================
   LAYOUT WRAPPERS
   ===================================================== */
.faithstream-wrapper {
    display: flex;
    height: 100vh;
    padding-top: 60px;
}

.faithstream-main {
    flex: 1;
    margin-left: 0;
    overflow-y: auto;
    width: 100%;
}

@media (min-width: 768px) {
    .faithstream-main {
        margin-left: 256px;
    }
}

/* =====================================================
   TOP NAVIGATION
   ===================================================== */
.faithstream-topnav {
    background-color: #ffffff;
    border-bottom: 1px solid #f3f4f6;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 40;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 32px;
    width: 100%;
}

.faithstream-topnav .logo {
    font-size: 1.5rem;
    font-weight: 900;
    color: #dc2626;
    letter-spacing: -0.025em;
    text-decoration: none;
}

.faithstream-topnav .search-wrap {
    display: none;
    align-items: center;
    border-radius: 9999px;
    padding: 8px 16px;
    border: 1px solid #d1d5db;
    background-color: #f3f4f6;
    width: 300px;
    transition: border-color 0.2s;
}

@media (min-width: 768px) {
    .faithstream-topnav .search-wrap {
        display: flex;
    }
}

.faithstream-topnav .search-wrap:focus-within {
    border-color: #bc0006;
}

.faithstream-topnav .search-wrap input {
    background: transparent;
    border: none;
    outline: none;
    font-size: 16px;
    color: #2a1614;
    width: 100%;
}

.faithstream-topnav .nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.faithstream-topnav .nav-icon-btn {
    padding: 8px;
    border-radius: 9999px;
    border: none;
    background: transparent;
    cursor: pointer;
    color: #4b5563;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s, color 0.2s;
}

.faithstream-topnav .nav-icon-btn:hover {
    background-color: #ffe9e6;
    color: #dc2626;
}

/* =====================================================
   SIDEBAR
   ===================================================== */
.faithstream-sidebar {
    background-color: #ffffff;
    border-right: 1px solid #f3f4f6;
    position: fixed;
    left: 0;
    top: 0;
    height: 100%;
    width: 256px;
    display: none;
    flex-direction: column;
    padding-top: 80px;
    padding-bottom: 32px;
    padding-left: 16px;
    padding-right: 16px;
    z-index: 30;
    overflow-y: auto;
}

@media (min-width: 768px) {
    .faithstream-sidebar {
        display: flex;
    }
}

.faithstream-sidebar .user-block {
    margin-bottom: 32px;
    padding: 0 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.faithstream-sidebar .user-block img {
    width: 40px;
    height: 40px;
    border-radius: 9999px;
    object-fit: cover;
    border: 1px solid #e9bcb6;
}

.faithstream-sidebar .user-block .user-name {
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: #2a1614;
}

.faithstream-sidebar .user-block .user-sub {
    font-size: 12px;
    font-weight: 500;
    color: #5f3f3a;
}

/* Sidebar nav links */
.faithstream-sidebar .sidebar-nav {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    list-style: none;
}

.faithstream-sidebar .sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 8px;
    text-decoration: none;
    color: #4b5563;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    transition: background-color 0.2s, color 0.2s;
}

.faithstream-sidebar .sidebar-nav a:hover {
    background-color: #f9fafb;
    color: #dc2626;
}

.faithstream-sidebar .sidebar-nav a.active {
    background-color: #f9fafb;
    color: #dc2626;
}

.faithstream-sidebar .sidebar-nav a .material-symbols-outlined {
    font-size: 20px;
}

/* Sidebar bottom links */
.faithstream-sidebar .sidebar-bottom {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid rgba(233, 188, 182, 0.3);
    display: flex;
    flex-direction: column;
    gap: 8px;
    list-style: none;
}

.faithstream-sidebar .sidebar-bottom a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 8px;
    text-decoration: none;
    color: #4b5563;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    transition: background-color 0.2s, color 0.2s;
}

.faithstream-sidebar .sidebar-bottom a:hover {
    background-color: #f9fafb;
    color: #dc2626;
}

/* =====================================================
   VIDEO CARD GRID
   ===================================================== */
.video-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
}

@media (min-width: 640px) {
    .video-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .video-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1280px) {
    .video-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.video-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
    cursor: pointer;
}

.video-card .thumb-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 16px;
    overflow: hidden;
    background-color: #ffe2dd;
    border: 1px solid rgba(233, 188, 182, 0.3);
}

.video-card .thumb-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-card:hover .thumb-wrap img {
    transform: scale(1.05);
}

.video-card .duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,0.8);
    color: #ffffff;
    font-size: 11px;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 6px;
    backdrop-filter: blur(4px);
}

.video-card .progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.3);
}

.video-card .progress-bar .progress-fill {
    height: 100%;
    background-color: #bc0006;
}

.video-card .card-title {
    font-size: 16px;
    font-weight: 600;
    color: #2a1614;
    line-height: 1.5;
    transition: color 0.2s;
}

.video-card:hover .card-title {
    color: #bc0006;
}

.video-card .card-meta {
    font-size: 12px;
    font-weight: 500;
    color: #5f3f3a;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
}

.video-card .meta-dot {
    width: 4px;
    height: 4px;
    border-radius: 9999px;
    background-color: #946e69;
    display: inline-block;
}

/* Video card with channel avatar (Faith page style) */
.video-card .card-body-with-avatar {
    display: flex;
    gap: 12px;
}

.video-card .channel-avatar {
    width: 40px;
    height: 40px;
    border-radius: 9999px;
    overflow: hidden;
    background-color: #ffdad5;
    flex-shrink: 0;
}

.video-card .channel-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-card .card-info {
    flex: 1;
    min-width: 0;
}

.video-card .channel-name {
    font-size: 12px;
    font-weight: 500;
    color: #5f3f3a;
    margin-top: 4px;
}

/* =====================================================
   HERO / FEATURED SECTION
   ===================================================== */
.hero-section {
    position: relative;
    width: 100%;
    height: 614px;
    min-height: 400px;
    overflow: hidden;
    cursor: pointer;
}

.hero-section .hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transition: transform 0.7s ease-out;
}

.hero-section:hover .hero-bg {
    transform: scale(1.05);
}

.hero-section .hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0.3) 50%, transparent);
}

.hero-section .hero-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 32px;
    z-index: 10;
}

@media (min-width: 768px) {
    .hero-section .hero-content {
        padding: 48px;
    }
}

.hero-section .hero-badge {
    display: inline-block;
    padding: 4px 12px;
    margin-bottom: 16px;
    border-radius: 9999px;
    background: rgba(188, 0, 6, 0.9);
    color: #ffffff;
    font-size: 12px;
    font-weight: 500;
    backdrop-filter: blur(4px);
}

.hero-section h1 {
    font-size: 48px;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: #ffffff;
    margin-bottom: 16px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.hero-section .hero-desc {
    font-size: 18px;
    line-height: 1.6;
    color: #e5e7eb;
    margin-bottom: 32px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
    max-width: 600px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hero-section .hero-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.hero-section .btn-primary {
    background-color: #bc0006;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    padding: 12px 24px;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.2s;
    text-decoration: none;
}

.hero-section .btn-primary:hover {
    background-color: #e9080e;
}

.hero-section .btn-secondary {
    background: rgba(255,255,255,0.1);
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    padding: 12px 24px;
    border-radius: 9999px;
    border: 1px solid rgba(255,255,255,0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.2s;
    backdrop-filter: blur(12px);
    text-decoration: none;
}

.hero-section .btn-secondary:hover {
    background: rgba(255,255,255,0.2);
}

/* =====================================================
   SECTION HEADINGS
   ===================================================== */
.section-heading {
    font-size: 32px;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.01em;
    color: #2a1614;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-heading .material-symbols-outlined {
    color: #bc0006;
    font-size: 24px;
}

/* =====================================================
   PAGE HEADER (Faith, Entertainment, Growth pages)
   ===================================================== */
.page-header {
    margin-bottom: 40px;
}

.page-header h1 {
    font-size: 48px;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: #2a1614;
    margin-bottom: 16px;
}

.page-header p {
    font-size: 18px;
    line-height: 1.6;
    color: #5f3f3a;
    max-width: 768px;
}

/* =====================================================
   FILTER CHIPS
   ===================================================== */
.filter-chips {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 16px;
    margin-bottom: 32px;
    scrollbar-width: none;
}

.filter-chips::-webkit-scrollbar {
    display: none;
}

.filter-chip {
    padding: 8px 24px;
    border-radius: 9999px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    white-space: nowrap;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
}

.filter-chip.active {
    background-color: #bc0006;
    color: #ffffff;
}

.filter-chip:not(.active) {
    background-color: #ffe9e6;
    color: #5f3f3a;
}

.filter-chip:not(.active):hover {
    background-color: #ffe2dd;
    color: #bc0006;
}

/* =====================================================
   CHANNEL PROFILE PAGE
   ===================================================== */
.channel-banner {
    width: 100%;
    height: 240px;
    position: relative;
    overflow: hidden;
    background-color: #ffe2dd;
}

@media (min-width: 768px) {
    .channel-banner {
        height: 320px;
    }
}

.channel-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    opacity: 0.9;
}

.channel-banner .banner-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);
}

.channel-info-wrap {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 32px;
}

.channel-info-header {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
    position: relative;
    margin-top: -48px;
    margin-bottom: 32px;
}

@media (min-width: 768px) {
    .channel-info-header {
        flex-direction: row;
        align-items: flex-end;
    }
}

.channel-avatar-large {
    width: 128px;
    height: 128px;
    border-radius: 9999px;
    border: 4px solid #fff8f7;
    overflow: hidden;
    background-color: #ffe9e6;
    z-index: 10;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    flex-shrink: 0;
}

.channel-avatar-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.channel-meta {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
}

@media (min-width: 768px) {
    .channel-meta {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
}

.channel-meta h1 {
    font-size: 48px;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: #2a1614;
    margin-bottom: 4px;
}

.channel-stats {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 16px;
    color: #5f3f3a;
}

.channel-desc {
    font-size: 16px;
    line-height: 1.5;
    color: #5f3f3a;
    margin-top: 12px;
    max-width: 672px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.btn-subscribe {
    background-color: #bc0006;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    padding: 12px 48px;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}

.btn-subscribe:hover {
    background-color: #e9080e;
}

.channel-tabs {
    display: flex;
    border-bottom: 1px solid #e9bcb6;
    margin-bottom: 32px;
    overflow-x: auto;
}

.channel-tabs a {
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: #5f3f3a;
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.2s;
}

.channel-tabs a:hover {
    color: #2a1614;
}

.channel-tabs a.active {
    color: #bc0006;
    border-bottom: 2px solid #bc0006;
}

.sort-buttons {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
}

.sort-btn {
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    padding: 4px 24px;
    border-radius: 9999px;
    border: 1px solid #e9bcb6;
    cursor: pointer;
    transition: background-color 0.2s;
}

.sort-btn.active {
    background-color: #ffe2dd;
    color: #2a1614;
}

.sort-btn:not(.active) {
    background-color: #fff8f7;
    color: #5f3f3a;
}

.sort-btn:not(.active):hover {
    background-color: #ffe2dd;
}

/* =====================================================
   CONTENT PADDING WRAPPER
   ===================================================== */
.content-pad {
    padding: 32px;
}

@media (min-width: 768px) {
    .content-pad {
        padding: 48px;
    }
}

.content-sections {
    max-width: 1440px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 64px;
}
