/*
Theme Name: Crédito Empreendedor
Theme URI: https://creditoempreendedor.com.br
Description: Plataforma Crédito Empreendedor - Buscador de linhas de crédito para o seu negócio.
Author: Crédito Empreendedor
Author URI: https://creditoempreendedor.com.br
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: credito-empreendedor
*/

/* ==========================================================================
   CSS Custom Properties (Design Tokens)
   ========================================================================== */

:root {
    /* Primary Colors */
    --ce-primary: hsl(200, 25%, 14%);
    --ce-primary-fg: hsl(40, 15%, 96%);
    --ce-secondary: hsl(165, 55%, 38%);
    --ce-secondary-fg: hsl(0, 0%, 100%);

    /* Background & Surface */
    --ce-background: hsl(40, 15%, 96%);
    --ce-foreground: hsl(200, 25%, 14%);
    --ce-card: hsl(0, 0%, 100%);
    --ce-card-fg: hsl(200, 25%, 14%);

    /* Muted */
    --ce-muted: hsl(40, 10%, 91%);
    --ce-muted-fg: hsl(200, 10%, 46%);

    /* Borders & Inputs */
    --ce-border: hsl(40, 10%, 87%);
    --ce-input: hsl(40, 10%, 87%);

    /* Destructive */
    --ce-destructive: hsl(0, 84%, 60%);

    /* Radius */
    --ce-radius: 0.625rem;
    --ce-radius-lg: 0.75rem;
    --ce-radius-xl: 1rem;
    --ce-radius-2xl: 1.25rem;
    --ce-radius-full: 9999px;

    /* Font */
    --ce-font: 'Inter', system-ui, -apple-system, sans-serif;

    /* Shadows */
    --ce-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --ce-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --ce-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --ce-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);

    /* Transitions */
    --ce-transition: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --ce-transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   Reset & Base
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--ce-font);
    background-color: var(--ce-background);
    color: var(--ce-foreground);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    cursor: pointer;
    font-family: inherit;
}

/* ==========================================================================
   Layout Utilities
   ========================================================================== */

.ce-container {
    max-width: 80rem;
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}

.ce-container--narrow {
    max-width: 64rem;
}

.ce-flex-1 {
    flex: 1;
}

/* ==========================================================================
   Header
   ========================================================================== */

.ce-header {
    position: sticky;
    top: 0;
    z-index: 50;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--ce-border);
}

.ce-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    /* Ensures Logo Left, Actions Right */
    height: 4rem;
    max-width: 80rem;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Brand */
.ce-header__brand {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.ce-header__logo-link img {
    height: 2rem;
    width: auto;
    display: block;
}

.ce-header__logo-link .custom-logo-link {
    display: flex;
    align-items: center;
}

.ce-header__site-title {
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--ce-foreground);
    text-decoration: none;
}

/* Desktop Actions */
.ce-header__actions {
    display: none;
    /* Hidden on mobile */
    align-items: center;
    gap: 2rem;
}

.ce-header__nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.ce-header__nav a {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--ce-muted-fg);
    transition: color 0.15s;
    text-decoration: none;
}

.ce-header__nav a:hover {
    color: var(--ce-foreground);
}

/* Mobile Toggle */
.ce-header__mobile-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background: transparent;
    border: none;
    color: var(--ce-foreground);
    cursor: pointer;
}

.ce-header__mobile-toggle svg {
    width: 1.5rem;
    height: 1.5rem;
}

/* Mobile Menu */
.ce-mobile-menu {
    display: none;
    border-top: 1px solid var(--ce-border);
    background-color: var(--ce-card);
    padding: 1rem;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    box-shadow: var(--ce-shadow-lg);
}

.ce-mobile-menu.is-open {
    display: block;
}

.ce-mobile-menu__nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.ce-mobile-menu__nav a:not(.ce-btn) {
    display: block;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    font-weight: 500;
    color: var(--ce-foreground);
    border-radius: var(--ce-radius);
    text-decoration: none;
}

.ce-mobile-menu__nav a:not(.ce-btn):hover {
    background-color: var(--ce-muted);
}

.ce-mobile-menu__cta {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--ce-border);
}

/* Desktop Menu (wp_nav_menu) */
.ce-header__menu {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.ce-header__menu-item {
    position: relative;
}

.ce-header__link {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--ce-muted-fg);
    transition: color 0.15s;
    text-decoration: none;
    padding: 0.5rem 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    border-radius: var(--ce-radius);
}

.ce-header__link:hover {
    color: var(--ce-foreground);
}

.ce-header__menu-item--active>.ce-header__link {
    color: var(--ce-foreground);
    font-weight: 600;
}

/* Dropdown Arrow */
.ce-header__dropdown-arrow {
    transition: transform var(--ce-transition);
    flex-shrink: 0;
}

.ce-header__menu-item--has-children:hover>.ce-header__link .ce-header__dropdown-arrow {
    transform: rotate(180deg);
}

/* Desktop Submenu (Dropdown) */
.ce-header__submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    list-style: none;
    margin: 0;
    padding: 0.5rem;
    background-color: var(--ce-card);
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-lg);
    box-shadow: var(--ce-shadow-lg);
    z-index: 100;
    animation: ce-fade-in 0.15s ease;
}

@keyframes ce-fade-in {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ce-header__menu-item--has-children:hover>.ce-header__submenu {
    display: block;
}

.ce-header__submenu-item {
    list-style: none;
}

.ce-header__submenu-link {
    display: block;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--ce-muted-fg);
    text-decoration: none;
    border-radius: var(--ce-radius);
    transition: all var(--ce-transition);
}

.ce-header__submenu-link:hover {
    color: var(--ce-foreground);
    background-color: var(--ce-muted);
}

.ce-header__submenu-item.ce-header__menu-item--active>.ce-header__submenu-link {
    color: var(--ce-secondary);
    font-weight: 500;
}

