/**
 * CREA Template Stylesheet
 * @package     Joomla.Site
 * @subpackage  Templates.crea
 * @copyright   Copyright (C) 2024 OACOM. All rights reserved.
 * @license     GNU General Public License version 3 or later
 */

/* ==========================================================================
   CSS Variables & Base
   ========================================================================== */

:root {
    --crea-primary: #6F9553;
    --crea-secondary: #F1E9E2;
    --crea-text: #252525;
    --crea-header-bg: #F1E9E2;
    --crea-footer-bg: #6F9553;
    --crea-body-bg: #F1E9E2;
    --crea-white: #ffffff;
    --crea-black: #000000;
    --crea-gray: #666666;
    --crea-light-gray: #f5f5f5;
    --crea-border: #e0e0e0;
    --crea-header-height: 80px;
    --crea-mobile-header-height: 60px;
    --crea-transition: 0.3s ease;
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */

*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body.site {
    font-family: 'Titillium Web', 'Roboto', -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--crea-text);
    background-color: var(--crea-body-bg);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Add padding for fixed headers */
body.site {
    padding-top: var(--crea-mobile-header-height);
}

@media (min-width: 992px) {
    body.site {
        padding-top: 0;
    }
    body.site.sticky-header-active {
        padding-top: var(--crea-header-height);
    }
}

/* ==========================================================================
   Mobile Header - Exact styling from original orbit template
   ========================================================================== */

#header-mobile {
    height: 60px;
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    z-index: 1030;
    background: #F1E9E2;
}

#header-mobile .offcanvas-toggler {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    padding: 0.5rem 1rem;
}

#header-mobile .logo-mobile {
    position: absolute;
    left: 1rem;
    top: 0.5rem;
    bottom: 0.5rem;
    display: flex;
    align-items: center;
}

#header-mobile .logo-mobile img {
    max-height: 100%;
    width: auto;
}

#header-mobile .site-title-mobile {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--crea-primary);
}

/* ==========================================================================
   Desktop Header
   ========================================================================== */

#header.site-header {
    background-color: var(--crea-header-bg);
    position: relative;
    z-index: 1020;
}

#header.site-header.sticky-header {
    position: sticky;
    top: 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header-inner {
    padding: 0;
}

.header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: var(--crea-header-height);
    padding: 0 2rem;
}

.header-logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.header-logo .logo-img {
    max-height: 60px;
    width: auto;
}

.header-logo .site-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--crea-primary);
}

/* ==========================================================================
   Navigation
   ========================================================================== */

.header-nav {
    flex: 1;
    display: flex;
    justify-content: center;
}

.header-nav .nav,
.header-nav .navbar-nav,
.header-nav ul.nav,
.header-nav > div > ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.5rem;
}

.header-nav .nav-item,
.header-nav li {
    position: relative;
}

.header-nav .nav-link,
.header-nav a {
    display: block;
    padding: 1rem 1.25rem;
    color: var(--crea-text);
    text-decoration: none;
    font-weight: 500;
    transition: color var(--crea-transition);
}

.header-nav .nav-link:hover,
.header-nav .nav-link:focus,
.header-nav .nav-link.active,
.header-nav .nav-item.active > .nav-link,
.header-nav a:hover,
.header-nav li.active > a,
.header-nav li.current > a {
    color: var(--crea-primary);
}

/* Dropdown menus */
.header-nav .dropdown-menu,
.header-nav ul ul {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background-color: var(--crea-white);
    border: none;
    border-radius: 0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    padding: 0.5rem 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all var(--crea-transition);
    list-style: none;
    z-index: 1000;
}

.header-nav .nav-item:hover > .dropdown-menu,
.header-nav li:hover > ul {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.header-nav .dropdown-item,
.header-nav ul ul a {
    padding: 0.75rem 1.5rem;
    color: var(--crea-text);
    font-weight: 400;
    transition: all var(--crea-transition);
}

.header-nav .dropdown-item:hover,
.header-nav .dropdown-item:focus,
.header-nav ul ul a:hover {
    background-color: var(--crea-secondary);
    color: var(--crea-primary);
}

/* ==========================================================================
   Header Right & CTA
   ========================================================================== */

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.btn-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    background-color: var(--crea-primary);
    color: var(--crea-white) !important;
    font-weight: 600;
    text-decoration: none;
    border-radius: 4px;
    transition: all var(--crea-transition);
    border: 2px solid var(--crea-primary);
}

.btn-cta:hover,
.btn-cta:focus {
    background-color: transparent;
    color: var(--crea-primary) !important;
}

/* ==========================================================================
   Burger Icon / Offcanvas Toggle
   ========================================================================== */

.offcanvas-toggler,
.offcanvas-toggler-desktop {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    background: transparent;
    border: none;
    cursor: pointer;
}

.burger-icon {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
}

.burger-icon span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--crea-text);
    transition: all var(--crea-transition);
}

.offcanvas-toggler:hover .burger-icon span,
.offcanvas-toggler-desktop:hover .burger-icon span {
    background-color: var(--crea-primary);
}

/* ==========================================================================
   Title/Banner Section
   ========================================================================== */

.title-section {
    width: 100%;
}

.title-section .container-fluid {
    padding: 0;
}

/* SP Page Builder compatibility */
.title-section .sppb-section,
.title-section .sp-page-builder {
    margin: 0;
}

/* ==========================================================================
   Breadcrumb
   ========================================================================== */

.breadcrumb-wrapper {
    background-color: var(--crea-light-gray);
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--crea-border);
}

.breadcrumb-wrapper .breadcrumb {
    margin: 0;
    padding: 0;
    background: transparent;
}

.breadcrumb-wrapper .breadcrumb-item + .breadcrumb-item::before {
    content: ">";
    color: var(--crea-gray);
}

.breadcrumb-wrapper .breadcrumb-item a {
    color: var(--crea-gray);
    text-decoration: none;
}

.breadcrumb-wrapper .breadcrumb-item a:hover {
    color: var(--crea-primary);
}

.breadcrumb-wrapper .breadcrumb-item.active {
    color: var(--crea-text);
}

/* ==========================================================================
   Main Content
   ========================================================================== */

.site-main {
    min-height: 50vh;
    padding: 0;
}

.main-content {
    padding: 0;
}

.container-fluid {
    padding: 0;
}

/* Sidebar Styles */
.sidebar {
    padding: 1rem;
}

.sidebar-left {
    border-right: 1px solid var(--crea-border);
}

.sidebar-right {
    border-left: 1px solid var(--crea-border);
}

/* ==========================================================================
   Bottom Section
   ========================================================================== */

.bottom-section {
    background-color: var(--crea-light-gray);
    padding: 3rem 0;
}

/* ==========================================================================
   Footer - Full width matching original site
   ========================================================================== */

.site-footer {
    background-color: var(--crea-footer-bg);
    color: var(--crea-white);
    padding: 3rem 0 1.5rem;
    width: 100%;
}

.site-footer .container {
    max-width: 100%;
    padding: 0 5%;
}

.site-footer a {
    color: var(--crea-white);
    opacity: 0.9;
    transition: opacity var(--crea-transition);
}

.site-footer a:hover {
    opacity: 1;
    color: var(--crea-white);
}

.site-footer h3,
.site-footer h4,
.site-footer h5 {
    color: var(--crea-white);
    font-weight: 600;
}

.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 2rem;
    padding: 2rem 5%;
}

.footer-logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
}

.footer-logo img {
    max-height: 80px;
    width: auto;
}

.footer-logo .footer-contact {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-logo .footer-contact a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #FFF;
    font-size: 1rem;
}

.footer-columns {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
}

.footer-column h5 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: #FFF;
}

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

.footer-column ul li {
    margin-bottom: 0.5rem;
}

.footer-column ul li a {
    color: #FFF;
    font-size: 0.95rem;
}

/* Footer module chrome */
.footer-module {
    margin-bottom: 1rem;
}

.footer-module-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #FFF;
    margin-bottom: 1rem;
}

.footer-module-content ul,
.footer-module-content .nav,
.footer-module-content .menu {
    list-style: none;
    padding: 0;
    margin: 0;
    width: 100%;
}

.footer-module-content ul li,
.footer-module-content .nav-item,
.footer-module-content .menu li {
    margin-bottom: 0.5rem;
    width: 100%;
}

