@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Space+Mono:ital,wght@0,400;0,700;1,400&family=Unbounded:wght@700;800;900&display=swap');

:root {
    --bg-void: #060709;
    --surface-graphite: #12151D;
    --card-bottom: #0E1017;
    --laser-orange: #FF5426;
    --amber-phosphor: #FFA23A;
    --emerald-bargain: #10B981;
    --speculative-red: #EF4444;
    --steel-fade: #7E889B;
    --chalk-white: #FFFFFF;
}

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

html, body {
    background-color: var(--bg-void) !important;
    color: #F3F4F6 !important;
    font-family: 'Inter', sans-serif !important;
    max-width: 100vw !important;
    min-height: 100vh !important;
    min-height: 100dvh !important;
    overflow-x: hidden !important;
}

.meso-app-wrapper {
    max-width: 1380px;
    min-height: 100vh;
    min-height: 100dvh;
    margin: 0 auto;
    padding: 16px 16px 20px 16px;
    display: flex;
    flex-direction: column;
}

/* 1. Top Header */
.meso-top-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 18px;
}

.brand-block {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none !important;
    cursor: pointer !important;
    user-select: none;
    transition: opacity 0.15s ease;
}
.brand-block:hover { opacity: 0.85; }

.brand-logo-img {
    height: 42px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 0 12px rgba(255, 84, 38, 0.3));
}

.brand-title {
    font-family: 'Unbounded', sans-serif;
    font-size: 1.55rem;
    font-weight: 900;
    letter-spacing: -0.04em;
    display: flex;
    align-items: center;
}

.brand-solid { color: #FFFFFF; }
.brand-wireframe {
    color: transparent;
    -webkit-text-stroke: 1.5px #7E889B;
    margin-left: 2px;
}

.brand-sys-tag {
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    color: var(--steel-fade);
    padding: 2px 6px;
    border: 1px solid rgba(126, 136, 155, 0.25);
    border-radius: 4px;
    margin-left: 10px;
}

/* 2. Category HUD Grid */
.category-chip-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
    margin-bottom: 12px;
    width: 100%;
}

.cat-chip {
    background: var(--surface-graphite);
    border: 1px solid rgba(126, 136, 155, 0.22);
    color: var(--steel-fade);
    padding: 6px 4px;
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: all 0.15s ease;
}

.cat-chip:hover {
    color: #FFFFFF;
    border-color: var(--laser-orange);
}

.cat-chip.active {
    background: rgba(255, 84, 38, 0.14);
    border-color: var(--laser-orange);
    color: #FFFFFF;
    box-shadow: 0 0 10px rgba(255, 84, 38, 0.22);
}

.cat-chip svg {
    width: 14px !important;
    height: 14px !important;
    min-width: 14px !important;
    min-height: 14px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    flex-shrink: 0 !important;
    display: inline-block !important;
    vertical-align: middle !important;
    transition: stroke 0.15s ease;
}

.cat-chip svg * {
    fill: none !important;
    stroke: currentColor !important;
}

