/*
Theme Name: Astra Immo France
Template: astra
Version: 2.3
Description: Thème enfant pour Immo Actu France
*/

/* ===== DESIGN TOKENS ===== */
:root {
  --c-navy:    #1B3A5C;
  --c-navy-d:  #122840;
  --c-gold:    #C9922A;
  --c-gold-l:  #F5E8D0;
  --c-blue:    #2E7FCC;
  --c-blue-l:  #EBF4FD;
  --c-success: #1E6B3C;
  --c-warn:    #8C5A00;
  --c-red:     #B42B2B;
  --c-text:    #1E1E1E;
  --c-muted:   #5C5C5C;
  --c-border:  #DDE2EA;
  --c-bg:      #F7F9FC;
  --c-white:   #FFFFFF;
  --font-h:    'Merriweather', Georgia, serif;
  --font-b:    'Inter', system-ui, sans-serif;
  --radius:    6px;
  --radius-l:  10px;
  --shadow-s:  0 1px 4px rgba(0,0,0,.07);
  --shadow-m:  0 3px 14px rgba(0,0,0,.09);
  --shadow-l:  0 8px 30px rgba(0,0,0,.12);
}

/* ===== FONTS ===== */
@import url('https://fonts.googleapis.com/css2?family=Merriweather:wght@400;700;900&family=Inter:wght@400;500;600;700&display=swap');

/* ===== RESET / BASE ===== */
body {
  font-family: var(--font-b);
  color: var(--c-text);
  background: var(--c-bg);
  font-size: 16px;
  line-height: 1.8;
}
h1, h2, h3, h4 {
  font-family: var(--font-h);
  color: var(--c-navy);
  line-height: 1.3;
}
a { color: var(--c-blue); text-decoration: none; }
a:hover { color: var(--c-navy); }

/* ===== HEADER ===== */
.site-header {
  border-bottom: 3px solid var(--c-gold);
  background: var(--c-white) !important;
  box-shadow: var(--shadow-s);
}
.site-title a {
  font-family: var(--font-h) !important;
  font-size: 1.55rem !important;
  font-weight: 700 !important;
  color: var(--c-navy) !important;
}
.site-description {
  color: var(--c-muted);
  font-size: .82rem;
}

/* ===== NAV ===== */
.main-header-menu .menu-item a {
  font-family: var(--font-b);
  font-size: .875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--c-navy) !important;
  padding: 6px 14px !important;
  transition: color .2s;
}
.main-header-menu .menu-item a:hover,
.main-header-menu .current-menu-item > a {
  color: var(--c-gold) !important;
}