/* Mobile Menu List (wp_nav_menu) */
.ce-mobile-menu__list {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.ce-mobile-menu__link {
    display: block;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    font-weight: 500;
    color: var(--ce-foreground);
    border-radius: var(--ce-radius);
    text-decoration: none;
    transition: background-color var(--ce-transition);
}

.ce-mobile-menu__link:hover {
    background-color: var(--ce-muted);
}

.ce-mobile-menu__item--active>.ce-mobile-menu__link,
.ce-mobile-menu__item--active>.ce-mobile-menu__link-wrap>.ce-mobile-menu__link {
    color: var(--ce-secondary);
    font-weight: 600;
}

/* Mobile Submenu Toggle */
.ce-mobile-menu__link-wrap {
    display: flex;
    align-items: center;
}

.ce-mobile-menu__link-wrap>.ce-mobile-menu__link {
    flex: 1;
}

.ce-mobile-menu__toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border: none;
    background: transparent;
    color: var(--ce-muted-fg);
    cursor: pointer;
    border-radius: var(--ce-radius);
    transition: all var(--ce-transition);
}

.ce-mobile-menu__toggle:hover {
    background-color: var(--ce-muted);
    color: var(--ce-foreground);
}

.ce-mobile-menu__toggle svg {
    transition: transform var(--ce-transition);
}

.ce-mobile-menu__item--has-children.is-open>.ce-mobile-menu__link-wrap .ce-mobile-menu__toggle svg {
    transform: rotate(180deg);
}

/* Mobile Submenu (Accordion) */
.ce-mobile-menu__submenu {
    display: none;
    list-style: none;
    margin: 0;
    padding: 0 0 0 1rem;
}

.ce-mobile-menu__item--has-children.is-open>.ce-mobile-menu__submenu {
    display: block;
}

.ce-mobile-menu__submenu .ce-mobile-menu__link {
    font-size: 0.9375rem;
    font-weight: 400;
    padding: 0.5rem 1rem;
    color: var(--ce-muted-fg);
}

.ce-mobile-menu__submenu .ce-mobile-menu__link:hover {
    color: var(--ce-foreground);
}

/* Responsive */
@media (min-width: 1024px) {
    .ce-header__actions {
        display: flex;
    }

    .ce-header__mobile-toggle {
        display: none;
    }

    .ce-mobile-menu {
        display: none !important;
    }
}

.ce-mobile-menu__cta {
    margin-top: 0.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--ce-border);
}

@media (min-width: 768px) {
    .ce-header__inner {
        height: 4rem;
        flex-direction: row;
        /* Reset to normal row on desktop */
    }

    .ce-header__logo {
        margin-right: auto;
        /* Push logo to the left on desktop */
    }

    .ce-header__logo img {
        height: 1.75rem;
    }

    .ce-header__nav {
        display: flex;
    }

    .ce-header__cta {
        display: flex;
    }

    .ce-header__mobile-toggle {
        display: none;
    }

    .ce-mobile-menu {
        display: none !important;
    }
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.ce-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    padding: 0.5rem 1.25rem;
    border-radius: var(--ce-radius-full);
    border: none;
    cursor: pointer;
    transition: all var(--ce-transition);
    text-decoration: none;
    line-height: 1.4;
    white-space: nowrap;
}

.ce-btn--primary {
    background-color: var(--ce-primary);
    color: var(--ce-primary-fg);
}

.ce-btn--primary:hover {
    opacity: 0.9;
}

.ce-btn--secondary {
    background-color: var(--ce-secondary);
    color: var(--ce-secondary-fg);
}

.ce-btn--secondary:hover {
    opacity: 0.9;
}

.ce-btn--outline {
    background-color: transparent;
    border: 1px solid var(--ce-border);
    color: var(--ce-foreground);
}

.ce-btn--outline:hover {
    background-color: var(--ce-muted);
}

.ce-btn--ghost {
    background-color: transparent;
    border: none;
    color: var(--ce-muted-fg);
}

.ce-btn--ghost:hover {
    background-color: var(--ce-muted);
    color: var(--ce-foreground);
}

.ce-btn--sm {
    font-size: 0.75rem;
    padding: 0.375rem 1rem;
}

.ce-btn--text-lg {
    font-size: 1rem;
    padding: 0.875rem 1.5rem;
}

.ce-btn--lg {
    font-size: 0.9375rem;
    padding: 0.75rem 2rem;
}

.ce-btn--full {
    width: 100%;
}

.ce-btn svg {
    width: 1rem;
    height: 1rem;
    flex-shrink: 0;
}

.ce-btn--sm svg {
    width: 0.875rem;
    height: 0.875rem;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.ce-hero {
    position: relative;
    overflow: hidden;
    background-color: var(--ce-primary);
    padding: 3rem 1rem 4rem;
}

.ce-hero__bg {
    position: absolute;
    inset: 0;
    opacity: 0.2;
}

.ce-hero__bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ce-hero__content {
    position: relative;
    max-width: 80rem;
    margin: 0 auto;
    text-align: center;
}

.ce-hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 1rem;
    border-radius: var(--ce-radius-full);
    border: 1px solid rgba(246, 244, 241, 0.15);
    background-color: rgba(246, 244, 241, 0.1);
    margin-bottom: 1.5rem;
}

.ce-hero__badge-dot {
    width: 0.375rem;
    height: 0.375rem;
    border-radius: 50%;
    background-color: var(--ce-secondary);
}

.ce-hero__badge-text {
    font-size: 0.75rem;
    font-weight: 500;
    color: rgba(246, 244, 241, 0.8);
}

.ce-hero__title {
    font-size: 1.875rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    color: var(--ce-primary-fg);
    text-wrap: balance;
    line-height: 1.2;
    margin: 0;
}

.ce-hero__subtitle {
    max-width: 36rem;
    margin: 1.25rem auto 1.25rem;
    /* Balanced top/bottom margin */
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(246, 244, 241, 0.7);
}

.ce-hero__search {
    margin-top: 2.5rem;
}

@media (min-width: 640px) {
    .ce-hero {
        padding: 5rem 1rem 6rem;
    }

    .ce-hero__title {
        font-size: 2.25rem;
    }

    .ce-hero__subtitle {
        font-size: 1.125rem;
    }
}

@media (min-width: 1024px) {
    .ce-hero__title {
        font-size: 3rem;
    }
}

@media (min-width: 1280px) {
    .ce-hero__title {
        font-size: 3.5rem;
    }
}

/* ==========================================================================
   Search Form (Hero)
   ========================================================================== */

.ce-search {
    max-width: 42rem;
    margin: 0 auto;
}