.cat-chip:hover svg { stroke: #FFFFFF !important; }
.cat-chip.active svg { stroke: var(--laser-orange) !important; }

.lbl-short { display: none; }
.lbl-full { display: inline; }

/* 3. Search Bar */
.search-form-block {
    margin-bottom: 14px;
    width: 100%;
}

.search-bar-inner {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.search-icon-slot {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

#query {
    width: 100% !important;
    height: 48px !important;
    min-height: 48px !important;
    background-color: var(--surface-graphite) !important;
    border: 1px solid rgba(126, 136, 155, 0.28) !important;
    border-radius: 8px !important;
    padding-left: 46px !important;
    padding-right: 120px !important;
    color: #FFFFFF !important;
    font-family: 'Inter', sans-serif !important;
    font-size: 0.95rem !important;
    outline: none !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

#query:focus {
    border-color: var(--laser-orange) !important;
    box-shadow: 0 0 0 1px var(--laser-orange) !important;
}

#query::placeholder {
    font-family: 'Space Mono', monospace !important;
    color: var(--steel-fade) !important;
    opacity: 0.8 !important;
    letter-spacing: 0.04em !important;
}

.search-action-btn {
    position: absolute;
    right: 4px;
    top: 4px;
    bottom: 4px;
    padding: 0 20px;
    background: linear-gradient(135deg, #FF5426 0%, #D83C12 100%);
    border: none;
    border-radius: 6px;
    color: #FFFFFF;
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(255, 84, 38, 0.35);
    transition: transform 0.15s ease;
}
.search-action-btn:hover { transform: scale(1.02); }

/* 4. Preferences Drawer */
.preferences-expander {
    background: rgba(18, 21, 29, 0.65);
    border: 1px solid rgba(126, 136, 155, 0.18);
    border-radius: 8px;
    margin-bottom: 20px;
    overflow: visible !important;
    transition: border-color 0.12s ease, box-shadow 0.12s ease;
}

.preferences-expander.open {
    border-color: rgba(255, 84, 38, 0.4) !important;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45);
}

.preferences-summary {
    padding: 10px 14px;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    user-select: none !important;
    -webkit-user-select: none !important;
    touch-action: manipulation !important;
    outline: none !important;
    -webkit-tap-highlight-color: transparent !important;
}

.preferences-summary * {
    user-select: none !important;
    -webkit-user-select: none !important;
    pointer-events: none !important;
}

.pref-summary-title {
    flex: 1 1 auto;
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--steel-fade);
}

.pref-chevron {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--steel-fade);
    transition: transform 0.12s ease-out, color 0.10s ease;
    flex-shrink: 0;
}

.preferences-expander.open .pref-chevron {
    transform: rotate(90deg);
    color: var(--amber-phosphor) !important;
}

.preferences-expander .preferences-content {
    display: none;
    padding: 14px;
    border-top: 1px solid rgba(126, 136, 155, 0.14);
    flex-wrap: wrap;
    gap: 16px;
}

.preferences-expander.open .preferences-content {
    display: flex;
    animation: meso-pref-open 0.12s ease-out forwards;
    will-change: transform, opacity;
}

@keyframes meso-pref-open {
    from { opacity: 0; transform: translateY(-2px); }
    to { opacity: 1; transform: translateY(0); }
}

.pref-col {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.pref-label {
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--steel-fade);
    text-transform: uppercase;
}

/* Sort dropdown positioning */
.sort-select-wrapper {
    position: relative !important;
    width: 190px !important;
}

.sort-select-wrapper .custom-select-trigger {
    width: 100% !important;
    min-width: 100% !important;
    max-width: 100% !important;
    height: 38px;
    padding: 0 10px;
    background: var(--surface-graphite);
    border: 1px solid rgba(126, 136, 155, 0.25);
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    color: #FFFFFF;
}

.sort-select-wrapper .custom-select-options {
    left: 0 !important;
    right: auto !important;
    min-width: 190px !important;
    width: 100% !important;
    z-index: 1050 !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.9) !important;
}

/* Budget slider and readout badge */
.budget-col {
    min-width: 190px !important;
}

.pref-label-row {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
    width: 100% !important;
}

.budget-val-badge {
    font-family: 'Space Mono', monospace !important;
    font-size: 0.80rem !important;
    font-weight: 700 !important;
    color: var(--amber-phosphor) !important;
    background: #0E1017 !important;
    border: 1px solid rgba(255, 162, 58, 0.35) !important;
    border-radius: 4px !important;
    padding: 2px 7px !important;
    letter-spacing: 0.04em !important;
    box-shadow: 0 0 8px rgba(255, 162, 58, 0.15) !important;
}

.budget-range-input {
    -webkit-appearance: none !important;
    appearance: none !important;
    width: 100% !important;
    height: 6px !important;
    background: #0E1017 !important;
    border: 1px solid rgba(126, 136, 155, 0.25) !important;
    border-radius: 3px !important;
    outline: none !important;
    cursor: pointer !important;
    margin-top: 6px !important;
}

.budget-range-input::-webkit-slider-thumb {
    -webkit-appearance: none !important;
    appearance: none !important;
    width: 16px !important;
    height: 16px !important;
    border-radius: 50% !important;
    background: var(--laser-orange) !important;
    border: 2px solid #FFFFFF !important;
    cursor: pointer !important;
    box-shadow: 0 0 8px rgba(255, 84, 38, 0.6) !important;
    transition: transform 0.12s ease !important;
}

