/* ========================================================
   CAREXPLORER GEMINI V3 - FUSION DESIGN PREMIUM
   Merge: Gemini V2 aesthetics + search-chat.html functionality
======================================================== */

/* ========== VARIABLES ========== */
:root {
    /* Couleurs principales */
    --bg-main: #0F0F1A;
    --bg-card: rgba(26, 26, 46, 0.8);
    --bg-sidebar: rgba(12, 12, 20, 0.95);

    /* Accents - Violet */
    --primary: #ffffff;
    --accent: #D285FF;
    --accent-hover: #c066f7;
    --accent-glow: rgba(210, 133, 255, 0.3);

    /* Textes */
    --text-main: #ffffff;
    --text-secondary: #888888;
    --text-muted: #555555;

    /* Bordures */
    --border-light: rgba(64, 64, 112, 0.5);
    --border-hover: rgba(255, 255, 255, 0.15);

    /* Radius */
    --radius-xl: 24px;
    --radius-l: 20px;
    --radius-m: 16px;
    --radius-s: 12px;
    --radius-full: 50px;

    /* Fonts - Inter uniquement */
    --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

    /* Sidebar */
    --sidebar-width: 280px;
}

/* ========== RESET ========== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    background-color: #080810;
    color: var(--text-main);
    font-family: var(--font-body);
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.5;
}

button, input, select {
    font-family: inherit;
}

a {
    text-decoration: none;
    color: inherit;
}

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

/* ========== ANIMATIONS ========== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(30px, -30px); }
}

/* Animation des 3 points de typing - EXACTE de search-chat.html */
@keyframes ce-typing {
    0%, 60%, 100% { transform: translateY(0); }
    30% { transform: translateY(-4px); }
}

@keyframes ce-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* ========== BACKGROUND ========== */
.ce-bg-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

/* Canvas étoiles */
#ce-stars-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Blobs violet */
.ce-gradient-blob {
    position: fixed;
    border-radius: 50%;
    filter: blur(200px);
    opacity: 0.08;
    pointer-events: none;
}

/* Noise */
.ce-noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.05'/%3E%3C/svg%3E");
    opacity: 0.1;
    pointer-events: none;
}

.blob-1 {
    width: 600px;
    height: 600px;
    background: #8b5cf6;
    top: -200px;
    left: 20%;
    animation: float 15s infinite ease-in-out;
}

.blob-2 {
    width: 500px;
    height: 500px;
    background: #a855f7;
    bottom: -100px;
    right: 10%;
    animation: float 12s infinite ease-in-out reverse;
}

/* ========== NAVBAR (Homepage) ========== */
.ce-navbar {
    position: fixed;
    top: 16px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    z-index: 100;
    padding: 0 16px;
}

