/*
Theme Name: Crawl Theory
Author: Lakshit Rajput
Author URI: https://lakshitrajput.co.in/
Description: A high-performance editorial theme for Crawl Theory, meticulously crafted for local SEO experts and publishers.
Version: 1.1
*/

:root {
    --primary-color: #064e3b;
    /* Deep Forest Green */
    --primary-dark: #043a2c;
    --accent-color: #11d03b;
    /* Emerald Green */
    --accent-hover: #0eb032;
    --bg-light: #F8FAF9;
    /* Very Light Forest Wash */
    --bg-surface: #FFFFFF;
    --text-main: #111412;
    --text-muted: #64748B;
    --white: #FFFFFF;
    --radius-lg: 24px;
    --radius-md: 12px;
    --radius-sm: 8px;
    --container-width: 1280px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', 'Inter', sans-serif;
    color: var(--text-main);
    line-height: 1.5;
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 600;
    line-height: 1.2;
}

/* Header */
.main-header {
    background-color: #064e3b;
    /* Match Footer */
    padding: 16px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
}

.main-header.is-scrolled {
    background-color: rgba(6, 78, 59, 0.95);
    backdrop-filter: blur(10px);
    padding: 12px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.main-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

/* Header Search */
.header-search-container {
    flex: 1;
    max-width: 400px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.main-header.is-scrolled .header-search-container {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.header-search-form {
    width: 100%;
}

.header-search-form .search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.header-search-form .search-icon {
    position: absolute;
    left: 16px;
    color: rgba(255, 255, 255, 0.5);
    pointer-events: none;
}

.header-search-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 100px;
    padding: 10px 16px 10px 44px;
    color: var(--white);
    font-size: 14px;
    transition: var(--transition);
}

.header-search-input:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--accent-color);
    outline: none;
    box-shadow: 0 0 0 4px rgba(17, 208, 59, 0.1);
}

.header-search-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.logo a {
    font-size: 30px;
    font-weight: 700;
    color: var(--white);
}

.logo a span {
    color: #11d03b;
}

.nav-link {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
}

.nav-link:hover {
    color: var(--white);
}

.nav-link.accent {
    color: #11d03b;
}

/* Hero Section */
@keyframes ambientGlow {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.hero {
    background: linear-gradient(-45deg, #064e3b, #043a2c, #065f46, #064e3b);
    background-size: 400% 400%;
    animation: ambientGlow 15s ease infinite;
    position: relative;
    overflow: hidden;
    color: var(--white);
    padding-top: 60px;
    margin-bottom: 80px;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle at 80% 20%, rgba(17, 208, 59, 0.15), transparent 40%),
        radial-gradient(circle at 20% 80%, rgba(17, 208, 59, 0.1), transparent 40%);
    pointer-events: none;
}

.hero .hero-main-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 30px;
    margin-bottom: 120px;
}

.hero-tabs-container {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-tabs {
    display: flex;
    list-style: none;
    gap: 48px;
}

.hero-tab {
    display: block;
    padding: 20px 0;
    font-weight: 600;
    font-size: 24px;
    color: rgba(255, 255, 255, 0.6);
    border-bottom: 4px solid transparent;
    transition: all 0.3s ease;
}

.hero-tab:hover {
    color: var(--white);
}

.hero-tab.active {
    color: #11d03b;
    border-bottom-color: #11d03b;
}

.hero h1 {
    font-size: 56px;
    margin-bottom: 24px;
}

.hero p {
    font-size: 18px;
    opacity: 0.8;
}

/* Category Filter */
.category-nav {
    border-bottom: 1px solid #EAECF0;
    margin-top: 40px;
}

.category-list {
    display: flex;
    list-style: none;
    gap: 32px;
    overflow-x: auto;
    padding-bottom: 2px;
}

.category-item a {
    display: block;
    padding: 16px 0;
    font-weight: 500;
    font-size: 16px;
    color: var(--text-muted);
    border-bottom: 4px solid transparent;
    white-space: nowrap;
}

.category-item a:hover,
.category-item.active a {
    color: var(--primary-color);
    border-bottom-color: var(--accent-color);
}

/* Search Bar */
.search-container.rectangular {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-sm);
    padding: 8px 32px;
    display: flex;
    align-items: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    max-width: 800px;
    width: 100%;
    height: 72px;
}

