/* OVIIGI EXCHANGE PREMIUM V2 */

.oviigi-exchange-v2 {
  position: fixed;
  top: 92px;
  right: 18px;
  z-index: 950;
  color: #fff;
  font-family: inherit;
  font-size: 13px;
}

.oviigi-exchange-v2 *,
.oviigi-exchange-v2 *::before,
.oviigi-exchange-v2 *::after {
  box-sizing: border-box;
}

.oe2-trigger {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 36px;
  padding: 7px 13px;
  border: 1px solid rgba(91, 217, 245, .48);
  border-radius: 999px;
  background: rgba(9, 29, 51, .76);
  color: #fff;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .17);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.oe2-trigger span:first-child {
  color: #59ddf6;
  font-size: 18px;
}

.oe2-trigger:hover {
  border-color: #5cdef5;
  background: rgba(14, 47, 76, .94);
}

.oe2-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: min(340px, calc(100vw - 24px));
  max-height: calc(100dvh - 160px);
  overflow-y: auto;
  padding: 17px;
  border: 1px solid rgba(91, 217, 245, .30);
  border-radius: 18px;
  background: rgba(8, 26, 47, .96);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .30);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
}

.oe2-panel[hidden] {
  display: none !important;
}

.oe2-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.oe2-heading strong {
  display: block;
  font-size: 16px;
  font-weight: 750;
  letter-spacing: .1px;
}

.oe2-heading small {
  display: block;
  margin-top: 5px;
  color: #9ebed3;
  font-size: 10px;
}