.footer-module-content ul li a,
.footer-module-content .nav-link,
.footer-module-content .menu a {
    display: block;
    width: 100%;
    color: #FFF;
    font-size: 0.95rem;
    opacity: 0.9;
    transition: opacity 0.2s ease;
    padding: 0;
}

.footer-module-content ul li a:hover,
.footer-module-content .nav-link:hover,
.footer-module-content .menu a:hover {
    opacity: 1;
}

.footer-main {
    padding: 1.5rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    margin-top: 1.5rem;
}

.copyright {
    padding: 1rem 5%;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 0.875rem;
    opacity: 0.9;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.copyright-left {
    margin: 0;
}

.copyright-right {
    text-align: right;
}

.copyright-right a {
    color: #FFF;
    text-decoration: none;
    transition: opacity var(--crea-transition);
}

.copyright-right a:hover {
    text-decoration: underline;
    opacity: 0.8;
}

@media (max-width: 767.98px) {
    .copyright {
        flex-direction: column;
        text-align: center;
    }

    .copyright-right {
        text-align: center;
    }
}

/* ==========================================================================
   Mobile Footer CTA - Exact styling from original orbit template
   ========================================================================== */

#footer-mobile {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    line-height: 3rem;
    padding: 1rem 0;
    background-color: #6F9553 !important;
    color: #FFF;
    text-align: center;
    z-index: 1030;
    font-size: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3rem;
}

#footer-mobile a {
    color: #FFF;
    text-decoration: none;
    transition: transform var(--crea-transition);
}

#footer-mobile a:hover {
    color: #FFF;
    transform: scale(1.1);
}

/* Add bottom padding to body when mobile footer is visible */
@media (max-width: 991.98px) {
    body.site {
        padding-bottom: 60px;
    }
}

/* ==========================================================================
   Offcanvas Menu (Sidebar) - Mobile-friendly with expandable submenus
   ========================================================================== */

.offcanvas {
    width: 100%;
    max-width: 350px;
    background-color: var(--crea-primary);
}

.offcanvas-header {
    background-color: var(--crea-primary);
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.offcanvas-logo {
    max-height: 45px;
    width: auto;
}

.offcanvas-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #FFF;
}

.offcanvas-body {
    padding: 0;
    background-color: var(--crea-primary);
    overflow-y: auto;
}

/* Main menu list */
.offcanvas-body .nav,
.offcanvas-body > ul,
.offcanvas-body > div > ul {
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
}

/* First level menu items - full width */
.offcanvas-body .nav > .nav-item,
.offcanvas-body > ul > li,
.offcanvas-body > div > ul > li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    position: relative;
    width: 100%;
}

/* First level links - full width, large touch target */
.offcanvas-body .nav > .nav-item > .nav-link,
.offcanvas-body > ul > li > a,
.offcanvas-body > div > ul > li > a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 1.15rem 1.5rem;
    color: #FFF;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    background-color: transparent;
    transition: background-color 0.2s ease;
    min-height: 56px;
}

.offcanvas-body .nav > .nav-item > .nav-link:hover,
.offcanvas-body .nav > .nav-item > .nav-link:focus,
.offcanvas-body > ul > li > a:hover,
.offcanvas-body > ul > li > a:focus,
.offcanvas-body > div > ul > li > a:hover,
.offcanvas-body > div > ul > li > a:focus {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Active state */
.offcanvas-body .nav > .nav-item.active > .nav-link,
.offcanvas-body > ul > li.active > a,
.offcanvas-body > ul > li.current > a,
.offcanvas-body > div > ul > li.active > a,
.offcanvas-body > div > ul > li.current > a {
    background-color: rgba(255, 255, 255, 0.15);
}

/* Parent items with children - toggle indicator */
.offcanvas-body .nav > .nav-item.parent > .nav-link::after,
.offcanvas-body > ul > li.parent > a::after,
.offcanvas-body > ul > li.deeper > a::after,
.offcanvas-body > div > ul > li.parent > a::after,
.offcanvas-body > div > ul > li.deeper > a::after {
    content: '+';
    font-size: 1.5rem;
    font-weight: 300;
    line-height: 1;
    margin-left: auto;
    padding-left: 1rem;
    transition: transform 0.3s ease;
}

/* Rotate indicator when open */
.offcanvas-body .nav > .nav-item.parent.open > .nav-link::after,
.offcanvas-body > ul > li.parent.open > a::after,
.offcanvas-body > ul > li.deeper.open > a::after,
.offcanvas-body > div > ul > li.parent.open > a::after,
.offcanvas-body > div > ul > li.deeper.open > a::after {
    content: '−';
}

/* Submenu - hidden by default */
.offcanvas-body ul ul,
.offcanvas-body .nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 0;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.15);
    transition: max-height 0.3s ease-out;
}

/* Submenu visible when parent is open */
.offcanvas-body li.open > ul,
.offcanvas-body .nav-item.open > ul {
    max-height: 500px;
    transition: max-height 0.4s ease-in;
}

/* Submenu items */
.offcanvas-body ul ul li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.offcanvas-body ul ul li:last-child {
    border-bottom: none;
}

/* Submenu links */
.offcanvas-body ul ul a {
    display: block;
    width: 100%;
    padding: 0.9rem 1.5rem 0.9rem 2.5rem;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    font-weight: 400;
    text-decoration: none;
    transition: background-color 0.2s ease, padding-left 0.2s ease;
}

.offcanvas-body ul ul a:hover,
.offcanvas-body ul ul a:focus {
    background-color: rgba(255, 255, 255, 0.08);
    padding-left: 2.75rem;
}

.offcanvas-body ul ul li.active > a,
.offcanvas-body ul ul li.current > a {
    background-color: rgba(255, 255, 255, 0.1);
    color: #FFF;
}

/* Third level submenu */
.offcanvas-body ul ul ul {
    background-color: rgba(0, 0, 0, 0.1);
}

.offcanvas-body ul ul ul a {
    padding-left: 3.5rem;
}

.offcanvas-body ul ul ul a:hover {
    padding-left: 3.75rem;
}

/* Dropdown toggle for Joomla menu module */
.offcanvas-body .dropdown-toggle::after {
    display: none;
}

/* Hide Bootstrap dropdown styling in offcanvas */
.offcanvas-body .dropdown-menu {
    position: static !important;
    display: block !important;
    max-height: 0;
    overflow: hidden;
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    float: none;
    box-shadow: none;
    transition: max-height 0.3s ease-out;
}

.offcanvas-body .dropdown.open > .dropdown-menu,
.offcanvas-body .nav-item.open > .dropdown-menu {
    max-height: 500px;
    transition: max-height 0.4s ease-in;
}

.offcanvas-body .dropdown-menu .dropdown-item {
    padding: 0.9rem 1.5rem 0.9rem 2.5rem;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    background: transparent;
}

.offcanvas-body .dropdown-menu .dropdown-item:hover,
.offcanvas-body .dropdown-menu .dropdown-item:focus {
    background-color: rgba(255, 255, 255, 0.08);
    color: #FFF;
}

/* ==========================================================================
   Back to Top Button
   ========================================================================== */