.search-input-group {
    flex: 1;
    display: flex;
    align-items: center;
}

.search-input {
    border: none;
    padding: 10px 0;
    width: 100%;
    font-size: 18px;
    outline: none;
    color: var(--white);
    background: transparent;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.search-divider {
    width: 1px;
    height: 32px;
    background-color: rgba(255, 255, 255, 0.1);
    margin: 0 20px;
}

.custom-dropdown-container {
    position: relative;
    min-width: 180px;
}

.custom-dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}

.selected-category {
    font-size: 16px;
    font-weight: 500;
    color: var(--white);
}

.chevron-icon {
    color: var(--text-muted);
    transition: transform 0.3s ease;
}

.custom-dropdown-container.active .chevron-icon {
    transform: rotate(180deg);
}

.custom-dropdown-menu {
    position: absolute;
    top: calc(100% + 12px);
    left: -20px;
    right: -10px;
    background: var(--white);
    border-radius: var(--radius-sm);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    list-style: none;
    padding: 8px;
    display: none;
    z-index: 100;
    border: 1px solid #EAECF0;
}

.custom-dropdown-container.active .custom-dropdown-menu {
    display: block;
}

.dropdown-item {
    padding: 12px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 15px;
    color: #000;
    transition: background 0.2s ease;
}

.dropdown-item:hover {
    background-color: var(--bg-light);
}

.dropdown-item.active {
    background-color: rgba(42, 232, 85, 0.15);
    color: #000;
    font-weight: 600;
}

.search-btn.rectangular {
    background: var(--accent-color);
    border: none;
    border-radius: var(--radius-sm);
    padding: 0 24px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--white);
    font-weight: 600;
    font-size: 16px;
    transition: all 0.3s ease;
}

.search-btn.rectangular:hover {
    background: var(--accent-hover);
}

/* Featured Section */
.featured-section,
.latest-section,
.learn-section,
.resources-section,
.guide-section,
.news-section,
.search-results-container,
.editorial-section {
    margin-bottom: 120px;
}

.editorial-section {
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.editorial-section:nth-child(even) {
    background-color: var(--bg-light);
}

.section-info {
    position: sticky;
    top: 120px;
    height: fit-content;
}

.section-tag {
    display: inline-block;
    padding: 6px 16px;
    background-color: rgba(17, 208, 59, 0.1);
    color: var(--primary-color);
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 100px;
    margin-bottom: 24px;
    border: 1px solid rgba(17, 208, 59, 0.2);
}

.section-title {
    font-size: 48px;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 24px;
}

.featured-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 40px;
}

.featured-card.large {
    height: 100%;
}

.featured-image-link {
    display: block;
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 24px;
    border: 1px solid #EAECF0;
}

.featured-image {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.featured-title {
    font-size: 36px;
    margin-bottom: 16px;
}

.featured-title a:hover {
    color: var(--accent-color);
}

.featured-excerpt {
    color: var(--text-muted);
    font-size: 18px;
    margin-bottom: 24px;
}

.featured-list {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.featured-item {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 20px;
}

.featured-item-image {
    width: 120px;
    height: 120px;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid #EAECF0;
}

.featured-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-item-title {
    font-size: 18px;
    margin-bottom: 12px;
    line-height: 1.4;
}

.featured-item-title a:hover {
    color: var(--accent-color);
}

/* Post Grid */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 48px 32px;
    padding: 60px 0;
}

/* Post Card */
.news-r.post-card {
    background: var(--white);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid #EAECF0;
}

.post-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(6, 78, 59, 0.08);
    border-color: rgba(17, 208, 59, 0.3);
}

.post-card-image {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    border-radius: var(--radius-lg);
    margin-bottom: 20px;
    transition: all 0.3s ease;
    border: 1px solid #EAECF0;
}

.post-card-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.post-card-dot {
    opacity: 0.5;
}

.post-card-title {
    font-size: 22px;
    line-height: 1.3;
    margin-bottom: 16px;
    font-weight: 600;
}

.post-card-title a:hover {
    color: var(--accent-color);
}

.post-card-excerpt {
    font-size: 15px;
    color: var(--text-muted);
    margin-bottom: 24px;
    line-height: 1.6;
}

.post-card-author-v2 {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-top: auto;
    margin-bottom: 16px;
}