/* ===== HERO SECTION (Homepage) ===== */
.hero-section {
  background: linear-gradient(135deg, var(--c-navy) 0%, #1e4d7a 50%, #2B5C8A 100%);
  padding: 80px 24px 70px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero-section::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}
.hero-section::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0; right: 0;
  height: 50px;
  background: var(--c-bg);
  clip-path: ellipse(55% 100% at 50% 100%);
}
.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
}
.hero-title {
  color: #fff !important;
  font-size: clamp(1.8rem, 4.5vw, 2.8rem);
  font-weight: 900;
  margin-bottom: 1rem;
  line-height: 1.2;
}
.hero-subtitle {
  color: rgba(255,255,255,.85);
  font-size: 1.15rem;
  max-width: 640px;
  margin: 0 auto 2rem;
  line-height: 1.7;
}
.hero-cta {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}
.btn-primary {
  display: inline-block;
  background: var(--c-gold);
  color: #fff !important;
  padding: 14px 32px;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: .95rem;
  transition: transform .2s, box-shadow .2s;
  box-shadow: 0 4px 15px rgba(201,146,42,.4);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(201,146,42,.5);
  color: #fff !important;
}
.btn-secondary {
  display: inline-block;
  background: transparent;
  color: #fff !important;
  padding: 14px 32px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: .95rem;
  border: 2px solid rgba(255,255,255,.4);
  transition: all .2s;
}
.btn-secondary:hover {
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.7);
  color: #fff !important;
}
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 48px;
}
.stat-item {
  text-align: center;
}
.stat-number {
  display: block;
  font-family: var(--font-h);
  font-size: 2rem;
  font-weight: 900;
  color: var(--c-gold);
}
.stat-label {
  display: block;
  font-size: .8rem;
  color: rgba(255,255,255,.6);
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* ===== TOOLS SECTION (Homepage) ===== */
.tools-section {
  background: var(--c-white);
  padding: 60px 20px;
  text-align: center;
  box-shadow: var(--shadow-s);
  position: relative;
}
.section-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.section-title {
  font-size: 1.8rem;
  color: var(--c-navy) !important;
  margin-bottom: .5rem;
}
.section-subtitle {
  color: var(--c-muted);
  font-size: 1rem;
  margin-bottom: 36px;
}
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  max-width: 960px;
  margin: 0 auto;
}
.tool-card {
  background: var(--c-bg);
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-l);
  padding: 28px 16px;
  text-align: center;
  transition: all .25s;
  cursor: pointer;
}
.tool-card:hover {
  border-color: var(--c-blue);
  box-shadow: var(--shadow-m);
  transform: translateY(-3px);
}
.tool-icon {
  font-size: 2.2rem;
  margin-bottom: 12px;
  display: block;
}
.tool-link {
  font-weight: 700;
  font-size: .9rem;
  color: var(--c-navy) !important;
  text-decoration: none;
  display: block;
  margin-bottom: 4px;
}
.tool-card:hover .tool-link {
  color: var(--c-blue) !important;
}
.tool-card p {
  color: var(--c-muted);
  font-size: .78rem;
  margin: 0;
  line-height: 1.4;
}

/* ===== CATEGORIES SECTION (Homepage) ===== */
.categories-section {
  padding: 60px 20px;
  max-width: 1120px;
  margin: 0 auto;
}
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}
.category-card {
  background: var(--c-white);
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-l);
  padding: 28px 24px;
  box-shadow: var(--shadow-s);
  transition: all .25s;
  text-decoration: none;
  display: block;
  border-top: 4px solid var(--c-border);
}
.category-card:hover {
  box-shadow: var(--shadow-m);
  transform: translateY(-3px);
}
.category-card h3 {
  font-size: 1.05rem;
  margin: 0 0 8px;
  font-family: var(--font-b);
  font-weight: 700;
  color: var(--c-navy);
}
.category-card p {
  font-size: .85rem;
  color: var(--c-muted);
  margin: 0 0 14px;
  line-height: 1.6;
}
.category-card a {
  font-size: .82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--c-blue);
}
/* Category card accent colors */
.cat-marche  { border-top-color: var(--c-blue); }
.cat-achat   { border-top-color: var(--c-success); }
.cat-vente   { border-top-color: var(--c-gold); }
.cat-location { border-top-color: #7B4FD0; }
.cat-invest  { border-top-color: var(--c-navy); }
.cat-fisca   { border-top-color: var(--c-red); }
.cat-renov   { border-top-color: #F0A500; }
.cat-outils  { border-top-color: var(--c-blue); }

/* ===== LATEST ARTICLES SECTION (Homepage) ===== */
.latest-articles-section {
  background: var(--c-white);
  padding: 60px 20px;
}
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  max-width: 1100px;
  margin: 0 auto;
}
.article-card {
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-l);
  padding: 24px;
  transition: all .25s;
}
.article-card:hover {
  box-shadow: var(--shadow-m);
  transform: translateY(-2px);
}
.article-cat {
  display: inline-block;
  background: var(--c-navy);
  color: #fff;
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 3px 10px;
  border-radius: 3px;
  margin-bottom: 10px;
}
.article-card h3 {
  font-size: 1rem;
  font-family: var(--font-b);
  font-weight: 700;
  margin: 0 0 8px;
  line-height: 1.4;
}
.article-card h3 a {
  color: var(--c-navy);
}
.article-card h3 a:hover {
  color: var(--c-blue);
}
.article-excerpt {
  font-size: .85rem;
  color: var(--c-muted);
  line-height: 1.6;
  margin: 0 0 10px;
}
.article-meta {
  font-size: .75rem;
  color: var(--c-muted);
}
.section-cta {
  text-align: center;
  margin-top: 30px;
}
.section-cta a {
  display: inline-block;
  background: var(--c-navy);
  color: #fff !important;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: .9rem;
  transition: background .2s;
}
.section-cta a:hover {
  background: var(--c-blue);
}

