/* Main Dashboard Styles */

/* Header Styles from includes/header.php */
:root {
    --text-color: #2D3748;
    --primary-color: #10B981;
    --primary-green: #008f4c;
    --bg-color: #F7FAFC;
    --border-color: #E2E8F0;
    --card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --hover-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --font-main: 'Poppins', sans-serif;
    --sidebar-width: 240px;
    --header-height: 70px;
    --text-muted: #7B7B7B;
}

body,
.dashboard-wrapper {
    font-family: var(--font-main);
    background-color: var(--bg-color);
    margin: 0;
    padding: 0;
    color: var(--text-color);
    overflow-x: hidden;
    box-sizing: border-box;
}

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

/* Layout Grid */
.dashboard-wrapper {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    grid-template-rows: var(--header-height) 1fr;
    grid-template-areas:
        "logo header"
        "sidebar content";
    min-height: 100vh;
}

/* LOGO & SIDEBAR */
.area-logo {
    grid-area: logo;
    background: #fff;
    display: flex;
    align-items: center;
    padding-left: 24px;
    border-bottom: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
}

.area-sidebar {
    grid-area: sidebar;
    background: #fff;
    border-right: 1px solid var(--border-color);
    padding: 20px 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

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

.nav-item {
    margin-bottom: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 12px 24px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 15px;
    font-weight: 300;
    transition: all 0.2s;
    gap: 12px;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-green);
    background: #f0fdf4;
    font-weight: 500;
    border-right: 3px solid var(--primary-green);
}

.nav-link i {
    font-size: 20px;
}

.help-banner {
    margin: 20px;
    background: #001f3f;
    border-radius: 12px;
    padding: 20px;
    color: #fff;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.help-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 45%, rgba(255, 255, 255, 0.1) 50%, transparent 55%);
    pointer-events: none;
}

/* HEADER */
.area-header {
    grid-area: header;
    background: #fff;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 30px;
}

.dashboard-crumb {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.global-search {
    position: relative;
    width: 400px;
}

.global-search input {
    width: 100%;
    background: #f5f5f5;
    border: none;
    padding: 10px 15px 10px 40px;
    border-radius: 6px;
    font-family: var(--font-main);
    font-size: 14px;
}

.global-search i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #aaa;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.credits-capsule {
    background: #f0fdf4;
    color: var(--primary-green);
    padding: 6px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* MAIN CONTENT AREA SHARED STYLES */
.area-content {
    grid-area: content;
    padding: 30px;
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 30px;
    align-items: start;
}

/* Dashboard Home Styles from dashboard.php */
.welcome-title {
    margin-top: 0;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
}

.action-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.action-card {
    background: #e6f7ef;
    padding: 20px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: transform 0.2s;
}

.action-card:hover {
    transform: translateY(-3px);
}

.action-card i {
    font-size: 24px;
    color: var(--primary-green);
}

.action-card.wide {
    grid-column: span 3;
}

.stats-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    border: 1px solid #eee;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.01);
}

.stat-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
}

.stat-value {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    display: flex;
    align-items: center;
    gap: 8px;
}

.stat-value i {
    font-size: 24px;
    color: gold;
}

.btn-buy-credits {
    background: var(--primary-green);
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 15px;
    font-size: 14px;
}

.favorites-section h3 {
    font-size: 16px;
    margin-bottom: 15px;
    color: #333;
}

.fav-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.fav-card {
    background: #fafafa;
    padding: 15px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid #eee;
}

.fav-card i {
    color: gold;
}

/* Right Sidebar specifics (dashboard.php) */
.activity-timeline {
    margin-top: 20px;
}

.activity-item {
    position: relative;
    padding-left: 20px;
    margin-bottom: 20px;
    border-left: 2px solid #eee;
}

.activity-dot {
    position: absolute;
    left: -6px;
    top: 0;
    width: 10px;
    height: 10px;
    background: var(--primary-green);
    border-radius: 50%;
}

.activity-text {
    font-size: 13px;
    color: #555;
    margin-bottom: 4px;
}

.activity-time {
    font-size: 11px;
    color: #999;
}

