/* Atlantic Image Defense v1.15.4.19.35.258
   Cross-surface checkbox and file-upload harmonization.
   v258 excludes the dedicated cookie preference switches from the generic square-checkbox reset.
   Public, portal and authentication contexts only. */

body.aid-context-public,
body.aid-context-portal,
body.aid-context-auth {
  --aid-form-control-accent: #12a9b3;
  --aid-form-control-accent-strong: #087f8b;
  --aid-form-control-focus: rgba(18, 169, 179, .24);
  --aid-form-control-radius: 12px;
}

body.aid-context-public {
  --aid-choice-surface: #0f192b;
  --aid-choice-border: #7f96aa;
  --aid-file-surface: #0d1728;
  --aid-file-border: rgba(139, 168, 188, .46);
  --aid-file-text: #e9f2f6;
  --aid-file-button-bg: linear-gradient(135deg, #0e7d89 0%, #0a5668 100%);
  --aid-file-button-border: rgba(109, 231, 228, .42);
  --aid-file-button-text: #ffffff;
}

body.aid-context-portal,
body.aid-context-auth {
  --aid-choice-surface: #ffffff;
  --aid-choice-border: #73889a;
  --aid-file-surface: #f8fafc;
  --aid-file-border: #c8d4de;
  --aid-file-text: #233543;
  --aid-file-button-bg: linear-gradient(135deg, #172737 0%, #24475b 100%);
  --aid-file-button-border: #365a6f;
  --aid-file-button-text: #ffffff;
}

/*
 * Checkbox reset.
 * The explicit inline size prevents generic width:100% rules from pushing
 * the native control to the opposite side of its text.
 */
body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]),
body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]),
body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]) {
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
  display: inline-block;
  inline-size: 20px;
  block-size: 20px;
  width: 20px;
  height: 20px;
  min-inline-size: 20px;
  min-block-size: 20px;
  min-width: 20px;
  min-height: 20px;
  max-inline-size: 20px;
  max-block-size: 20px;
  max-width: 20px;
  max-height: 20px;
  flex: 0 0 20px;
  order: -1;
  margin: 2px 0 0;
  padding: 0;
  border: 2px solid var(--aid-choice-border);
  border-radius: 6px;
  background-color: var(--aid-choice-surface);
  background-position: center;
  background-repeat: no-repeat;
  background-size: 12px 12px;
  box-shadow: 0 1px 2px rgba(5, 17, 28, .12), inset 0 1px 0 rgba(255, 255, 255, .12);
  vertical-align: top;
  cursor: pointer;
  transition: border-color .16s ease, background-color .16s ease, box-shadow .16s ease, transform .12s ease;
}

body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):hover,
body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):hover,
body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):hover {
  border-color: var(--aid-form-control-accent);
}

body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):focus-visible,
body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):focus-visible,
body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):focus-visible {
  outline: none;
  border-color: var(--aid-form-control-accent);
  box-shadow: 0 0 0 4px var(--aid-form-control-focus);
}

body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):checked,
body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):checked,
body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):checked {
  border-color: var(--aid-form-control-accent-strong);
  background-color: var(--aid-form-control-accent-strong);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2.4' d='m3.2 8.3 3 3.1 6.7-7'/%3E%3C/svg%3E");
}

body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):indeterminate,
body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):indeterminate,
body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):indeterminate {
  border-color: var(--aid-form-control-accent-strong);
  background-color: var(--aid-form-control-accent-strong);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-width='2.4' d='M3.2 8h9.6'/%3E%3C/svg%3E");
}

body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):active,
body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):active,
body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):active {
  transform: scale(.94);
}

body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):disabled,
body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):disabled,
body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]):disabled {
  cursor: not-allowed;
  opacity: .52;
}

/* Keep ordinary, unclassed checkbox labels readable without altering bespoke cards. */
body.aid-context-public label:not([class]):has(> input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing])),
body.aid-context-portal label:not([class]):has(> input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing])),
body.aid-context-auth label:not([class]):has(> input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing])) {
  display: inline-flex;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 10px;
  min-width: 0;
  text-align: left;
  cursor: pointer;
}