/* Desktop search bar */
.ce-search__bar {
    display: none;
    align-items: center;
    border-radius: var(--ce-radius-full);
    border: 1px solid var(--ce-border);
    background-color: var(--ce-card);
    box-shadow: var(--ce-shadow-lg);
    overflow: hidden;
}

.ce-search__bar-icon {
    margin-left: 1.25rem;
    color: var(--ce-muted-fg);
    flex-shrink: 0;
}

.ce-search__bar-icon svg {
    width: 1.25rem;
    height: 1.25rem;
}

.ce-search__bar-input {
    flex: 1;
    min-width: 0;
    background: transparent;
    border: none;
    padding: 1rem;
    font-size: 1rem;
    color: var(--ce-foreground);
    outline: none;
}

.ce-search__bar-input::placeholder {
    color: var(--ce-muted-fg);
}

.ce-search__bar-btn {
    margin-right: 0.5rem;
    flex-shrink: 0;
}

/* Mobile search */
.ce-search__mobile {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.ce-search__mobile .ce-btn {
    height: 3rem;
    font-size: 1rem;
    box-shadow: var(--ce-shadow-md);
}

.ce-search__mobile-bar {
    display: flex;
    align-items: center;
    border-radius: var(--ce-radius-xl);
    border: 1px solid var(--ce-border);
    background-color: var(--ce-card);
    box-shadow: var(--ce-shadow-lg);
}

.ce-search__mobile-bar svg {
    margin-left: 1rem;
    width: 1.25rem;
    height: 1.25rem;
    color: var(--ce-muted-fg);
    flex-shrink: 0;
}

.ce-search__mobile-bar input {
    flex: 1;
    min-width: 0;
    background: transparent;
    border: none;
    padding: 0.875rem 0.75rem;
    font-size: 0.875rem;
    color: var(--ce-foreground);
    outline: none;
}

.ce-search__mobile-bar input::placeholder {
    color: var(--ce-muted-fg);
}

@media (min-width: 640px) {
    .ce-search__bar {
        display: flex;
    }

    .ce-search__mobile {
        display: none;
    }
}

/* Tags populares */
.ce-search__tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.ce-search__tags-label {
    font-size: 0.75rem;
    color: rgba(246, 244, 241, 0.6);
}

.ce-search__tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: var(--ce-radius-full);
    border: 1px solid rgba(246, 244, 241, 0.2);
    background-color: rgba(246, 244, 241, 0.1);
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--ce-primary-fg);
    cursor: pointer;
    transition: background-color var(--ce-transition);
}

.ce-search__tag:hover {
    background-color: rgba(246, 244, 241, 0.2);
}

/* Filtros estruturados */
.ce-search__filters {
    margin-bottom: 1.5rem;
    padding: 1rem;
    border-radius: var(--ce-radius-xl);
    border: 1px solid rgba(246, 244, 241, 0.1);
    background-color: rgba(246, 244, 241, 0.05);
}

.ce-search__filters-label {
    text-align: center;
    font-size: 0.75rem;
    font-weight: 500;
    color: rgba(246, 244, 241, 0.7);
    margin-bottom: 0.75rem;
}

.ce-search__filters-grid {
    display: grid;
    gap: 0.75rem;
}

@media (min-width: 640px) {
    .ce-search__filters-grid {
        grid-template-columns: 1fr 1fr auto;
    }
}

/* ==========================================================================
   Form Elements
   ========================================================================== */

.ce-select,
.ce-input {
    width: 100%;
    padding: 0.625rem 0.75rem;
    font-size: 0.875rem;
    font-family: var(--ce-font);
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius);
    background-color: var(--ce-card);
    color: var(--ce-foreground);
    outline: none;
    transition: border-color var(--ce-transition);
    appearance: none;
}

.ce-select:focus,
.ce-input:focus {
    border-color: var(--ce-secondary);
    box-shadow: 0 0 0 2px rgba(44, 150, 121, 0.15);
}

.ce-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236a7b80' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    padding-right: 2.25rem;
}

.ce-select--hero,
.ce-input--hero {
    border-color: rgba(246, 244, 241, 0.2);
    background-color: rgba(246, 244, 241, 0.1);
    color: var(--ce-primary-fg);
}

.ce-select--hero {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23f6f4f1' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}

.ce-select--hero option {
    background-color: var(--ce-card);
    color: var(--ce-foreground);
}

.ce-form-group {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.ce-form-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--ce-foreground);
}

/* ==========================================================================
   Trust Banner
   ========================================================================== */

.ce-trust {
    border-bottom: 1px solid var(--ce-border);
    background-color: var(--ce-card);
    padding: 1rem;
}

.ce-trust__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    max-width: 80rem;
    margin: 0 auto;
}

.ce-trust__item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ce-trust__item svg {
    width: 1rem;
    height: 1rem;
    color: var(--ce-secondary);
}

.ce-trust__item span {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--ce-muted-fg);
}

@media (min-width: 640px) {
    .ce-trust__inner {
        gap: 2.5rem;
    }
}

/* ==========================================================================
   Stats Section
   ========================================================================== */

.ce-stats {
    padding: 3.5rem 1rem;
}

.ce-stats__header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.ce-stats__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ce-foreground);
    text-wrap: balance;
}

.ce-stats__subtitle {
    max-width: 32rem;
    margin: 0.5rem auto 0;
    font-size: 0.875rem;
    color: var(--ce-muted-fg);
}

.ce-stats__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    max-width: 56rem;
    margin: 0 auto;
}

.ce-stats__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1.25rem;
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-2xl);
    background-color: var(--ce-card);
}

.ce-stats__card-icon {
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--ce-radius-xl);
    background-color: rgba(44, 150, 121, 0.1);
    margin-bottom: 0.75rem;
}

.ce-stats__card-icon svg {
    width: 1.5rem;
    height: 1.5rem;
    color: var(--ce-secondary);
}

.ce-stats__card-value {
    font-size: 1.875rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    color: var(--ce-foreground);
}

.ce-stats__card-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--ce-foreground);
    margin-top: 0.25rem;
}

.ce-stats__card-desc {
    font-size: 0.75rem;
    color: var(--ce-muted-fg);
    margin-top: 0.125rem;
}