.budget-range-input::-webkit-slider-thumb:hover { transform: scale(1.15) !important; }

.budget-range-input::-moz-range-thumb {
    width: 16px !important;
    height: 16px !important;
    border-radius: 50% !important;
    background: var(--laser-orange) !important;
    border: 2px solid #FFFFFF !important;
    cursor: pointer !important;
    box-shadow: 0 0 8px rgba(255, 84, 38, 0.6) !important;
}

/* Marketplace provider selection tags */
.store-pills-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.store-pill {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    border-radius: 6px;
    background: #0E1017;
    border: 1px solid rgba(126, 136, 155, 0.25);
    color: #FFFFFF;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    user-select: none;
    transition: border-color 0.15s ease, opacity 0.15s ease;
}

.store-pill input[type="checkbox"] {
    display: none;
}

.store-pill:has(input:checked) {
    border-color: var(--laser-orange);
    color: #FFFFFF;
    opacity: 1;
}

.store-pill:has(input:not(:checked)) {
    opacity: 0.4;
    border-color: rgba(126, 136, 155, 0.2);
}

/* 5. Country Selector */
.header-country-wrapper { position: relative; }
.custom-select-trigger {
    width: 142px;
    min-width: 142px;
    max-width: 142px;
    height: 38px;
    padding: 0 10px;
    background: var(--surface-graphite);
    border: 1px solid rgba(126, 136, 155, 0.25);
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    color: #FFFFFF;
    white-space: nowrap;
    overflow: hidden;
}