.back-to-top {
    position: fixed;
    bottom: 80px;
    right: 1.5rem;
    width: 44px;
    height: 44px;
    background-color: var(--crea-primary);
    color: var(--crea-white);
    border: none;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1020;
    transition: all var(--crea-transition);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.back-to-top:hover {
    background-color: var(--crea-text);
    transform: translateY(-3px);
}

.back-to-top.visible {
    display: flex;
}

@media (min-width: 992px) {
    .back-to-top {
        bottom: 2rem;
    }
}

/* ==========================================================================
   Module Chrome - Card Style
   ========================================================================== */

.card-module {
    background-color: var(--crea-white);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.card-module .card-header {
    background-color: var(--crea-secondary);
    padding: 1rem 1.5rem;
    border-bottom: none;
}

.card-module .card-header h3 {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--crea-text);
}

.card-module .card-body {
    padding: 1.5rem;
}

/* ==========================================================================
   System Messages
   ========================================================================== */

.alert {
    border: none;
    border-radius: 8px;
    padding: 1rem 1.5rem;
    margin-bottom: 1.5rem;
}

.alert-success {
    background-color: rgba(111, 149, 83, 0.15);
    color: var(--crea-primary);
}

.alert-danger {
    background-color: rgba(220, 53, 69, 0.15);
    color: #dc3545;
}

.alert-warning {
    background-color: rgba(255, 193, 7, 0.15);
    color: #856404;
}

.alert-info {
    background-color: rgba(0, 123, 255, 0.15);
    color: #0056b3;
}

/* ==========================================================================
   Typography
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    margin-top: 0;
    margin-bottom: 1rem;
    font-family: 'Titillium Web', 'Roboto', sans-serif;
    font-weight: 600;
    line-height: 1.3;
    color: var(--crea-text);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

a {
    color: var(--crea-primary);
    text-decoration: none;
    transition: color var(--crea-transition);
}

a:hover {
    color: var(--crea-text);
}

p {
    margin-top: 0;
    margin-bottom: 1rem;
}

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

/* ==========================================================================
   Forms
   ========================================================================== */

.form-control {
    border: 1px solid var(--crea-border);
    border-radius: 4px;
    padding: 0.75rem 1rem;
    transition: border-color var(--crea-transition), box-shadow var(--crea-transition);
}

.form-control:focus {
    border-color: var(--crea-primary);
    box-shadow: 0 0 0 0.2rem rgba(111, 149, 83, 0.25);
    outline: none;
}

.btn-primary {
    background-color: var(--crea-primary);
    border-color: var(--crea-primary);
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: #5a7a44;
    border-color: #5a7a44;
}

/* ==========================================================================
   Articles & Blog
   ========================================================================== */

.item-page,
.blog,
.category-blog {
    padding: 0;
}

.page-header h1,
.page-header h2 {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--crea-secondary);
}

.article-info {
    font-size: 0.875rem;
    color: var(--crea-gray);
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--crea-border);
}

.item-image {
    position: relative;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    overflow: hidden;
}

.badge-brouillon {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    background: #dc3545;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    pointer-events: none;
}

.item-image img {
    width: 100%;
    height: auto;
}

.readmore {
    margin-top: 1rem;
}

.blog-item,
.items-row {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--crea-border);
}

.blog-item:last-child,
.items-row:last-child {
    border-bottom: none;
}

/* ==========================================================================
   Masonry Blog Layout - Matching original crea.bzh design
   ========================================================================== */

.com-content-category-blog.blog {
    padding: 2rem 5%;
    background-color: var(--crea-body-bg);
}

/* Masonry Grid Container */
.com-content-category-blog__items.blog-items,
.blog-items.masonry-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: start;
}