@media (min-width: 640px) {
    .ce-stats {
        padding: 5rem 1rem;
    }

    .ce-stats__title {
        font-size: 1.875rem;
    }

    .ce-stats__subtitle {
        font-size: 1rem;
    }

    .ce-stats__grid {
        gap: 1.5rem;
    }

    .ce-stats__card {
        padding: 1.5rem;
    }

    .ce-stats__card-value {
        font-size: 2.25rem;
    }
}

@media (min-width: 1024px) {
    .ce-stats__grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ==========================================================================
   Category Cards
   ========================================================================== */

.ce-categories {
    border-top: 1px solid var(--ce-border);
    background-color: var(--ce-card);
    padding: 4rem 1rem;
}

.ce-categories__header {
    margin-bottom: 2.5rem;
}

.ce-categories__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ce-foreground);
    text-wrap: balance;
}

.ce-categories__subtitle {
    margin-top: 0.5rem;
    color: var(--ce-muted-fg);
}

.ce-categories__grid {
    display: grid;
    gap: 0.75rem;
}

.ce-category-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem;
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-xl);
    background-color: var(--ce-background);
    transition: all var(--ce-transition);
}

.ce-category-card:hover {
    border-color: rgba(27, 42, 49, 0.2);
    box-shadow: var(--ce-shadow-sm);
}

.ce-category-card__body {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.ce-category-card__icon {
    width: 2.75rem;
    height: 2.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--ce-radius);
    background-color: rgba(44, 150, 121, 0.1);
    flex-shrink: 0;
}

.ce-category-card__icon svg {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--ce-secondary);
}

.ce-category-card__label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-category-card__desc {
    font-size: 0.75rem;
    color: var(--ce-muted-fg);
    margin-top: 0.125rem;
}

.ce-category-card__arrow {
    flex-shrink: 0;
    color: var(--ce-muted-fg);
    transition: all var(--ce-transition);
}

.ce-category-card__arrow svg {
    width: 1rem;
    height: 1rem;
}

.ce-category-card:hover .ce-category-card__arrow {
    color: var(--ce-foreground);
    transform: translateX(2px);
}

@media (min-width: 640px) {
    .ce-categories__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .ce-categories__title {
        font-size: 1.875rem;
    }
}

@media (min-width: 1024px) {
    .ce-categories__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ==========================================================================
   Credit Line Card
   ========================================================================== */

.ce-credit-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 1.25rem;
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-xl);
    background-color: var(--ce-card);
    transition: all var(--ce-transition);
}

.ce-credit-card:hover {
    border-color: rgba(27, 42, 49, 0.3);
    box-shadow: var(--ce-shadow-md);
}

.ce-credit-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.ce-credit-card__institution {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--ce-muted-fg);
}

.ce-credit-card__badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
}

.ce-credit-card__name {
    margin-top: 0.75rem;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.4;
    color: var(--ce-foreground);
}

.ce-credit-card__desc {
    margin-top: 0.5rem;
    flex: 1;
    font-size: 0.75rem;
    line-height: 1.6;
    color: var(--ce-muted-fg);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ce-credit-card__details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--ce-border);
}

.ce-credit-card__detail {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.ce-credit-card__detail-icon {
    flex-shrink: 0;
    color: var(--ce-secondary);
}

.ce-credit-card__detail-icon svg {
    width: 0.875rem;
    height: 0.875rem;
}

.ce-credit-card__detail-label {
    font-size: 0.625rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--ce-muted-fg);
}

.ce-credit-card__detail-value {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-credit-card__action {
    margin-top: 1.25rem;
}

@media (min-width: 640px) {
    .ce-credit-card {
        padding: 1.5rem;
    }

    .ce-credit-card__name {
        font-size: 1rem;
    }

    .ce-credit-card__desc {
        font-size: 0.875rem;
    }
}

/* ==========================================================================
   Badges
   ========================================================================== */

.ce-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.125rem 0.5rem;
    font-size: 0.625rem;
    font-weight: 500;
    border-radius: var(--ce-radius-full);
    white-space: nowrap;
}

.ce-badge--secondary {
    background-color: rgba(44, 150, 121, 0.1);
    color: var(--ce-secondary);
}

.ce-badge--primary {
    background-color: rgba(27, 42, 49, 0.1);
    color: var(--ce-primary);
}

.ce-badge--outline {
    border: 1px solid var(--ce-border);
    color: var(--ce-foreground);
    background-color: transparent;
    font-size: 0.75rem;
}

.ce-badge--active {
    border-color: rgba(44, 150, 121, 0.5);
    color: var(--ce-secondary);
}

/* ==========================================================================
   Featured Section
   ========================================================================== */

.ce-featured {
    padding: 4rem 1rem;
}

.ce-featured__header {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.ce-featured__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ce-foreground);
    text-wrap: balance;
}

.ce-featured__subtitle {
    margin-top: 0.5rem;
    color: var(--ce-muted-fg);
}

.ce-featured__link {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ce-secondary);
    transition: color var(--ce-transition);
}

.ce-featured__link:hover {
    opacity: 0.8;
}

.ce-featured__link svg {
    width: 1rem;
    height: 1rem;
    transition: transform var(--ce-transition);
}

.ce-featured__link:hover svg {
    transform: translateX(2px);
}

.ce-featured__grid {
    display: grid;
    gap: 1.25rem;
}

@media (min-width: 640px) {
    .ce-featured__header {
        flex-direction: row;
        align-items: flex-end;
        justify-content: space-between;
    }

    .ce-featured__title {
        font-size: 1.875rem;
    }

    .ce-featured__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .ce-featured__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ==========================================================================
   CTA Section
   ========================================================================== */

.ce-cta {
    border-top: 1px solid var(--ce-border);
    background-color: var(--ce-card);
    padding: 4rem 1rem;
}

.ce-cta__inner {
    max-width: 42rem;
    margin: 0 auto;
    text-align: center;
}

.ce-cta__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ce-foreground);
    text-wrap: balance;
}

.ce-cta__text {
    margin-top: 0.75rem;
    color: var(--ce-muted-fg);
}

.ce-cta__action {
    margin-top: 2rem;
}

@media (min-width: 640px) {
    .ce-cta__title {
        font-size: 1.875rem;
    }
}

/* ==========================================================================
   Results Page
   ========================================================================== */

.ce-results-header {
    background-color: var(--ce-primary);
    padding: 2.5rem 1rem;
}