body.aid-context-public label:has(> input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing])) > :not(input[type="checkbox"]),
body.aid-context-portal label:has(> input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing])) > :not(input[type="checkbox"]),
body.aid-context-auth label:has(> input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing])) > :not(input[type="checkbox"]) {
  min-width: 0;
}

/* Public request centre: explicitly undo the historic width:100% inheritance. */
body.aid-context-public .aid-request-form input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]) {
  width: 20px;
  min-width: 20px;
  max-width: 20px;
}

body.aid-context-public .aid-request-consent,
body.aid-context-public .aid-request-check-grid label {
  justify-content: flex-start;
  text-align: left;
}

/* Corporate file-upload field, progressively enhanced with native selector styling. */
body.aid-context-public input[type="file"],
body.aid-context-portal input[type="file"],
body.aid-context-auth input[type="file"] {
  box-sizing: border-box;
  display: block;
  width: 100%;
  max-width: 100%;
  min-height: 52px;
  padding: 6px;
  border: 1px solid var(--aid-file-border);
  border-radius: var(--aid-form-control-radius);
  background: var(--aid-file-surface);
  color: var(--aid-file-text);
  font: inherit;
  font-size: 13px;
  line-height: 1.35;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 4px 12px rgba(7, 20, 32, .06);
  transition: border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
}

body.aid-context-public input[type="file"]:hover,
body.aid-context-portal input[type="file"]:hover,
body.aid-context-auth input[type="file"]:hover {
  border-color: var(--aid-form-control-accent);
}

body.aid-context-public input[type="file"]:focus-visible,
body.aid-context-portal input[type="file"]:focus-visible,
body.aid-context-auth input[type="file"]:focus-visible {
  outline: none;
  border-color: var(--aid-form-control-accent);
  box-shadow: 0 0 0 4px var(--aid-form-control-focus);
}

body.aid-context-public input[type="file"]::file-selector-button,
body.aid-context-portal input[type="file"]::file-selector-button,
body.aid-context-auth input[type="file"]::file-selector-button,
body.aid-context-public input[type="file"]::-webkit-file-upload-button,
body.aid-context-portal input[type="file"]::-webkit-file-upload-button,
body.aid-context-auth input[type="file"]::-webkit-file-upload-button {
  min-height: 38px;
  margin: 0 12px 0 0;
  padding: 8px 16px;
  border: 1px solid var(--aid-file-button-border);
  border-radius: 9px;
  background: var(--aid-file-button-bg);
  color: var(--aid-file-button-text);
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .015em;
  cursor: pointer;
  box-shadow: 0 5px 12px rgba(6, 20, 30, .14), inset 0 1px 0 rgba(255, 255, 255, .12);
  transition: filter .16s ease, transform .12s ease, box-shadow .16s ease;
}

body.aid-context-public input[type="file"]:hover::file-selector-button,
body.aid-context-portal input[type="file"]:hover::file-selector-button,
body.aid-context-auth input[type="file"]:hover::file-selector-button,
body.aid-context-public input[type="file"]:hover::-webkit-file-upload-button,
body.aid-context-portal input[type="file"]:hover::-webkit-file-upload-button,
body.aid-context-auth input[type="file"]:hover::-webkit-file-upload-button {
  filter: brightness(1.08);
}

body.aid-context-public input[type="file"]:active::file-selector-button,
body.aid-context-portal input[type="file"]:active::file-selector-button,
body.aid-context-auth input[type="file"]:active::file-selector-button,
body.aid-context-public input[type="file"]:active::-webkit-file-upload-button,
body.aid-context-portal input[type="file"]:active::-webkit-file-upload-button,
body.aid-context-auth input[type="file"]:active::-webkit-file-upload-button {
  transform: translateY(1px);
  box-shadow: 0 2px 7px rgba(6, 20, 30, .16);
}

body.aid-context-public input[type="file"]:disabled,
body.aid-context-portal input[type="file"]:disabled,
body.aid-context-auth input[type="file"]:disabled {
  cursor: not-allowed;
  opacity: .58;
}