/* Blog Item Card */
.com-content-category-blog__item.blog-item,
.blog-items .blog-item {
    background-color: var(--crea-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    margin: 0;
    padding: 0;
    border: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    break-inside: avoid;
}

.com-content-category-blog__item.blog-item:hover,
.blog-items .blog-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

/* Blog Item Image */
.blog-item .item-image,
.blog-item .pull-left,
.blog-item .pull-right,
.blog-item figure {
    margin: 0;
    padding: 0;
    border-radius: 0;
    overflow: hidden;
}

.blog-item .item-image img,
.blog-item figure img,
.blog-item .pull-left img,
.blog-item .pull-right img {
    width: 100%;
    height: auto;
    aspect-ratio: 16/10;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.blog-item:hover .item-image img,
.blog-item:hover figure img {
    transform: scale(1.05);
}

/* Blog Item Content */
.blog-item .item-content,
.blog-item .blog-item-content {
    padding: 1.5rem;
}

/* Blog Item Link Wrapper */
.blog-item .blog-item-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* Blog Item Title */
.blog-item h2,
.blog-item .page-header h2,
.blog-item .item-title {
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.4;
    margin: 0;
    color: var(--crea-text);
    transition: color 0.3s ease;
}

.blog-item:hover h2 {
    color: var(--crea-primary);
}

.blog-item h2 a,
.blog-item .item-title a {
    color: var(--crea-text);
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-item h2 a:hover,
.blog-item .item-title a:hover {
    color: var(--crea-primary);
}

/* Blog Item Meta/Info */
.blog-item .article-info,
.blog-item .item-info {
    font-size: 0.85rem;
    color: var(--crea-gray);
    margin-bottom: 0.75rem;
    padding: 0;
    border: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.blog-item .article-info dd,
.blog-item .article-info dt {
    display: inline;
    margin: 0;
}

.blog-item .article-info .icon-calendar,
.blog-item .article-info .icon-user {
    margin-right: 0.25rem;
}

/* Blog Item Text/Intro */
.blog-item p,
.blog-item .item-intro {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--crea-text);
    margin: 0 0 1rem 0;
}

/* Read More Button */
.blog-item .readmore,
.blog-item .btn-readmore {
    margin-top: auto;
}

.blog-item .readmore a,
.blog-item .btn-readmore a,
.blog-item a.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: var(--crea-primary);
    color: var(--crea-white) !important;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.blog-item .readmore a:hover,
.blog-item .btn-readmore a:hover,
.blog-item a.btn:hover {
    background-color: var(--crea-text);
}

/* Featured/Leading Item - Larger */
.blog-featured .blog-item:first-child,
.leading-0 .blog-item,
.com-content-category-blog__item--leading {
    grid-column: span 2;
}

.blog-featured .blog-item:first-child h2,
.leading-0 .blog-item h2,
.com-content-category-blog__item--leading h2 {
    font-size: 1.75rem;
}

/* Category Label/Badge */
.blog-item .category-name,
.blog-item .item-category {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background-color: var(--crea-primary);
    color: var(--crea-white);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 4px;
    margin-bottom: 0.75rem;
}

/* Responsive Masonry */
@media (max-width: 991.98px) {
    .com-content-category-blog__items.blog-items,
    .blog-items.masonry-3 {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .blog-featured .blog-item:first-child,
    .leading-0 .blog-item,
    .com-content-category-blog__item--leading {
        grid-column: span 2;
    }

    .com-content-category-blog.blog {
        padding: 1.5rem 3%;
    }
}

@media (max-width: 767.98px) {
    .com-content-category-blog__items.blog-items,
    .blog-items.masonry-3 {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .blog-featured .blog-item:first-child,
    .leading-0 .blog-item,
    .com-content-category-blog__item--leading {
        grid-column: span 1;
    }

    .com-content-category-blog.blog {
        padding: 1rem;
    }

    .blog-item .item-content,
    .blog-item .blog-item-content {
        padding: 1rem;
    }

    .blog-item h2,
    .blog-item .item-title {
        font-size: 1.1rem;
    }
}

/* Image-only cards (no text) */
.blog-item.image-only .item-content,
.blog-item.no-text .item-content {
    padding: 0;
}

.blog-item.image-only .item-image,
.blog-item.no-text .item-image {
    border-radius: 12px;
}

/* CSS Columns Masonry fallback for older browsers */
@supports not (display: grid) {
    .com-content-category-blog__items.blog-items,
    .blog-items.masonry-3 {
        column-count: 3;
        column-gap: 1.5rem;
    }

    .com-content-category-blog__item.blog-item,
    .blog-items .blog-item {
        display: inline-block;
        width: 100%;
        margin-bottom: 1.5rem;
    }

    @media (max-width: 991.98px) {
        .com-content-category-blog__items.blog-items,
        .blog-items.masonry-3 {
            column-count: 2;
        }
    }

    @media (max-width: 767.98px) {
        .com-content-category-blog__items.blog-items,
        .blog-items.masonry-3 {
            column-count: 1;
        }
    }
}

/* ==========================================================================
   Category Hero - Collage style (image + colored content frame)
   ========================================================================== */

.category-hero {
    display: flex;
    align-items: center;
    margin: 0 0 2rem;
    position: relative;
    padding: 3rem 5%;
}

.category-hero__image {
    flex: 0 0 55%;
    max-width: 55%;
    overflow: hidden;
}

.category-hero__image img {
    width: 100%;
    height: auto;
    display: block;
}

.category-hero__content {
    flex: 0 0 45%;
    max-width: 45%;
    background: linear-gradient(225deg, rgb(180, 151, 134) 0%, rgb(180, 151, 134) 100%);
    padding: 2.5rem 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    margin-left: -10%;
    z-index: 1;
    box-shadow: -10px 15px 20px 0 rgba(0, 0, 0, 0.3);
}

.category-hero__title {
    font-size: 2.75rem;
    font-weight: 600;
    color: #fff !important;
    margin: 0 0 1rem;
    padding: 0;
    border: none;
    line-height: 1.2;
}

.category-hero__description {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.25rem;
    line-height: 1.6;
}

.category-hero__description p {
    margin: 0 0 0.75rem;
    color: rgba(255, 255, 255, 0.8);
}

.category-hero__description p:last-child {
    margin-bottom: 0;
}

.category-hero__description strong {
    color: #fff;
}

.category-hero__description a {
    color: #fff;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.category-hero__description a:hover {
    opacity: 0.8;
}

/* When no image, content takes full width */
.category-hero:not(:has(.category-hero__image)) .category-hero__content {
    flex: 1;
    max-width: 100%;
    margin-left: 0;
    box-shadow: 0 10px 20px 0 rgba(0, 0, 0, 0.15);
}

/* Responsive - Tablet */
@media (max-width: 991.98px) {
    .category-hero__content {
        padding: 2rem 2rem;
        margin-left: -3%;
    }

    .category-hero__title {
        font-size: 2.25rem;
    }

    .category-hero__description {
        font-size: 1.1rem;
    }
}

/* Responsive - Mobile */
@media (max-width: 767.98px) {
    .category-hero {
        flex-direction: column;
        padding: 1.5rem 1rem;
    }

    .category-hero__image {
        flex: none;
        max-width: 100%;
        height: 250px;
    }

    .category-hero__image img {
        height: 100%;
        object-fit: cover;
    }

    .category-hero__content {
        flex: none;
        max-width: 90%;
        margin-left: 5%;
        margin-top: -2rem;
        box-shadow: 0 10px 20px 0 rgba(0, 0, 0, 0.2);
    }

    .category-hero__title {
        font-size: 1.75rem;
    }

    .category-hero__description {
        font-size: 1rem;
    }
}

/* Page Header for Blog Category */
.com-content-category-blog .page-header,
.blog .page-header {
    padding: 2rem 5% 1rem;
    margin: 0;
    border: none;
}

.com-content-category-blog .page-header h2,
.blog .page-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--crea-text);
    margin: 0;
    border: none;
    padding: 0;
}

/* Blog pagination */
.com-content-category-blog .pagination-wrapper,
.blog .pagination-wrapper {
    padding: 2rem 5%;
    display: flex;
    justify-content: center;
}

.com-content-category-blog .pagination,
.blog .pagination {
    gap: 0.25rem;
}

.com-content-category-blog .page-item .page-link,
.blog .page-item .page-link {
    border-radius: 8px;
    padding: 0.75rem 1rem;
    color: var(--crea-text);
    border: 1px solid var(--crea-border);
}

.com-content-category-blog .page-item.active .page-link,
.blog .page-item.active .page-link {
    background-color: var(--crea-primary);
    border-color: var(--crea-primary);
    color: var(--crea-white);
}

.com-content-category-blog .page-item .page-link:hover,
.blog .page-item .page-link:hover {
    background-color: var(--crea-secondary);
    color: var(--crea-primary);
}

/* ==========================================================================
   Pagination
   ========================================================================== */

.pagination {
    margin-top: 2rem;
}

.page-link {
    color: var(--crea-primary);
    border-color: var(--crea-border);
}

.page-link:hover {
    background-color: var(--crea-secondary);
    border-color: var(--crea-border);
    color: var(--crea-primary);
}

.page-item.active .page-link {
    background-color: var(--crea-primary);
    border-color: var(--crea-primary);
}

/* ==========================================================================
   Tables
   ========================================================================== */

.table {
    margin-bottom: 1.5rem;
}

.table thead th {
    background-color: var(--crea-secondary);
    border-bottom: 2px solid var(--crea-border);
    font-weight: 600;
}

/* ==========================================================================
   Utilities
   ========================================================================== */

.text-primary { color: var(--crea-primary) !important; }
.bg-primary { background-color: var(--crea-primary) !important; }
.bg-secondary { background-color: var(--crea-secondary) !important; }

/* Hide tarteaucitron floating icon (we have footer link instead) */
#tarteaucitronIcon {
    display: none !important;
}

/* SP Page Builder overrides - Consistent colors */
.sppb-article-info-wrap a,
.sppb-article-info a,
.sppb-meta-category a,
.sppb-article-meta a,
.sp-page-builder a,
.sppb-addon a {
    color: var(--crea-primary);
}

.sppb-article-info-wrap a:hover,
.sppb-article-info a:hover,
.sppb-meta-category a:hover,
.sppb-article-meta a:hover,
.sp-page-builder a:hover,
.sppb-addon a:hover {
    color: var(--crea-text);
}

/* SP Page Builder buttons */
.sppb-btn-primary,
.sppb-btn-success {
    background-color: var(--crea-primary) !important;
    border-color: var(--crea-primary) !important;
}

.sppb-btn-primary:hover,
.sppb-btn-success:hover {
    background-color: var(--crea-text) !important;
    border-color: var(--crea-text) !important;
}

/* Accessibility helpers - Exact styling from original orbit template */
.h1_off {
    position: absolute;
    height: 0;
    overflow: hidden;
}

.h2_off {
    position: absolute;
    height: 0;
    overflow: hidden;
}

.sr-only {
    position: absolute;
    height: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ==========================================================================
   Responsive Adjustments
   ========================================================================== */

@media (max-width: 991.98px) {
    .site-main {
        padding: 1.5rem 0;
    }

    .main-content {
        padding: 0 1rem;
    }

    .sidebar {
        border: none;
        border-top: 1px solid var(--crea-border);
        padding: 1.5rem 1rem;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.5rem; }
}

@media (max-width: 767.98px) {
    .header-row {
        padding: 0 1rem;
    }

    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }
}

/* ==========================================================================
   Projet Layout - Full-width article with hero image (like crea.bzh)
   ========================================================================== */

.projet-layout {
    margin: 0;
    padding: 0;
    background-color: var(--crea-white);
}

/* Hero Section - Full width edge-to-edge */
.projet-hero {
    position: relative;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    height: 70vh;
    min-height: 450px;
    max-height: 800px;
    overflow: hidden;
}

.projet-hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.projet-hero-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top,
        rgba(0, 0, 0, 0.85) 0%,
        rgba(0, 0, 0, 0.5) 40%,
        rgba(0, 0, 0, 0.2) 70%,
        transparent 100%);
    padding: 6rem 5% 3rem;
}

.projet-hero-content {
    max-width: 1200px;
    margin: 0 auto;
}

.projet-hero-content h1 {
    color: #FFF;
    font-size: 6rem;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.4);
    line-height: 1.1;
}

/* Header without hero - for articles without featured image */
.projet-header {
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    padding: 4rem 5%;
    background: linear-gradient(135deg, var(--crea-primary) 0%, #5a7a44 100%);
}

.projet-header h1 {
    font-size: 6rem;
    font-weight: 700;
    margin: 0;
    color: #FFF;
    max-width: 50%;
    line-height: 1.1;
}

/* Body Content Container */
.projet-body {
    padding: 3rem 5%;
    max-width: 1400px;
    margin: 0 auto;
}

/* Two-column layout when gallery exists */
.projet-body.has-gallery .projet-main {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 3rem;
    align-items: start;
}

.projet-content-column {
    min-width: 0;
}

/* Subtitle styling */
.projet-subtitle {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.9);
    margin-top: 0.75rem;
    font-weight: 400;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.projet-header .projet-subtitle {
    color: rgba(255, 255, 255, 0.85);
}

/* Gallery Column - Right side masonry */
.projet-gallery-column {
    position: sticky;
    top: 100px;
}

.projet-masonry-gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.projet-gallery-item {
    display: block;
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.projet-gallery-item:nth-child(3n+1) {
    grid-column: span 2;
}

.projet-gallery-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.4s ease;
}

.projet-gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.projet-gallery-item:hover img {
    transform: scale(1.05);
}

.projet-gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 0.75rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: #fff;
    font-size: 0.85rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.projet-gallery-item:hover .projet-gallery-caption {
    opacity: 1;
}

/* Gallery Section - Thumbnail grid like original */
.projet-before-content {
    margin-bottom: 3rem;
}

/* ACF Gallery and similar thumbnail grids (for legacy support) */
.projet-gallery,
.acfgallery,
.sigProContainer,
.projet-body .acfgallery_list {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 1rem;
    margin-bottom: 3rem;
    padding: 0;
    list-style: none;
}

.projet-gallery a,
.acfgallery a,
.sigProContainer a,
.acfgallery_list li a {
    display: block;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 1;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.projet-gallery a:hover,
.acfgallery a:hover,
.sigProContainer a:hover,
.acfgallery_list li a:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.projet-gallery img,
.acfgallery img,
.sigProContainer img,
.acfgallery_list img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.projet-gallery a:hover img,
.acfgallery a:hover img,
.sigProContainer a:hover img,
.acfgallery_list li a:hover img {
    transform: scale(1.1);
}

/* Content Section with nice typography */
.projet-intro {
    font-size: 1.35rem;
    line-height: 1.8;
    color: var(--crea-text);
    margin-bottom: 2.5rem;
    padding-bottom: 2.5rem;
    border-bottom: 2px solid var(--crea-secondary);
    font-weight: 400;
}

.projet-intro p:first-child {
    margin-top: 0;
}

.projet-intro strong {
    color: var(--crea-primary);
}

/* Main Content Styling */
.projet-content {
    font-size: 1.1rem;
    line-height: 1.9;
    color: var(--crea-text);
}

.projet-content h2 {
    font-size: 2rem;
    font-weight: 700;
    margin: 3rem 0 1.5rem;
    color: var(--crea-primary);
    position: relative;
    padding-bottom: 0.75rem;
}

.projet-content h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: var(--crea-primary);
    border-radius: 2px;
}

.projet-content h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 2.5rem 0 1rem;
    color: var(--crea-text);
}