.country-current-flag {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.custom-select-trigger span:not(.select-chevron) {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.select-chevron {
    font-size: 1.05rem;
    color: var(--steel-fade);
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    line-height: 1;
    flex-shrink: 0;
}

.custom-select-options {
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    background: var(--surface-graphite);
    border: 1px solid rgba(255, 84, 38, 0.35);
    border-radius: 8px;
    min-width: 180px;
    max-height: 280px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.8);
}
.custom-select-options.hidden { display: none !important; }

.custom-option {
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.84rem;
    color: #E5E7EB;
    cursor: pointer;
}
.custom-option:hover { background: rgba(255, 84, 38, 0.15); color: #FFFFFF; }
.custom-option img { width: 16px !important; height: 16px !important; border-radius: 50% !important; object-fit: cover !important; }

/* 6. Live Tracker Box */
.meso-live-tracker-box {
    position: relative;
    background: #0E1017;
    border: 1px solid rgba(126, 136, 155, 0.22);
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.meso-live-tracker-box.hidden { display: none !important; }

@keyframes meso-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 7. Summary Metrics Bar */
.summary-bar {
    background-color: var(--surface-graphite);
    border: 1px solid rgba(126, 136, 155, 0.18);
    border-radius: 8px;
    padding: 10px 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    align-items: center;
    font-size: 0.86rem;
    color: var(--steel-fade);
    margin-bottom: 20px;
}
.summary-bar.hidden { display: none !important; }
.sum-item { display: flex; align-items: center; gap: 8px; }
.sum-item > *:first-child {
    width: 20px;
    min-width: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.sum-best { font-family: 'Space Mono', monospace; color: var(--laser-orange); font-weight: 700; }
.sum-avg { font-family: 'Space Mono', monospace; color: #FFFFFF; font-weight: 700; }

/* 8. Results Grid & Cards */
.feed-section { width: 100%; flex: 1 0 auto; display: flex; flex-direction: column; }
.feed-header-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    font-family: 'Space Mono', monospace;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--amber-phosphor);
    letter-spacing: 0.08em;
}
.pulse-led {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: var(--laser-orange);
    box-shadow: 0 0 8px var(--laser-orange);
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.deal-card {
    display: flex;
    flex-direction: column;
    height: 385px;
    background: linear-gradient(180deg, #12151D 0%, #0E1017 100%);
    border: 1px solid rgba(126, 136, 155, 0.16);
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease;
}
.deal-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 84, 38, 0.5);
}

.card-img {
    width: 100%;
    height: 185px;
    object-fit: cover;
    background: #090B0E;
    border-bottom: 1px solid rgba(126, 136, 155, 0.12);
}

.card-content {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    height: 200px;
    padding: 12px 14px 10px 14px;
    justify-content: space-between;
}

.card-meta-row { display: flex; justify-content: space-between; align-items: center; height: 22px; }
.deal-badge {
    font-family: 'Inter', sans-serif;
    font-size: 0.70rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 4px;
    text-transform: uppercase;
    background: rgba(18, 21, 29, 0.85);
    border: 1px solid rgba(126, 136, 155, 0.2);
}

.badge-wallapop { border-left: 3px solid #ff6a00 !important; color: #ff9147 !important; }
.badge-subito { border-left: 3px solid #E63946 !important; color: #FF6B77 !important; }
.badge-vinted { border-left: 3px solid #007788 !important; color: #38bdf8 !important; }
.badge-ebay { border-left: 3px solid #0064d2 !important; color: #60a5fa !important; }
.badge-rebuy { border-left: 3px solid #008cd2 !important; color: #38bdf8 !important; }
.badge-kleinanzeigen { border-left: 3px solid #86b817 !important; color: #a3e635 !important; }
.badge-blocket { border-left: 3px solid #EA3323 !important; color: #F87171 !important; }
.badge-olx { border-left: 3px solid #23E5DB !important; color: #23E5DB !important; }

.card-console { font-family: 'Space Mono', monospace; font-size: 0.70rem; font-weight: 700; color: var(--steel-fade); display: flex; align-items: center; }
.card-img-link {
    display: block;
    width: 100%;
    cursor: pointer;
    overflow: hidden;
    text-decoration: none;
    line-height: 0;
}
.card-img-link:hover .card-img {
    opacity: 0.92;
}

.card-title {
    font-size: 0.88rem;
    font-weight: 600;
    color: #FFFFFF;
    line-height: 1.35;
    height: 42px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    text-decoration: none !important;
    cursor: pointer !important;
    transition: color 0.15s ease;
}
.card-title:hover {
    color: var(--laser-orange) !important;
}
.price-tag { font-family: 'Space Mono', monospace; font-size: 1.25rem; font-weight: 700; }
.sub-price { font-family: 'Space Mono', monospace; font-size: 0.70rem; color: var(--steel-fade); line-height: 1.3; }
.loc-text { font-size: 0.74rem; color: var(--steel-fade); display: flex; align-items: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.flag-icon-card { width: 14px; height: 14px; border-radius: 50%; object-fit: cover; }

.card-actions { display: flex; gap: 8px; margin-top: auto; }
.buy-button {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #181C26;
    border: 1px solid rgba(126, 136, 155, 0.22);
    color: #FFFFFF !important;
    text-decoration: none;
    padding: 8px 10px;
    border-radius: 6px;
    font-size: 0.84rem;
    font-weight: 600;
}
.buy-button:hover { background: var(--laser-orange); border-color: var(--laser-orange); }
.flag-button { background: #181C26; border: 1px solid rgba(126, 136, 155, 0.22); border-radius: 6px; padding: 0 8px; cursor: pointer; color: #7E889B; }
.flag-button:hover { color: #EF4444; border-color: #EF4444; }

/* 9. Terminal Footer */
.meso-terminal-footer {
    margin-top: auto !important;
    margin-bottom: 0 !important;
    padding: 10px 14px;
    background: rgba(18, 21, 29, 0.45);
    border: 1px solid rgba(126, 136, 155, 0.16);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
    font-family: 'Space Mono', monospace;
    width: 100%;
    max-width: 580px;
    margin-left: auto;
    margin-right: auto;
}

.footer-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
    width: 100%;
}

.footer-link-btn {
    background: #0E1017;
    border: 1px solid rgba(126, 136, 155, 0.18);
    border-radius: 4px;
    color: #7E889B;
    font-family: 'Space Mono', monospace;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    cursor: pointer;
    transition: all 0.15s ease;
    padding: 5px 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.footer-link-btn:hover {
    color: #FFA23A;
    border-color: #FFA23A;
    background: rgba(255, 162, 58, 0.08);
}

.footer-link-btn.coffee-glow {
    color: #FF5426;
    border-color: rgba(255, 84, 38, 0.28);
    background: rgba(255, 84, 38, 0.04);
}

.footer-link-btn.coffee-glow:hover {
    color: #FFFFFF;
    border-color: #FF5426;
    background: rgba(255, 84, 38, 0.15);
}

.footer-sep { display: none; }

.footer-meta {
    font-size: 0.60rem;
    color: #7E889B;
    letter-spacing: 0.06em;
    opacity: 0.7;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    width: 100%;
    padding-top: 8px;
    border-top: 1px dashed rgba(126, 136, 155, 0.14);
    line-height: 1.3;
}
.footer-meta .meta-dot { color: rgba(126, 136, 155, 0.35); }

.meso-terminal-footer ~ .meso-terminal-footer,
.meso-terminal-footer + .meso-terminal-footer {
    display: none !important;
}

/* 10. Modal Dialogs */
.meso-modal-backdrop {
    position: fixed !important;
    inset: 0 !important;
    background: rgba(6, 7, 9, 0.88) !important;
    backdrop-filter: blur(5px) !important;
    z-index: 10000 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 20px !important;
}
.meso-modal-backdrop.hidden { display: none !important; }

.meso-modal-window {
    background: #12151D;
    border: 1px solid rgba(255, 84, 38, 0.45);
    border-radius: 12px;
    max-width: 780px;
    width: 100%;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.85);
    overflow: hidden;
}

.meso-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #0E1017;
    border-bottom: 1px solid rgba(126, 136, 155, 0.18);
    padding: 8px 16px 0 16px;
}
.meso-modal-tabs { display: flex; gap: 8px; }
.meso-tab-btn {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: #7E889B;
    font-family: 'Space Mono', monospace;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    padding: 10px 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.meso-tab-btn:hover { color: #FFFFFF; }
.meso-tab-btn.active { color: #FFA23A; border-bottom-color: #FFA23A; }
.meso-tab-btn.coffee-tab.active { color: #FF5426; border-bottom-color: #FF5426; }

.meso-modal-close {
    background: none;
    border: none;
    color: #7E889B;
    font-size: 1.6rem;
    cursor: pointer;
    line-height: 1;
    padding: 0 6px;
    margin-bottom: 8px;
}
.meso-modal-close:hover { color: #EF4444; }

.meso-modal-body { padding: 24px 28px; overflow-y: auto; font-family: 'Inter', sans-serif; color: #E5E7EB; }
.meso-tab-content { display: none; }
.meso-tab-content.active { display: block; }
.meso-section-title { font-family: 'Space Mono', monospace; font-size: 0.82rem; font-weight: 700; color: #FF5426; margin: 18px 0 8px 0; text-transform: uppercase; }
.meso-section-title:first-child { margin-top: 0; }
.meso-p { font-size: 0.88rem; line-height: 1.65; color: #D1D5DB; margin-bottom: 12px; }
.meso-list { margin: 0 0 16px 20px; font-size: 0.86rem; line-height: 1.6; color: #9CA3AF; }
.meso-list li { margin-bottom: 6px; }
.meso-list strong { color: #FFFFFF; }
.meso-callout-box { background: #0E1017; border-left: 3px solid #FFA23A; padding: 12px 16px; border-radius: 4px; font-size: 0.86rem; color: #F3F4F6; margin-bottom: 16px; }
.meso-coffee-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 20px 0; }
.meso-coffee-btn { display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: 8px; text-decoration: none; background: #0E1017; border: 1px solid rgba(126, 136, 155, 0.2); }
.meso-coffee-btn strong { display: block; color: #FFFFFF; font-family: 'Space Mono', monospace; font-size: 0.88rem; }
.meso-coffee-btn small { color: #9CA3AF; font-size: 0.74rem; }
.meso-footnote { font-family: 'Space Mono', monospace; font-size: 0.72rem; color: #7E889B; text-align: center; margin-top: 14px; }

/* 11. Responsive Layout */
@media (max-width: 768px) {
    .meso-app-wrapper {
    max-width: 1380px;
    min-height: 100vh;
    min-height: 100dvh;
    margin: 0 auto;
    padding: 16px 16px 20px 16px;
    display: flex;
    flex-direction: column;
}
    .meso-top-header { flex-direction: row; align-items: center; }
    .brand-title { font-size: 1.25rem; }
    .brand-sys-tag { display: none; }
    .search-action-btn { padding: 0 14px; font-size: 0.78rem; }
    #query { padding-right: 95px !important; }
    .summary-bar { flex-direction: column; align-items: flex-start; gap: 10px; }
    .sum-item { width: 100%; justify-content: flex-start; gap: 8px; }
    .sum-item:first-child > *:last-child,
    .sum-item .sum-best,
    .sum-item .sum-avg { margin-left: auto; }
    /* 2-Column Subito-Style Mobile Grid & Calibrated Tactical Cards */
    .results-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }

    .deal-card {
        height: 360px !important;
        border-radius: 8px !important;
    }

    .card-img {
        height: 140px !important;
    }

    .card-content {
        height: 220px !important;
        padding: 8px 8px 6px 8px !important;
    }

    .card-meta-row {
        height: 18px !important;
        gap: 4px !important;
    }

    .deal-badge {
        font-size: 0.58rem !important;
        padding: 1px 4px !important;
        border-radius: 3px !important;
    }

    .card-console {
        font-size: 0.60rem !important;
        max-width: 75px !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
    }

    .card-console svg {
        width: 11px !important;
        height: 11px !important;
    }

    .card-img-link {
    display: block;
    width: 100%;
    cursor: pointer;
    overflow: hidden;
    text-decoration: none;
    line-height: 0;
}
.card-img-link:hover .card-img {
    opacity: 0.92;
}

.card-title {
    font-size: 0.88rem;
    font-weight: 600;
    color: #FFFFFF;
    line-height: 1.35;
    height: 42px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    text-decoration: none !important;
    cursor: pointer !important;
    transition: color 0.15s ease;
}
.card-title:hover {
    color: var(--laser-orange) !important;
}

    .price-tag {
        font-size: 1.05rem !important;
    }

    .sub-price {
        font-size: 0.58rem !important;
        line-height: 1.2 !important;
    }

    .loc-text {
        font-size: 0.64rem !important;
    }

    .flag-icon-card {
        width: 12px !important;
        height: 12px !important;
    }

    .card-actions {
        height: 30px !important;
        gap: 5px !important;
        margin-top: auto !important;
    }

    .buy-button {
        padding: 4px 6px !important;
        font-size: 0.70rem !important;
        border-radius: 4px !important;
    }

    .buy-button span {
        margin-left: 3px !important;
    }

    .buy-button svg {
        width: 10px !important;
        height: 10px !important;
    }

    .flag-button {
        padding: 0 5px !important;
        font-size: 0.68rem !important;
        border-radius: 4px !important;
    }
    
    .category-chip-bar { gap: 4px !important; margin-bottom: 10px !important; }
    .cat-chip { padding: 6px 2px !important; font-size: 0.69rem !important; border-radius: 5px !important; }
    .cat-chip svg { width: 12px !important; height: 12px !important; }
    .lbl-short { display: inline !important; }
    .lbl-full { display: none !important; }

    .meso-terminal-footer {
        margin-top: 18px;
        padding: 8px 10px;
        gap: 6px;
        border-radius: 6px;
        max-width: 100%;
    }
    .footer-links {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 5px;
        width: 100%;
    }
    .footer-link-btn {
        width: auto;
        padding: 4px 7px;
        font-size: 0.62rem;
        flex: 0 1 auto;
    }
    .footer-sep { display: none; }
    .footer-meta {
        flex-direction: column;
        gap: 2px;
        font-size: 0.58rem;
        padding-top: 6px;
    }
    .footer-meta .meta-dot { display: none; }

    .meso-coffee-grid { grid-template-columns: 1fr; }
}

/* 12. Moderation Report Sheet */
.report-modal-window {
    max-width: 460px !important;
    border-color: rgba(239, 68, 68, 0.45) !important;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.9) !important;
}

.report-modal-header {
    padding: 10px 16px !important;
    border-bottom: 1px solid rgba(239, 68, 68, 0.25) !important;
}

.report-header-tag {
    font-family: 'Space Mono', monospace;
    font-size: 0.74rem;
    font-weight: 700;
    color: #EF4444;
    letter-spacing: 0.08em;
}

.report-modal-body {
    padding: 16px 20px 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.report-target-meta {
    background: #0E1017;
    border: 1px solid rgba(126, 136, 155, 0.2);
    border-radius: 6px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    overflow: hidden;
}

.report-target-title-text {
    font-size: 0.82rem;
    color: #E5E7EB;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

.report-reasons-intro {
    font-family: 'Space Mono', monospace;
    font-size: 0.70rem;
    color: var(--steel-fade);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

.report-reasons-list {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.report-reason-btn {
    background: #0E1017;
    border: 1px solid rgba(126, 136, 155, 0.22);
    border-radius: 6px;
    color: #F3F4F6;
    padding: 10px 12px;
    font-family: 'Inter', sans-serif;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    text-align: left;
    transition: all 0.15s ease;
}

.report-reason-btn:hover {
    border-color: #EF4444;
    background: rgba(239, 68, 68, 0.1);
    color: #FFFFFF;
    transform: translateX(2px);
}

.report-reason-btn .reason-icon {
    font-size: 1rem;
    line-height: 1;
}

.report-actions-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 6px;
}

.report-cancel-btn {
    background: transparent;
    border: 1px solid rgba(126, 136, 155, 0.25);
    color: var(--steel-fade);
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.report-cancel-btn:hover {
    color: #FFFFFF;
    border-color: #7E889B;
}

/* 13. Flagged Card Placeholder */
.deal-card-reported {
    border-color: rgba(239, 68, 68, 0.45) !important;
    background: #0E1017 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
}

.reported-card-inner {
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    height: 100%;
}

.reported-card-icon {
    font-size: 1.4rem;
    line-height: 1;
}

.reported-card-status {
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    font-weight: 700;
    color: #EF4444;
    letter-spacing: 0.06em;
}

.reported-card-reason {
    font-size: 0.72rem;
    color: var(--steel-fade);
    background: rgba(18, 21, 29, 0.85);
    border: 1px solid rgba(126, 136, 155, 0.2);
    border-radius: 4px;
    padding: 3px 8px;
    max-width: 90%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reported-card-title {
    font-size: 0.74rem;
    color: #9CA3AF;
    max-width: 90%;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.25;
    margin: 2px 0 6px 0;
}

.undo-report-btn {
    background: #181C26;
    border: 1px solid rgba(255, 84, 38, 0.4);
    border-radius: 6px;
    color: #FFFFFF;
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 8px 12px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease;
    margin-top: auto;
}

.undo-report-btn:hover {
    background: var(--laser-orange);
    border-color: var(--laser-orange);
    transform: scale(1.02);
}
.search-clear-slot {
    position: absolute;
    right: 110px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 3;
    padding: 5px;
    border-radius: 50%;
    background: rgba(18, 21, 29, 0.8);
}
.search-clear-slot:hover svg { stroke: #EF4444; }
.search-clear-slot.hidden { display: none !important; }
/* placeholder when a listing has no image */
.card-img-ph {
    width: 100%;
    height: 185px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #090B0E;
    border-bottom: 1px solid rgba(126, 136, 155, 0.12);
    color: rgba(126, 136, 155, 0.45);
    font-family: 'Space Mono', monospace;
    font-size: 0.70rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    line-height: 1;
}
@media (max-width: 768px) {
    .card-img-ph { height: 140px !important; font-size: 0.62rem; }
}

/* meso-scroll-perf: skip rendering of off-screen cards */
.deal-card {
    content-visibility: auto;
    contain-intrinsic-size: auto 385px;
}
@media (max-width: 768px) {
    .deal-card { contain-intrinsic-size: auto 360px; }
}

/* meso-pager */
#meso-pager {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin: 22px 0 8px 0;
}
.meso-pg {
    min-width: 38px;
    height: 38px;
    padding: 0 10px;
    background: var(--surface-graphite);
    border: 1px solid rgba(126, 136, 155, 0.25);
    border-radius: 6px;
    color: #FFFFFF;
    font-family: 'Space Mono', monospace;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
}
.meso-pg:hover { border-color: var(--laser-orange); }
.meso-pg.active {
    background: rgba(255, 84, 38, 0.14);
    border-color: var(--laser-orange);
    box-shadow: 0 0 10px rgba(255, 84, 38, 0.22);
}
.meso-pg:disabled { opacity: 0.35; cursor: default; border-color: rgba(126, 136, 155, 0.25); }
.meso-pg-gap { color: var(--steel-fade); font-family: 'Space Mono', monospace; padding: 0 2px; }
@media (max-width: 768px) {
    .meso-pg { min-width: 34px; height: 34px; padding: 0 8px; font-size: 0.76rem; }
}

/* meso-pager-big */
#meso-pager { gap: 8px; margin: 26px 0 12px 0; }
.meso-pg { min-width: 46px; height: 46px; padding: 0 12px; font-size: 0.98rem; border-radius: 8px; }
.meso-pg-gap { font-size: 1rem; padding: 0 4px; }
@media (max-width: 768px) {
    #meso-pager { gap: 6px; }
    .meso-pg { min-width: 42px; height: 42px; padding: 0 10px; font-size: 0.90rem; }
}
.badge-leboncoin { border-left: 3px solid #FF6E14 !important; color: #FF8C42 !important; }

/* meso-dropdown-layer: i menu a tendina stanno sopra barra risultati e schede */
.preferences-expander { position: relative; z-index: 40; }
.preferences-expander .preferences-content { position: relative; z-index: 41; }
.sort-select-wrapper .custom-select-options { opacity: 1 !important; background: #12151D !important; }

/* meso-share */
.share-button { background: #181C26; border: 1px solid rgba(126, 136, 155, 0.22); border-radius: 6px; padding: 0 9px; cursor: pointer; color: #7E889B; display: flex; align-items: center; justify-content: center; }
.share-button:hover { color: #FF5426; border-color: #FF5426; }
@media (max-width: 768px) { .share-button { padding: 0 6px !important; border-radius: 4px !important; } .share-button svg { width: 12px; height: 12px; } }

/* meso-clearpos */
.search-clear-slot { right: calc(var(--meso-btn-w, 100px) + 14px) !important; padding: 5px !important; background: rgba(239, 68, 68, 0.12) !important; border: 1px solid rgba(239, 68, 68, 0.45); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); transition: background .15s ease, box-shadow .15s ease, border-color .15s ease; }
.search-clear-slot svg { stroke: #EF4444 !important; width: 14px; height: 14px; display: block; }
.search-clear-slot:hover { background: rgba(239, 68, 68, 0.24) !important; border-color: #EF4444; box-shadow: 0 0 10px rgba(239, 68, 68, 0.35); }
#query { padding-right: calc(var(--meso-btn-w, 100px) + 54px) !important; }

/* meso-tourshine */
@keyframes mtShine {
  0%   { background-position: -120% 0; box-shadow: 0 0 0 0 rgba(255, 84, 38, 0); }
  50%  { box-shadow: 0 0 14px 3px rgba(255, 84, 38, 0.75); border-color: #FF5426; color: #fff; }
  100% { background-position: 220% 0; box-shadow: 0 0 0 0 rgba(255, 84, 38, 0); }
}
#meso-tour-card .mt-btns .mt-skip.mt-shine {
  background-image: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.45) 50%, transparent 70%);
  background-size: 200% 100%;
  background-repeat: no-repeat;
  animation: mtShine 1.5s ease-in-out 0.6s 3;
}

/* meso-gamesbtn */
.mub-games { color: #FFA23A; border-color: rgba(255, 162, 58, 0.55); }
.mub-games:hover { color: #FFFFFF; border-color: #FFA23A; background: rgba(255, 162, 58, 0.14); }
@media (max-width: 640px) { .mub-coffee { grid-column: 1 / -1; } }
