:root {
    --estim-navy:   #1F3864;
    --estim-accent: #C9A84C;
    --estim-bg:     #f8f9fb;
    --estim-card:   #ffffff;
    --estim-border: #e2e6ed;
    --estim-text:   #2c3e50;
    --estim-muted:  #6b7a8d;
    --estim-radius: 10px;
    --estim-shadow: 0 4px 24px rgba(31,56,100,.10);
}

/* ── Conteneur ── */
.estimmo-wrap {
    font-family: Georgia, serif;
    background: var(--estim-bg);
    border-radius: var(--estim-radius);
    padding: 28px;
    max-width: 860px;
    margin: 0 auto;
    box-shadow: var(--estim-shadow);
    border: 1px solid var(--estim-border);
    color: var(--estim-text);
    box-sizing: border-box;
}

/* ── Header ── */
.estimmo-header { display:flex; align-items:center; gap:14px; margin-bottom:22px; padding-bottom:16px; border-bottom:2px solid var(--estim-accent); }
.estimmo-logo   { font-size:2rem; line-height:1; }
.estimmo-title  { font-size:1.4rem; font-weight:700; color:var(--estim-navy); margin:0 0 4px; }
.estimmo-subtitle { font-size:.78rem; color:var(--estim-muted); margin:0; font-style:italic; }

/* ── Formulaire ── */
.estimmo-form { display:grid; grid-template-columns:1fr 1fr; gap:14px 18px; }
@media (max-width:560px) { .estimmo-form { grid-template-columns:1fr; } }
.estimmo-field      { display:flex; flex-direction:column; gap:4px; }
.estimmo-field-full { grid-column:1/-1; }
.req { color:var(--estim-accent); }
.field-hint { font-size:.72rem; color:var(--estim-muted); font-style:italic; margin-top:2px; }

.estimmo-field label { font-size:.82rem; font-weight:600; color:var(--estim-navy); letter-spacing:.02em; }
.estimmo-field input,
.estimmo-field select {
    padding:9px 12px; border:1.5px solid var(--estim-border); border-radius:7px;
    font-size:.92rem; font-family:inherit; background:var(--estim-card); color:var(--estim-text);
    transition:border-color .2s,box-shadow .2s; outline:none; width:100%; box-sizing:border-box;
}
.estimmo-field input:focus,
.estimmo-field select:focus { border-color:var(--estim-accent); box-shadow:0 0 0 3px rgba(201,168,76,.16); }