.projet-content h4 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 2rem 0 1rem;
    color: var(--crea-text);
}

.projet-content p {
    margin-bottom: 1.5rem;
}

.projet-content ul,
.projet-content ol {
    margin: 1.5rem 0 2rem 0;
    padding-left: 0;
}

.projet-content ul {
    list-style: none;
}

.projet-content ul li {
    position: relative;
    padding-left: 1.75rem;
    margin-bottom: 0.75rem;
}

.projet-content ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.6rem;
    width: 8px;
    height: 8px;
    background-color: var(--crea-primary);
    border-radius: 50%;
}

.projet-content ol {
    counter-reset: item;
    list-style: none;
}

.projet-content ol li {
    position: relative;
    padding-left: 2.5rem;
    margin-bottom: 0.75rem;
    counter-increment: item;
}

.projet-content ol li::before {
    content: counter(item);
    position: absolute;
    left: 0;
    top: 0;
    width: 1.75rem;
    height: 1.75rem;
    background-color: var(--crea-primary);
    color: #FFF;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.projet-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 2rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.projet-content blockquote {
    margin: 2rem 0;
    padding: 1.5rem 2rem;
    background-color: var(--crea-secondary);
    border-left: 4px solid var(--crea-primary);
    border-radius: 0 8px 8px 0;
    font-style: italic;
    font-size: 1.15rem;
}

.projet-content a {
    color: var(--crea-primary);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.projet-content a:hover {
    color: var(--crea-text);
}

/* Meta Info */
.projet-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    padding: 2rem 0;
    margin-top: 3rem;
    border-top: 2px solid var(--crea-secondary);
    font-size: 0.95rem;
    color: var(--crea-gray);
}

.projet-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.projet-meta a {
    color: var(--crea-primary);
    font-weight: 500;
}

.projet-meta a:hover {
    color: var(--crea-text);
}

/* Article Navigation */
.projet-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2.5rem 0;
    margin-top: 2rem;
    border-top: 2px solid var(--crea-secondary);
    gap: 1rem;
}

.projet-nav-prev,
.projet-nav-next {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.75rem;
    background-color: var(--crea-primary);
    color: #FFF !important;
    font-weight: 600;
    font-size: 1rem;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(111, 149, 83, 0.3);
}

.projet-nav-prev:hover,
.projet-nav-next:hover {
    background-color: var(--crea-text);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

/* Back to list link */
.projet-back {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
    color: var(--crea-primary);
    font-weight: 500;
    text-decoration: none;
}

.projet-back:hover {
    color: var(--crea-text);
}

/* Lightbox */
.projet-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    cursor: default;
    padding: 2rem;
}

.projet-lightbox-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 90vw;
    max-height: 85vh;
}

.projet-lightbox-image {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 4px;
}

.projet-lightbox-info {
    margin-top: 1.5rem;
    text-align: center;
    max-width: 600px;
}

.projet-lightbox-title {
    color: #fff;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0 0 0.5rem;
}

.projet-lightbox-description {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
    line-height: 1.6;
}

.projet-lightbox-counter {
    position: absolute;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.projet-lightbox-close,
.projet-lightbox-prev,
.projet-lightbox-next {
    position: absolute;
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.projet-lightbox-close {
    top: 1rem;
    right: 1.5rem;
    font-size: 2.5rem;
    line-height: 1;
}

.projet-lightbox-prev,
.projet-lightbox-next {
    top: 50%;
    transform: translateY(-50%);
    font-size: 3rem;
    padding: 1rem;
}

.projet-lightbox-prev {
    left: 1rem;
}

.projet-lightbox-next {
    right: 1rem;
}

.projet-lightbox-close:hover,
.projet-lightbox-prev:hover,
.projet-lightbox-next:hover {
    color: var(--crea-primary);
}

/* Responsive - Tablet */
@media (max-width: 991.98px) {
    .projet-hero {
        height: 55vh;
        min-height: 350px;
    }

    .projet-hero-content h1,
    .projet-header h1 {
        font-size: 4.5rem;
    }

    .projet-subtitle {
        font-size: 1.2rem;
    }

    .projet-hero-overlay {
        padding: 4rem 4% 2.5rem;
    }

    .projet-body {
        padding: 2rem 4%;
    }

    /* Stack columns on tablet */
    .projet-body.has-gallery .projet-main {
        grid-template-columns: 1fr;
    }

    .projet-gallery-column {
        position: relative;
        top: 0;
        margin-top: 2rem;
    }

    .projet-masonry-gallery {
        grid-template-columns: repeat(3, 1fr);
    }

    .projet-gallery-item:nth-child(3n+1) {
        grid-column: span 1;
    }

    .projet-gallery,
    .acfgallery,
    .sigProContainer,
    .projet-body .acfgallery_list {
        grid-template-columns: repeat(4, 1fr);
        gap: 0.75rem;
    }

    .projet-content h2 {
        font-size: 1.75rem;
    }

    .projet-content h3 {
        font-size: 1.35rem;
    }

    .projet-lightbox-prev,
    .projet-lightbox-next {
        font-size: 2rem;
    }
}

/* Responsive - Mobile */
@media (max-width: 767.98px) {
    .projet-hero {
        height: 45vh;
        min-height: 280px;
    }

    .projet-hero-content h1,
    .projet-header h1 {
        font-size: 3rem;
    }

    .projet-subtitle {
        font-size: 1rem;
    }

    .projet-hero-overlay {
        padding: 3rem 1rem 1.5rem;
    }

    .projet-header {
        padding: 2.5rem 1rem;
    }

    .projet-body {
        padding: 1.5rem 1rem;
    }

    .projet-intro {
        font-size: 1.1rem;
        line-height: 1.7;
    }

    .projet-masonry-gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }

    .projet-gallery,
    .acfgallery,
    .sigProContainer,
    .projet-body .acfgallery_list {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.5rem;
    }

    .projet-content {
        font-size: 1rem;
    }

    .projet-content h2 {
        font-size: 1.5rem;
        margin: 2rem 0 1rem;
    }

    .projet-content h3 {
        font-size: 1.25rem;
    }

    .projet-content ul li,
    .projet-content ol li {
        padding-left: 1.5rem;
    }

    .projet-content ol li::before {
        width: 1.5rem;
        height: 1.5rem;
        font-size: 0.75rem;
    }

    .projet-navigation {
        flex-direction: column;
        gap: 1rem;
    }

    .projet-nav-prev,
    .projet-nav-next {
        width: 100%;
        justify-content: center;
    }

    .projet-lightbox-content {
        max-height: 80vh;
    }

    .projet-lightbox-image {
        max-height: 50vh;
    }

    .projet-lightbox-info {
        padding: 0 1rem;
    }

    .projet-lightbox-title {
        font-size: 1.1rem;
    }

    .projet-lightbox-description {
        font-size: 0.9rem;
    }
}

/* ==========================================================================
   Frontend Article Edit Form
   ========================================================================== */

/* Hide SEOmaster inline toggle globally */
#seomaster-inline-toggle,
button.seomaster-inline-toggle {
    display: none !important;
    visibility: hidden !important;
    width: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    position: absolute !important;
    clip: rect(0, 0, 0, 0) !important;
}

/* Hide site chrome on edit page */
body.crea-edit-active {
    padding-top: 0 !important;
    background: #f4f5f7;
}

body.crea-edit-active #header,
body.crea-edit-active #header-mobile,
body.crea-edit-active .breadcrumb-wrapper,
body.crea-edit-active .title-section,
body.crea-edit-active #bottom-section,
body.crea-edit-active #cta,
body.crea-edit-active #footer,
body.crea-edit-active #footer-mobile,
body.crea-edit-active .back-to-top,
body.crea-edit-active .offcanvas {
    display: none !important;
}

body.crea-edit-active #main-content {
    padding: 0;
    margin: 0;
}

