/* Mina landing — ROI calculator page (roi.html)
   Reuses the homepage chrome (styles.css) and maps the calculator onto
   the Branding Mina scales: cream cards, marine result card, orange accents.
*/

/* —— Page section —— */
.roi {
  display: flex;
  flex-direction: column;
  gap: 64px;
  padding: 64px 120px 140px;
}

.roi__header {
  display: flex;
  flex-direction: column;
  gap: 40px;
  max-width: 860px;
}

.roi__title {
  margin: 0;
  max-width: 720px;
  font-family: var(--font-display);
  font-size: 39px;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -0.04em;
  color: var(--grey-8);
}

.roi__title em {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--orange-5);
  white-space: nowrap;
}

.roi__lead {
  margin: -16px 0 0;
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 400;
  line-height: 32px;
  color: var(--grey-4);
}

@media (max-width: 1024px) {
  .roi {
    gap: 48px;
    padding: 48px clamp(1.25rem, 5vw, 4rem) clamp(3.5rem, 8vw, 8.5rem);
  }
}

@media (max-width: 640px) {
  .roi {
    gap: 32px;
    padding: 32px 16px 64px;
  }

  .roi__header {
    gap: 16px;
  }

  .roi__title {
    font-size: clamp(1.75rem, 7vw, 2.25rem);
  }

  .roi__lead {
    margin: 0;
    font-size: 16px;
    line-height: 28px;
  }
}

/* No "Let's talk" marquee on this page: the section bottom padding is enough */
.roi + .site-footer {
  padding-top: 0;
}

/* —— Calculator —— */
.mina-roi {
  --surface-0: var(--brown-0);
  --surface-1: var(--brown-0-5);
  --line: var(--brown-5);
  --text-1: var(--grey-8);
  --text-2: var(--grey-5);
  --text-3: var(--grey-4);
  --series-1: var(--orange-5);
  --series-2: var(--sky-7);
  --series-3: var(--brown-7);
  --radius: 20px;
  font-family: var(--font-sans);
  color: var(--text-1);
  line-height: 1.45;
}

.mr-grid {
  display: grid;
  grid-template-columns: minmax(300px, 380px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

@media (max-width: 900px) {
  .mr-grid { grid-template-columns: minmax(0, 1fr); }
}

.mr-results {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}

/* Inputs card */
.mr-card {
  padding: 32px;
  border-radius: var(--radius);
  background: var(--surface-1);
}

.mr-card h2 {
  margin: 0 0 24px;
  font-family: var(--font-display);
  font-size: 25px;
  font-weight: 400;
  line-height: 1.2;
  color: var(--text-1);
}

.mr-field { margin-bottom: 20px; }

.mr-field > label,
.mr-legend {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-1);
}

.mr-hint {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.4;
  color: var(--text-3);
}

.mr-input {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-0);
  color: var(--text-1);
  font: inherit;
  font-size: 16px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  transition: border-color 0.15s ease;
}

.mr-input:hover { border-color: var(--brown-6); }

.mr-input:focus-visible {
  outline: 2px solid var(--orange-5);
  outline-offset: 1px;
}

.mr-money { position: relative; }
.mr-money .mr-input { padding-right: 34px; }

.mr-money span {
  position: absolute;
  top: 50%;
  right: 14px;
  transform: translateY(-50%);
  font-size: 15px;
  font-weight: 500;
  color: var(--text-3);
}

/* Chips — same pill language as the nav lang switch */
.mr-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mr-chip {
  padding: 8px 14px;
  border: 0;
  border-radius: 99px;
  background: var(--brown-3);
  color: var(--text-1);
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.mr-chip:hover { background: var(--brown-5); }

.mr-chip[aria-pressed="true"] {
  background: var(--grey-8);
  color: var(--brown-1-5);
  box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.1);
}

.mr-chip[aria-pressed="true"]:hover { background: var(--grey-7); }

.mr-chip:focus-visible {
  outline: 2px solid var(--orange-5);
  outline-offset: 2px;
}