/* History View Styles from history-view.php */
.history-container {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.history-header h2 {
    margin: 0;
    font-size: 24px;
    color: var(--text-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.filter-form {
    display: flex;
    gap: 15px;
    align-items: center;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.filter-group label {
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.filter-input {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    color: #555;
    outline: none;
}

.filter-btn {
    background: var(--primary-green);
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    align-self: flex-end;
    transition: all 0.2s;
}

.filter-btn:hover {
    background: #007a40;
    transform: translateY(-1px);
}

.history-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.history-table th {
    text-align: left;
    padding: 15px;
    background: #f8f9fa;
    color: #666;
    font-weight: 600;
    font-size: 14px;
    border-bottom: 2px solid #eee;
}

.history-table td {
    padding: 15px;
    border-bottom: 1px solid #eee;
    font-size: 14px;
    color: #444;
    vertical-align: middle;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status-success {
    background: #e6f7ef;
    color: var(--primary-green);
}

.status-pending {
    background: #fff8e1;
    color: #f59e0b;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: #f0fdf4;
    color: var(--primary-green);
    border: 1px solid #d1f7e4;
    border-radius: 6px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
}

.action-btn:hover {
    background: var(--primary-green);
    color: #fff;
    border-color: var(--primary-green);
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #999;
}

/* Category View Specific Styles from category-view.php */
.category-header {
    margin-bottom: 30px;
}

.category-title {
    font-size: 24px;
    font-weight: 600;
    margin: 0 0 20px 0;
    color: #1a1a1a;
}

.category-toolbar {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 30px;
}

.category-search {
    flex: 1;
    position: relative;
    max-width: 400px;
}

.category-search input {
    width: 100%;
    padding: 10px 15px 10px 40px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: var(--font-main);
    font-size: 14px;
    background: #fff;
}

.category-search i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
}

.btn-consultar-green {
    background: var(--primary-green);
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.category-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 0;
}

.category-tab {
    padding: 12px 20px;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    position: relative;
    border-bottom: 2px solid transparent;
}

.category-tab:hover {
    color: var(--primary-green);
}

.category-tab.active {
    color: var(--primary-green);
    border-bottom-color: var(--primary-green);
}

/* Integration List Table */
.integration-table {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #eee;
}

.integration-header {
    display: grid;
    grid-template-columns: 3fr 1fr 1fr 1fr;
    padding: 16px 24px;
    background: #f9f9f9;
    font-size: 13px;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.integration-row {
    display: grid;
    grid-template-columns: 3fr 1fr 1fr 1fr;
    padding: 20px 24px;
    border-top: 1px solid #f0f0f0;
    align-items: center;
    transition: background 0.2s;
}

.integration-row:hover {
    background: #fafafa;
}

.integration-info {
    display: flex;
    align-items: center;
    gap: 16px;
}

.integration-icon {
    width: 48px;
    height: 48px;
    background: #e6f7ef;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.integration-icon i {
    font-size: 24px;
    color: var(--primary-green);
}

.integration-details {
    flex: 1;
}

.integration-name {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.integration-description {
    font-size: 13px;
    color: #777;
}

.integration-value {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 600;
    color: var(--primary-green);
}

.integration-value i {
    font-size: 18px;
}

.integration-type {
    font-size: 13px;
    color: #666;
}

.integration-date {
    font-size: 13px;
    color: #999;
}

/* Query Form Specific Styles from query-form.php */
.query-container {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
    border: 1px solid #eee;
}

.query-header {
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}

.query-breadcrumb {
    font-size: 13px;
    color: #777;
    margin-bottom: 12px;
}

.query-breadcrumb a {
    color: var(--primary-green);
    text-decoration: none;
}

.query-breadcrumb a:hover {
    text-decoration: underline;
}

.query-title {
    font-size: 28px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 10px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.query-title i {
    color: var(--primary-green);
    font-size: 32px;
}

.query-description {
    color: #666;
    font-size: 15px;
}

.query-meta {
    display: flex;
    gap: 30px;
    margin-top: 15px;
}

.query-meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #555;
}

.query-meta-item i {
    color: var(--primary-green);
}

.query-meta-item strong {
    color: var(--primary-green);
    font-weight: 600;
}

.query-form-section {
    margin-top: 30px;
}

.query-form-section h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 20px 0;
}

.form-wrapper {
    background: #f9f9f9;
    padding: 25px;
    border-radius: 8px;
    border: 1px solid #eee;
}

/* Enhance form styles from shortcodes */
.form-wrapper form {
    max-width: 600px;
}

.form-wrapper label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
    font-size: 14px;
}

.form-wrapper input,
.form-wrapper select,
.form-wrapper textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: var(--font-main);
    font-size: 14px;
    margin-bottom: 16px;
    background: #fff;
}

/* ... existing styles ... */

/* Bottom Navigation - Hidden on Desktop (Global Defaults) */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-top: 1px solid #eee;
    height: 70px;
    align-items: center;
    justify-content: space-around;
    z-index: 999;
    padding-bottom: env(safe-area-inset-bottom);
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #9CA3AF;
    text-decoration: none;
    font-size: 11px;
    gap: 4px;
    font-weight: 500;
}

.mobile-nav-item i {
    font-size: 24px;
}

.mobile-nav-item.active {
    color: var(--primary-green);
}

/* MOBILE RESPONSIVENESS */
@media (max-width: 768px) {

    /* Main Layout */
    .dashboard-wrapper {
        display: block;
        /* Stack everything */
        height: auto;
        min-height: 100vh;
        padding-bottom: 80px;
        /* Space for bottom nav */
    }

    /* Hide Desktop Sidebar */
    .area-sidebar {
        display: none !important;
    }

    /* Header Adjustments */
    .area-header {
        padding: 15px 20px;
        height: auto;
        flex-direction: column;
        gap: 15px;
        position: sticky;
        top: 0;
        z-index: 100;
    }

    .header-left {
        width: 100%;
        justify-content: space-between;
        gap: 15px;
    }

    /* Hide Breadcrumb text on mobile if needed, or adjust */
    .dashboard-crumb {
        display: none;
    }

    .mobile-logo {
        display: flex !important;
        grid-area: logo;
        /* Assign to the logo area in our new mobile grid */
    }

    /* Make Logo visible in header if we move it there, 
       but currently it's in .area-logo which is grid area 'logo'.
       We need to handle .area-logo visibility.
    */
    .area-logo {
        display: none;
        /* We might want to move logo to header-left for mobile */
    }

    /* Re-structure Header for Mobile: Logo Left, Credits Right, Search Below */
    .area-header {
        display: grid;
        grid-template-columns: 1fr auto;
        grid-template-areas:
            "logo credits"
            "search search";
        align-items: center;
        padding: 15px;
    }

    /* We need to inject the logo into the header or make .area-logo part of the flow.
       Since HTML structure is fixed, we might need a mobile-only logo in the header
       or adjust the grid areas. 
       Let's try to simulate the structure:
    */

    /* Reset areas for mobile block layout */
    .area-logo,
    .area-header,
    .area-sidebar,
    .area-content {
        grid-area: auto;
    }

    /* Force display:none on the separate logo area container to avoid duplication if we add one,
       OR style it to be the top bar. 
       Current HTML: .area-logo is separate. 
       Let's hide .area-logo and put a logo inside .area-header via JS or PHP, 
       OR just style .area-logo and .area-header to stack correctly.
    */
    .area-logo {
        display: flex;
        position: absolute;
        /* Hacky? No, let's just use flex order or display */
        border: none;
        padding: 10px 20px;
        width: auto;
        height: 60px;
        z-index: 101;
    }

    /* Actually, better approach: 
       Hide .area-logo.
       Show a mobile logo inside .header-left.
    */
    .area-logo {
        display: none;
    }

    .header-left {
        flex-direction: column;
        /* Search below */
        align-items: flex-start;
        display: contents;
        /* Let children flow in grid */
    }

    /* Global Search - Full Width below */
    .global-search {
        grid-area: search;
        width: 100%;
        margin-top: 10px;
    }

    .global-search input {
        width: 100%;
        background: #F3F4F6;
        border: none;
        padding: 12px 15px 12px 40px;
        border-radius: 8px;
        /* Softer radius */
    }

    /* Header Right - Credits */
    .header-right {
        grid-area: credits;
        gap: 10px;
    }

    .user-avatar {
        display: none;
        /* Hide avatar on mobile to save space? Image shows credits. */
    }

    .credits-capsule {
        background: #F0FDF4;
        /* Light green */
        border-radius: 20px;
        padding: 6px 12px;
        font-size: 13px;
    }

    /* Content Area */
    .area-content {
        display: block;
        /* Stack columns */
        padding: 20px;
        max-width: 100vw;
        overflow-x: hidden;
    }

    .dashboard-main {
        max-width: 100%;
    }

    /* Query Sidebar Spacing */
    .sidebar-wrapper {
        margin-top: 40px;
        margin-bottom: 80px;
        border-top: 1px solid #eee;
        padding-top: 30px;
    }

    /* Action Grid - 2 Columns Grid */
    .action-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
        padding-bottom: 0;
        margin-bottom: 25px;
        overflow-x: visible;
    }

    .action-card {
        width: 100%;
        padding: 20px 10px;
        font-size: 13px;
        flex: none;
        scroll-snap-align: none;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        height: 100%;
    }

    /* Integration Tables / Lists - Remove fixed width on mobile */
    .history-table,
    .integration-table,
    .integration-header,
    .integration-row {
        min-width: 0 !important;
        width: 100%;
    }

    /* Wrap tables in a scroll container if not already
       (We might need to add this wrapper via JS or PHP,
        but for now let's try to make the containers scrollable)
    */
    .history-container,
    .integration-table {
        overflow-x: auto;
        display: block;
        /* Ensure it behaves as a block for styling */
    }

    /* Adjust Integration Row for Mobile if we want stacking instead of scrolling */
    /* Alternatively, stack them for better UX */
    .integration-header {
        display: none;
        /* Hide headers on mobile */
    }

    .integration-row {
        display: flex;
        flex-direction: column;
        min-width: 0;
        /* Reset width */
        width: 100%;
        padding: 15px;
        gap: 10px;
        border-bottom: 1px solid #eee;
        position: relative;
        /* Context for absolute positioning */
    }

    .integration-info {
        width: 100%;
        padding-right: 90px;
        /* Space for credit value */
    }

    .integration-value {
        position: absolute;
        top: 15px;
        right: 10px;
        /* Reduced from 15px */
        font-size: 12px;
        /* Reduced from 14px */
        background: #f0fdf4;
        padding: 4px 8px;
        border-radius: 4px;
        max-width: 100px;
        /* Prevent it from getting too wide */
        text-align: right;
    }

    .integration-type,
    .integration-date {
        padding-left: 0;
        margin-top: 2px;
        font-size: 11px;
        color: #999;
        align-self: flex-end;
        /* Push to right in flex column */
        text-align: right;
    }

    /* Re-arrange grid columns for the row items */
    .integration-table .integration-row>div {
        /* This selects the direct children of the grid-turned-flex row */
        text-align: left;
    }

    /* Sidebar Items (Category Sidebar) */
    .sidebar-item-desc {
        -webkit-line-clamp: 2;
    }

    /* Category View Mobile Adjustments */
    .category-toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }

    .btn-consultar-green {
        justify-content: center;
        width: 100%;
    }

    .category-tabs {
        overflow-x: auto;
        white-space: nowrap;
        padding-bottom: 5px;
    }

    .category-tab {
        flex-shrink: 0;
    }

    /* Remove previous grid definition for integration-row inside media query if it conflicts */


    .action-card i {
        background: #E6F7EF;
        /* Green circle bg */
        width: 50px;
        height: 50px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 24px;
        color: var(--primary-green);
        margin-bottom: 5px;
    }

    /* Special colors for specific icons if needed */
    /* .action-card:nth-child(2) i { color: ... } */

    /* Stats Grid */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .stat-card {
        padding: 15px;
        border-radius: 16px;
        /* Increased radius */
        box-shadow: none;
        border: 1px solid #F0F0F0;
    }

    .stat-title {
        font-size: 13px;
        color: #1a1a1a;
        font-weight: 700;
        /* Bolder */
    }

    .stat-value {
        font-size: 20px;
        margin-top: 5px;
    }

    .btn-buy-credits {
        width: 100%;
        justify-content: center;
        font-size: 12px;
        padding: 8px;
        margin-top: 10px;
    }

    /* Favorites Grid */
    .fav-grid {
        grid-template-columns: 1fr;
    }

    .fav-card {
        font-size: 12px;
        justify-content: space-between;
    }

    /* Right Sidebar (Activity) - Move below */
    .right-sidebar {
        margin-top: 30px;
    }

    /* Bottom Navigation */
    .mobile-bottom-nav {
        display: flex;
    }

    /* Hide specific span in mobile logo to prevent double text if SVG has text */
    .mobile-logo span {
        display: none;
    }
}



.form-wrapper input:focus,
.form-wrapper select:focus,
.form-wrapper textarea:focus {
    outline: none;
    border-color: var(--primary-green);
}

.form-wrapper button[type="submit"] {
    background: var(--primary-green) !important;
    color: #fff !important;
    border: none !important;
    padding: 12px 30px !important;
    border-radius: 6px !important;
    font-weight: 500 !important;
    cursor: pointer !important;
    font-size: 15px !important;
    margin-top: 10px !important;
}

.form-wrapper button[type="submit"]:hover {
    background: #007a41 !important;
}

.result-section {
    margin-top: 30px;
}

/* Category Sidebar Styles from category-sidebar.php */
.category-sidebar {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
    border: 1px solid #eee;
    position: sticky;
    top: 20px;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
}

.category-sidebar h3 {
    margin: 0 0 20px 0;
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
}

.sidebar-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.sidebar-tab {
    padding: 8px 16px;
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
}

.sidebar-tab:hover {
    background: #e8f5e9;
    color: var(--primary-green);
    border-color: var(--primary-green);
}

.sidebar-tab.active {
    background: var(--primary-green);
    color: #fff;
    border-color: var(--primary-green);
}

.sidebar-search {
    position: relative;
    margin-bottom: 20px;
}

.sidebar-search input {
    width: 100%;
    padding: 10px 15px 10px 35px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 13px;
    font-family: var(--font-main);
}

.sidebar-search input:focus {
    outline: none;
    border-color: var(--primary-green);
}

.sidebar-search i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 14px;
}