body.crea-edit-active #main-content > .container-fluid {
    padding: 0;
    max-width: none;
}

body.crea-edit-active #main-content > .container-fluid > .row {
    margin: 0;
}

body.crea-edit-active #component {
    padding: 0;
    max-width: none;
}

/* Edit page layout */
.crea-edit-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* === Custom Editor Header === */
.crea-edit-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0 1.5rem;
    height: 56px;
    background: var(--crea-white);
    border-bottom: 1px solid var(--crea-border);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
    flex-shrink: 0;
}

.crea-edit-header__left {
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 0;
}

.crea-edit-header__logo img {
    height: 32px;
    width: auto;
}

.crea-edit-header__title {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
    min-width: 0;
}

.crea-edit-header__label {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--crea-primary);
}

.crea-edit-header__name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--crea-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 400px;
}

.crea-edit-header__actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

/* Header action buttons */
.crea-edit-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    font-family: 'Titillium Web', sans-serif;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background var(--crea-transition), transform 0.1s ease;
    white-space: nowrap;
}

.crea-edit-btn:active {
    transform: scale(0.97);
}

.crea-edit-btn i {
    font-size: 0.75rem;
}

.crea-edit-btn--save {
    background: var(--crea-primary);
    color: var(--crea-white);
}

.crea-edit-btn--save:hover {
    background: #5d8244;
}

.crea-edit-btn--close {
    background: #e8f5e0;
    color: var(--crea-primary);
}

.crea-edit-btn--close:hover {
    background: #d5ebc9;
}

.crea-edit-btn--copy {
    background: var(--crea-light-gray);
    color: var(--crea-gray);
}

.crea-edit-btn--copy:hover {
    background: var(--crea-border);
    color: var(--crea-text);
}

.crea-edit-btn--cancel {
    background: none;
    color: var(--crea-gray);
    padding: 0.45rem 0.75rem;
}

.crea-edit-btn--cancel:hover {
    background: #fee;
    color: #c33;
}

/* Mobile header adjustments */
@media (max-width: 767.98px) {
    .crea-edit-header {
        padding: 0 0.75rem;
        gap: 0.5rem;
    }

    .crea-edit-header__name {
        max-width: 120px;
        font-size: 0.8rem;
    }

    .crea-edit-btn span {
        display: none;
    }

    .crea-edit-btn {
        padding: 0.45rem 0.65rem;
    }

    .crea-edit-btn i {
        font-size: 0.9rem;
    }
}

/* === Form Body === */
.crea-edit-body {
    flex: 1;
    width: 100%;
    padding: 1.5rem;
}

/* Two-column layout */
.crea-edit-columns {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.crea-edit-col-main {
    flex: 1;
    min-width: 0;
}

.crea-edit-col-side {
    flex: 0 0 380px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: sticky;
    top: 72px;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
}

@media (max-width: 1199.98px) {
    .crea-edit-columns {
        flex-direction: column;
    }
    .crea-edit-col-side {
        flex: none;
        width: 100%;
        position: static;
        max-height: none;
    }
}

/* Right column panels */
.crea-edit-panel {
    background: var(--crea-white);
    border-radius: 10px;
    padding: 1.25rem;
    border: 1px solid var(--crea-border);
}

.crea-edit-panel__title {
    font-family: 'Titillium Web', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--crea-gray);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.crea-edit-panel__title i {
    color: var(--crea-primary);
    font-size: 0.9em;
}

/* Tab styling */
.crea-edit-col-main joomla-tab [role="tablist"] {
    background: var(--crea-white);
    border-radius: 10px 10px 0 0;
    border-bottom: 2px solid var(--crea-border);
    padding: 0 0.5rem;
    gap: 0;
    flex-wrap: wrap;
}

.crea-edit-col-main joomla-tab [role="tab"] {
    padding: 0.75rem 1.25rem;
    font-size: 0.85rem;
    font-weight: 600;
    font-family: 'Titillium Web', sans-serif;
    color: var(--crea-gray);
    border: none;
    border-bottom: 3px solid transparent;
    background: none;
    transition: color var(--crea-transition), border-color var(--crea-transition);
    white-space: nowrap;
}

.crea-edit-col-main joomla-tab [role="tab"]:hover {
    color: var(--crea-text);
}

.crea-edit-col-main joomla-tab [role="tab"][aria-selected="true"] {
    color: var(--crea-primary);
    border-bottom-color: var(--crea-primary);
}

/* Tab content panels */
.crea-edit-col-main joomla-tab-element {
    background: var(--crea-white);
    padding: 1.5rem;
    border-radius: 0 0 10px 10px;
}

/* Form controls */
.crea-edit-body .control-group {
    margin-bottom: 1rem;
}

.crea-edit-body .control-label label {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--crea-text);
    margin-bottom: 0.3rem;
}

.crea-edit-body .form-control {
    border: 2px solid var(--crea-border);
    border-radius: 8px;
    padding: 0.6rem 0.85rem;
    font-size: 0.95rem;
    transition: border-color var(--crea-transition), box-shadow var(--crea-transition);
}

.crea-edit-body .form-control:focus {
    border-color: var(--crea-primary);
    box-shadow: 0 0 0 3px rgba(111, 149, 83, 0.15);
}

/* Sous-titre field inline after title */
.crea-edit-field-subtitle {
    margin-bottom: 0.5rem;
}

/* Hide the old bottom buttons (now in header) */
.crea-edit-page > .crea-edit-body form > .mb-2 {
    display: none;
}

/* Joomla media modal: full-screen, polished */
body.crea-edit-active .joomla-modal .modal-dialog,
body.crea-edit-active .modal .modal-dialog {
    max-width: 90vw !important;
    width: 90vw !important;
    margin: 2vh auto !important;
}

body.crea-edit-active .joomla-modal .modal-content,
body.crea-edit-active .modal .modal-content {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    border: none;
}

body.crea-edit-active .joomla-modal .modal-header,
body.crea-edit-active .modal .modal-header {
    background: var(--crea-white);
    border-bottom: 1px solid var(--crea-border);
    padding: 1rem 1.5rem;
}

body.crea-edit-active .joomla-modal .modal-header .modal-title,
body.crea-edit-active .modal .modal-header .modal-title {
    font-family: 'Titillium Web', sans-serif;
    font-weight: 700;
}

body.crea-edit-active .joomla-modal .modal-body,
body.crea-edit-active .modal .modal-body {
    padding: 0;
}

body.crea-edit-active .joomla-modal .modal-body iframe,
body.crea-edit-active .modal .modal-body iframe {
    min-height: 75vh !important;
    height: 75vh !important;
    width: 100% !important;
    border: none;
}

body.crea-edit-active .joomla-modal .modal-footer,
body.crea-edit-active .modal .modal-footer {
    background: var(--crea-light-gray);
    border-top: 1px solid var(--crea-border);
    padding: 0.75rem 1.5rem;
}

body.crea-edit-active .modal-backdrop {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

/* ==========================================================================
   com_media modal (loaded via tmpl=component in iframe)
   ========================================================================== */

body.contentpane.component {
    font-family: 'Titillium Web', 'Roboto', -apple-system, sans-serif;
}

/* Hide SEO, accessibility, cookie widgets in component/modal views */
body.contentpane .seomaster-inline-toggle,
body.contentpane button.seomaster-inline-toggle,
body.contentpane #seomaster-inline-toggle,
body.contentpane .djacc,
body.contentpane .djacc-container,
body.contentpane [class*="djacc"],
body.contentpane #tarteaucitronRoot {
    display: none !important;
    visibility: hidden !important;
    width: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
}

