/*
Theme Name: VSLPlay Knowledge Base 1.9.4
Theme URI: https://vslplay.com/
Description: A clone of the Crisp Acknowledge theme for VSLPlay Help Center.
Version: 1.9.4
Author: VSLPlay Team
*/

:root {
    /* Colors */
    --primary-header-bg: #000000;
    --page-background: #fcfcfc;
    --text-main: #1c293b;
    --text-light: #64748b;
    --accent-blue: #2563eb;
    --sidebar-bg: transparent;
    --active-cat-bg: #e2e8f0;
    --search-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --card-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --border-radius: 8px;

    /* Typography */
    --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-sans);
    background-color: var(--page-background);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Header */
.site-header {
    background-color: var(--primary-header-bg);
    color: #fff;
    padding: 30px 0;
    /* Balanced padding v1.9.0 */
}

@media (max-width: 768px) {
    .site-header {
        padding: 20px 0 30px;
    }
}

.header-inner {
    max-width: 100%;
    /* Changed from 1100px to Full Width */
    margin: 0;
    /* Align to edges */
    padding: 0 40px;
    /* Added side padding for aesthetics */
    display: flex;
    justify-content: space-between;
    align-items: center;
    /* Vertical Center */
    margin-bottom: 40px;
}

.site-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    /* Margin Top controlled by Customizer */
}

.site-logo img {
    height: auto;
    max-width: 100%;
    max-height: 80px;
    /* Tighter safety limit v1.9.1 */
    /* Height controlled by Customizer */
}

.site-nav a {
    color: #ccc;
    text-decoration: none;
    margin-left: 20px;
    font-size: 14px;
    transition: color 0.2s;
}

.site-nav a:hover {
    color: #fff;
}

/* Search Hero */
.search-hero {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
    padding-bottom: 40px;
}

.search-hero h1 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 24px;
    color: #fff;
}

.search-form {
    position: relative;
}

.search-input {
    width: 100%;
    padding: 16px 20px 16px 48px;
    border-radius: var(--border-radius);
    border: none;
    font-size: 16px;
    box-shadow: var(--search-shadow);
    outline: none;
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    width: 20px;
    height: 20px;
}

/* Live Search Results */
.live-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    margin-top: 8px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    z-index: 100;
    overflow: hidden;
    text-align: left;
    border: 1px solid #e2e8f0;
}

.search-results-header {
    background: #f8fafc;
    padding: 8px 16px;
    font-size: 11px;
    text-transform: uppercase;
    color: var(--text-light);
    font-weight: 600;
    border-bottom: 1px solid #e2e8f0;
}

.search-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    text-decoration: none;
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.1s;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: #f1f5f9;
}

.result-title {
    font-size: 14px;
    color: var(--text-main);
    font-weight: 500;
}

.result-category {
    font-size: 11px;
    background: #e0e7ff;
    color: #4338ca;
    padding: 2px 8px;
    border-radius: 99px;
}

.search-no-result {
    padding: 16px;
    color: var(--text-light);
    font-size: 14px;
    text-align: center;
}

/* Main Content */
.site-main {
    max-width: 1100px;
    /* Wider for sidebar layout */
    margin: 40px auto 60px;
    padding: 0 20px;
    position: relative;
    z-index: 10;
}

/* 2-Column Layout (Sidebar + Content) */
.layout-sidebar {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 40px;
    align-items: start;
}

/* Logo Alignment Styles */
.site-header.logo-center .header-inner {
    justify-content: center;
}

.site-header.logo-right .header-inner {
    justify-content: flex-end;
}

/* Sidebar Right Position */
.layout-sidebar.sidebar-right {
    grid-template-columns: 1fr 250px;
}

.layout-sidebar.sidebar-right .sidebar {
    order: 2;
}

.sidebar-title {
    font-size: 13px;
    text-transform: uppercase;
    color: #000000 !important;
    font-weight: 700;
    margin-bottom: 16px;
    margin-top: 0;
    letter-spacing: 1px;
    background: none !important;
    background-color: transparent !important;
    padding: 0 !important;
    display: block !important;
    position: relative;
    z-index: 10;
    border: none !important;
    box-shadow: none !important;
}

.sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar ul li {
    margin-bottom: 8px;
}

.sidebar ul li a {
    display: block;
    color: var(--text-main);
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 6px;
    transition: background-color 0.2s ease;
    background: white;
}