.ce-results-header__title {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    color: var(--ce-primary-fg);
}

.ce-results-header__subtitle {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: rgba(246, 244, 241, 0.6);
}

.ce-results {
    padding: 2rem 1rem;
}

.ce-results__layout {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 80rem;
    margin: 0 auto;
}

.ce-results__sidebar {
    width: 100%;
    flex-shrink: 0;
}

.ce-results__content {
    flex: 1;
}

.ce-results__count {
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: var(--ce-muted-fg);
}

.ce-results__count strong {
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-results__grid {
    display: grid;
    gap: 1.5rem;
}

.ce-results__empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 1.5rem;
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-xl);
    background-color: var(--ce-card);
}

.ce-results__empty-icon {
    width: 4rem;
    height: 4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--ce-radius-full);
    background-color: var(--ce-muted);
    margin-bottom: 1rem;
}

.ce-results__empty-icon svg {
    width: 2rem;
    height: 2rem;
    color: var(--ce-muted-fg);
}

.ce-results__empty h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-results__empty p {
    margin-top: 0.5rem;
    max-width: 28rem;
    font-size: 0.875rem;
    color: var(--ce-muted-fg);
}

.ce-results__loading {
    display: none;
    justify-content: center;
    padding: 3rem;
}

.ce-results__loading.is-loading {
    display: flex;
}

.ce-spinner {
    width: 2.5rem;
    height: 2.5rem;
    border: 3px solid var(--ce-border);
    border-top-color: var(--ce-secondary);
    border-radius: 50%;
    animation: ce-spin 0.6s linear infinite;
}

@keyframes ce-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (min-width: 640px) {
    .ce-results-header {
        padding: 3.5rem 1rem;
    }

    .ce-results-header__title {
        font-size: 1.875rem;
    }

    .ce-results-header__subtitle {
        font-size: 1rem;
    }

    .ce-results__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .ce-results__layout {
        flex-direction: row;
    }

    .ce-results__sidebar {
        width: 18rem;
    }
}

/* ==========================================================================
   Pagination
   ========================================================================== */

.ce-pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 3rem;
    flex-wrap: wrap;
}

.ce-pagination .page-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.5rem;
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius);
    background-color: var(--ce-card);
    color: var(--ce-muted-fg);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all var(--ce-transition);
}

.ce-pagination .page-numbers:hover,
.ce-pagination .page-numbers.current {
    border-color: var(--ce-secondary);
    background-color: var(--ce-secondary);
    color: #fff;
}

.ce-pagination .page-numbers.dots {
    border: none;
    background-color: transparent;
    cursor: default;
}

.ce-pagination .page-numbers.dots:hover {
    color: var(--ce-muted-fg);
}

/* ==========================================================================
   Load More
   ========================================================================== */
.ce-load-more {
    margin-top: 30px;
    text-align: center;
}

/* ==========================================================================
   Filters Sidebar
   ========================================================================== */

.ce-filters {
    padding: 1.25rem;
    border-radius: var(--ce-radius-xl);
    border: 1px solid var(--ce-border);
    background-color: var(--ce-card);
}

.ce-filters__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.ce-filters__header-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ce-filters__header-title svg {
    width: 1rem;
    height: 1rem;
    color: var(--ce-foreground);
}

.ce-filters__header-title h2 {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-filters__toggle-icon {
    display: none;
    width: 1.25rem;
    height: 1.25rem;
    color: var(--ce-muted-fg);
    transition: transform var(--ce-transition);
}

.ce-filters__body {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.ce-filters__value-range {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

@media (max-width: 1023px) {
    .ce-filters__header {
        margin-bottom: 0;
        cursor: pointer;
    }

    .ce-filters__toggle-icon {
        display: block;
    }

    /* Rotate icon when open */
    .ce-filters__header.is-open .ce-filters__toggle-icon {
        transform: rotate(180deg);
    }

    .ce-filters__body {
        display: none;
        margin-top: 1.25rem;
        padding-top: 1.25rem;
        border-top: 1px solid var(--ce-border);
    }

    .ce-filters__body.is-open {
        display: flex;
    }
}

/* ==========================================================================
   Single Credit Line Detail
   ========================================================================== */

.ce-single-header {
    background-color: var(--ce-primary);
    padding: 2.5rem 1rem;
}

.ce-single-header__back {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.875rem;
    color: rgba(246, 244, 241, 0.5);
    margin-bottom: 1.5rem;
    transition: color var(--ce-transition);
}

.ce-single-header__back:hover {
    color: var(--ce-primary-fg);
}

.ce-single-header__back svg {
    width: 1rem;
    height: 1rem;
}

.ce-single-header__institution {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(246, 244, 241, 0.5);
    margin-bottom: 0.5rem;
}

.ce-single-header__title {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    color: var(--ce-primary-fg);
    text-wrap: balance;
}

@media (min-width: 640px) {
    .ce-single-header {
        padding: 3.5rem 1rem;
    }

    .ce-single-header__title {
        font-size: 1.5rem;
    }
}

@media (min-width: 1024px) {
    .ce-single-header__title {
        font-size: 1.875rem;
    }
}

.ce-single {
    padding: 2rem 1rem;
}

.ce-single__layout {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 64rem;
    margin: 0 auto;
}

.ce-single__main {
    flex: 1;
}

.ce-single__sidebar {
    width: 100%;
    flex-shrink: 0;
}

@media (min-width: 1024px) {
    .ce-single__layout {
        flex-direction: row;
    }

    .ce-single__sidebar {
        width: 20rem;
    }
}

/* Cards for single page */
.ce-card {
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-xl);
    background-color: var(--ce-card);
    overflow: hidden;
}

.ce-card__header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--ce-border);
}

.ce-card__header svg {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--ce-secondary);
}

.ce-card__header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-card__body {
    padding: 1.25rem 1.5rem;
}

.ce-card__body p {
    line-height: 1.7;
    color: var(--ce-muted-fg);
}

/* Metrics grid */
.ce-metrics {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
}

.ce-metric {
    padding: 1rem;
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-xl);
    background-color: var(--ce-card);
}

.ce-metric__icon {
    width: 2.25rem;
    height: 2.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--ce-radius);
    background-color: rgba(44, 150, 121, 0.1);
    margin-bottom: 0.5rem;
}