/* Media toolbar */
body.contentpane.component .media-toolbar {
    background: #f8f9fa;
    border-bottom: 1px solid #e0e0e0;
    padding: 0.6rem 1rem;
}

body.contentpane.component .media-toolbar .btn {
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.4rem 0.85rem;
}

body.contentpane.component .media-toolbar .btn-secondary {
    background: #fff;
    border: 1px solid #d0d0d0;
    color: #333;
}

body.contentpane.component .media-toolbar .btn-secondary:hover {
    background: #f0f0f0;
}

/* Media browser grid */
body.contentpane.component .media-browser-grid .media-browser-item {
    border-radius: 8px;
    border: 2px solid transparent;
    transition: border-color 0.2s, box-shadow 0.2s;
}

body.contentpane.component .media-browser-grid .media-browser-item:hover {
    border-color: var(--crea-primary, #6F9553);
    box-shadow: 0 2px 8px rgba(111, 149, 83, 0.15);
}

body.contentpane.component .media-browser-grid .media-browser-item.selected {
    border-color: var(--crea-primary, #6F9553);
    background: rgba(111, 149, 83, 0.05);
}

body.contentpane.component .media-browser-image img {
    border-radius: 6px;
}

/* Tree sidebar */
body.contentpane.component .media-tree {
    border-right: 1px solid #e0e0e0;
    padding: 0.75rem;
    font-size: 0.875rem;
}

/* Search input */
body.contentpane.component input.form-control {
    border-radius: 6px;
}

/* Compact image panels */
.crea-edit-panel--compact {
    padding: 0.75rem 1rem;
}

/* Hide verbose Joomla labels in panels (redundant with panel title) */
.crea-edit-panel .control-label {
    display: none;
}

/* Compact field spacing */
.crea-edit-panel .control-group {
    margin-bottom: 0.5rem;
}

/* Smaller image preview */
.crea-edit-panel--compact .field-media-preview {
    max-height: 80px;
    margin-bottom: 0.4rem;
}

.crea-edit-panel--compact .field-media-preview img {
    max-height: 70px;
    width: auto;
    border-radius: 4px;
}

/* Compact buttons */
.crea-edit-panel--compact .btn {
    font-size: 0.8rem;
    padding: 0.3rem 0.6rem;
}

/* Compact input fields */
.crea-edit-panel--compact .form-control {
    font-size: 0.85rem;
    padding: 0.4rem 0.6rem;
}

/* Galerie panel */
.crea-edit-panel .yapuka-mode-selector > .form-label {
    display: none;
}

.crea-edit-panel .yapuka-gallery-field {
    font-size: 0.875rem;
}

/* Hide reading time on projet articles */
.projet-layout .reading-time {
    display: none;
}

/* ==========================================================================
   Article Edit Button (fixed bottom-right FAB)
   ========================================================================== */

.projet-layout > .icons,
.illustrated-blog-layout > .icons,
.legal-article > .icons {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 1000;
}

.projet-layout > .icons .float-end,
.illustrated-blog-layout > .icons .float-end,
.legal-article > .icons .float-end {
    float: none !important;
}

.projet-layout > .icons a,
.illustrated-blog-layout > .icons a,
.legal-article > .icons a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.7rem 1.25rem;
    background: var(--crea-primary);
    color: var(--crea-white) !important;
    border-radius: 50px;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 600;
    font-family: 'Titillium Web', sans-serif;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transition: background var(--crea-transition), transform 0.15s ease, box-shadow var(--crea-transition);
}

.projet-layout > .icons a:hover,
.illustrated-blog-layout > .icons a:hover,
.legal-article > .icons a:hover {
    background: #5d8244;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(111, 149, 83, 0.4);
}

.projet-layout > .icons a .icon-edit,
.illustrated-blog-layout > .icons a .icon-edit,
.legal-article > .icons a .icon-edit {
    font-size: 1rem;
}

.projet-layout > .icons a [role="tooltip"],
.illustrated-blog-layout > .icons a [role="tooltip"],
.legal-article > .icons a [role="tooltip"] {
    display: none;
}

/* Hide ConsentKit floating icon — managed via inline button instead */
.ck-icon.ck-icon--bottom-right {
    display: none !important;
}

/* ==========================================================================
   Login Page - Full viewport takeover
   ========================================================================== */

/* Hide header, footer, CTA, breadcrumb, etc. when login page is active */
body.crea-login-active #header,
body.crea-login-active #header-mobile,
body.crea-login-active .breadcrumb-wrapper,
body.crea-login-active .title-section,
body.crea-login-active #bottom-section,
body.crea-login-active #cta,
body.crea-login-active #footer,
body.crea-login-active #footer-mobile,
body.crea-login-active .back-to-top,
body.crea-login-active .offcanvas {
    display: none !important;
}

body.crea-login-active {
    padding-top: 0 !important;
    background: var(--crea-white);
}

body.crea-login-active #main-content {
    padding: 0;
    margin: 0;
}

body.crea-login-active #main-content > .container-fluid {
    padding: 0;
    max-width: none;
}

body.crea-login-active #main-content > .container-fluid > .row {
    margin: 0;
}

body.crea-login-active #component {
    padding: 0;
    max-width: none;
}

/* Login page layout */
.crea-login-page {
    display: flex;
    min-height: 100vh;
    width: 100vw;
}

/* Visual / image side */
.crea-login-visual {
    display: none;
    position: relative;
    flex: 1;
    background: url('/images/mp-juin-04.jpg') center/cover no-repeat;
    overflow: hidden;
}

.crea-login-visual__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        160deg,
        rgba(111, 149, 83, 0.88) 0%,
        rgba(111, 149, 83, 0.55) 40%,
        rgba(37, 37, 37, 0.45) 100%
    );
}

.crea-login-visual__content {
    position: absolute;
    bottom: 4rem;
    left: 3rem;
    right: 3rem;
    color: #fff;
    z-index: 1;
}

.crea-login-visual__content h2 {
    font-family: 'Titillium Web', sans-serif;
    font-size: 2.25rem;
    font-weight: 700;
    margin: 0 0 0.75rem;
    line-height: 1.2;
}

.crea-login-visual__content p {
    font-size: 1.1rem;
    margin: 0;
    opacity: 0.9;
    max-width: 420px;
    line-height: 1.5;
}

@media (min-width: 992px) {
    .crea-login-visual {
        display: block;
    }
}

/* Form side */
.crea-login-form-side {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--crea-white);
    padding: 2.5rem 1.5rem;
}

@media (min-width: 992px) {
    .crea-login-form-side {
        flex: 0 0 520px;
        max-width: 520px;
        padding: 3rem 4rem;
        box-shadow: -6px 0 40px rgba(0, 0, 0, 0.06);
        z-index: 1;
    }
}

.crea-login-form-wrapper {
    width: 100%;
    max-width: 380px;
}

/* Logo */
.crea-login-logo {
    margin-bottom: 2.5rem;
}

.crea-login-logo img {
    height: 56px;
    width: auto;
}

/* Title */
.crea-login-title {
    font-family: 'Titillium Web', sans-serif;
    font-size: 1.85rem;
    font-weight: 700;
    color: var(--crea-text);
    margin: 0 0 0.25rem;
}

.crea-login-subtitle {
    font-size: 0.95rem;
    color: var(--crea-gray);
    margin: 0 0 2rem;
}

/* Form fields */
.crea-login-field {
    margin-bottom: 1.25rem;
}

.crea-login-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--crea-text);
    margin-bottom: 0.4rem;
    letter-spacing: 0.02em;
}

.crea-login-label i {
    color: var(--crea-primary);
    margin-right: 0.35rem;
    width: 1em;
    text-align: center;
}

.crea-login-input {
    width: 100%;
    padding: 0.8rem 1rem;
    font-size: 0.95rem;
    font-family: inherit;
    border: 2px solid var(--crea-border);
    border-radius: 8px;
    background: var(--crea-light-gray);
    color: var(--crea-text);
    transition: border-color var(--crea-transition), box-shadow var(--crea-transition), background var(--crea-transition);
    outline: none;
}