.sidebar ul li a:hover {
    color: var(--text-main);
    background-color: rgba(0, 0, 0, 0.03);
}

.sidebar-menu a.active {
    background-color: #e2e8f0;
    /* Match screenshot active state */
    color: #1e293b;
    font-weight: 700;
}

/* Sticky Sidebar */
.sidebar {
    position: -webkit-sticky;
    position: sticky;
    top: 20px;
    align-self: start;
}

/* Breadcrumbs */
.vsl-breadcrumbs {
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 24px;
}

.vsl-breadcrumbs a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.2s;
}

.vsl-breadcrumbs a:hover {
    color: var(--accent-blue);
}

.vsl-breadcrumbs .separator {
    margin: 0 8px;
    color: #cbd5e1;
}

.vsl-breadcrumbs .current {
    color: var(--text-main);
    font-weight: 500;
}

/* Sticky Sidebar */
.sidebar {
    position: -webkit-sticky;
    position: sticky;
    top: 20px;
    align-self: start;
}

/* Breadcrumbs */
.vsl-breadcrumbs {
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 24px;
}

.vsl-breadcrumbs a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.2s;
}

.vsl-breadcrumbs a:hover {
    color: var(--accent-blue);
}

.vsl-breadcrumbs .separator {
    margin: 0 8px;
    color: #cbd5e1;
}

.vsl-breadcrumbs .current {
    color: var(--text-main);
    font-weight: 500;
}

/* Article List (Right Column) */
.article-list-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.article-card-row {
    background: #fff;
    border-radius: var(--border-radius);
    padding: 24px;
    box-shadow: var(--card-shadow);
    display: flex;
    /* Row layout */
    justify-content: space-between;
    align-items: flex-start;
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid transparent;
}

.article-card-row:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    border-color: #e2e8f0;
}

.article-row-content {
    display: flex;
    gap: 16px;
    max-width: 75%;
}

.article-row-icon {
    font-size: 20px;
    color: #000;
    margin-top: 2px;
    /* Align with title */
}

.article-row-text h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 8px;
}

.article-row-text p {
    font-size: 14px;
    color: var(--text-light);
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-row-meta {
    text-align: right;
    min-width: 100px;
}

.meta-label {
    display: block;
    font-size: 12px;
    color: var(--text-light);
    margin-bottom: 4px;
}

/* POPULARITY BARS */
.popularity-bar {
    display: inline-flex;
    gap: 3px;
}

.popularity-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #cbd5e1;
    /* Empty state */
}

.popularity-dot.active {
    background-color: #0f172a;
    /* Filled state (Dark matching screenshot) */
}

/* Fallback / Search */
.article-container {
    background: #fff;
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--card-shadow);
}

/* Category Grid (Home) - Retained */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 24px;
}

.category-card {
    background: #fff;
    border-radius: var(--border-radius);
    padding: 24px;
    box-shadow: var(--card-shadow);
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.category-card:hover {
    content: '';
    transform: translateY(-2px);
}

/* Simplified hover */
.category-icon {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.category-content h2 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}

.category-content p {
    font-size: 14px;
    color: var(--text-light);
    margin: 0;
}

.category-meta {
    margin-top: 12px;
    font-size: 12px;
    font-weight: 500;
    color: #9ca3af;
}

.category-tag {
    background: #e0e7ff;
    color: #3730a3;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    text-transform: uppercase;
}


/* Footer */
.site-footer {
    text-align: center;
    padding: 40px 0;
    color: var(--text-light);
    font-size: 14px;
    margin-top: auto;
}

.footer-action {
    background: #fff;
    border: 1px solid #e5e7eb;
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    display: inline-block;
    margin-top: 10px;
}

/* Mobile */
@media (max-width: 768px) {
    .layout-sidebar {
        grid-template-columns: 1fr;
    }

    .sidebar-menu {
        display: none;
        /* Hide sidebar on mobile or make it a dropdown */
    }

    .header-inner {
        flex-direction: column;
        gap: 16px;
    }

    .category-grid {
        grid-template-columns: 1fr;
    }
}

/* WhatsApp Floating Button */
/* WhatsApp Floating Button - v1.7 */
#whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    width: 60px;
    height: 60px;
    display: block;
    cursor: pointer;
    transition: transform 0.2s ease;
    background: transparent;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

#whatsapp-float img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 50%;
}

#whatsapp-float:hover {
    transform: scale(1.1);
}