.author-info-stack {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.author-name-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.author-name {
    font-weight: 600;
    font-size: 16px;
    color: var(--text-main);
}

.post-card-read-time {
    font-size: 14px;
    color: var(--text-muted);
}

.author-position {
    font-size: 13px;
    color: var(--text-muted);
}

.post-card-date-bottom {
    font-size: 13px;
    color: var(--text-muted);
    opacity: 0.7;
}

/* Responsiveness */
@media (max-width: 1024px) {
    .hero {
        padding: 60px 0 0;
    }

    .hero h1 {
        font-size: 40px;
    }

    .hero .hero-main-container {
        flex-direction: column;
        text-align: center;
        gap: 40px;
        margin-bottom: 40px;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero-search {
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .featured-grid {
        grid-template-columns: 1fr;
    }

    .hero-tabs {
        gap: 32px;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .hero {
        padding: 40px 0 0;
    }

    .hero h1 {
        font-size: 32px;
    }

    .hero p {
        font-size: 16px;
    }

    .search-container.rectangular {
        flex-direction: row;
        height: 56px;
        padding: 0 16px;
        gap: 8px;
    }

    .search-input-group {
        flex: 1;
    }

    .search-input {
        font-size: 14px;
    }

    .search-divider {
        display: block;
        height: 20px;
        margin: 0 8px;
    }

    .custom-dropdown-container {
        width: auto;
        min-width: 120px;
        padding: 0;
        border: none;
    }

    .selected-category {
        font-size: 13px;
    }

    .custom-dropdown-trigger {
        gap: 6px;
    }

    .hero-tabs {
        gap: 24px;
        overflow-x: auto;
        padding-bottom: 0;
        justify-content: flex-start;
        -ms-overflow-style: none;
        scrollbar-width: none;
    }

    .hero-tabs::-webkit-scrollbar {
        display: none;
    }

    .hero-tab {
        font-size: 14px;
        padding: 16px 0;
        white-space: nowrap;
    }

    .posts-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .featured-item {
        grid-template-columns: 1fr;
    }

    .featured-item-image {
        width: 100%;
        height: 200px;
    }
}

/* Latest Section */
.latest-section {
    padding: 60px 0;
    background-color: var(--white);
    border-top: 1px solid #EAECF0;
}

.latest-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    margin-top: 40px;
    border-top: 1px solid #EAECF0;
}

.latest-card {
    background-color: var(--white);
    padding: 40px 32px;
    display: flex;
    flex-direction: column;
    height: 100%;
    border-right: 1px solid #EAECF0;
    border-bottom: 1px solid #EAECF0;
}

/* Remove right border on the last item of each row for desktop */
@media (min-width: 1025px) {
    .latest-card:nth-child(4n) {
        border-right: none;
    }
}

.latest-card-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    justify-content: space-between;
}

.latest-meta-top {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.category-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: var(--bg-light);
    padding: 6px 12px;
    border-radius: 100px;
    width: fit-content;
    transition: opacity 0.2s ease;
}

.category-tag:hover {
    opacity: 0.8;
}

.category-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #FF8904;
    /* Default orange dot */
}

.category-name {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--primary-color);
}

.meta-info {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
}

.meta-dot {
    width: 4px;
    height: 4px;
}

.latest-card-title {
    font-size: 24px;
    line-height: 1.3;
    font-weight: 600;
    margin-bottom: 40px;
    letter-spacing: -0.5px;
}

.latest-card-title a:hover {
    text-decoration: underline;
}

.latest-card-footer {
    margin-top: auto;
}

.latest-author {
    display: flex;
    align-items: center;
    gap: 16px;
    transition: opacity 0.2s ease;
}

.latest-author:hover {
    opacity: 0.8;
}

.latest-author-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    object-fit: cover;
}

.latest-author-name {
    font-weight: 600;
    font-size: 15px;
    color: var(--text-main);
}

.latest-author-position {
    font-size: 14px;
    color: var(--text-muted);
}

@media (max-width: 768px) {
    .latest-card {
        padding: 24px;
        border-right: none;
        border-bottom: 1px solid #EAECF0;
    }

    .latest-card-title {
        font-size: 20px;
    }
}

/* Learn Section */
.learn-section {
    padding: 80px 0;
    background-color: #F9FAFB;
    border-top: 1px solid #EAECF0;
}

