.velv-consent[hidden],
.velv-consent [hidden],
.velv-consent-floating[hidden] { display: none !important; }

html.velv-consent-open { overflow: hidden !important; }

#velv-consent {
  bottom: 0 !important;
  height: 100vh !important;
  height: 100dvh !important;
  left: 0 !important;
  margin: 0 !important;
  max-height: none !important;
  max-width: none !important;
  padding: 0 !important;
  position: fixed !important;
  right: 0 !important;
  top: 0 !important;
  transform: none !important;
  width: 100vw !important;
  z-index: 2147482999 !important;
}

#velv-consent,
#velv-consent * { box-sizing: border-box; }

.velv-consent__backdrop {
  background: rgba(18, 27, 36, .62);
  inset: 0;
  position: fixed !important;
  transform: none !important;
  width: 100vw !important;
  height: 100vh !important;
  height: 100dvh !important;
  z-index: 2147483000;
}

.velv-consent__dialog {
  background: var(--velv-consent-bg, #fff);
  border: 1px solid var(--velv-consent-border, #d4d6d8);
  box-shadow: 0 20px 70px rgba(0, 0, 0, .3);
  color: var(--velv-consent-text, #2f343b);
  left: 50vw !important;
  max-height: calc(100vh - 36px);
  max-width: 840px !important;
  overflow-y: auto;
  padding: 28px 30px 20px;
  position: fixed !important;
  top: 50vh !important;
  top: 50dvh !important;
  transform: translate(-50%, -50%) !important;
  width: calc(100vw - 32px) !important;
  z-index: 2147483001;
}

.velv-consent__dialog h2 {
  color: var(--velv-consent-text, #2f343b);
  font-size: 22px;
  font-weight: 600;
  line-height: 1.3;
  margin: 0 34px 12px 0;
  text-transform: none;
}

.velv-consent__message {
  color: var(--velv-consent-text, #2f343b);
  font-size: 15px;
  line-height: 1.55;
  margin: 0;
}

.velv-consent__close {
  background: transparent;
  border: 0;
  color: var(--velv-consent-text, #2f343b);
  cursor: pointer;
  font-size: 30px;
  line-height: 1;
  padding: 6px;
  position: absolute;
  right: 13px;
  top: 10px;
}

.velv-consent__intro-actions,
.velv-consent__settings-actions {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 24px;
}

.velv-consent__button {
  align-items: center;
  border: 2px solid var(--velv-consent-primary, #0b3a78);
  border-radius: 2px;
  cursor: pointer;
  display: inline-flex;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  justify-content: center;
  line-height: 1.25;
  min-height: 48px;
  padding: 10px 14px;
  text-align: center;
}

.velv-consent__button--primary {
  background: var(--velv-consent-primary, #0b3a78);
  color: #fff !important;
}

.velv-consent__button--outline {
  background: #fff;
  color: var(--velv-consent-primary, #0b3a78);
}

.velv-consent__button:focus-visible,
.velv-consent__category-toggle:focus-visible,
.velv-consent__back:focus-visible,
.velv-consent__close:focus-visible {
  outline: 3px solid rgba(11, 58, 120, .28);
  outline-offset: 2px;
}

.velv-consent--saving .velv-consent__button { opacity: .65; }

.velv-consent__categories {
  border-bottom: 1px solid var(--velv-consent-border, #d4d6d8);
  margin-top: 20px;
}

.velv-consent__category {
  border-top: 1px solid var(--velv-consent-border, #d4d6d8);
}

.velv-consent__category-row {
  align-items: center;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  min-height: 62px;
}

.velv-consent__category-toggle {
  align-items: center;
  background: transparent;
  border: 0;
  color: var(--velv-consent-text, #2f343b);
  cursor: pointer;
  display: flex;
  flex: 1 1 auto;
  font: inherit;
  font-size: 16px;
  font-weight: 650;
  gap: 9px;
  padding: 14px 0;
  text-align: left;
}

.velv-consent__chevron {
  display: inline-block;
  font-size: 25px;
  line-height: 1;
  transform: rotate(0deg);
  transition: transform .18s ease;
}

.velv-consent__category--open .velv-consent__chevron { transform: rotate(90deg); }

.velv-consent__always {
  color: var(--velv-consent-primary, #0b3a78);
  flex: 0 0 auto;
  font-size: 13px;
  font-weight: 600;
}

.velv-consent__choice {
  align-items: center;
  display: flex;
  flex: 0 0 auto;
  font-size: 13px;
  gap: 7px;
  margin: 0;
}

.velv-consent__choice input {
  height: 1px;
  opacity: 0;
  position: absolute;
  width: 1px;
}

.velv-consent__switch {
  background: #e6554f;
  border-radius: 20px;
  cursor: pointer;
  height: 27px;
  position: relative;
  transition: background .18s ease;
  width: 50px;
}

.velv-consent__switch::after {
  background: #fff;
  border-radius: 50%;
  content: '×';
  color: #e6554f;
  font-size: 16px;
  height: 21px;
  left: 3px;
  line-height: 19px;
  position: absolute;
  text-align: center;
  top: 3px;
  transition: transform .18s ease;
  width: 21px;
}

.velv-consent__choice input:checked + .velv-consent__switch { background: var(--velv-consent-primary, #0b3a78); }
.velv-consent__choice input:checked + .velv-consent__switch::after {
  color: var(--velv-consent-primary, #0b3a78);
  content: '✓';
  transform: translateX(23px);
}
.velv-consent__choice input:focus-visible + .velv-consent__switch { outline: 3px solid rgba(11, 58, 120, .28); }

.velv-consent__details {
  padding: 0 0 18px 33px;
}
.velv-consent__details > p {
  color: var(--velv-consent-text, #2f343b);
  font-size: 14px;
  line-height: 1.5;
  margin: 0 0 14px;
}
.velv-consent__table-wrap { overflow-x: auto; }
.velv-consent__table {
  border-collapse: collapse;
  font-size: 12px;
  min-width: 640px;
  width: 100%;
}
.velv-consent__table th,
.velv-consent__table td {
  border: 1px solid var(--velv-consent-border, #d4d6d8);
  color: var(--velv-consent-text, #2f343b);
  line-height: 1.35;
  padding: 8px;
  text-align: left;
  vertical-align: top;
}
.velv-consent__table th { background: rgba(0, 0, 0, .035); font-weight: 700; }
.velv-consent__table th:first-child { width: 20%; }
.velv-consent__table th:nth-child(2) { width: 18%; }
.velv-consent__table th:last-child { width: 15%; }

.velv-consent__back {
  background: transparent;
  border: 0;
  color: var(--velv-consent-primary, #0b3a78);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  margin-top: 13px;
  padding: 4px 0;
}

.velv-consent__error {
  background: #fff0ef;
  border-left: 4px solid #c7352d;
  color: #8b211c;
  font-size: 13px;
  margin: 16px 0 0;
  padding: 10px 12px;
}

.velv-consent__footer {
  align-items: flex-end;
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 14px;
  text-align: right;
}
.velv-consent__footer a { color: var(--velv-consent-primary, #0b3a78); font-size: 13px; text-decoration: underline; }
.velv-consent__footer small { color: var(--velv-consent-text, #2f343b); font-size: 11px; opacity: .82; overflow-wrap: anywhere; }
.velv-consent__identifier strong { font-weight: 600; }

.velv-consent-floating {
  align-items: center;
  background: var(--velv-consent-primary, #0b3a78) !important;
  background-image: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  bottom: 0 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .18);
  box-sizing: border-box;
  color: #fff !important;
  cursor: pointer;
  display: inline-flex !important;
  font-family: Arial, Helvetica, sans-serif !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  gap: 7px;
  height: 40px !important;
  justify-content: center;
  line-height: 1 !important;
  margin: 0 !important;
  max-height: 40px !important;
  max-width: calc(100vw - 16px);
  min-height: 40px !important;
  min-width: 0 !important;
  padding: 0 16px !important;
  position: fixed;
  transform: none !important;
  white-space: nowrap;
  width: 260px !important;
  -webkit-text-fill-color: #fff !important;
  z-index: 2147482990;
}
.velv-consent-floating span { color: #fff !important; -webkit-text-fill-color: #fff !important; }
.velv-consent-floating--right { left: auto !important; right: 0 !important; }
.velv-consent-floating--left { left: 0 !important; right: auto !important; }
.velv-consent-floating svg {
  color: #fff !important;
  fill: none;
  height: 18px;
  stroke: #fff !important;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
  width: 18px;
}

@media (max-width: 767.98px) {
  .velv-consent__dialog { max-height: calc(100vh - 18px); max-height: calc(100dvh - 18px); padding: 20px 17px 15px; width: calc(100vw - 18px) !important; }
  .velv-consent__dialog h2 { font-size: 18px; }
  .velv-consent__message { font-size: 13px; line-height: 1.45; }
  .velv-consent__intro-actions, .velv-consent__settings-actions { grid-template-columns: 1fr; gap: 8px; margin-top: 17px; }
  .velv-consent__button { font-size: 13px; min-height: 43px; }
  .velv-consent__category-row { min-height: 55px; }
  .velv-consent__category-toggle { font-size: 14px; }
  .velv-consent__always { font-size: 11px; }
  .velv-consent__details { padding-left: 0; }
  .velv-consent__footer { align-items: center; text-align: center; }
  .velv-consent-floating { font-size: 13px !important; padding: 0 12px !important; width: calc(50vw - 3px) !important; }
}

/* v2.0.6 — Mobile floating control UX
 * Home: keep the full-width half-screen control.
 * Inner pages: compact icon-only control.
 * Cart/checkout/account/auth: hide reopen control so it cannot cover actions.
 * The initial consent dialog is NOT affected by these rules.
 */
@media (max-width: 767.98px) {
  body:not(#index) .velv-consent-floating {
    border-radius: 50% !important;
    bottom: 8px !important;
    height: 42px !important;
    max-height: 42px !important;
    min-height: 42px !important;
    min-width: 42px !important;
    padding: 0 !important;
    width: 42px !important;
  }

  body:not(#index) .velv-consent-floating--right {
    left: auto !important;
    right: 6px !important;
  }

  body:not(#index) .velv-consent-floating--left {
    left: 6px !important;
    right: auto !important;
  }

  body:not(#index) .velv-consent-floating span {
    border: 0 !important;
    clip: rect(0 0 0 0) !important;
    height: 1px !important;
    margin: -1px !important;
    overflow: hidden !important;
    padding: 0 !important;
    position: absolute !important;
    white-space: nowrap !important;
    width: 1px !important;
  }

  body:not(#index) .velv-consent-floating svg {
    height: 20px !important;
    width: 20px !important;
  }

  body#cart .velv-consent-floating,
  body#checkout .velv-consent-floating,
  body#order .velv-consent-floating,
  body#authentication .velv-consent-floating,
  body#registration .velv-consent-floating,
  body#my-account .velv-consent-floating,
  body[id^="module-"] .velv-consent-floating {
    display: none !important;
  }
}