.ce-metric__icon svg {
    width: 1.125rem;
    height: 1.125rem;
    color: var(--ce-secondary);
}

.ce-metric__label {
    font-size: 0.6875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--ce-muted-fg);
}

.ce-metric__value {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ce-foreground);
    margin-top: 0.25rem;
}

.ce-metric__sub {
    font-size: 0.75rem;
    color: var(--ce-muted-fg);
}

@media (min-width: 640px) {
    .ce-metrics {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Requirements list */
.ce-requirements {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.ce-requirements li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--ce-muted-fg);
}

.ce-requirements li::before {
    content: '';
    display: inline-block;
    width: 0.375rem;
    height: 0.375rem;
    border-radius: 50%;
    background-color: var(--ce-primary);
    flex-shrink: 0;
    margin-top: 0.5rem;
}

/* Sidebar CTA card */
.ce-sidebar-cta {
    position: sticky;
    top: 6rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.ce-sidebar-card {
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-xl);
    background-color: var(--ce-card);
    padding: 1.25rem;
}

.ce-sidebar-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-sidebar-card p {
    font-size: 0.875rem;
    color: var(--ce-muted-fg);
    margin-top: 0.5rem;
}

.ce-sidebar-card__info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ce-sidebar-card__info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.ce-sidebar-card__info-item svg {
    width: 1rem;
    height: 1rem;
    color: var(--ce-muted-fg);
    flex-shrink: 0;
}

.ce-sidebar-card__info-item .label {
    color: var(--ce-muted-fg);
}

.ce-sidebar-card__info-item .value {
    font-weight: 500;
    color: var(--ce-foreground);
}

/* Related credit lines */
.ce-related {
    margin-top: 3rem;
}

.ce-related__title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ce-foreground);
    margin-bottom: 1.5rem;
}

.ce-related__grid {
    display: grid;
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .ce-related__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .ce-related__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ==========================================================================
   Footer
   ========================================================================== */

.ce-footer {
    border-top: 1px solid var(--ce-border);
    background-color: var(--ce-primary);
    color: var(--ce-primary-fg);
}

.ce-footer__inner {
    max-width: 80rem;
    margin: 0 auto;
    padding: 3rem 1rem;
}

.ce-footer__grid {
    display: grid;
    gap: 2.5rem;
}

.ce-footer__brand,
.ce-footer__col {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.ce-footer__col nav {
    align-items: center;
}

.ce-footer__brand p {
    margin-top: 0.75rem;
    max-width: 20rem;
    font-size: 0.875rem;
    line-height: 1.6;
    color: rgba(246, 244, 241, 0.6);
}

.ce-footer__brand img {
    height: 1.5rem;
    width: auto;
}

.ce-footer__col h3 {
    margin-bottom: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(246, 244, 241, 0.5);
}

.ce-footer__col nav {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.ce-footer__col a {
    font-size: 0.875rem;
    color: rgba(246, 244, 241, 0.7);
    transition: color var(--ce-transition);
}

.ce-footer__col a:hover {
    color: var(--ce-primary-fg);
}

.ce-footer__col p {
    font-size: 0.75rem;
    line-height: 1.6;
    color: rgba(246, 244, 241, 0.5);
}

.ce-footer__bottom {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(246, 244, 241, 0.1);
    text-align: center;
    font-size: 0.75rem;
    color: rgba(246, 244, 241, 0.4);
}

@media (min-width: 640px) {
    .ce-footer__inner {
        padding: 4rem 1rem;
    }

    .ce-footer__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .ce-footer__brand,
    .ce-footer__col {
        align-items: flex-start;
        text-align: left;
    }

    .ce-footer__col nav {
        align-items: flex-start;
    }
}

@media (min-width: 1024px) {
    .ce-footer__grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
}

/* Footer — Contact List */
.ce-footer__contact-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.ce-footer__contact-list li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: rgba(246, 244, 241, 0.7);
}

.ce-footer__contact-list li svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    opacity: 0.6;
}

.ce-footer__contact-list li a {
    color: rgba(246, 244, 241, 0.7);
    transition: color var(--ce-transition);
}

.ce-footer__contact-list li a:hover {
    color: var(--ce-primary-fg);
}

.ce-footer__contact-list li span {
    color: rgba(246, 244, 241, 0.7);
}

/* Footer — Social Icons */
.ce-footer__social {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

.ce-footer__social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(246, 244, 241, 0.1);
    color: rgba(246, 244, 241, 0.7);
    transition: all var(--ce-transition);
}

.ce-footer__social a:hover {
    background: rgba(246, 244, 241, 0.2);
    color: var(--ce-primary-fg);
}

.ce-footer__social svg {
    width: 18px;
    height: 18px;
}



/* ==========================================================================
   Utility: Text classes
   ========================================================================== */

.text-balance {
    text-wrap: balance;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Separator */
.ce-separator {
    border: none;
    border-top: 1px solid var(--ce-border);
    margin: 1rem 0;
}

.ce-text-break {
    flex: 1;
    min-width: 0;
    word-break: break-word;
    /* Prevents overflow */
    display: block;
    /* Ensure block behavior */
    line-height: 1.6;
    /* Readability */
    color: var(--ce-muted-fg);
}

/* ==========================================================================
   Blog Section
   ========================================================================== */

.ce-latest-news {
    padding: 5rem 0;
    background-color: var(--ce-background);
}

/* --- Breadcrumb --- */
.ce-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    color: var(--ce-muted-fg);
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.ce-breadcrumb a {
    color: var(--ce-muted-fg);
    text-decoration: none;
    transition: color var(--ce-transition);
}

.ce-breadcrumb a:hover {
    color: var(--ce-secondary);
}

.ce-breadcrumb__sep {
    display: flex;
    align-items: center;
}

.ce-breadcrumb__sep svg {
    width: 0.75rem;
    height: 0.75rem;
    opacity: 0.5;
}

.ce-breadcrumb__current {
    color: var(--ce-foreground);
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 20rem;
}

/* --- Post Card --- */
.ce-post-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background-color: var(--ce-card);
    border: 1px solid var(--ce-border);
    border-radius: var(--ce-radius-xl);
    overflow: hidden;
    transition: transform var(--ce-transition-slow), box-shadow var(--ce-transition-slow), border-color var(--ce-transition);
    position: relative;
}

.ce-post-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.1);
    border-color: transparent;
}