.ce-navbar-content {
    background: rgba(15, 15, 26, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 40px;
    padding: 8px 12px 8px 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.ce-logo {
    display: flex;
    align-items: center;
}

.ce-logo-svg {
    height: 20px;
    width: auto;
}

.ce-nav-links {
    display: flex;
    gap: 2px;
}

.ce-link {
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    padding: 6px 12px;
    border-radius: 20px;
    transition: all 0.2s;
}

.ce-link:hover,
.ce-link.active {
    color: white;
    background: rgba(255, 255, 255, 0.08);
}

.ce-nav-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.ce-btn-ghost {
    color: #080810;
    font-size: 13px;
    font-weight: 600;
    padding: 8px 16px;
    background: #ffffff;
    border-radius: 20px;
    transition: all 0.2s;
    white-space: nowrap;
}

.ce-btn-ghost:hover {
    background: rgba(255, 255, 255, 0.9);
    transform: scale(1.02);
}

.ce-mobile-trigger {
    display: none;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    width: 36px;
    height: 36px;
    color: white;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.ce-mobile-trigger:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* ========== MOBILE MENU ========== */
.ce-mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 280px;
    background: rgba(15, 15, 26, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-left: 1px solid var(--border-light);
    z-index: 200;
    padding: 20px;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.ce-mobile-menu.open {
    transform: translateX(0);
}

.ce-mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.ce-mobile-menu-title {
    font-size: 18px;
    font-weight: 700;
    font-family: var(--font-heading);
}

.ce-mobile-close {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    width: 36px;
    height: 36px;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ce-mobile-menu-links {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ce-mobile-link {
    color: var(--text-secondary);
    font-size: 16px;
    font-weight: 500;
    padding: 12px 16px;
    border-radius: 12px;
    transition: all 0.2s;
}

.ce-mobile-link:hover,
.ce-mobile-link.active {
    color: white;
    background: rgba(255, 255, 255, 0.05);
}

.ce-mobile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 199;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.ce-mobile-overlay.open {
    opacity: 1;
    pointer-events: all;
}

/* ========== HOMEPAGE HERO ========== */
.ce-page-content {
    padding-top: 220px;
    display: flex;
    justify-content: center;
    width: 100%;
    min-height: 100vh;
}

.ce-container {
    width: 100%;
    max-width: 1000px;
    padding: 0 20px;
}

.ce-hero-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    animation: fadeIn 0.8s ease-out;
}

/* Badge */
.ce-badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    border-radius: 100px;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 24px;
    transition: border-color 0.2s;
    cursor: default;
}

.ce-badge-pill:hover {
    border-color: var(--border-hover);
}

.ce-badge-new {
    background: var(--accent);
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

/* Typography */
.ce-title-display {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 20px;
}

.text-gradient {
    background: linear-gradient(to right, #ffffff 40%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.ce-subtitle-text {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--text-secondary);
    line-height: 1.6;
    max-width: 600px;
    margin-bottom: 40px;
    font-weight: 400;
}

/* ========== SEARCH CARD ========== */
.glass-card {
    background: rgba(26, 26, 46, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 8px;
    width: 100%;
    max-width: 700px;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s, border-color 0.3s;
}

.glass-card:focus-within {
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* Tabs */
.ce-search-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 8px;
    padding-left: 8px;
}

.ce-tab-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    padding: 6px 12px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s;
}

.ce-tab-btn:hover {
    color: white;
    background: rgba(255, 255, 255, 0.05);
}

.ce-tab-btn.active {
    color: white;
    background: rgba(255, 255, 255, 0.1);
}

.ce-tab-content {
    display: none;
}

.ce-tab-content.active {
    display: block;
}

/* Input Area */
.ce-input-area {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 18px;
    display: flex;
    align-items: center;
    padding: 6px 6px 6px 20px;
    border: 1px solid transparent;
    transition: border-color 0.2s;
}

.ce-input-area:focus-within {
    border-color: var(--accent);
}

.ce-input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 12px;
}

.ce-search-icon {
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
    flex-shrink: 0;
}

.ce-input-wrapper input {
    width: 100%;
    background: none;
    border: none;
    color: white;
    font-size: 16px;
    outline: none;
}

.ce-input-wrapper input::placeholder {
    color: #525252;
}

.ce-search-submit {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: var(--accent);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all 0.2s;
    flex-shrink: 0;
}

.ce-search-submit:hover {
    background: var(--accent-hover);
    transform: scale(1.05);
}

/* Quick Filters / Suggestions */
.ce-quick-filters {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 12px 6px 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.ce-quick-filters::-webkit-scrollbar {
    display: none;
}

.ce-filters-label {
    font-size: 12px;
    color: var(--text-muted);
    white-space: nowrap;
    flex-shrink: 0;
}

.ce-tags-scroll {
    display: flex;
    gap: 8px;
}

.ce-tag {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-light);
    color: var(--text-secondary);
    padding: 8px 14px;
    border-radius: var(--radius-full);
    font-size: 13px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s;
}

.ce-tag:hover {
    background: rgba(59, 130, 246, 0.15);
    color: white;
    border-color: var(--accent);
}

/* Criteria Grid (Filters Tab) */
.ce-criteria-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 12px;
}

.ce-criteria-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ce-criteria-item.full-width {
    grid-column: 1 / -1;
}

.ce-criteria-item label {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}

.ce-select {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    color: white;
    padding: 10px 12px;
    font-size: 14px;
    outline: none;
    cursor: pointer;
    transition: all 0.2s;
    appearance: none;
    -webkit-appearance: none;
}

.ce-select:hover {
    border-color: var(--border-hover);
}

.ce-select:focus {
    border-color: var(--accent);
}

.ce-select option {
    background: var(--bg-main);
    color: white;
}

.ce-slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.ce-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.ce-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    border: none;
}

.ce-btn-search {
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 14px;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 12px;
    transition: all 0.2s;
}

.ce-btn-search:hover {
    background: var(--accent-hover);
    transform: scale(1.02);
}

/* Social Proof */
.ce-social-proof {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 40px;
    opacity: 0.6;
    transition: opacity 0.3s;
}

.ce-social-proof:hover {
    opacity: 1;
}

.ce-avatars {
    display: flex;
}

.ce-avatars img {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid var(--bg-main);
    margin-left: -8px;
}

.ce-avatars img:first-child {
    margin-left: 0;
}

.ce-proof-text {
    font-size: 15px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.ce-proof-text .highlight {
    color: white;
    font-weight: 700;
    font-size: 18px;
}

.ce-proof-emoji {
    font-size: 18px;
}

/* ========================================================
   LISTING PAGE LAYOUT
======================================================== */
.listing-page {
    overflow: hidden;
}

.listing-page .ce-bg-layer {
    z-index: 0;
}

.ce-listing-layout {
    display: flex;
    min-height: 100vh;
    position: relative;
}

/* ========== SIDEBAR ========== */
.ce-sidebar {
    width: var(--sidebar-width);
    background: var(--bg-sidebar);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-right: 1px solid var(--border-light);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 50;
    transition: transform 0.3s ease;
}

.ce-sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.ce-sidebar-logo .ce-logo-svg {
    height: 22px;
    width: auto;
}

.ce-sidebar-close {
    display: none;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    width: 32px;
    height: 32px;
    color: white;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}

.ce-sidebar-nav {
    flex: 1;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow-y: auto;
}

.ce-sidebar-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    color: white;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    width: 100%;
    text-align: left;
}

.ce-sidebar-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--border-hover);
}

.ce-new-search-btn {
    background: linear-gradient(135deg, var(--accent), #818cf8);
    border: none;
}

.ce-new-search-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px var(--accent-glow);
}

.ce-sidebar-section {
    margin-top: 8px;
}

.ce-sidebar-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
    padding: 0 4px;
    margin-bottom: 8px;
    display: block;
}