/* ===== TRUST SECTION (Homepage) ===== */
.trust-section {
  padding: 40px 20px;
  text-align: center;
}
.trust-grid {
  display: flex;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
  max-width: 900px;
  margin: 0 auto;
}
.trust-item {
  text-align: center;
}
.trust-item span:first-child {
  display: block;
  font-size: 1.8rem;
  margin-bottom: 6px;
}
.trust-item strong {
  display: block;
  font-size: .9rem;
  color: var(--c-navy);
}
.trust-item span:last-child {
  font-size: .78rem;
  color: var(--c-muted);
}

/* ===== ARTICLES (Single) ===== */
.entry-content {
  max-width: 780px;
  margin: 0 auto;
}
.entry-content h2 {
  font-size: 1.45rem;
  margin-top: 2.4rem;
  padding-bottom: .5rem;
  border-bottom: 2px solid var(--c-gold-l);
}
.entry-content h3 {
  font-size: 1.15rem;
  margin-top: 1.8rem;
  color: var(--c-blue);
  font-family: var(--font-b);
  font-weight: 600;
}
.article-intro {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--c-text);
  margin-bottom: 1.5rem;
}

/* ===== INFO BOXES (Articles + Tools) ===== */
.box-info, .box-warn, .box-ok, .box-tip {
  padding: 18px 22px;
  border-radius: var(--radius);
  margin: 24px 0;
  font-size: .93rem;
  line-height: 1.65;
}
.box-info {
  background: var(--c-blue-l);
  border-left: 4px solid var(--c-blue);
}
.box-warn {
  background: #FFF8EC;
  border-left: 4px solid var(--c-gold);
}
.box-ok {
  background: #EDF7F1;
  border-left: 4px solid var(--c-success);
}
.box-tip {
  background: #F9F3FF;
  border-left: 4px solid #7B4FD0;
}
.box-info strong, .box-warn strong, .box-ok strong, .box-tip strong {
  display: block;
  margin-bottom: 6px;
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* ===== DATA TABLES (Articles + Tools) ===== */
.entry-content table,
.data-table,
.result-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .9rem;
  margin: 20px 0;
}
.entry-content th,
.data-table th {
  background: var(--c-navy);
  color: #fff;
  padding: 11px 14px;
  text-align: left;
  font-weight: 500;
  font-size: .85rem;
}
.entry-content td,
.data-table td,
.result-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--c-border);
}
.entry-content tr:nth-child(even) td,
.data-table tr:nth-child(even) td {
  background: #F5F7FA;
}
.result-table .total-row td {
  background: var(--c-navy) !important;
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
}
.result-table .highlight td,
.result-table tr.highlight td {
  background: var(--c-blue-l) !important;
  font-weight: 600;
}

