/* ============================================
   ENHANCED PAGES DESIGN - 2025 MODERN AESTHETIC
   For: blogs.php, videos.php, courses.php, store.php
   ============================================ */

/* ============================================
   GLOBAL ENHANCEMENTS & VARIABLES
   ============================================ */
:root {
    --primary-color: #0a1f3a;
    --secondary-color: #1f5a9f;
    --accent-color: #8b7355;
    --text-color: #2c2c2c;
    --bg-color: #f9f7f4;
    --card-bg: #ffffff;
    --border-color: #e8e4dd;
    --success-color: #2e7d32;
    --danger-color: #c62828;
}

/* ============================================
   BLOGS PAGE ENHANCEMENTS
   ============================================ */

/* Filters Section - Branded Dark Theme */
.blogs-filters-section {
    background: var(--primary-color);
    padding: 3rem 0;
    margin-bottom: 3rem;
    color: white;
}

.blogs-filters-section .filters {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
}

.blogs-filters-section .search-bar {
    width: 100%;
    max-width: 650px;
    padding: 1rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    font-size: 1.05rem;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    transition: all 0.3s ease;
}

.blogs-filters-section .search-bar::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.blogs-filters-section .search-bar:focus {
    outline: none;
    border-color: var(--secondary-color);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.blogs-filters-section .category-filters {
    display: flex;
    gap: 0.8rem;
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    padding: 10px 5px;
    scrollbar-width: none;
}

.blogs-filters-section .category-filters::-webkit-scrollbar {
    display: none;
}

.blogs-filters-section .category-link {
    padding: 0.7rem 1.4rem;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    white-space: nowrap;
}

.blogs-filters-section .category-link:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    transform: translateY(-2px);
}

.blogs-filters-section .category-link.active {
    background: var(--secondary-color);
    color: #ffffff;
    border-color: var(--secondary-color);
    box-shadow: 0 4px 10px rgba(31, 90, 159, 0.4);
}

.blogs-filters-section .search-bar:focus {
    outline: none;
    border-color: var(--secondary-color);
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(31, 90, 159, 0.1);
}

.blogs-filters-section .category-filters {
    display: flex;
    gap: 0.8rem;
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    padding-bottom: 10px;
    /* Space for scrollbar */
    scrollbar-width: thin;
    /* Firefox */
    scrollbar-color: var(--secondary-color) #e0e0e0;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    max-width: 100%;
}

/* Custom scrollbar for Webkit */
.blogs-filters-section .category-filters::-webkit-scrollbar {
    height: 6px;
}

.blogs-filters-section .category-filters::-webkit-scrollbar-track {
    background: #e0e0e0;
    border-radius: 3px;
}

.blogs-filters-section .category-filters::-webkit-scrollbar-thumb {
    background-color: var(--secondary-color);
    border-radius: 3px;
}

.blogs-filters-section .filters {
    width: 100%;
    /* Ensure filters container doesn't constrain width too much for scrolling */
}

.blogs-filters-section .category-link {
    padding: 0.6rem 1.2rem;
    background: #f0f0f0;
    color: #555;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.blogs-filters-section .category-link:hover {
    background: var(--secondary-color);
    color: #ffffff;
    transform: translateY(-1px);
}

.blogs-filters-section .category-link.active {
    background: var(--secondary-color);
    color: #ffffff;
    border-color: var(--secondary-color);
}

/* Priority Categories */
.blogs-filters-section .category-link.priority {
    border-color: var(--accent-color);
    color: var(--accent-color);
    border-width: 2px;
}

.blogs-filters-section .category-link.priority:hover {
    background: var(--accent-color);
    color: white;
}

/* Enhanced Article Cards - Premium Feel */
.article-card {
    background: var(--card-bg);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
    cursor: pointer;
    border: 1px solid var(--border-color);
    height: 100%;
}

.article-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
    border-color: var(--secondary-color);
}

.article-image-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #e0e0e0;
}

.article-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.article-card:hover .article-image {
    transform: scale(1.05);
}

.article-category-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(31, 90, 159, 0.9);
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    z-index: 2;
}

.article-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.article-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 0.8rem 0;
    color: var(--primary-color);
    line-height: 1.4;
    font-family: 'Merriweather', serif;
}

.article-excerpt {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #666;
    margin-bottom: 1rem;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: #999;
    padding-top: 1rem;
    border-top: 1px solid #f0f0f0;
}

/* ============================================
   VIDEOS PAGE ENHANCEMENTS
   ============================================ */

.video-card {
    background: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    text-decoration: none !important;
    /* Force remove underline */
}

.video-card a {
    text-decoration: none !important;
    color: inherit;
}