.mr-splits {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.mr-split {
  display: grid;
  grid-template-columns: 1fr 80px;
  gap: 8px;
  align-items: center;
  font-size: 14px;
  color: var(--text-2);
}

.mr-split input {
  width: 100%;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-0);
  color: var(--text-1);
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.mr-split input:focus-visible {
  outline: 2px solid var(--orange-5);
  outline-offset: 1px;
}

.mr-adv {
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.mr-adv summary {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-1);
  list-style: none;
  cursor: pointer;
}

.mr-adv summary::-webkit-details-marker { display: none; }

.mr-adv summary::before {
  content: "+ ";
  font-weight: 600;
  color: var(--orange-5);
}

.mr-adv[open] summary::before { content: "− "; }

.mr-adv .mr-field {
  margin-top: 16px;
  margin-bottom: 0;
}

/* Headline result — marine card, as "Pilotage budgétaire fiable" */
.mr-hero {
  padding: 32px;
  border-radius: var(--radius);
  background: var(--marine-5);
  color: var(--brown-0);
}

.mr-hero-lab {
  font-size: 16px;
  font-weight: 500;
  color: var(--brown-0);
}

.mr-hero-num {
  margin: 12px 0 8px;
  font-family: var(--font-display);
  font-size: clamp(2.75rem, 6vw, 4.5rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

.mr-hero-note {
  font-size: 14px;
  line-height: 1.5;
  color: #cecece;
}

/* Benefit tiles */
.mr-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 16px;
}

.mr-tile {
  padding: 20px;
  border-radius: var(--radius);
  background: var(--surface-1);
}

.mr-tile-h {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-1);
}

.mr-dot {
  flex: 0 0 auto;
  width: 10px;
  height: 10px;
  border-radius: 99px;
}

.mr-tile-num {
  margin: 12px 0 6px;
  font-family: var(--font-display);
  font-size: 31px;
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.mr-tile-note {
  font-size: 13px;
  line-height: 1.4;
  color: var(--text-3);
}

/* Chart + detail cards */
.mr-chart {
  padding: 24px 28px;
  border-radius: var(--radius);
  background: var(--surface-1);
}

.mr-chart h3 {
  margin: 0 0 4px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 400;
  line-height: 1.2;
}

.mr-chart p.mr-cap {
  margin: 0 0 20px;
  font-size: 13px;
  color: var(--text-3);
}

.mr-bar {
  display: flex;
  gap: 3px;
  width: 100%;
  height: 36px;
}

.mr-seg {
  position: relative;
  height: 100%;
  min-width: 2px;
  border-radius: 3px;
  cursor: default;
  transition: filter 0.12s ease;
}

.mr-seg:first-child { border-radius: 10px 3px 3px 10px; }
.mr-seg:last-child  { border-radius: 3px 10px 10px 3px; }
.mr-seg:hover { filter: brightness(1.06); }

.mr-legend2 {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 14px;
}

.mr-leg {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-2);
}

.mr-leg b {
  font-weight: 600;
  color: var(--text-1);
  font-variant-numeric: tabular-nums;
}

.mr-tip {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  z-index: 5;
  padding: 6px 10px;
  border-radius: 8px;
  background: var(--grey-8);
  color: var(--brown-1-5);
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%);
  transition: opacity 0.12s ease;
}

.mr-seg:hover .mr-tip { opacity: 1; }

.mr-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.mr-table th,
.mr-table td {
  padding: 10px 6px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.mr-table th {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-3);
}

.mr-table td:last-child,
.mr-table th:last-child {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.mr-table tr.mr-tot td {
  border-top: 1px solid var(--grey-3);
  border-bottom: 0;
  font-weight: 600;
}

.mr-table .mr-src {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  font-weight: 400;
  color: var(--text-3);
}

/* Audit CTA — sky card */
.mr-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 28px;
  border-radius: var(--radius);
  background: var(--sky-3);
}

.mr-cta p {
  max-width: 52ch;
  margin: 0;
  font-size: 16px;
  line-height: 24px;
  color: var(--grey-8);
}

/* Method and sources */
.mr-foot {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-3);
}

.mr-foot h2 {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 400;
  color: var(--text-1);
}

.mr-foot p { max-width: 860px; margin: 0 0 12px; }
.mr-foot ul { margin: 0; padding-left: 18px; }
.mr-foot li { margin-bottom: 4px; }

.mr-foot a {
  color: var(--text-2);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.mr-foot a:hover { color: var(--orange-5); }

.mr-hidden { display: none !important; }

@media (max-width: 640px) {
  .mr-card,
  .mr-hero { padding: 24px 20px; }

  .mr-chart,
  .mr-cta { padding: 20px; }

  .mr-cta .btn {
    width: 100%;
  }
}
