/* ================================================================
   NOS EXPERTISES — page-specific styles
   Builds on colors_and_type.css + home-styles.css (header, footer,
   .partners, .reveal). Navy / champagne / ivory system.
   ================================================================ */

/* ============================================================
   HERO — navy, maillage + brand diamond, title overlaid
   ============================================================ */
.exp-hero {
  position: relative;
  min-height: clamp(560px, 82vh, 880px);
  display: flex;
  align-items: center;
  justify-content: center;
  background: #010c22;
  color: #fff;
  overflow: hidden;
}
.exp-hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
  z-index: 0;
  pointer-events: none;
}
.exp-hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(1,21,54,0.55) 0%, rgba(1,21,54,0.34) 38%, rgba(1,21,54,0.5) 66%, rgba(1,12,34,0.95) 100%),
    radial-gradient(ellipse at 50% 44%, rgba(1,21,54,0.22) 0%, rgba(1,21,54,0.4) 70%, rgba(1,21,54,0.62) 100%);
}
.exp-hero::before {
  display: none;
}
/* large faint diamond mark behind the title */
.exp-hero-mark {
  position: absolute;
  width: clamp(320px, 42vw, 540px);
  height: clamp(320px, 42vw, 540px);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  opacity: 0.14;
  mix-blend-mode: soft-light;
  pointer-events: none;
}
.exp-hero-head {
  position: relative;
  z-index: 2;
  max-width: 960px;
  padding: calc(var(--header-h, 96px) + 32px) 32px 48px;
  text-align: center;
}
.exp-hero-head .eyebrow {
  font-family: var(--fg-font-body);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-champagne);
  display: inline-flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 26px;
}
.exp-hero-head .eyebrow .dia {
  width: 6px; height: 6px;
  background: var(--fg-champagne);
  transform: rotate(45deg);
  opacity: 0.85;
}
.exp-hero-head h1 {
  font-family: var(--fg-font-display);
  font-weight: 400;
  font-size: clamp(44px, 6.4vw, 92px);
  line-height: 1.04;
  letter-spacing: 0.01em;
  margin: 0 0 24px;
  color: #fff;
  text-wrap: balance;
  text-shadow: 0 2px 36px rgba(1, 21, 54, 0.55);
}
.exp-hero-head .baseline {
  font-family: var(--fg-font-display);
  font-style: italic;
  font-size: clamp(18px, 2.2vw, 25px);
  line-height: 1.45;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.86);
  max-width: 660px;
  margin: 0 auto;
  text-wrap: balance;
  text-shadow: 0 2px 24px rgba(1, 21, 54, 0.5);
}

/* ============================================================
   CHAPEAU — intro paragraph on ivory + light maillage
   ============================================================ */
.exp-intro {
  position: relative;
  background: var(--fg-ivory);
  padding: 110px 56px;
  overflow: hidden;
}
.exp-intro::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='36' height='36' viewBox='0 0 36 36'><path d='M 0 0 L 36 36 M 36 0 L 0 36' stroke='%23011536' stroke-opacity='0.07' stroke-width='0.4'/></svg>");
  background-size: 36px 36px;
  pointer-events: none;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 36%, transparent 82%);
          mask-image: radial-gradient(ellipse at center, #000 36%, transparent 82%);
}
.exp-intro-inner {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
  text-align: center;
}
.exp-intro .eyebrow {
  font-family: var(--fg-font-body);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--fg-navy-500);
  margin-bottom: 22px;
}
.exp-intro hr.exp-rule {
  width: 80px; height: 1px;
  background: var(--fg-gold-rule);
  border: 0;
  margin: 0 auto 38px;
}
.exp-intro p {
  font-family: var(--fg-font-display);
  font-style: italic;
  font-size: clamp(21px, 2.5vw, 28px);
  line-height: 1.55;
  letter-spacing: 0.01em;
  color: var(--fg-navy);
  margin: 0;
  text-wrap: pretty;
}

/* ============================================================
   CHEF D'ORCHESTRE — embedded conceptual plate
   ============================================================ */
.exp-orchestre {
  background: #06090f;
  padding: 0;
}
.exp-orchestre-inner {
  position: relative;
  max-width: none;
  width: 100%;
  margin: 0;
  height: 100vh;
  overflow: hidden;
  background: #06090f;
}
.orchestre-frame {
  width: 100%; height: 100%;
  border: 0;
  display: block;
}
.exp-orchestre-inner .corner { display: none; }

/* ============================================================
   EXPERTISES — editorial two-column sections
   ============================================================ */