/* ── Suggestion BAN ── */
.suggest-box {
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--estim-card);
    border: 1.5px solid var(--estim-accent);
    border-top: none;
    border-radius: 0 0 8px 8px;
    z-index: 2147483647;
    box-shadow: 0 8px 24px rgba(31,56,100,.15);
    max-height: 280px;
    overflow-y: auto;
}
.suggest-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid var(--estim-border);
    transition: background .15s;
}
.suggest-item:last-child { border-bottom: none; }
.suggest-item:hover,
.suggest-item.active { background: #f0f4ff; }
.suggest-ico   { font-size:1.1rem; flex-shrink:0; }
.suggest-label { flex:1; font-size:.88rem; color:var(--estim-text); }
.suggest-type  { font-size:.7rem; color:var(--estim-muted); background:#f1f3f8; padding:1px 6px; border-radius:10px; }

/* ── Bouton ── */
.estimmo-btn {
    width:100%; padding:13px 22px; background:var(--estim-navy); color:#fff;
    border:none; border-radius:8px; font-size:.97rem; font-weight:700; font-family:inherit;
    cursor:pointer; display:flex; align-items:center; justify-content:center; gap:8px;
    transition:background .2s; letter-spacing:.03em;
}
.estimmo-btn:hover    { background:#16295a; }
.estimmo-btn:disabled { opacity:.6; cursor:not-allowed; }
.estimmo-error { padding:11px 15px; background:#fef2f2; border:1px solid #fca5a5; border-radius:7px; color:#dc2626; font-size:.87rem; }

/* ── Résultats ── */
.estimmo-addr { background:var(--estim-navy); color:#fff; padding:10px 16px; border-radius:7px; font-size:.86rem; margin-bottom:18px; }

/* ── Onglets ── */
.estimmo-tabs { display:flex; gap:3px; margin-bottom:18px; border-bottom:2px solid var(--estim-border); flex-wrap:wrap; }
.tab-btn { background:none; border:none; border-bottom:3px solid transparent; padding:9px 14px; font-family:inherit; font-size:.85rem; font-weight:600; color:var(--estim-muted); cursor:pointer; margin-bottom:-2px; transition:color .2s,border-color .2s; white-space:nowrap; }
.tab-btn:hover  { color:var(--estim-navy); }
.tab-active     { color:var(--estim-navy) !important; border-bottom-color:var(--estim-accent) !important; }
.tab-pane       { display:none; }
.tab-pane-active { display:block; animation:efadeIn .25s ease; }
@keyframes efadeIn { from{opacity:0;transform:translateY(6px)} to{opacity:1;transform:none} }

/* ── Prix ── */
.price-row { display:grid; grid-template-columns:1fr 1.2fr 1fr; gap:12px; margin-bottom:16px; }
@media(max-width:560px){.price-row{grid-template-columns:1fr;}}
.price-box { background:var(--estim-card); border:1.5px solid var(--estim-border); border-radius:var(--estim-radius); padding:14px; text-align:center; }
.price-center { border-color:var(--estim-accent); box-shadow:0 0 0 3px rgba(201,168,76,.12); transform:translateY(-4px); }
.price-lbl  { font-size:.73rem; font-weight:600; color:var(--estim-muted); text-transform:uppercase; letter-spacing:.06em; margin-bottom:5px; }
.price-val  { font-size:1.4rem; font-weight:700; color:var(--estim-navy); }
.price-center .price-val { color:var(--estim-accent); font-size:1.6rem; }
.price-m2   { margin-top:3px; font-size:.77rem; color:var(--estim-muted); }

/* ── Meta chips ── */
.estimmo-meta { display:flex; flex-wrap:wrap; gap:6px 10px; font-size:.78rem; color:var(--estim-muted); margin-bottom:18px; }
.meta-chip    { background:#f1f3f8; padding:3px 9px; border-radius:20px; }

/* ── Carte ── */
.map-wrap    { margin-bottom:18px; }
.estimmo-map { width:100%; height:230px; border:none; border-radius:var(--estim-radius); display:block; }
.section-title { font-size:.9rem; font-weight:700; color:var(--estim-navy); margin-bottom:9px; border-left:3px solid var(--estim-accent); padding-left:9px; }

/* ── Location ── */
.rent-header  { display:flex; align-items:center; gap:12px; margin-bottom:5px; }
.rent-title   { font-size:1.05rem; font-weight:700; color:var(--estim-navy); }
.rent-sub     { font-size:.77rem; color:var(--estim-muted); }
.rendement-card { background:linear-gradient(135deg,#1F3864,#2a4a85); color:#fff; border-radius:var(--estim-radius); padding:16px 20px; margin:16px 0; text-align:center; }
.rendement-lbl  { font-size:.8rem; opacity:.82; margin-bottom:6px; font-weight:600; }
.rendement-val  { font-size:2.1rem; font-weight:700; }
.rendement-detail { font-size:.75rem; opacity:.7; margin-top:4px; }
.rent-disclaimer  { font-size:.75rem; color:var(--estim-muted); font-style:italic; }

/* ── Secteur DVF ── */
.secteur-sub   { font-size:.82rem; color:var(--estim-muted); font-style:italic; margin:0 0 12px; }
.ventes-grid   { display:grid; grid-template-columns:repeat(auto-fill,minmax(195px,1fr)); gap:10px; margin-bottom:12px; }
.vente-card    { background:var(--estim-card); border:1.5px solid var(--estim-border); border-radius:8px; padding:11px; transition:box-shadow .2s,border-color .2s; }
.vente-card:hover { border-color:var(--estim-accent); box-shadow:0 3px 12px rgba(31,56,100,.09); }
.vente-top     { display:flex; justify-content:space-between; align-items:center; margin-bottom:6px; }
.vente-badge   { background:var(--estim-navy); color:#fff; font-size:.67rem; font-weight:700; padding:2px 6px; border-radius:20px; text-transform:uppercase; }
.vente-date    { font-size:.72rem; color:var(--estim-muted); }
.vente-prix    { font-size:1.15rem; font-weight:700; color:var(--estim-navy); margin-bottom:4px; }
.vente-row     { display:flex; justify-content:space-between; font-size:.76rem; margin-bottom:4px; }
.vente-surf    { color:var(--estim-muted); }
.vente-m2      { font-weight:600; }
.vente-addr    { font-size:.73rem; color:var(--estim-muted); border-top:1px solid var(--estim-border); padding-top:4px; }
.mediane-box   { background:#eef1ff; border:1px solid #c7d2fe; border-radius:7px; padding:10px 14px; font-size:.84rem; color:var(--estim-navy); margin-top:6px; }
.dvf-source-note { font-size:.72rem; color:var(--estim-muted); font-style:italic; margin-top:8px; }

/* ── BDNB / RNIC ── */
.data-section-title { font-size:.9rem; font-weight:700; color:var(--estim-navy); margin-bottom:10px; border-left:3px solid var(--estim-accent); padding-left:9px; }
.data-grid  { display:grid; grid-template-columns:repeat(auto-fill,minmax(160px,1fr)); gap:8px; margin-bottom:10px; }
.data-item  { background:var(--estim-card); border:1px solid var(--estim-border); border-radius:6px; padding:10px 12px; }
.data-label { display:block; font-size:.72rem; color:var(--estim-muted); margin-bottom:4px; text-transform:uppercase; letter-spacing:.04em; }
.data-value { font-size:.9rem; font-weight:600; color:var(--estim-navy); }

/* Sources badges */
.data-sources-list { display:flex; flex-wrap:wrap; gap:6px; margin-top:12px; justify-content:center; }
.source-badge { background:#f1f3f8; border:1px solid var(--estim-border); padding:4px 10px; border-radius:20px; font-size:.75rem; color:var(--estim-muted); }

/* ── Disclaimer / Reset ── */
.estimmo-disclaimer { font-size:.74rem; color:var(--estim-muted); font-style:italic; border-top:1px solid var(--estim-border); padding-top:11px; margin:14px 0; }
.estimmo-reset { background:none; border:1.5px solid var(--estim-navy); color:var(--estim-navy); padding:7px 15px; border-radius:7px; font-size:.85rem; font-family:inherit; cursor:pointer; font-weight:600; transition:background .2s,color .2s; }
.estimmo-reset:hover { background:var(--estim-navy); color:#fff; }

/* ── Liens utiles ── */
.liens-intro { background:#f0f4ff; border:1px solid #c7d2fe; border-radius:8px; padding:12px 16px; font-size:.88rem; color:#1F3864; margin-bottom:16px; }
.liens-grid  { display:grid; grid-template-columns:repeat(auto-fill,minmax(240px,1fr)); gap:10px; margin-bottom:20px; }

.lien-card {
    display:flex; align-items:center; gap:12px;
    background:var(--estim-card); border:1.5px solid var(--estim-border);
    border-radius:8px; padding:12px 14px; text-decoration:none; color:var(--estim-text);
    transition:border-color .2s, box-shadow .2s;
}
.lien-card:hover { border-color:var(--estim-accent); box-shadow:0 3px 12px rgba(31,56,100,.1); }
.lien-icon    { font-size:1.4rem; width:38px; height:38px; border-radius:8px; display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.lien-content { flex:1; display:flex; flex-direction:column; gap:2px; }
.lien-content strong { font-size:.85rem; color:var(--estim-navy); }
.lien-content span   { font-size:.75rem; color:var(--estim-muted); }
.lien-arrow   { font-size:1.1rem; color:var(--estim-muted); }

/* ── Table sources ── */
.sources-table { width:100%; border-collapse:collapse; font-size:.83rem; margin-bottom:10px; }
.sources-table td { padding:7px 10px; border-bottom:1px solid var(--estim-border); }
.sources-table tr:last-child td { border-bottom:none; }
.sources-table tr:nth-child(even) td { background:#f8f9fb; }
.sources-table td:first-child { font-size:1rem; width:30px; text-align:center; }
.sources-table td:nth-child(3) { color:var(--estim-muted); font-size:.78rem; }

/* Masquer l'autocomplete Google Maps sur le champ estimmo */
#estim-address + .pac-container,
.estimmo-wrap .pac-container {
    display: none !important;
}

.sug-item { display:flex; align-items:center; gap:10px; padding:9px 14px; cursor:pointer; border-bottom:1px solid var(--estim-border); }
.sug-item:last-child { border-bottom:none; }
.sug-item:hover, .sug-item.active { background:#f0f4ff; }
.sug-ico   { font-size:1.1rem; flex-shrink:0; }
.sug-label { flex:1; font-size:.88rem; color:var(--estim-text); }
.sug-type  { font-size:.7rem; color:var(--estim-muted); background:#f1f3f8; padding:1px 6px; border-radius:10px; }