/* ===== OUTIL WRAPPER (Tool Pages) ===== */
.outil-wrapper {
  background: var(--c-white);
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-l);
  padding: 0;
  max-width: 820px;
  margin: 30px auto;
  box-shadow: var(--shadow-m);
  overflow: hidden;
}
.outil-intro {
  background: linear-gradient(135deg, var(--c-navy), #2B5C8A);
  color: #fff;
  padding: 32px 36px;
}
.outil-intro h2 {
  color: #fff !important;
  font-size: 1.4rem;
  margin: 0 0 8px;
  border: none;
  padding: 0;
}
.outil-intro p {
  color: rgba(255,255,255,.8);
  font-size: .9rem;
  margin: 0;
  line-height: 1.6;
}

/* Calculator card */
.calculator-card {
  padding: 32px 36px;
}
.calculator-card h3 {
  font-family: var(--font-b);
  font-weight: 700;
  font-size: 1rem;
  color: var(--c-navy);
  margin: 0 0 20px;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.calc-form {
  margin-bottom: 0;
}
.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-group {
  margin-bottom: 18px;
}
.form-group label {
  display: block;
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--c-navy);
}
.form-group input[type="number"],
.form-group select {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius);
  font-size: .95rem;
  font-family: var(--font-b);
  background: var(--c-bg);
  color: var(--c-text);
  transition: border-color .2s, box-shadow .2s;
  box-sizing: border-box;
}
.form-group input:focus,
.form-group select:focus {
  border-color: var(--c-blue);
  box-shadow: 0 0 0 3px rgba(46,127,204,.15);
  outline: none;
  background: #fff;
}
.form-group .hint,
.form-group small {
  font-size: .78rem;
  color: var(--c-muted);
  margin-top: 4px;
  display: block;
}

/* Calculate button */
.btn-calc {
  background: linear-gradient(135deg, var(--c-navy), #2B5C8A);
  color: #fff;
  border: none;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font-b);
  width: 100%;
  transition: all .2s;
  box-shadow: 0 4px 12px rgba(27,58,92,.3);
  margin-top: 8px;
}
.btn-calc:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(27,58,92,.4);
}

/* Result block */
.result-block {
  background: var(--c-bg);
  border-top: 3px solid var(--c-gold);
  padding: 28px 36px;
  margin-top: 24px;
  animation: slideDown .3s ease;
}
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}
.result-block h3 {
  font-family: var(--font-b);
  font-weight: 700;
  color: var(--c-navy);
  font-size: 1rem;
  margin: 0 0 16px;
}
.disclaimer {
  font-size: .78rem;
  color: var(--c-muted);
  margin-top: 12px;
  font-style: italic;
}

/* ===== DPE BARS (DPE Tool) ===== */
.dpe-barre-container {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 24px 0;
}
.dpe-barre-container > div {
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: var(--radius);
  padding: 8px 14px;
  font-weight: 600;
  font-size: .85rem;
  color: #fff;
  transition: all .3s;
}
.dpe-barre-container > div.active {
  outline: 3px solid var(--c-navy);
  transform: scale(1.03);
  box-shadow: var(--shadow-m);
}

/* ===== CONTENT SECTION (below tools) ===== */
.content-section {
  max-width: 820px;
  margin: 0 auto;
  padding: 40px 36px;
}
.content-section h2 {
  font-size: 1.35rem;
  padding-bottom: .4rem;
  border-bottom: 2px solid var(--c-gold-l);
  margin-top: 2rem;
}
.content-section h3 {
  font-size: 1.1rem;
  color: var(--c-blue);
  margin-top: 1.6rem;
}

/* ===== ACTU BADGE ===== */
.actu-badge {
  display: inline-block;
  background: var(--c-red);
  color: #fff;
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  padding: 3px 10px;
  border-radius: 3px;
  margin-right: 8px;
  vertical-align: middle;
}
.actu-badge.gold { background: var(--c-gold); }
.actu-badge.green { background: var(--c-success); }

/* ===== SIDEBAR ===== */
.widget-title {
  font-size: 1rem;
  font-family: var(--font-b);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--c-navy);
  border-bottom: 2px solid var(--c-gold);
  padding-bottom: 8px;
  margin-bottom: 16px;
}