.exp-list {
  background: var(--fg-ivory);
  padding: 0 56px 40px;
}
.exp {
  max-width: 1200px;
  margin: 0 auto;
  padding: 92px 0;
  border-top: 1px solid var(--fg-line);
  scroll-margin-top: calc(var(--header-h, 96px) + 24px);
}
.exp-inner {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: 80px;
  align-items: start;
}
.exp-aside {
  position: sticky;
  top: calc(var(--header-h, 96px) + 40px);
}
.exp-num {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--fg-font-display);
  font-size: 16px;
  letter-spacing: 0.28em;
  color: var(--fg-champagne-600);
  margin-bottom: 22px;
}
.exp-num .dia {
  width: 9px; height: 9px;
  background: var(--fg-champagne);
  transform: rotate(45deg);
}
.exp-aside h2 {
  font-family: var(--fg-font-display);
  font-weight: 400;
  font-size: clamp(30px, 3.4vw, 44px);
  line-height: 1.1;
  letter-spacing: 0.02em;
  color: var(--fg-navy);
  margin: 0 0 24px;
  text-wrap: balance;
}
.exp-accroche {
  font-family: var(--fg-font-display);
  font-style: italic;
  font-size: clamp(18px, 1.9vw, 22px);
  line-height: 1.45;
  letter-spacing: 0.01em;
  color: var(--fg-navy-500);
  margin: 0;
  padding-left: 22px;
  border-left: 2px solid var(--fg-champagne);
  text-wrap: pretty;
}
.exp-body { padding-top: 6px; }
.exp-desc {
  font-family: var(--fg-font-body);
  font-size: 17px;
  line-height: 1.78;
  color: var(--fg-ink-2);
  margin: 0;
  text-wrap: pretty;
}
.exp-sujets { margin-top: 38px; }
.exp-sujets-label {
  font-family: var(--fg-font-body);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--fg-champagne);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.exp-sujets-label::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(255, 225, 182, 0.22);
}
.chips {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.chips li {
  font-family: var(--fg-font-body);
  font-size: 13px;
  letter-spacing: 0.01em;
  color: rgba(255, 255, 255, 0.84);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 225, 182, 0.2);
  border-radius: var(--fg-radius-sm);
  padding: 7px 13px;
  transition: border-color 280ms ease, color 280ms ease, background 280ms ease, transform 280ms ease;
}
.chips li:hover {
  border-color: var(--fg-champagne);
  background: rgba(255, 225, 182, 0.12);
  color: #fff;
  transform: translateY(-1px);
}

/* ============================================================
   EXPERTISES — sticky stacking cards (scroll reveal)
   ============================================================ */
.exp-stack {
  background: var(--fg-ivory);
  padding: 72px 56px 120px;
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
  max-width: 1320px;
  margin: 0 auto;
  --thread: 0; /* @kind other */
  --lit: 0; /* @kind other */
}
/* luminous scroll thread — a champagne spine in the centre gutter that
   draws from card 1 to card 8 as the section scrolls past (--thread 0→1). */