.crea-login-input::placeholder {
    color: #aaa;
}

.crea-login-input:focus {
    border-color: var(--crea-primary);
    background: var(--crea-white);
    box-shadow: 0 0 0 3px rgba(111, 149, 83, 0.15);
}

/* Password toggle */
.crea-login-password-wrap {
    position: relative;
}

.crea-login-password-wrap .crea-login-input {
    padding-right: 3rem;
}

.crea-login-password-toggle {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--crea-gray);
    cursor: pointer;
    transition: color var(--crea-transition);
    padding: 0;
}

.crea-login-password-toggle:hover {
    color: var(--crea-primary);
}

/* Remember me checkbox */
.crea-login-remember {
    margin-bottom: 1.5rem;
}

.crea-login-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--crea-gray);
    cursor: pointer;
    user-select: none;
}

.crea-login-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    border: 2px solid var(--crea-border);
    border-radius: 4px;
    accent-color: var(--crea-primary);
    cursor: pointer;
    flex-shrink: 0;
}

/* Submit button */
.crea-login-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.85rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Titillium Web', sans-serif;
    color: var(--crea-white);
    background: var(--crea-primary);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background var(--crea-transition), transform 0.15s ease, box-shadow var(--crea-transition);
    letter-spacing: 0.02em;
}

.crea-login-btn:hover {
    background: #5d8244;
    box-shadow: 0 4px 12px rgba(111, 149, 83, 0.35);
    transform: translateY(-1px);
}

.crea-login-btn:active {
    transform: translateY(0);
}

.crea-login-btn i {
    font-size: 0.85em;
    transition: transform var(--crea-transition);
}

.crea-login-btn:hover i {
    transform: translateX(3px);
}

.crea-login-btn--secondary {
    background: var(--crea-secondary);
    color: var(--crea-text);
}

.crea-login-btn--secondary:hover {
    background: #e6dad0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.crea-login-extra {
    margin-bottom: 0.75rem;
}

/* Links */
.crea-login-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--crea-border);
}

.crea-login-links a {
    font-size: 0.875rem;
    color: var(--crea-primary);
    text-decoration: none;
    transition: color var(--crea-transition);
}

.crea-login-links a:hover {
    color: #5d8244;
    text-decoration: underline;
}

.crea-login-links__sep {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--crea-border);
    flex-shrink: 0;
}

/* Footer CTA */
.crea-login-footer {
    margin-top: 2rem;
    padding: 1.25rem;
    background: var(--crea-secondary);
    border-radius: 10px;
    text-align: center;
}

.crea-login-footer p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--crea-gray);
    line-height: 1.5;
}

.crea-login-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-weight: 600;
    color: var(--crea-primary) !important;
    text-decoration: none;
    margin-top: 0.25rem;
    transition: gap var(--crea-transition);
}

.crea-login-cta:hover {
    gap: 0.6rem;
    text-decoration: none;
}

/* Description text for reset pages */
.crea-login-description {
    font-size: 0.9rem;
    color: var(--crea-gray);
    line-height: 1.6;
    margin: 0 0 1.75rem;
}

/* Hide default Joomla chrome around login */
.com-users-login .page-header {
    display: none;
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
    #header-mobile,
    #footer-mobile,
    .offcanvas,
    .back-to-top,
    .offcanvas-toggler,
    .offcanvas-toggler-desktop {
        display: none !important;
    }

    body.site {
        padding: 0 !important;
    }

    .site-footer {
        background-color: transparent;
        color: var(--crea-text);
    }
}

/* ==========================================================================
   Dashboard - User Profile with Content Management
   ========================================================================== */

.crea-dashboard {
    max-width: 80%;
    min-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

@media (max-width: 1280px) {
    .crea-dashboard {
        max-width: 100%;
        min-width: 0;
    }
}

.crea-dashboard .page-header h1 {
    font-size: 1.8rem;
    color: var(--crea-text);
    margin-bottom: 1.5rem;
}

/* Two-column layout */
.crea-dashboard .row {
    --bs-gutter-x: 2rem;
}

/* Profile section */
.crea-dashboard__profile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    background: var(--crea-white);
    border-radius: 8px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.crea-dashboard__profile-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.crea-dashboard__avatar {
    font-size: 2.5rem;
    color: var(--crea-primary);
    line-height: 1;
}

.crea-dashboard__avatar + div {
    display: flex;
    flex-direction: column;
}

.crea-dashboard__username {
    font-size: 0.85rem;
    color: var(--crea-gray);
}

/* Toolbar */
.crea-dashboard__toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.crea-dashboard__section-title {
    font-size: 1.25rem;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.crea-dashboard__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--crea-primary);
    color: var(--crea-white);
    font-size: 0.8rem;
    font-weight: 600;
    min-width: 1.6rem;
    height: 1.6rem;
    border-radius: 999px;
    padding: 0 0.4rem;
}

.crea-dashboard__add-btn {
    white-space: nowrap;
}

/* Empty state */
.crea-dashboard__empty {
    text-align: center;
    padding: 3rem 1rem;
    background: var(--crea-white);
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.crea-dashboard__empty i {
    font-size: 3rem;
    color: var(--crea-border);
    margin-bottom: 1rem;
    display: block;
}

.crea-dashboard__empty p {
    color: var(--crea-gray);
    margin-bottom: 1.5rem;
}

/* Articles list */
.crea-dashboard__articles {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.crea-dashboard__article {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    background: var(--crea-white);
    border-radius: 8px;
    padding: 1rem 1.25rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    transition: box-shadow var(--crea-transition);
}

.crea-dashboard__article-thumb {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 6px;
    overflow: hidden;
}

.crea-dashboard__article-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.crea-dashboard__article:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}

.crea-dashboard__article--unpublished {
    border-left: 3px solid #f0ad4e;
    opacity: 0.85;
}

.crea-dashboard__article--locked {
    opacity: 0.6;
}

.crea-dashboard__article-main {
    flex: 1;
    min-width: 0;
}

.crea-dashboard__article-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.crea-dashboard__article-title a {
    color: var(--crea-text);
    text-decoration: none;
}

.crea-dashboard__article-title a:hover {
    color: var(--crea-primary);
}

.crea-dashboard__article-category {
    display: block;
    font-size: 0.8rem;
    color: var(--crea-gray, #888);
    margin-bottom: 0.25rem;
}

.crea-dashboard__article-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    font-size: 0.8rem;
}

.crea-dashboard__article-date {
    color: var(--crea-gray);
}

.crea-dashboard__article-date i {
    margin-right: 0.2rem;
}

.crea-dashboard__article-actions {
    display: flex;
    gap: 0.35rem;
    flex-shrink: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .crea-dashboard {
        padding: 0 1rem;
    }

    .crea-dashboard__profile {
        flex-direction: column;
        align-items: flex-start;
    }

    .crea-dashboard__article {
        flex-direction: column;
        align-items: flex-start;
    }

    .crea-dashboard__article-actions {
        width: 100%;
    }

    .crea-dashboard__article-actions .btn {
        flex: 1;
        text-align: center;
    }

    .crea-dashboard__article-actions .btn span {
        display: inline !important;
    }

    .crea-dashboard__tabs {
        flex-direction: column;
    }

    .crea-dashboard__tab {
        justify-content: center;
    }
}

/* Tabs */
.crea-dashboard__tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--crea-border, #e0e0e0);
    margin-bottom: 1.5rem;
}

.crea-dashboard__tab {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border: none;
    background: none;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--crea-gray, #888);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: color 0.2s, border-color 0.2s;
}

.crea-dashboard__tab:hover {
    color: var(--crea-text, #333);
}

.crea-dashboard__tab--active {
    color: var(--crea-primary);
    border-bottom-color: var(--crea-primary);
}

.crea-dashboard__tab .crea-dashboard__count {
    font-size: 0.75rem;
    min-width: 1.4rem;
    height: 1.4rem;
}

/* Tab panels */
.crea-dashboard__tab-panel--hidden {
    display: none;
}

/* Stats tab */
.crea-dashboard__stats-iframe-wrap {
    position: relative;
    width: 100%;
    padding-bottom: 65%;
    background: var(--crea-white, #fff);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.crea-dashboard__stats-iframe-wrap iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.crea-dashboard__stats-footer {
    margin-top: 1rem;
    text-align: right;
}