/* ===== BREADCRUMBS ===== */
.immo-breadcrumbs {
  font-size: .82rem;
  color: var(--c-muted);
  margin-bottom: 16px;
  padding: 8px 0;
}
.immo-breadcrumbs a {
  color: var(--c-blue);
  text-decoration: none;
}
.immo-breadcrumbs a:hover {
  color: var(--c-navy);
  text-decoration: underline;
}
.immo-breadcrumbs .sep {
  margin: 0 6px;
  color: var(--c-border);
}
.immo-breadcrumbs .current {
  color: var(--c-muted);
  font-weight: 500;
}

/* ===== SOCIAL SHARE BUTTONS ===== */
.share-buttons {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 36px;
  padding-top: 24px;
  border-top: 2px solid var(--c-border);
}
.share-label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--c-navy);
  margin-right: 4px;
}
.share-btn {
  display: inline-block;
  padding: 8px 16px;
  border-radius: var(--radius);
  font-size: .8rem;
  font-weight: 600;
  text-decoration: none !important;
  color: #fff !important;
  transition: opacity .2s, transform .15s;
}
.share-btn:hover {
  opacity: .85;
  transform: translateY(-1px);
}
.share-fb { background: #1877F2; }
.share-tw { background: #000; }
.share-li { background: #0A66C2; }
.share-em { background: var(--c-muted); }

/* ===== FEATURED IMAGES (Blog + Singles) ===== */
.post-thumb-img-content img,
.ast-blog-single-element img.wp-post-image {
  border-radius: var(--radius-l);
  max-height: 320px;
  object-fit: cover;
  width: 100%;
}
.ast-article-post .post-thumb-img-content {
  border-radius: var(--radius-l);
  overflow: hidden;
  max-height: 220px;
}
.ast-article-post .post-thumb-img-content img {
  max-height: 220px;
}
/* Blog grid cards: tighter image */
.ast-separate-container .ast-article-post {
  border-radius: var(--radius-l);
  overflow: hidden;
}
.ast-row .blog-layout-4 .post-thumb-img-content,
.ast-row .blog-layout-1 .post-thumb-img-content {
  max-height: 200px;
  overflow: hidden;
}

/* ===== FOOTER ===== */
.site-footer {
  background: var(--c-navy-d) !important;
  color: rgba(255,255,255,.75);
  border-top: 3px solid var(--c-gold);
}
.ast-footer-widget-1 .widget-title,
.ast-footer-widget-2 .widget-title,
.ast-footer-widget-3 .widget-title {
  color: var(--c-gold) !important;
  border-color: rgba(201,146,42,.4);
}
.site-footer a { color: rgba(255,255,255,.75); }
.site-footer a:hover { color: var(--c-gold); }
.ast-footer-copyright {
  background: rgba(0,0,0,.25) !important;
  color: rgba(255,255,255,.5);
  font-size: .82rem;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .hero-section { padding: 56px 16px 50px; }
  .hero-title { font-size: 1.6rem; }
  .hero-stats { gap: 24px; }
  .stat-number { font-size: 1.5rem; }
  .tools-grid { grid-template-columns: repeat(2, 1fr); }
  .categories-grid { grid-template-columns: 1fr; }
  .articles-grid { grid-template-columns: 1fr; }
  .calc-grid { grid-template-columns: 1fr; }
  .calculator-card { padding: 24px 20px; }
  .outil-intro { padding: 24px 20px; }
  .result-block { padding: 20px; }
  .content-section { padding: 24px 20px; }
  .hero-cta { flex-direction: column; align-items: center; }
  .btn-primary, .btn-secondary { width: 100%; text-align: center; max-width: 280px; }
}
@media (max-width: 480px) {
  .tools-grid { grid-template-columns: 1fr; }
  .hero-stats { flex-direction: column; gap: 16px; }
  .trust-grid { flex-direction: column; gap: 20px; }
}
