/* ────────── 1. Overall canvas ────────── */
.supplement-page {
  margin-inline: clamp(16px, 8vw, 15vw);
  font-family: 'IBM Plex Sans', sans-serif;
}

/* ────────── 2. Top utility bar ────────── */
.supplement-header {
  max-width: 1120px;
  margin-block-start: 64px;
  margin-block-end: 120px;
  margin-inline: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  gap: 1rem;
}

:dir(rtl) .supplement-header {
  flex-direction: row-reverse;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 1.6rem;
  color: #1A2950;
  font-weight: 700;
  font-size: 18px;
  line-height: 1;
}

:dir(rtl) .back-link {
  flex-direction: row-reverse;
}

.back-link:hover {
  text-decoration: underline;
}

/* back-arrow icon */
.back-link svg{
  width:44px;          /* any size you like */
  height:auto;
  padding:12px;
  box-sizing:border-box;
  fill:none;           /* important – we're using stroke now */
  border:1px solid #EE4794;
  border-radius:50%;
  display:inline-block;
  vertical-align:middle;
  transition:background-color .2s, stroke .2s, transform .2s;
  transform: none; /* Base state for transition */
}

/* flex centring only if flex is supported */
@supports (display: flex) {
  .back-link svg {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
}

/* hover / focus */
.back-link:hover svg,
.back-link:focus svg { background-color: #EE4794; }

.back-link:hover svg,
.back-link:focus svg { color: white; }

/* ────────── 3. Graphics area ────────── */
.supplement-graphic {
  max-width: 1120px;
  margin: 0 auto 120px;
  text-align: center;
}

.supplement-graphic img {
  width: auto;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
  display: block;
}

.supplement-graphic[data-index="0"] img {
  width: 100%;
}

.supplement-graphic[data-index="1"] img {
  width: 57.32%;
}

/* download button */
.btn-download {
  display: inline-flex;
  align-items: center;
  gap: 1.25rem;
  width: max-content;
  margin: 32px auto 0;
  padding: .75rem 1.75rem;
  color: #fff;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  background: #1A2950;
  transition: background .25s;
}

.btn-download svg {
  width: 14px;
  height: 15px;
  stroke: currentColor;
}
:dir(rtl) .btn-download svg {
  transform: scaleX(-1);
}

.btn-download:hover { background: #EE4794; }

/* ────────── 4. Bottom language band ────────── */
.language-band {
  background: #1A2950;
  padding-block: 120px;
  padding-inline: clamp(16px, 8vw, 15vw);
  color: #ffffff;
}

.language-band h3 {
  max-width: 1120px;
  margin-inline: auto;
  margin-block-end: 40px;
  display: flex;
  align-items: center;
  font-size: 24px;
  font-weight: 600;
  text-align: start;
  color: #ffffff;
}

.lang-band-icon {
  width: 24px;
  height: 24px;
  margin-inline-end: 12px;
}

.language-grid {
  max-width: 1120px;
  margin-inline: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 48px;
  line-height: 1.4;
}

.language-grid a {
  color: #ffffff;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  display: inline-block;
  padding: 0;                       /* kills any stray grid gap */
}

.language-grid a:hover { text-decoration: underline; }

/* ────────── Language picker (header) ────────── */
.lang-picker {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  background: #E2ECF3;
  border: 1px solid #E2ECF3;
  border-radius: 10px;
  padding-inline: 1.2rem;
  padding-block: .8rem;
  font-size: 18px;
}

/* keep for a11y but hide visually */
.lang-picker select {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  border: 0;
  clip: rect(0 0 0 0);
  overflow: hidden;
}

.lang-label  {
  font-weight: 700;
  color: #1A2950;
  line-height: 1;
}

.lang-label img {
  width: 26px;
  height: 26px;
  margin: 12px;
  vertical-align: middle;
}

/* trigger button */
.lang-trigger {
  background: none;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 6.6rem;
  font: inherit;
  color: #1A2950;
  cursor: pointer;
}

.lang-trigger svg {
  transition: transform .2s;
}

:dir(rtl) .lang-trigger svg {
  transform: scaleX(-1);
}

.lang-trigger[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

:dir(rtl) .lang-trigger[aria-expanded="true"] svg {
  transform: scaleX(-1) rotate(180deg);
}

/* menu panel */
.lang-menu {
  position: absolute;
  z-index: 20;
  top: calc(100% + 6px);
  inset-inline-end: 0;
  width: 192px;
  background: #E2ECF3;
  border: 1px solid #E2ECF3;
  border-radius: 8px;
  box-shadow: 0 8px 32px rgba(0,0,0,.12);
  list-style: none;
  margin: 0;
  padding: .5rem 0;
}

.lang-menu li {
  padding-inline: 1.2rem;
  padding-block: .65rem;
  font-size: 18px;
  color: #1A2950;
  cursor: pointer;
  text-align: start;
}

.lang-menu li:hover      { background: #D1E3E9; }
.lang-menu li.is-selected {
  font-weight: 700;
  text-decoration: underline;
}

/* limited stylistic control inside <select>/<option> */
.lang-picker select option {
  background: #ffffff;
  padding-inline: 1rem;
  padding-block: .55rem;
  font-size: 16px;
}

.lang-picker select option:checked {
  background: #eaf2ff;
  color: #1A2950;
  text-decoration: underline;
}

/* ────────── Responsive tweaks ────────── */

/* ≤ 826 px ─────────────────────────────── */
@media (max-width: 826px) {
  .back-link svg {
    align-self: flex-start;
  }
}

/* ≤ 600 px ─────────────────────────────── */
@media (max-width: 600px) {
  .supplement-header {
    flex-direction: column-reverse;
    align-items: flex-start;
    gap: 64px;
    margin-block-end: 64px;
  }

  /* Ensure RTL nav also stacks and aligns to the inline-end edge */
  :dir(rtl) .supplement-header {
    flex-direction: column-reverse;
    align-items: flex-end;
  }
  
  .supplement-graphic[data-index="1"] img {
    width: 100%;
  }
}