.sidebar-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sidebar-item {
    padding: 12px;
    border: 1px solid #eee;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    color: inherit;
    display: block;
}

.sidebar-item:hover {
    border-color: var(--primary-green);
    background: #f9fffe;
    transform: translateX(2px);
}

.sidebar-item.active {
    border-color: var(--primary-green);
    background: #f0fdf4;
}

.sidebar-item-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
}

.sidebar-item-icon {
    color: var(--primary-green);
    font-size: 18px;
    flex-shrink: 0;
}

.sidebar-item-name {
    font-size: 14px;
    font-weight: 500;
    color: #1a1a1a;
    flex: 1;
}

.sidebar-item-desc {
    font-size: 12px;
    color: #666;
    line-height: 1.4;
    margin: 0 0 8px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.sidebar-item-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.sidebar-item-value {
    font-size: 11px;
    color: #777;
    display: flex;
    align-items: center;
    gap: 4px;
}

.sidebar-item-btn {
    background: var(--primary-green);
    color: #fff;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.sidebar-item-btn:hover {
    background: #007a41;
}

.sidebar-item.active .sidebar-item-btn {
    background: #007a41;
}

.result-section h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 15px 0;
}

/* WordPress Admin Bar Compatibility */
body.admin-bar .dashboard-wrapper {
    min-height: calc(100vh - 32px);
    position: relative;
    top: 0;
}

@media screen and (max-width: 782px) {
    body.admin-bar .dashboard-wrapper {
        min-height: calc(100vh - 46px);
        margin-top: 0;
        /* WordPress adds margin to html, not body usually, but safe to reset */
    }
}

/* Mobile Highlighted Nav Item (FAB style with Text) */
.mobile-nav-item.nav-highlight {
    position: relative;
    color: var(--primary-green);
    overflow: visible;
    /* Allow icon to overflow upwards */
}

.mobile-nav-item.nav-highlight i {
    position: absolute;
    top: -25px;
    left: 50%;
    transform: translateX(-50%);
    background: #DCFCE7;
    /* Light green background */
    border: 4px solid white;
    /* Border to separate from bar */
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.05);
    font-size: 24px;
    margin-bottom: 0;
    z-index: 10;
}

.mobile-nav-item.nav-highlight span {
    display: block;
    /* Show text */
    margin-top: 28px;
    /* Push text down to clear the floating icon */
    font-size: 10px;
    font-weight: 500;
}

.mobile-nav-item.active {
    color: var(--primary-green);
}