@media (max-width: 600px) {
  body.aid-context-public input[type="file"],
  body.aid-context-portal input[type="file"],
  body.aid-context-auth input[type="file"] {
    min-height: 50px;
    font-size: 12px;
  }

  body.aid-context-public input[type="file"]::file-selector-button,
  body.aid-context-portal input[type="file"]::file-selector-button,
  body.aid-context-auth input[type="file"]::file-selector-button,
  body.aid-context-public input[type="file"]::-webkit-file-upload-button,
  body.aid-context-portal input[type="file"]::-webkit-file-upload-button,
  body.aid-context-auth input[type="file"]::-webkit-file-upload-button {
    max-width: 58%;
    padding-inline: 12px;
    white-space: normal;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]),
  body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]),
  body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]),
  body.aid-context-public input[type="file"],
  body.aid-context-portal input[type="file"],
  body.aid-context-auth input[type="file"],
  body.aid-context-public input[type="file"]::file-selector-button,
  body.aid-context-portal input[type="file"]::file-selector-button,
  body.aid-context-auth input[type="file"]::file-selector-button {
    transition: none;
  }
}

@media (forced-colors: active) {
  body.aid-context-public input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]),
  body.aid-context-portal input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]),
  body.aid-context-auth input[type="checkbox"]:not([data-pref]):not([data-analytics]):not([data-marketing]) {
    -webkit-appearance: auto;
    appearance: auto;
  }
}

/* AID SAME-LINE DECLARATION LAYOUT FIX v1.15.4.19.35.261 START
 * Long legal confirmations use a stable two-column grid: checkbox first,
 * declaration text second. Cookie switches remain excluded and untouched.
 */
body.aid-context-public.aid-request-center-page label.aid-request-consent,
body.aid-context-public label.aid-stacked-declaration,
body.aid-context-portal label.aid-stacked-declaration,
body.aid-context-auth label.aid-stacked-declaration {
  box-sizing: border-box !important;
  display: grid !important;
  grid-template-columns: 20px minmax(0, 1fr) !important;
  grid-template-rows: auto !important;
  align-items: start !important;
  justify-content: stretch !important;
  column-gap: 12px !important;
  row-gap: 0 !important;
  width: 100% !important;
  min-width: 0 !important;
  text-align: left !important;
}

body.aid-context-public.aid-request-center-page label.aid-request-consent > input[type="checkbox"],
body.aid-context-public label.aid-stacked-declaration > input[type="checkbox"],
body.aid-context-portal label.aid-stacked-declaration > input[type="checkbox"],
body.aid-context-auth label.aid-stacked-declaration > input[type="checkbox"] {
  grid-column: 1 !important;
  grid-row: 1 !important;
  order: 0 !important;
  align-self: start !important;
  justify-self: start !important;
  flex: 0 0 20px !important;
  inline-size: 20px !important;
  block-size: 20px !important;
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
  margin: 1px 0 0 !important;
}

body.aid-context-public.aid-request-center-page label.aid-request-consent > span,
body.aid-context-public label.aid-stacked-declaration > span,
body.aid-context-portal label.aid-stacked-declaration > span,
body.aid-context-auth label.aid-stacked-declaration > span {
  grid-column: 2 !important;
  grid-row: 1 !important;
  display: block !important;
  align-self: start !important;
  width: auto !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  text-align: left !important;
  line-height: 1.48 !important;
  overflow-wrap: anywhere !important;
}

@media (max-width: 575.98px) {
  body.aid-context-public.aid-request-center-page label.aid-request-consent,
  body.aid-context-public label.aid-stacked-declaration,
  body.aid-context-portal label.aid-stacked-declaration,
  body.aid-context-auth label.aid-stacked-declaration {
    grid-template-columns: 20px minmax(0, 1fr) !important;
    column-gap: 10px !important;
  }
}
/* AID SAME-LINE DECLARATION LAYOUT FIX v1.15.4.19.35.261 END */

/* AID RESPONSIVE HUMAN-VISIBLE DATE/TIME CONTROLS v1.15.4.19.35.263 START
 * Cross-screen correction: the input owns the visible icon, while the native
 * WebKit picker indicator remains transparent and clickable. This prevents
 * low contrast and intrinsic-width overflow on phones and tablets.
 */
body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]) {
  display: block !important;
  inline-size: 100% !important;
  width: 100% !important;
  min-inline-size: 0 !important;
  min-width: 0 !important;
  max-inline-size: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
  padding-inline-end: 58px !important;
  background-repeat: no-repeat !important;
  background-position: right 15px center !important;
  background-size: 22px 22px !important;
}