.video-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.video-thumbnail-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #000;
}

.video-thumbnail-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.9;
    transition: transform 0.5s ease, opacity 0.3s ease;
}

.video-card:hover .video-thumbnail-container img {
    transform: scale(1.05);
    opacity: 1;
}

.play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(31, 90, 159, 0.9);
    /* Blue play button */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    z-index: 5;
}

.video-card:hover .play-icon {
    transform: translate(-50%, -50%) scale(1.1);
    background: #1f5a9f;
}

.video-card-content {
    padding: 1.2rem;
}

.video-card-content h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
    margin: 0 0 0.5rem 0;
    line-height: 1.4;
    text-decoration: none !important;
}

.video-card-content p {
    font-size: 0.9rem;
    color: #666;
    margin: 0;
    line-height: 1.5;
    text-decoration: none !important;
}

/* ============================================
   COURSES PAGE ENHANCEMENTS
   ============================================ */

.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem 0;
}

.course-card {
    background: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.course-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.course-image-container {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
    background: #f0f0f0;
}

.course-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.course-card:hover .course-image-container img {
    transform: scale(1.05);
}

.course-level-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 4px 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    border-radius: 4px;
}

.course-card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.course-card-content h3 {
    font-family: 'Merriweather', serif;
    font-size: 1.2rem;
    color: var(--primary-color);
    margin: 0 0 0.8rem 0;
    line-height: 1.3;
    font-weight: 700;
}

.course-card-content p {
    color: #555;
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 0 0 1.2rem 0;
    flex-grow: 1;
}

.course-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.85rem;
    color: #777;
}

.course-price {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--secondary-color);
    color: white;
    font-weight: 600;
    font-size: 1rem;
    border-radius: 4px;
    margin-top: auto;
    align-self: flex-start;
}

.course-price.free {
    background: var(--success-color);
}

/* ============================================
   STORE PAGE ENHANCEMENTS
   ============================================ */

.store-page {
    background: var(--bg-color);
    padding: 2rem 0;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    padding: 0;
}

.product-card {
    background: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.product-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover img {
    transform: scale(1.05);
}

.product-card h3 {
    font-family: 'Merriweather', serif;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
    margin: 1.2rem 1.2rem 0.5rem 1.2rem;
    line-height: 1.4;
}

.product-card .price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin: 0 1.2rem 1rem 1.2rem;
}

.stock-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--success-color);
    color: #ffffff;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    margin: 0 1.2rem 1rem 1.2rem;
    align-self: flex-start;
}

.stock-badge.out-of-stock {
    background: var(--danger-color);
}

.product-card .btn {
    width: calc(100% - 2.4rem);
    margin: 0 1.2rem 1.2rem 1.2rem;
    padding: 0.8rem;
    background: var(--secondary-color);
    color: #ffffff;
    border: none;
    border-radius: 4px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.product-card .btn:hover {
    background: #14447a;
    transform: translateY(-2px);
}

.quantity-selector {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 0 1.2rem 1rem 1.2rem;
}

.quantity-btn {
    width: 30px;
    height: 30px;
    border: 1px solid var(--secondary-color);
    background: #fff;
    color: var(--secondary-color);
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.quantity-btn:hover {
    background: var(--secondary-color);
    color: #fff;
}

.quantity-input {
    width: 50px;
    padding: 0.4rem;
    text-align: center;
    border: 1px solid #ccc;
    border-radius: 4px;
}

/* ============================================
   FOOTER ENHANCEMENTS
   ============================================ */

.site-footer {
    background: #1a1a1a;
    color: #ffffff;
    margin-top: 4rem;
    padding-top: 3rem;
    border-top: 4px solid var(--accent-color);
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-top {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo-img {
    max-width: 150px;
    margin-bottom: 1rem;
}

.footer-tagline {
    font-style: italic;
    color: #ccc;
    margin-bottom: 1rem;
}

.footer-heading {
    color: #fff;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-menu li {
    margin-bottom: 0.8rem;
}

.footer-menu a {
    color: #aaa;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-menu a:hover {
    color: #fff;
}

.footer-bottom {
    background: #111;
    padding: 1.5rem 0;
    border-top: 1px solid #333;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-copyright {
    color: #888;
    font-size: 0.9rem;
    margin: 0;
}

.footer-bottom-links {
    display: flex;
    gap: 1rem;
}

.footer-bottom-links a {
    color: #888;
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-bottom-links a:hover {
    color: #fff;
}

@media (max-width: 900px) {
    .footer-top {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 600px) {
    .footer-top {
        grid-template-columns: 1fr;
    }

    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
    }
}