.learn-main-grid {
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 48px;
}

.learn-info-block {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.learn-label {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.learn-title {
    font-size: 16px;
    line-height: 1.6;
    font-weight: 400;
    color: var(--text-muted);
}

.learn-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    margin-top: 12px;
}

.learn-cta:hover {
    text-decoration: underline;
}

.learn-posts-container {
    display: grid;
    grid-template-rows: auto auto;
    gap: 32px;
}

.learn-featured-post {
    border-bottom: 1px solid #EAECF0;
    padding-bottom: 32px;
}

.learn-card.horizontal {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 32px;
}

.learn-card-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 16px;
}

.learn-card-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.meta-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
}

.learn-card-title {
    font-size: 24px;
    line-height: 1.3;
    font-weight: 600;
}

.learn-card-title.mini {
    font-size: 18px;
}

.learn-card-author {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 8px;
}

.learn-card-author .author-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 10px;
}

.learn-card-author .author-name {
    font-weight: 600;
    font-size: 14px;
}

.learn-card-author .author-position {
    font-size: 13px;
    color: var(--text-muted);
}

.learn-small-posts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
}

.learn-card.vertical {
    border-right: 1px solid #EAECF0;
    padding-right: 24px;
}

.learn-small-posts .learn-card.vertical:last-child {
    border-right: none;
    padding-right: 0;
}