.oe2-close {
  border: 0;
  padding: 0 4px;
  background: transparent;
  color: #c1d8e8;
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.oe2-panel label {
  display: block;
  margin: 10px 0 6px;
  color: #b6d0e2;
  font-size: 11px;
  font-weight: 600;
}

.oe2-panel input,
.oe2-panel select {
  width: 100%;
  min-width: 0;
  min-height: 42px;
  padding: 10px;
  border: 1px solid #355672;
  border-radius: 10px;
  outline: none;
  background: #102b48;
  color: #fff;
  font: inherit;
  font-size: 13px;
}

.oe2-panel input:focus,
.oe2-panel select:focus {
  border-color: #62dff6;
  box-shadow: 0 0 0 2px rgba(98, 223, 246, .14);
}

.oe2-currencies {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 36px minmax(0, 1fr);
  align-items: end;
  gap: 9px;
  margin-top: 12px;
}

.oe2-currencies > div {
  min-width: 0;
}

.oe2-swap {
  width: 36px;
  height: 42px;
  border: 1px solid rgba(93, 219, 245, .48);
  border-radius: 10px;
  background: rgba(28, 75, 108, .65);
  color: #65dff8;
  font-size: 21px;
  cursor: pointer;
}

.oe2-swap:hover {
  background: rgba(35, 101, 137, .85);
}

.oe2-result {
  margin-top: 18px;
  padding: 15px;
  border: 1px solid rgba(89, 217, 245, .14);
  border-radius: 12px;
  background: rgba(5, 20, 37, .75);
}

.oe2-result small {
  display: block;
  color: #9cbad0;
  font-size: 11px;
}

.oe2-result strong {
  display: block;
  margin-top: 7px;
  color: #fff;
  font-size: clamp(18px, 4vw, 23px);
  font-weight: 750;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.oe2-note {
  margin: 13px 0 0;
  color: #94b2c8;
  font-size: 10px;
  line-height: 1.6;
}

.oe2-trigger:focus-visible,
.oe2-close:focus-visible,
.oe2-swap:focus-visible {
  outline: 2px solid #65dff8;
  outline-offset: 3px;
}

@media (max-width: 600px) {
  .oviigi-exchange-v2 {
    top: 76px;
    right: 10px;
  }

  .oe2-trigger {
    min-height: 34px;
    padding: 6px 11px;
    font-size: 11px;
  }

  .oe2-panel {
    width: min(330px, calc(100vw - 20px));
    max-height: calc(100dvh - 130px);
    padding: 15px;
    border-radius: 16px;
  }
}

@media (max-height: 500px) {
  .oe2-panel {
    max-height: calc(100dvh - 105px);
  }
}


/* OVIIGI COMPACT SELECTOR 448A */
.oviigi-exchange-v2 .oe2-picker {
  width: 100%;
  min-height: 42px;
  padding: 10px;
  border: 1px solid #355672;
  border-radius: 10px;
  background: #102b48;
  color: #fff;
  font: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}
.oviigi-exchange-v2 .oe2-picker-popup {
  position: relative;
  margin-top: 12px;
  padding: 10px;
  border: 1px solid rgba(91,217,245,.4);
  border-radius: 12px;
  background: #0b2139;
}
.oviigi-exchange-v2 .oe2-picker-popup[hidden] {
  display: none !important;
}
.oviigi-exchange-v2 .oe2-picker-popup input {
  width: 100%;
  min-height: 38px;
  margin-bottom: 8px;
}
.oviigi-exchange-v2 .oe2-picker-list {
  max-height: 220px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.oviigi-exchange-v2 .oe2-picker-option {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
  background: transparent;
  color: #e5f4ff;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.oviigi-exchange-v2 .oe2-picker-option.is-selected {
  color: #65dff8;
  background: rgba(77,190,224,.12);
}
.oviigi-exchange-v2 .oe2-picker-option:focus-visible,
.oviigi-exchange-v2 .oe2-picker:focus-visible {
  outline: 2px solid #65dff8;
  outline-offset: 1px;
}


/* OVIIGI EXCHANGE GLASS PREMIUM 448B */

.oviigi-exchange-v2 .oe2-trigger {
  background: linear-gradient(
    135deg,
    rgba(38,112,162,.42),
    rgba(7,30,58,.42)
  );
  border: 1px solid rgba(115,224,255,.55);
  border-radius: 999px;
  box-shadow:
    0 8px 26px rgba(0,0,0,.16),
    inset 0 1px 0 rgba(255,255,255,.18);
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
}

.oviigi-exchange-v2 .oe2-panel {
  background: linear-gradient(
    145deg,
    rgba(39,99,144,.43),
    rgba(8,31,61,.56) 52%,
    rgba(8,27,53,.62)
  );
  border: 1px solid rgba(133,222,255,.42);
  border-radius: 20px;
  box-shadow:
    0 20px 55px rgba(0,0,0,.24),
    inset 0 1px 0 rgba(255,255,255,.16),
    inset 0 0 24px rgba(77,184,255,.045);
  backdrop-filter: blur(28px) saturate(165%);
  -webkit-backdrop-filter: blur(28px) saturate(165%);
}

.oviigi-exchange-v2 .oe2-panel input,
.oviigi-exchange-v2 .oe2-picker {
  background: rgba(13,43,76,.39);
  border: 1px solid rgba(143,209,242,.35);
  border-radius: 11px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.07);
  color: #fff;
}

.oviigi-exchange-v2 .oe2-swap {
  background: rgba(25,91,132,.36);
  border: 1px solid rgba(100,220,250,.55);
  border-radius: 11px;
  color: #72e7ff;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.oviigi-exchange-v2 .oe2-result {
  background: linear-gradient(
    120deg,
    rgba(7,37,66,.48),
    rgba(24,112,150,.23)
  );
  border: 1px solid rgba(78,211,245,.37);
  border-radius: 13px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.07);
}

.oviigi-exchange-v2 .oe2-result strong {
  color: #77eaff;
  text-shadow: 0 0 16px rgba(79,212,245,.15);
}

.oviigi-exchange-v2 .oe2-picker-popup {
  background: rgba(12,37,67,.86);
  border: 1px solid rgba(112,216,247,.42);
  border-radius: 13px;
  box-shadow: 0 12px 32px rgba(0,0,0,.22);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.oviigi-exchange-v2 .oe2-picker-option {
  border-radius: 7px;
}

.oviigi-exchange-v2 .oe2-picker-option:hover,
.oviigi-exchange-v2 .oe2-picker-option.is-selected {
  background: rgba(80,193,234,.17);
  color: #8cecff;
}

.oviigi-exchange-v2 .oe2-heading strong {
  color: #fff;
  letter-spacing: .15px;
}

.oviigi-exchange-v2 .oe2-heading small,
.oviigi-exchange-v2 .oe2-note {
  color: #c1d8e8;
}

@media (max-width:600px) {
  .oviigi-exchange-v2 .oe2-panel {
    border-radius: 17px;
    padding: 15px;
  }
}

@media (prefers-reduced-transparency:reduce) {
  .oviigi-exchange-v2 .oe2-panel {
    background: #153653;
  }
}


/* OVIIGI GLASS REFINED 448C */

/* Panneau principal : verre bleu nuit */
.oviigi-exchange-v2 .oe2-panel {
  background: linear-gradient(
    145deg,
    rgba(28, 79, 124, .32) 0%,
    rgba(9, 39, 75, .39) 52%,
    rgba(6, 27, 55, .46) 100%
  ) !important;

  border: 1px solid rgba(132, 218, 250, .28);

  box-shadow:
    0 18px 46px rgba(0, 0, 0, .20),
    inset 0 1px 0 rgba(255, 255, 255, .13);

  backdrop-filter: blur(32px) saturate(145%);
  -webkit-backdrop-filter: blur(32px) saturate(145%);
}

/* Petit bouton flottant */
.oviigi-exchange-v2 .oe2-trigger {
  background: linear-gradient(
    135deg,
    rgba(32, 107, 151, .32),
    rgba(8, 35, 66, .42)
  );

  border-color: rgba(125, 220, 250, .35);

  box-shadow:
    0 7px 20px rgba(0, 0, 0, .14),
    inset 0 1px 0 rgba(255, 255, 255, .12);

  backdrop-filter: blur(24px) saturate(145%);
  -webkit-backdrop-filter: blur(24px) saturate(145%);
}

/* Champs et selecteurs */
.oviigi-exchange-v2 .oe2-panel input,
.oviigi-exchange-v2 .oe2-picker {
  background: rgba(12, 47, 82, .37);
  border-color: rgba(139, 208, 239, .28);
  color: #ffffff;
}

/* Inversion des devises */
.oviigi-exchange-v2 .oe2-swap {
  background: rgba(30, 104, 145, .30);
  border-color: rgba(106, 214, 244, .35);
}

/* Resultat */
.oviigi-exchange-v2 .oe2-result {
  background: linear-gradient(
    125deg,
    rgba(5, 29, 56, .35),
    rgba(21, 91, 132, .23)
  );

  border-color: rgba(91, 209, 244, .24);
}

/* Liste de recherche compacte */
.oviigi-exchange-v2 .oe2-picker-popup {
  background: rgba(10, 37, 70, .76);
  border-color: rgba(115, 216, 246, .30);

  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}

.oviigi-exchange-v2 .oe2-picker-list {
  max-height: 220px;
}

/* Lisibilite */
.oviigi-exchange-v2 .oe2-heading strong {
  color: #ffffff;
}

.oviigi-exchange-v2 .oe2-result strong {
  color: #a0efff;
  text-shadow: none;
}

.oviigi-exchange-v2 .oe2-note {
  color: #d0e2ef;
}

/* Accessibilite : transparence reduite */
@media (prefers-reduced-transparency: reduce) {
  .oviigi-exchange-v2 .oe2-panel {
    background: #153653 !important;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}


/* OVIIGI EXCHANGE INTRO ANIMATION 448D */

/* Introduction du bouton flottant */
@keyframes oe2-intro {
  from {
    opacity: 0;
    transform: translateY(-12px) scale(.94);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Ouverture du panneau */
@keyframes oe2-panel-reveal {
  from {
    opacity: 0;
    transform: translateY(-9px) scale(.975);
    filter: brightness(1.14);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: brightness(1);
  }
}

/* Halo lumineux subtil */
@keyframes oe2-cyan-glow {
  0%, 100% {
    box-shadow:
      0 7px 20px rgba(0,0,0,.14),
      0 0 0 rgba(92,222,250,0);
  }
  50% {
    box-shadow:
      0 7px 20px rgba(0,0,0,.14),
      0 0 17px rgba(92,222,250,.24);
  }
}

.oviigi-exchange-v2 .oe2-trigger {
  animation:
    oe2-intro .7s cubic-bezier(.2,.8,.2,1) both,
    oe2-cyan-glow 2.6s ease-in-out .7s 1;
}

.oviigi-exchange-v2 .oe2-panel:not([hidden]) {
  transform-origin: top right;
  animation:
    oe2-panel-reveal .36s
    cubic-bezier(.2,.8,.2,1) both;
}

.oviigi-exchange-v2 .oe2-picker-popup:not([hidden]) {
  animation:
    oe2-panel-reveal .22s ease-out both;
}

.oviigi-exchange-v2 .oe2-swap {
  transition:
    background .2s ease,
    border-color .2s ease,
    transform .2s ease;
}

.oviigi-exchange-v2 .oe2-swap:hover {
  transform: rotate(180deg);
}

/* Respect des preferences d'accessibilite */
@media (prefers-reduced-motion: reduce) {
  .oviigi-exchange-v2 .oe2-trigger,
  .oviigi-exchange-v2 .oe2-panel:not([hidden]),
  .oviigi-exchange-v2 .oe2-picker-popup:not([hidden]) {
    animation: none !important;
  }

  .oviigi-exchange-v2 .oe2-swap {
    transition: none !important;
  }
}