.exp-thread {
  position: absolute;
  top: 72px;
  bottom: 120px;
  left: 50%;
  width: 2px;
  transform: translateX(-50%);
  z-index: 0;
  pointer-events: none;
  border-radius: 2px;
  background: rgba(255, 225, 182, 0.13);
}
.exp-thread::after {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 0;
  height: calc(var(--thread, 0) * 100%);
  border-radius: 2px;
  background: linear-gradient(180deg, rgba(255, 225, 182, 0.92), rgba(255, 225, 182, 0.42));
  box-shadow: 0 0 12px rgba(255, 225, 182, 0.5);
}
.exp-thread::before {
  content: "";
  position: absolute;
  left: 50%;
  top: calc(var(--thread, 0) * 100%);
  width: 9px; height: 9px;
  margin-left: -4.5px; margin-top: -4.5px;
  border-radius: 50%;
  background: var(--fg-champagne);
  box-shadow: 0 0 16px 3px rgba(255, 225, 182, 0.6);
}
.xcard {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  min-height: 440px;
  background: linear-gradient(158deg, #0a2350 0%, #011536 60%, #021026 100%);
  border: 1px solid rgba(255, 225, 182, 0.14);
  border-radius: var(--fg-radius-lg);
  box-shadow: 0 18px 46px -28px rgba(1, 21, 54, 0.5);
  overflow: hidden;
  scroll-margin-top: calc(var(--header-h, 96px) + 24px);
  transition: transform 460ms cubic-bezier(0.22, 1, 0.36, 1),
              box-shadow 460ms cubic-bezier(0.22, 1, 0.36, 1),
              border-color 460ms ease;
}
.xcard:hover {
  transform: translateY(-7px);
  box-shadow: 0 44px 84px -34px rgba(1, 21, 54, 0.62);
  border-color: rgba(255, 225, 182, 0.42);
}
/* maillage maison en dégradé — fort en haut-gauche, s'estompe vers le bas-droite */
.xcard::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='36' height='36' viewBox='0 0 36 36'><path d='M 0 0 L 36 36 M 36 0 L 0 36' stroke='%23FFE1B6' stroke-opacity='0.5' stroke-width='0.6'/></svg>");
  background-size: 36px 36px;
  background-position: 0 0;
  opacity: 0.22;
  -webkit-mask-image: linear-gradient(135deg, #000 0%, rgba(0,0,0,0.5) 46%, rgba(0,0,0,0) 90%);
  mask-image: linear-gradient(135deg, #000 0%, rgba(0,0,0,0.5) 46%, rgba(0,0,0,0) 90%);
  transition: opacity 520ms ease, background-position 900ms cubic-bezier(0.22, 1, 0.36, 1);
}
.xcard:hover::before {
  opacity: 0.85;
  background-position: 36px 36px;
}
.xcard-text {
  position: relative;
  z-index: 2;
  padding: clamp(32px, 3.2vw, 50px);
  display: flex;
  flex-direction: column;
  flex: 1;
}
.xnum {
  display: inline-flex; align-items: center; gap: 14px;
  font-family: var(--fg-font-display);
  font-size: 16px; letter-spacing: 0.28em;
  color: var(--fg-champagne-600);
  margin-bottom: 22px;
}
.xnum .dia { width: 9px; height: 9px; background: var(--fg-champagne); transform: rotate(45deg); }
.xcard-text h2 {
  font-family: var(--fg-font-display); font-weight: 400;
  font-size: clamp(30px, 3.2vw, 44px); line-height: 1.08;
  letter-spacing: 0.02em; color: #ffffff; margin: 0 0 18px;
  text-wrap: balance;
}
.xaccroche {
  font-family: var(--fg-font-display); font-style: italic;
  font-size: clamp(17px, 1.7vw, 21px); line-height: 1.45;
  color: var(--fg-champagne); margin: 0 0 22px;
  padding-left: 20px; border-left: 2px solid var(--fg-champagne);
  text-wrap: pretty;
}
.xdesc {
  font-family: var(--fg-font-body); font-size: 16.5px; line-height: 1.75;
  color: rgba(255, 255, 255, 0.82); margin: 0; text-wrap: pretty;
}
.xsujets { margin-top: 28px; }
/* calculette CTA (carte assurance de prêt — produit d'appel) */
.xcalc-link {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  margin-top: 26px;
  padding: 13px 22px;
  background: var(--fg-champagne);
  color: var(--fg-navy);
  font-family: var(--fg-font-body);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 0.03em;
  text-decoration: none;
  border: 1px solid var(--fg-champagne);
  transition: background 260ms ease, color 260ms ease;
}
.xcalc-link .dia {
  width: 7px; height: 7px;
  background: var(--fg-navy);
  transform: rotate(45deg);
  transition: transform 380ms cubic-bezier(0.22,1,0.36,1);
}
.xcalc-arrow { transition: transform 300ms ease; }
.xcalc-link:hover { background: transparent; color: var(--fg-navy); }
.xcalc-link:hover .dia { transform: rotate(225deg); }
.xcalc-link:hover .xcalc-arrow { transform: translateX(4px); }

/* "En discuter avec un expert" — outline CTA on every card except #02 */
.xdiscuter-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 26px;
  padding: 12px 22px;
  background: transparent;
  color: #fff;
  font-family: var(--fg-font-body);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 0.03em;
  text-decoration: none;
  border: 1px solid rgba(255, 225, 182, 0.32);
  transition: background 260ms ease, color 260ms ease, border-color 260ms ease;
}
.xdiscuter-link .dia {
  width: 7px; height: 7px;
  background: var(--fg-champagne);
  transform: rotate(45deg);
  transition: transform 380ms cubic-bezier(0.22, 1, 0.36, 1);
}
.xdiscuter-link:hover { background: var(--fg-champagne); color: var(--fg-navy); border-color: var(--fg-champagne); }
.xdiscuter-link:hover .dia { transform: rotate(225deg); }

/* visual side — navy panel with maillage, brand diamond & ghost numeral */
.xcard-visual {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  opacity: 0.5;
  pointer-events: none;
  transition: opacity 560ms ease;
}
.xcard:hover .xcard-visual { opacity: 0.9; }
.xcard:hover .xghost { -webkit-text-stroke-color: rgba(255, 225, 182, 0.5); }
.xcard-visual::before {
  content: "";
  display: none;
  position: absolute; inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='34' height='34' viewBox='0 0 34 34'><path d='M 0 0 L 34 34 M 34 0 L 0 34' stroke='%23FFE1B6' stroke-opacity='0.06' stroke-width='0.4'/></svg>");
  background-size: 34px 34px;
}
.xghost {
  position: absolute; right: 30px; bottom: -22px;
  font-family: var(--fg-font-display);
  font-size: clamp(150px, 15vw, 230px); line-height: 0.78;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 225, 182, 0.34);
  transition: -webkit-text-stroke-color 560ms ease;
  letter-spacing: 0.01em;
}
/* per-card geometric shape traced by a luminous halo */
.xcard-visual .xshape {
  display: none;
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  overflow: visible;
  pointer-events: none;
  z-index: 1;
}
.xcard-visual .xline {
  fill: none;
  stroke: rgba(255, 225, 182, 0.32);
  stroke-width: 1;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.xcard-visual .xnode { fill: var(--fg-champagne); }
/* Sober marker: a single solid, opaque champagne dot — no soft glow,
   tuned to the same finesse as the .xghost background numerals. */
.xcard-visual .xhalo { fill: transparent; opacity: 0; filter: none; }
.xcard-visual .xhalo-core { fill: var(--fg-champagne); opacity: 1; filter: none; }
@media (prefers-reduced-motion: reduce) {
  .xcard-visual .xshape animateMotion { display: none; }
  .xcard-visual .xhalo, .xcard-visual .xhalo-core { opacity: 0; }
}

.xmotif {
  position: absolute; top: 46%; left: 50%;
  transform: translate(-50%, -50%);
  width: clamp(150px, 16vw, 210px); height: clamp(150px, 16vw, 210px);
  opacity: 0.42;
}

/* harp — 8 faint strings per card; each lights as the sweeping point
   crosses it (left→right with scroll progress --thread 0→1). */
.xcard-visual .harp {
  position: absolute;
  inset: 11% 0;
  z-index: 2;
  pointer-events: none;
}
.hstr {
  position: absolute;
  top: 0; bottom: 0;
  left: var(--sx);
  width: 1.5px;
  transform: translateX(-50%);
  background: rgba(255, 225, 182, 0.07);
}
.hstr::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(255,225,182,0) 0%, rgba(255,225,182,0.55) 50%, rgba(255,225,182,0) 100%);
  box-shadow: 0 0 8px rgba(255, 225, 182, 0.4);
  opacity: clamp(0, calc(var(--lit, 0) - var(--sj) + 1), 1);
  transition: opacity 450ms ease;
}
.hsweep {
  display: none;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px) {
  .exp-hero { min-height: 72vh; }
  .exp-intro { padding: 80px 28px; }
  .exp-orchestre { padding: 0; }
  .exp-orchestre-inner { height: auto; aspect-ratio: 16 / 11; }
  .exp-list { padding: 0 28px 24px; }
  .exp { padding: 64px 0; }
  .exp-inner {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .exp-aside { position: static; }

/* closing CTA under the expertise cards */
.exp-cta {
  background: var(--fg-ivory);
  text-align: center;
  padding: 0 56px 120px;
}
.exp-cta-line {
  font-family: var(--fg-font-display);
  font-style: italic;
  font-size: clamp(20px, 2.4vw, 27px);
  color: var(--fg-navy);
  margin: 0 0 28px;
}
.exp-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--fg-champagne);
  color: var(--fg-navy);
  font-family: var(--fg-font-body);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.04em;
  padding: 17px 30px;
  text-decoration: none;
  border: 1px solid var(--fg-champagne);
  transition: background 280ms ease, color 280ms ease;
}
.exp-cta-btn .dia {
  width: 7px; height: 7px;
  background: var(--fg-navy);
  transform: rotate(45deg);
  transition: transform 400ms cubic-bezier(0.22,1,0.36,1);
}
.exp-cta-btn:hover { background: transparent; color: var(--fg-navy); }
.exp-cta-btn:hover .dia { transform: rotate(225deg); }

/* tablet & below: single-column grid */
  .exp-stack { padding: 48px 24px 90px; grid-template-columns: 1fr; gap: 22px; max-width: 640px; }
  .exp-thread { display: none; }
  .xcard { min-height: 0; }
  .xcard-visual .harp { display: none; }
  .xghost { font-size: 150px; bottom: -14px; right: 20px; }
}

@media (max-width: 560px) {
  .exp-intro { padding: 64px 22px; }
  .exp-list { padding: 0 22px 20px; }
  .exp { padding: 52px 0; }
  .exp-inner { gap: 28px; }
  .exp-stack { padding: 32px 16px 64px; gap: 18px; }
  .xcard { min-height: 0; }
  .xcard-text { padding: 30px 24px; }
  .xghost { font-size: 104px; bottom: -8px; right: 14px; }
}