@media (max-width: 1024px) {
    .learn-main-grid {
        grid-template-columns: 1fr;
    }

    .learn-card.horizontal {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .learn-small-posts {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .learn-card.vertical {
        border-right: none;
        padding-right: 0;
        border-bottom: 1px solid #EAECF0;
        padding-bottom: 24px;
    }
}

/* Resources Section */
.resources-section {
    padding: 80px 0;
    background-color: var(--white);
    border-top: 1px solid #EAECF0;
}

.resources-main-grid {
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 48px;
}

.resources-info-block {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.resources-label {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.resources-description {
    font-size: 16px;
    line-height: 1.6;
    font-weight: 400;
    color: var(--text-muted);
}

.resources-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    margin-top: 12px;
}

.resources-cta:hover {
    text-decoration: underline;
}

.resources-posts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.resource-card {
    background-color: #eef3ef;
    padding: 32px;
    border-radius: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.resource-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.resource-card-top {
    margin-bottom: 24px;
}

.last-updated {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

.resource-card-title {
    font-size: 20px;
    line-height: 1.4;
    font-weight: 700;
    margin-bottom: 32px;
}

.resource-card-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.resource-card-author .author-avatar img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
}

.resource-card-author .author-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--primary-color);
}

.resource-card-author .author-position {
    font-size: 12px;
    color: var(--text-muted);
}

.resource-card-author .author-details {
    display: flex;
    flex-direction: column;
}

@media (max-width: 1024px) {
    .resources-main-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .resources-posts-grid {
        grid-template-columns: 1fr;
    }
}

/* Guide Section */
.guide-section {
    padding: 80px 0;
    background-color: #F9FAFB;
    border-top: 1px solid #EAECF0;
    overflow: hidden;
}

.guide-main-grid {
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 48px;
}

.guide-info-block {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.guide-label {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.guide-description {
    font-size: 16px;
    line-height: 1.6;
    font-weight: 400;
    color: var(--text-muted);
}

.guide-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    margin-top: 12px;
}

.guide-cta:hover {
    text-decoration: underline;
}

.guide-carousel-wrapper {
    position: relative;
    width: 100%;
}

.guide-carousel-container {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.guide-carousel-container::-webkit-scrollbar {
    display: none;
}

.guide-card-carousel {
    flex: 0 0 100%;
    scroll-snap-align: start;
    background-color: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
}

.guide-card-carousel:hover {
    transform: translateY(-5px);
}

.guide-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.guide-card-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.guide-card-title {
    padding: 24px;
    font-size: 18px;
    line-height: 1.4;
    font-weight: 600;
    color: var(--primary-color);
}

.carousel-nav {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.carousel-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid #EAECF0;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--primary-color);
    transition: all 0.2s ease;
}

.carousel-btn:hover {
    background: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
}

@media (max-width: 1024px) {
    .guide-main-grid {
        grid-template-columns: 1fr;
    }
}

/* Sticky Info Blocks */
.learn-info-block,
.resources-info-block,
.guide-info-block,
.news-info-block {
    position: sticky;
    top: 120px;
    height: fit-content;
    align-self: start;
    z-index: 10;
}

@media (max-width: 1024px) {

    .learn-info-block,
    .resources-info-block,
    .guide-info-block,
    .news-info-block {
        position: static;
    }
}

/* News Section */
.news-section {
    padding: 80px 0;
    background-color: var(--white);
    border-top: 1px solid #EAECF0;
}

.news-main-grid {
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 48px;
}

.news-info-block {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.news-label {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.news-description {
    font-size: 16px;
    line-height: 1.6;
    font-weight: 400;
    color: var(--text-muted);
}

.news-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    margin-top: 12px;
}

.news-cta:hover {
    text-decoration: underline;
}

.news-posts-stack {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.news-row-card {
    background-color: #f2ebfe;
    border-radius: 24px;
    display: flex;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-row-card:hover {
    transform: translateX(8px);
    box-shadow: 0 4px 20px rgba(105, 56, 239, 0.1);
}

.news-row-image {
    flex: 0 0 280px;
}

.news-row-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-row-content {
    flex: 1;
    padding: 32px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.news-row-meta {
    margin-bottom: 12px;
}

.news-row-date {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    color: #6938EF;
    letter-spacing: 0.5px;
}

.news-row-title {
    font-size: 22px;
    line-height: 1.4;
    font-weight: 700;
    margin-bottom: 24px;
}

.news-row-title a {
    text-decoration: none;
    color: var(--primary-color);
}

.news-row-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #6938EF;
    text-decoration: none;
}

@media (max-width: 1024px) {
    .news-main-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .news-row-card {
        flex-direction: column;
    }

    .news-row-image {
        flex: 0 0 200px;
    }
}

/* Scroll Reveal Animations */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered card reveals */
.stagger-reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.stagger-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Site Footer */
.site-footer {
    background-color: #064e3b;
    /* Deep Dark Green */
    color: var(--white);
    padding-top: 0;
}

/* Footer CTA / Newsletter */
.footer-cta {
    background: linear-gradient(135deg, #065f46 0%, #064e3b 100%);
    padding: 80px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cta-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 60px;
}

.cta-text {
    flex: 1;
}

.cta-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--white);
}

.cta-description {
    font-size: 18px;
    color: #94A3B8;
    line-height: 1.6;
}

.cta-form {
    flex: 0 0 450px;
    display: flex;
    gap: 12px;
}

.cta-form input {
    flex: 1;
    padding: 16px 24px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: var(--white);
    font-size: 16px;
}

.cta-form button {
    padding: 16px 32px;
    border-radius: 12px;
    background: #11d03b;
    color: var(--primary-color);
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.cta-form button:hover {
    background: #0eb032;
    transform: translateY(-2px);
}

/* Footer Main */
.footer-main {
    padding: 100px 0 80px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 60px;
}

.footer-logo {
    font-size: 28px;
    font-weight: 800;
    color: var(--white);
    text-decoration: none;
    display: block;
    margin-bottom: 24px;
}

.footer-logo span {
    color: #11d03b;
}

.brand-description {
    color: #94A3B8;
    line-height: 1.7;
    margin-bottom: 32px;
    font-size: 16px;
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-links a {
    color: #94A3B8;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: #11d03b;
}

.footer-nav-title {
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 24px;
}

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

.footer-nav-list li {
    margin-bottom: 16px;
}

.footer-nav-list a {
    text-decoration: none;
    color: #94A3B8;
    font-size: 16px;
    transition: color 0.3s ease;
}

.footer-nav-list a:hover {
    color: #11d03b;
}

/* Footer Bottom */
.footer-bottom {
    padding: 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.bottom-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.copyright,
.developer-credit {
    color: #64748B;
    font-size: 14px;
}

.developer-credit a {
    color: #11d03b;
    text-decoration: none;
    font-weight: 600;
}

.developer-credit a:hover {
    text-decoration: underline;
}

@media (max-width: 640px) {
    .bottom-inner {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }
}

@media (max-width: 1024px) {
    .cta-inner {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }

    .cta-form {
        width: 100%;
        flex: none;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .cta-form {
        flex-direction: column;
    }
}

/* --- Advanced UI/UX Enhancements --- */

/* 1. Reading Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: #11d03b;
    z-index: 10001;
    transition: width 0.1s ease;
}

/* Floating Decorative Elements */
@keyframes float {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(15deg);
    }
}

.floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
    overflow: hidden;
}

.floating-shape {
    position: absolute;
    opacity: 0.4;
    animation: float 8s ease-in-out infinite;
}

.shape-triangle {
    width: 0;
    height: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
    border-bottom: 26px solid currentColor;
}

.shape-purple {
    color: #f3e8ff;
}

.shape-green {
    color: #f0fdf4;
}

.shape-1 {
    top: 10%;
    left: 5%;
    animation-delay: 0s;
}

.shape-2 {
    top: 30%;
    right: 5%;
    animation-delay: 2s;
}

.shape-3 {
    top: 50%;
    left: 8%;
    animation-delay: 4s;
}

.shape-4 {
    top: 70%;
    right: 10%;
    animation-delay: 1s;
}

.shape-5 {
    top: 90%;
    left: 15%;
    animation-delay: 3s;
}

/* 2. Buttons */
.btn-primary {
    background-color: var(--accent-color);
    color: var(--primary-color);
    padding: 14px 28px;
    border-radius: var(--radius-md);
    font-weight: 700;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(17, 208, 59, 0.2);
}

/* 3. Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: #11d03b;
    color: var(--primary-color);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background-color: #0eb032;
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* 3. Skeleton Loading */
.skeleton-card {
    background: var(--white);
    border-radius: 24px;
    padding: 32px;
    border: 1px solid #EAECF0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.skeleton-box {
    background: linear-gradient(90deg, #f0f0f0 25%, #f8f8f8 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: 8px;
}

.skeleton-image {
    width: 100%;
    height: 200px;
}

.skeleton-title {
    width: 80%;
    height: 24px;
}

.skeleton-text {
    width: 100%;
    height: 14px;
}

.skeleton-meta {
    width: 40%;
    height: 14px;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* 4. Image Blur-Up Placeholder */
img {
    transition: filter 0.3s ease;
}

img.lazy-loading {
    filter: blur(10px);
}

img.lazy-loaded {
    filter: blur(0);
}

/* Placeholder for missing images */
.placeholder-img {
    background: linear-gradient(135deg, #eef3ef 0%, #EAECF0 100%);
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.placeholder-img::after {
    content: 'CT';
    font-weight: 800;
    color: var(--accent-color);
    opacity: 0.3;
    font-size: 24px;
}

/* --- Search Results & Pagination --- */
.search-results-container {
    padding: 80px 0;
    min-height: 600px;
}

.search-results-header {
    margin-bottom: 48px;
    padding-bottom: 24px;
    border-bottom: 1px solid #EAECF0;
}

.search-results-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.search-results-count {
    font-size: 16px;
    color: #64748B;
    font-weight: 500;
}
/* Empty Section States */
.empty-section-message {
    padding: 60px 40px;
    background: var(--bg-light);
    border: 1px dashed rgba(6, 78, 59, 0.2);
    border-radius: var(--radius-md);
    text-align: center;
    color: var(--text-muted);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.empty-section-message svg {
    margin-bottom: 20px;
    color: var(--primary-color);
    opacity: 0.3;
}

.empty-section-message p {
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 16px;
}

.empty-section-message .btn-primary {
    padding: 10px 24px;
    font-size: 14px;
}

.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 100px 0;
}

.no-results p {
    font-size: 18px;
    color: #64748B;
    margin-bottom: 24px;
}

/* Pagination Styling */
.pagination-wrapper {
    grid-column: 1 / -1;
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid #EAECF0;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 12px;
    border-radius: 12px;
    border: 1px solid #EAECF0;
    color: #64748B;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

.page-numbers:hover {
    border-color: #11d03b;
    color: #11d03b;
    background: #f0fdf4;
}

.page-numbers.current {
    background: #11d03b;
    border-color: #11d03b;
    color: var(--white);
}

.page-numbers.prev,
.page-numbers.next {
    padding: 0 20px;
}

/* Custom Scrollbar for Category Nav */
.category-list::-webkit-scrollbar {
    height: 4px;
}

.category-list::-webkit-scrollbar-thumb {
    background: var(--accent-color);
    border-radius: 10px;
}