.ce-post-card__link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
}

.ce-post-card__image {
    position: relative;
    padding-top: 56.25%;
    background-color: var(--ce-surface);
    overflow: hidden;
}

.ce-post-card__img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--ce-transition-slow);
}

.ce-post-card:hover .ce-post-card__img {
    transform: scale(1.06);
}

.ce-post-card__img-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--ce-surface) 0%, var(--ce-muted) 100%);
    color: var(--ce-muted-fg);
}

.ce-post-card__img-placeholder svg {
    width: 3rem;
    height: 3rem;
    opacity: 0.4;
}

.ce-post-card__meta-badges {
    position: absolute;
    top: 0.875rem;
    left: 0.875rem;
    z-index: 2;
    display: flex;
    gap: 0.5rem;
}

.ce-badge--light {
    background-color: rgba(255, 255, 255, 0.92);
    color: var(--ce-foreground);
    font-weight: 600;
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 0.3rem 0.75rem;
    border-radius: var(--ce-radius-full);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.ce-post-card__content {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 1.25rem 1.5rem 1.5rem;
}

.ce-post-card__meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
    font-size: 0.8125rem;
    color: var(--ce-muted-fg);
}

.ce-post-card__date,
.ce-post-card__reading-time {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.ce-post-card__date svg,
.ce-post-card__reading-time svg {
    width: 0.875rem;
    height: 0.875rem;
    opacity: 0.7;
}

.ce-post-card__title {
    font-size: 1.125rem;
    font-weight: 700;
    line-height: 1.35;
    margin-bottom: 0.625rem;
    color: var(--ce-foreground);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    letter-spacing: -0.01em;
}

.ce-post-card__title a {
    color: inherit;
    text-decoration: none;
    transition: color var(--ce-transition);
}

.ce-post-card:hover .ce-post-card__title a {
    color: var(--ce-secondary);
}

.ce-post-card__excerpt {
    font-size: 0.875rem;
    color: var(--ce-muted-fg);
    line-height: 1.65;
    margin-bottom: 1.25rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1;
}

.ce-post-card__excerpt p {
    margin: 0;
}

.ce-post-card__footer {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding-top: 1rem;
    border-top: 1px solid var(--ce-border);
    margin-top: auto;
}

.ce-post-card__author {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ce-post-card__avatar {
    width: 1.75rem;
    height: 1.75rem;
    border-radius: var(--ce-radius-full);
    object-fit: cover;
}

.ce-post-card__author-name {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-post-card__read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--ce-secondary);
    transition: gap var(--ce-transition);
}

.ce-post-card__read-more svg {
    width: 0.875rem;
    height: 0.875rem;
    transition: transform var(--ce-transition);
}

.ce-post-card:hover .ce-post-card__read-more {
    gap: 0.625rem;
}

.ce-post-card:hover .ce-post-card__read-more svg {
    transform: translateX(2px);
}

/* --- Blog Hero --- */
.ce-blog-hero {
    padding: 3.5rem 0;
    background: linear-gradient(135deg, var(--ce-primary) 0%, hsl(200, 30%, 22%) 100%);
    text-align: center;
    border-bottom: none;
}

.ce-blog-hero .ce-breadcrumb {
    justify-content: center;
    margin-bottom: 1.25rem;
}

.ce-blog-hero .ce-breadcrumb,
.ce-blog-hero .ce-breadcrumb a {
    color: rgba(246, 244, 241, 0.5);
}

.ce-blog-hero .ce-breadcrumb a:hover {
    color: rgba(246, 244, 241, 0.8);
}

.ce-blog-hero .ce-breadcrumb__current {
    color: rgba(246, 244, 241, 0.9);
}

.ce-blog-hero__title {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--ce-primary-fg);
    margin-bottom: 0.75rem;
    letter-spacing: -0.025em;
}

.ce-blog-hero__subtitle {
    font-size: 1.0625rem;
    color: rgba(246, 244, 241, 0.65);
    max-width: 36rem;
    margin: 0 auto;
    line-height: 1.6;
}

@media (min-width: 768px) {
    .ce-blog-hero {
        padding: 4.5rem 0;
    }

    .ce-blog-hero__title {
        font-size: 2.75rem;
    }

    .ce-blog-hero__subtitle {
        font-size: 1.125rem;
    }
}

/* --- Blog Index --- */
.ce-blog-index {
    padding: 3rem 0 5rem;
}

.ce-blog-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 640px) {
    .ce-blog-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

@media (min-width: 1024px) {
    .ce-blog-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
}

/* --- Pagination --- */
.ce-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    margin-top: 3.5rem;
    padding-top: 2rem;
    border-top: 1px solid var(--ce-border);
}

.ce-pagination a,
.ce-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--ce-radius);
    text-decoration: none;
    transition: all var(--ce-transition);
}

.ce-pagination a {
    color: var(--ce-muted-fg);
    border: 1px solid var(--ce-border);
    background-color: var(--ce-card);
}

.ce-pagination a:hover {
    color: var(--ce-foreground);
    border-color: var(--ce-foreground);
    background-color: var(--ce-surface);
}

.ce-pagination span.current {
    background-color: var(--ce-primary);
    color: var(--ce-primary-fg);
    border: 1px solid var(--ce-primary);
    font-weight: 600;
}

.ce-pagination .prev,
.ce-pagination .next {
    gap: 0.375rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-pagination .prev svg,
.ce-pagination .next svg {
    width: 1rem;
    height: 1rem;
}

.ce-pagination .dots {
    border: none;
    color: var(--ce-muted-fg);
    min-width: auto;
    padding: 0 0.25rem;
}

/* --- Empty State --- */
.ce-empty-state {
    text-align: center;
    padding: 5rem 1rem;
}

.ce-empty-state__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 4rem;
    height: 4rem;
    margin: 0 auto 1.5rem;
    border-radius: var(--ce-radius-full);
    background-color: var(--ce-surface);
    color: var(--ce-muted-fg);
}

.ce-empty-state__icon svg {
    width: 1.5rem;
    height: 1.5rem;
}

.ce-empty-state h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ce-foreground);
    margin-bottom: 0.5rem;
}