body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]) {
  color-scheme: dark !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%23bdfcf7' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='16' rx='2'/%3E%3Cpath d='M16 3v4M8 3v4M3 10h18'/%3E%3C/svg%3E") !important;
}

body.aid-context-portal
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]) {
  color-scheme: light !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%230e667b' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='16' rx='2'/%3E%3Cpath d='M16 3v4M8 3v4M3 10h18'/%3E%3C/svg%3E") !important;
}

body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"])::-webkit-calendar-picker-indicator {
  box-sizing: border-box !important;
  width: 42px !important;
  height: 34px !important;
  min-width: 42px !important;
  min-height: 34px !important;
  max-width: 42px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  opacity: 0 !important;
  filter: none !important;
  cursor: pointer !important;
}

body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"])::-webkit-datetime-edit,
body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"])::-webkit-datetime-edit-fields-wrapper,
body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"])::-webkit-date-and-time-value {
  min-width: 0 !important;
  max-width: 100% !important;
  text-align: left !important;
}

body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]):hover,
body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]):focus {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.35' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='16' rx='2'/%3E%3Cpath d='M16 3v4M8 3v4M3 10h18'/%3E%3C/svg%3E") !important;
}

body.aid-context-portal
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]):hover,
body.aid-context-portal
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]):focus {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%23084f61' stroke-width='2.35' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='16' rx='2'/%3E%3Cpath d='M16 3v4M8 3v4M3 10h18'/%3E%3C/svg%3E") !important;
}

body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]):disabled {
  opacity: .58 !important;
  cursor: not-allowed !important;
}

@media (max-width: 991.98px) {
  body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
  input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]) {
    min-height: 48px !important;
    padding-inline-start: 14px !important;
    padding-inline-end: 52px !important;
    background-position: right 13px center !important;
    background-size: 20px 20px !important;
    font-size: 16px !important;
  }

  body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
  input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"])::-webkit-calendar-picker-indicator {
    width: 40px !important;
    min-width: 40px !important;
    height: 32px !important;
    min-height: 32px !important;
  }
}

@media (max-width: 575.98px) {
  body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
  input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]) {
    padding-inline-end: 48px !important;
    background-position: right 12px center !important;
    background-size: 19px 19px !important;
  }
}

@media (forced-colors: active) {
  body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
  input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]) {
    background-image: none !important;
    forced-color-adjust: auto !important;
  }

  body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
  input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"])::-webkit-calendar-picker-indicator {
    opacity: 1 !important;
    border: 1px solid ButtonText !important;
    background: ButtonFace !important;
  }
}
/* AID RESPONSIVE HUMAN-VISIBLE DATE/TIME CONTROLS v1.15.4.19.35.263 END */


/* AID TEMPORAL CONTROL MOBILE CONTAINMENT v1.15.4.19.35.264 START
 * Prevent intrinsic-width overflow in WebKit/Blink mobile controls. Public
 * request-center date fields also receive a dedicated visual shell in their
 * page stylesheet; these rules protect the remaining date/time fields.
 */
@media (max-width: 991.98px) {
  body:is(.aid-context-public,.aid-context-auth,.aid-context-recipient,.aid-context-portal)
  input:is([type="date"],[type="datetime-local"],[type="month"],[type="time"]) {
    -webkit-appearance: none !important;
    appearance: none !important;
    display: block !important;
    flex: 1 1 0 !important;
    inline-size: 100% !important;
    width: 100% !important;
    min-inline-size: 0 !important;
    min-width: 0 !important;
    max-inline-size: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    background-origin: border-box !important;
    background-clip: padding-box !important;
  }

  body.aid-context-public .aid-request-fields > label,
  body.aid-context-portal :is(.field,.filters-grid > label,.form-grid > .field),
  body.aid-context-recipient :is(.field,label),
  body.aid-context-auth :is(.field,label) {
    min-inline-size: 0 !important;
    min-width: 0 !important;
    max-inline-size: 100% !important;
    max-width: 100% !important;
  }
}
/* AID TEMPORAL CONTROL MOBILE CONTAINMENT v1.15.4.19.35.264 END */