.ce-sidebar-history {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ce-sidebar-history-item {
    padding: 10px 12px;
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ce-sidebar-history-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: white;
}

.ce-sidebar-footer {
    padding: 16px;
    border-top: 1px solid var(--border-light);
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ce-sidebar-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 14px;
    transition: all 0.2s;
}

.ce-sidebar-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: white;
}

/* Sidebar Overlay */
.ce-sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 40;
}

.ce-sidebar-overlay.open {
    display: block;
}

/* ========== MAIN CONTENT ========== */
.ce-main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin-left: var(--sidebar-width);
    position: relative;
}

/* Header */
.ce-listing-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border-light);
    background: rgba(15, 15, 26, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 30;
}

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

.ce-sidebar-toggle {
    display: none;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    width: 36px;
    height: 36px;
    color: white;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}

.ce-sidebar-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

.ce-header-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ce-header-title {
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 600;
    color: white;
}

.ce-header-subtitle {
    font-size: 13px;
    color: var(--text-secondary);
}

/* ========== CHAT AREA ========== */
.ce-chat-wrapper {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    padding-bottom: 180px;
}

.ce-messages {
    display: flex;
    flex-direction: column;
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

/* Message utilisateur */
.ce-message-user {
    align-self: flex-end;
    max-width: 75%;
    background: rgba(26, 26, 46, 0.9);
    color: #fff;
    padding: 14px 20px;
    border-radius: 20px 20px 4px 20px;
    font-size: 15px;
    animation: slideUp 0.3s ease;
    border: 1px solid var(--border-light);
}

/* Message assistant - SANS bulle (comme search-chat.html) */
.ce-message-assistant {
    align-self: flex-start;
    max-width: 100%;
    animation: slideUp 0.3s ease;
}

.ce-message-assistant-content {
    font-size: 15px;
    color: #e0e0e0;
    line-height: 1.7;
    margin-bottom: 20px;
}

/* Typewriter cursor */
.ce-typewriter-cursor {
    display: inline-block;
    width: 2px;
    height: 1em;
    background: var(--accent);
    margin-left: 2px;
    animation: ce-blink 0.7s infinite;
    vertical-align: text-bottom;
}

/* ========== TYPING INDICATOR - EXACT de search-chat.html ========== */
.ce-typing {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 0;
}

.ce-typing-dot {
    width: 8px;
    height: 8px;
    background: #444;
    border-radius: 50%;
    animation: ce-typing 1s ease-in-out infinite;
}

.ce-typing-dot:nth-child(2) {
    animation-delay: 0.15s;
}

.ce-typing-dot:nth-child(3) {
    animation-delay: 0.3s;
}

/* ========== CARDS PREMIUM - Design search-chat.html ========== */
.ce-chat-annonces {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 16px;
}

.ce-chat-annonces.autres {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.ce-chat-annonces.autres .ce-chat-card {
    transform: scale(0.95);
}

/* Card principale - EXACT de search-chat.html */
.ce-chat-card {
    background: linear-gradient(145deg, #1a1a1c 0%, #131314 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-l);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.ce-chat-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
}

/* Image container */
.ce-chat-card-image {
    position: relative;
    height: 160px;
    background: #0d0d0e;
    overflow: hidden;
    border-radius: var(--radius-l) var(--radius-l) 0 0;
}

.ce-chat-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.ce-chat-card:hover .ce-chat-card-image img {
    transform: scale(1.05);
}

/* Badge compteur images */
.ce-card-image-count {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Body card */
.ce-chat-card-body {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Header: Titre + Prix */
.ce-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
}

.ce-card-title-wrap {
    flex: 1;
    min-width: 0;
}

.ce-chat-card-title {
    font-family: var(--font-heading);
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

.ce-chat-card-finition {
    font-size: 12px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.5);
    margin: 2px 0 0 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ce-chat-card-price {
    font-family: var(--font-heading);
    font-size: 17px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    white-space: nowrap;
}

/* Specs grid avec icônes */
.ce-card-specs-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 12px;
}

.ce-card-spec {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.ce-card-spec-icon {
    width: 14px;
    height: 14px;
    opacity: 0.7;
    flex-shrink: 0;
}

.ce-card-spec-value {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Footer: Source + Badge vendeur */
.ce-card-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.ce-card-source-logo {
    height: 15px;
    width: auto;
    max-width: 70px;
}

.ce-card-vendor-badge {
    height: 18px;
    width: auto;
    max-width: 80px;
}

/* Bouton like */
.ce-card-like-btn {
    margin-left: auto;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.ce-card-like-btn svg {
    width: 16px;
    height: 16px;
    stroke: rgba(255, 255, 255, 0.5);
    fill: none;
    transition: all 0.2s;
}

.ce-card-like-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.ce-card-like-btn:hover svg {
    stroke: #f87171;
}

.ce-card-like-btn.liked svg {
    stroke: #f87171;
    fill: #f87171;
}

/* Section autres annonces */
.ce-autres-section {
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.ce-autres-title {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
    margin: 0 0 16px 0;
    font-weight: 500;
}

/* ========== CHAT INPUT FOOTER ========== */
.ce-chat-footer {
    position: fixed;
    bottom: 0;
    left: var(--sidebar-width);
    right: 0;
    padding: 16px 24px 24px;
    background: linear-gradient(to top, var(--bg-main) 60%, transparent);
    z-index: 20;
}

.ce-chat-suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.ce-chat-suggestion {
    background: rgba(26, 26, 46, 0.9);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-full);
    padding: 10px 14px;
    color: var(--text-secondary);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.ce-chat-suggestion:hover {
    background: rgba(59, 130, 246, 0.15);
    color: white;
    border-color: var(--accent);
}

.ce-chat-input-bar {
    display: flex;
    align-items: center;
    height: 56px;
    background: rgba(26, 26, 46, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-full);
    padding: 4px 4px 4px 24px;
    max-width: 900px;
    margin: 0 auto;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
    transition: border-color 0.2s;
}

.ce-chat-input-bar:focus-within {
    border-color: var(--accent);
}

.ce-chat-input {
    flex: 1;
    height: 100%;
    background: transparent;
    border: none;
    color: #ffffff;
    font-size: 15px;
    outline: none;
}

.ce-chat-input::placeholder {
    color: var(--text-secondary);
}

.ce-chat-send-btn {
    width: 48px;
    height: 48px;
    min-width: 48px;
    background: var(--accent);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
}

.ce-chat-send-btn:hover {
    background: var(--accent-hover);
    transform: scale(1.05);
}

.ce-chat-send-btn:disabled {
    background: #333;
    cursor: not-allowed;
    opacity: 0.5;
}

.ce-send-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1100px) {
    .ce-chat-annonces {
        grid-template-columns: repeat(2, 1fr);
    }
    .ce-chat-annonces.autres {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 900px) {
    .ce-chat-annonces,
    .ce-chat-annonces.autres {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    .ce-chat-card-image {
        height: 140px;
    }
}

@media (max-width: 768px) {
    /* Navbar mobile */
    .ce-navbar {
        top: 10px;
        padding: 0 16px;
    }

    .ce-navbar-content {
        padding: 8px 12px 8px 16px;
        width: 100%;
        display: flex;
        justify-content: space-between;
    }

    .ce-nav-links {
        display: none;
    }

    .ce-nav-actions {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-shrink: 0;
    }

    .ce-mobile-trigger {
        display: flex;
    }

    /* Bouton Connexion visible sur mobile */
    .ce-btn-ghost {
        display: block;
        padding: 6px 14px;
        font-size: 12px;
    }

    /* Container et contenu */
    .ce-page-content {
        padding-top: 130px;
    }

    .ce-container {
        padding: 0 20px;
    }

    .ce-hero-wrapper {
        padding: 0 4px;
    }

    .ce-title-display {
        font-size: 1.85rem;
        line-height: 1.2;
    }

    .ce-subtitle-text {
        font-size: 0.9rem;
        padding: 0 8px;
    }

    /* Badge */
    .ce-badge-pill {
        font-size: 11px;
        padding: 5px 10px;
        gap: 6px;
    }

    .ce-badge-new {
        font-size: 9px;
        padding: 2px 6px;
    }

    /* Search card */
    .ce-search-container {
        margin: 0;
    }

    .glass-card {
        padding: 6px;
        border-radius: 20px;
    }

    .ce-search-tabs {
        gap: 4px;
        padding: 4px;
    }

    .ce-tab-btn {
        font-size: 12px;
        padding: 8px 14px;
    }

    .ce-input-area {
        padding: 6px 6px 6px 12px;
    }

    #ce-main-input {
        font-size: 14px;
    }

    #ce-main-input::placeholder {
        font-size: 13px;
    }

    .ce-search-submit {
        width: 40px;
        height: 40px;
    }

    .ce-quick-filters {
        padding: 12px 12px 8px;
    }

    .ce-filters-label {
        font-size: 11px;
    }

    .ce-tag {
        font-size: 11px;
        padding: 6px 10px;
    }

    .ce-criteria-grid {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 12px;
    }

    .ce-criteria-item label {
        font-size: 12px;
    }

    .ce-select {
        font-size: 14px;
        padding: 10px 12px;
    }

    .ce-btn-search {
        font-size: 14px;
        padding: 12px 20px;
        margin: 12px;
    }

    /* Stats */
    .ce-social-proof {
        margin-top: 24px;
    }

    .ce-proof-text {
        font-size: 13px;
    }

    .ce-proof-text .highlight {
        font-size: 16px;
    }

    /* Menu mobile pleine largeur */
    .ce-mobile-menu {
        width: 100%;
        left: 0;
        right: 0;
        border-left: none;
        padding: 20px;
    }

    .ce-mobile-menu-header {
        margin-bottom: 24px;
    }

    .ce-mobile-menu-links {
        gap: 8px;
    }

    .ce-mobile-link {
        font-size: 18px;
        padding: 16px 20px;
        text-align: center;
        background: rgba(255, 255, 255, 0.03);
        border-radius: 16px;
    }

    .ce-mobile-link.active {
        background: rgba(255, 255, 255, 0.08);
    }

    /* Listing page mobile */
    .ce-sidebar {
        transform: translateX(-100%);
    }

    .ce-sidebar.open {
        transform: translateX(0);
    }

    .ce-sidebar-close {
        display: flex;
    }

    .ce-main-content {
        margin-left: 0;
    }

    .ce-sidebar-toggle {
        display: flex;
    }

    .ce-chat-footer {
        left: 0;
        padding: 12px 16px 16px;
    }

    .ce-listing-header {
        padding: 12px 16px;
    }

    .ce-header-title {
        font-size: 18px;
    }

    .ce-chat-wrapper {
        padding: 16px;
        padding-bottom: 200px;
    }

    .ce-message-user {
        max-width: 85%;
        font-size: 14px;
    }

    .ce-message-assistant-content {
        font-size: 14px;
    }

    .ce-chat-annonces,
    .ce-chat-annonces.autres {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .ce-chat-annonces.autres .ce-chat-card {
        transform: scale(1);
    }

    .ce-chat-card {
        border-radius: var(--radius-m);
    }

    .ce-chat-card-image {
        height: 200px;
        border-radius: var(--radius-m) var(--radius-m) 0 0;
    }

    .ce-chat-card-body {
        padding: 14px;
    }

    .ce-chat-card-title {
        font-size: 16px;
    }

    .ce-chat-card-finition {
        font-size: 13px;
    }

    .ce-chat-card-price {
        font-size: 18px;
    }

    .ce-card-specs-grid {
        gap: 8px 16px;
    }

    .ce-card-spec {
        font-size: 13px;
    }

    .ce-card-spec-icon {
        width: 16px;
        height: 16px;
    }

    .ce-chat-suggestions {
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 4px;
    }

    .ce-chat-suggestions::-webkit-scrollbar {
        display: none;
    }

    .blob-1,
    .blob-2 {
        width: 300px;
        height: 300px;
        filter: blur(60px);
    }
}

@media (max-width: 400px) {
    .ce-chat-card-image {
        height: 180px;
    }

    /* Très petits écrans */
    .ce-page-content {
        padding-top: 120px;
    }

    .ce-container {
        padding: 0 16px;
    }

    .ce-title-display {
        font-size: 1.6rem;
    }

    .ce-subtitle-text {
        font-size: 0.85rem;
    }

    .ce-btn-ghost {
        padding: 5px 12px;
        font-size: 11px;
    }

    .ce-logo-svg {
        height: 18px;
    }

    .ce-mobile-trigger {
        width: 32px;
        height: 32px;
    }

    .ce-mobile-trigger svg {
        width: 20px;
        height: 20px;
    }
}

/* ========== MODÈLES SUGGÉRÉS ========== */
.ce-modeles-suggeres {
    margin-top: 16px;
    padding: 14px 18px;
    background: rgba(210, 133, 255, 0.08);
    border-radius: 12px;
    border-left: 3px solid var(--accent);
}

.ce-modeles-suggeres-title {
    font-size: 0.85em;
    color: var(--accent);
    margin-bottom: 8px;
    font-weight: 600;
}

.ce-modeles-suggeres-list {
    font-size: 0.9em;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.6;
}