.ce-empty-state p {
    font-size: 1rem;
    color: var(--ce-muted-fg);
    max-width: 24rem;
    margin: 0 auto;
}

/* ==========================================================================
   Single Post
   ========================================================================== */

.ce-single-post {
    max-width: 100%;
    margin: 0 auto;
    padding-top: 0;
}

.ce-post-header {
    margin-bottom: 2.5rem;
    text-align: center;
    padding: 2.5rem 0 0;
}

.ce-post-header__meta {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.25rem;
    color: var(--ce-muted-fg);
    font-size: 0.8125rem;
    font-weight: 500;
}

.ce-post-header__meta svg {
    width: 0.875rem;
    height: 0.875rem;
    opacity: 0.7;
}

.ce-post-category-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.875rem;
    border-radius: var(--ce-radius-full);
    background-color: rgba(44, 150, 121, 0.1);
    color: var(--ce-secondary);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    text-decoration: none;
    transition: background-color var(--ce-transition);
    position: relative;
    z-index: 1;
}

.ce-post-category-badge:hover {
    background-color: rgba(44, 150, 121, 0.18);
}

.ce-post-date,
.ce-post-reading-time {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.ce-post-title {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1.2;
    color: var(--ce-foreground);
    letter-spacing: -0.025em;
    margin-bottom: 1.75rem;
    text-wrap: balance;
}

@media (min-width: 768px) {
    .ce-post-title {
        font-size: 2.5rem;
    }
}

@media (min-width: 1024px) {
    .ce-post-title {
        font-size: 2.75rem;
    }
}

/* Author Box */
.ce-post-author {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.ce-post-author__avatar img {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: var(--ce-radius-full);
    object-fit: cover;
    border: 2px solid var(--ce-border);
}

.ce-post-author__info {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.ce-post-author__name {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-post-author__date {
    font-size: 0.8125rem;
    color: var(--ce-muted-fg);
}

/* Thumbnail */
.ce-post-thumbnail {
    margin-bottom: 3rem;
    border-radius: var(--ce-radius-xl);
    overflow: hidden;
    box-shadow: 0 8px 30px -8px rgba(0, 0, 0, 0.12);
}

.ce-post-thumbnail img {
    display: block;
    width: 100%;
    height: auto;
}

/* Content */
.ce-post-content {
    font-size: 1.0625rem;
    line-height: 1.8;
    color: var(--ce-foreground);
}

.ce-post-content h2 {
    font-size: 1.75rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--ce-foreground);
}

.ce-post-content h3 {
    font-size: 1.375rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
    color: var(--ce-foreground);
}

.ce-post-content p {
    margin-bottom: 1.5rem;
}

.ce-post-content ul,
.ce-post-content ol {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.ce-post-content li {
    margin-bottom: 0.5rem;
    padding-left: 0.25rem;
}

.ce-post-content blockquote {
    border-left: 4px solid var(--ce-secondary);
    padding: 1.25rem 1.5rem;
    margin: 2rem 0;
    font-size: 1.125rem;
    font-style: italic;
    color: var(--ce-foreground);
    background-color: var(--ce-surface);
    border-radius: 0 var(--ce-radius) var(--ce-radius) 0;
}

.ce-post-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--ce-radius);
    margin: 1.5rem 0;
}

.ce-post-content a {
    color: var(--ce-secondary);
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: opacity var(--ce-transition);
}

.ce-post-content a:hover {
    opacity: 0.8;
}

.ce-post-content pre {
    background-color: var(--ce-primary);
    color: var(--ce-primary-fg);
    padding: 1.25rem 1.5rem;
    border-radius: var(--ce-radius-lg);
    overflow-x: auto;
    margin: 1.5rem 0;
    font-size: 0.875rem;
    line-height: 1.6;
}

.ce-post-content code {
    background-color: var(--ce-surface);
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
    font-size: 0.875em;
}

.ce-post-content pre code {
    background: none;
    padding: 0;
    border-radius: 0;
    font-size: inherit;
}

/* Share */
.ce-post-share {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 0;
    margin-top: 3rem;
    border-top: 1px solid var(--ce-border);
    border-bottom: 1px solid var(--ce-border);
}

.ce-post-share__label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ce-foreground);
    white-space: nowrap;
}

.ce-post-share__label svg {
    width: 1rem;
    height: 1rem;
}

.ce-post-share__buttons {
    display: flex;
    gap: 0.5rem;
}

.ce-post-share__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--ce-radius-full);
    border: 1px solid var(--ce-border);
    background: var(--ce-card);
    color: var(--ce-muted-fg);
    cursor: pointer;
    transition: all var(--ce-transition);
    text-decoration: none;
    position: relative;
    z-index: 1;
}

.ce-post-share__btn svg {
    width: 1rem;
    height: 1rem;
}

.ce-post-share__btn:hover {
    border-color: transparent;
}

.ce-post-share__btn--whatsapp:hover {
    background-color: #25D366;
    color: white;
}

.ce-post-share__btn--linkedin:hover {
    background-color: #0A66C2;
    color: white;
}

.ce-post-share__btn--facebook:hover {
    background-color: #1877F2;
    color: white;
}


@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(4px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

/* Related Posts */
.ce-related {
    padding-top: 3.5rem;
    margin-top: 3.5rem;
    border-top: 1px solid var(--ce-border);
}

.ce-related__title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: var(--ce-foreground);
}

/* Post Navigation */
.ce-post-nav {
    margin-top: 3.5rem;
    padding-top: 2rem;
    padding-bottom: 4rem;
    text-align: center;
}

.ce-post-nav .ce-btn {
    gap: 0.5rem;
}

.ce-post-nav .ce-btn svg {
    width: 1rem;
    height: 1rem;
}

/* ==========================================================================
   Filter Checkbox (FAMPE)
   ========================================================================== */

.ce-filters__checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--ce-foreground);
    cursor: pointer;
    user-select: none;
}

.ce-filters__checkbox-label input[type="checkbox"] {
    width: 1.125rem;
    height: 1.125rem;
    accent-color: var(--ce-secondary);
    cursor: pointer;
    flex-shrink: 0;
}

.ce-filters__help {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.8125rem;
    color: var(--ce-muted-fg);
    line-height: 1.4;
}