/**
 * @file
 * Estilos FASE 7.19–7.23 alineados a InterfacesMuestra (General / User Settings).
 */

html.certlink-portal-route .certlink-settings-shell {
  max-width: 100% !important;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

html.certlink-portal-route .certlink-settings-page-head {
  margin: var(--space-2, 8px) 0 var(--space-6, 24px);
}

html.certlink-portal-route .certlink-settings-page-head h2 {
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: var(--fs-4xl, 2rem);
  letter-spacing: var(--tracking-tight, -0.02em);
  color: #fff;
  margin: 0 0 6px;
}

html.certlink-portal-route .certlink-settings-page-head p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: var(--fs-md, 1rem);
  line-height: 1.5;
}

html.certlink-portal-route .certlink-settings-panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-2xl, 20px);
  padding: var(--space-8, 32px);
  box-shadow: var(--shadow-lg, 0 12px 40px rgba(0, 0, 0, 0.2));
}

html.certlink-portal-route .certlink-settings-section + .certlink-settings-section {
  margin-top: var(--space-8, 32px);
  padding-top: var(--space-8, 32px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* User Settings — Profile: campos directamente sobre el panel (sin sub-contenedor). */
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-section-head + .certlink-settings-section-sub {
  margin-bottom: var(--space-5, 20px);
}

html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field + .certlink-settings-section-head {
  margin-top: var(--space-8, 32px);
  padding-top: var(--space-8, 32px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* PIN: la sección sigue a los avisos de Security (maqueta .section + .section). */
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-notice + .certlink-settings-section {
  margin-top: var(--space-8, 32px);
  padding-top: var(--space-8, 32px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Security: avisos bajo cabecera de sección (el aire lo aporta section-head). */
html.certlink-portal-route .certlink-user-settings-form .certlink-settings-section-head + .certlink-settings-notice,
html.certlink-portal-route .certlink-user-settings-form .certlink-settings-section-head ~ .certlink-settings-notice,
html.certlink-portal-route .certlink-user-settings-page .certlink-settings-section-head + .certlink-settings-notice,
html.certlink-portal-route .certlink-user-settings-page .certlink-settings-section-head ~ .certlink-settings-notice {
  margin-top: 0;
}

html.certlink-portal-route body.path-settings-user .certlink-settings-shell [data-drupal-messages],
html.certlink-portal-route body.path-settings-user .certlink-settings-shell .messages {
  margin: 0 0 var(--space-5, 20px) !important;
  max-width: 100%;
}

html.certlink-portal-route body.path-settings-user .certlink-settings-shell [data-drupal-messages].toast-container {
  position: static !important;
  inset: auto !important;
  transform: none !important;
  width: 100% !important;
  max-width: 100% !important;
  padding: 0 !important;
}

html.certlink-portal-route body.path-settings-user .certlink-settings-shell [data-drupal-messages] .btn-close,
html.certlink-portal-route body.path-settings-user .certlink-settings-shell [data-drupal-messages] .toast-header {
  display: none !important;
}

html.certlink-portal-route body.path-settings-user .certlink-settings-shell [data-drupal-messages].toast-container .toast,
html.certlink-portal-route body.path-settings-user .certlink-settings-shell .messages--status {
  width: 100% !important;
  max-width: 100% !important;
  background: rgba(220, 248, 230, 0.96) !important;
  color: #0d3d1f !important;
  border: 1px solid #3d9a62 !important;
  border-radius: 8px !important;
  box-shadow: none !important;
  overflow: hidden;
}

html.certlink-portal-route body.path-settings-user .certlink-settings-shell [data-drupal-messages].toast-container .toast-body,
html.certlink-portal-route body.path-settings-user .certlink-settings-shell .messages--status {
  color: #0d3d1f !important;
  font-weight: 600;
  font-size: 14px;
  padding: 12px 16px !important;
  text-align: left !important;
}

html.certlink-portal-route .certlink-settings-section-head {
  display: flex;
  align-items: center;
  gap: var(--space-3, 12px);
  /* Maqueta Clients/User Settings: más aire entre título de sección y campos. */
  margin-bottom: var(--space-6, 24px);
}

html.certlink-portal-route .certlink-settings-section-head .ico {
  width: 34px;
  height: 34px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: var(--radius-md, 8px);
  background: var(--al-orange, #e8722e);
  border: 1px solid var(--al-orange, #e8722e);
}

html.certlink-portal-route .certlink-settings-section-head .ico svg {
  width: 18px;
  height: 18px;
  color: #fff;
}

html.certlink-portal-route .certlink-settings-section-head h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-xl, 1.25rem);
  color: #fff;
  margin: 0;
}

html.certlink-portal-route .certlink-settings-section-sub {
  margin: 0 0 var(--space-5, 20px);
  padding-left: 46px;
  color: rgba(255, 255, 255, 0.62);
  font-size: var(--fs-sm, 0.875rem);
  line-height: var(--lh-normal, 1.5);
}

html.certlink-portal-route .certlink-settings-field {
  margin-bottom: var(--space-5, 20px);
}

html.certlink-portal-route .certlink-settings-field:last-child {
  margin-bottom: 0;
}

html.certlink-portal-route .annex-row,
html.certlink-portal-route .certlink-annex-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-4, 16px);
  padding: var(--space-4, 16px) var(--space-5, 20px);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-lg, 12px);
  cursor: default;
}

html.certlink-portal-route .annex-row input,
html.certlink-portal-route .certlink-annex-row input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

html.certlink-portal-route .annex-row .box,
html.certlink-portal-route .certlink-annex-row .box {
  flex: none;
  width: 20px;
  height: 20px;
  border-radius: 5px;
  border: 2px solid rgba(255, 255, 255, 0.42);
  display: grid;
  place-items: center;
}

html.certlink-portal-route .annex-row .box svg,
html.certlink-portal-route .certlink-annex-row .box svg {
  width: 13px;
  height: 13px;
  color: #fff;
  opacity: 0;
  transform: scale(0.6);
}

html.certlink-portal-route .annex-row:has(input:checked),
html.certlink-portal-route .certlink-annex-row:has(input:checked),
html.certlink-portal-route .certlink-annex-row.is-signed {
  background: rgba(232, 114, 46, 0.12);
  border-color: var(--al-orange, #e8722e);
}

html.certlink-portal-route .annex-row:has(input:checked) .box,
html.certlink-portal-route .certlink-annex-row:has(input:checked) .box,
html.certlink-portal-route .certlink-annex-row.is-signed .box {
  background: var(--al-orange, #e8722e);
  border-color: var(--al-orange, #e8722e);
}

html.certlink-portal-route .annex-row:has(input:checked) .box svg,
html.certlink-portal-route .certlink-annex-row:has(input:checked) .box svg,
html.certlink-portal-route .certlink-annex-row.is-signed .box svg {
  opacity: 1;
  transform: scale(1);
}

html.certlink-portal-route .annex-text,
html.certlink-portal-route .certlink-annex-row .annex-text {
  margin: 0;
  font-size: var(--fs-md, 1rem);
  line-height: var(--lh-normal, 1.5);
  color: rgba(255, 255, 255, 0.86);
}

html.certlink-portal-route .annex-text strong,
html.certlink-portal-route .certlink-annex-row .annex-text strong {
  color: #fff;
  font-weight: 700;
}

html.certlink-portal-route .certlink-ai-translation-data {
  margin-top: var(--space-5, 20px);
}

html.certlink-portal-route .certlink-ai-translation-data__row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  align-items: center;
}

html.certlink-portal-route .certlink-ai-translation-data__choice {
  margin: 0;
}

html.certlink-portal-route .certlink-annex-restricted-panel {
  padding: var(--space-5, 20px);
}

html.certlink-portal-route .certlink-annex-restricted-panel__title {
  margin: 0 0 var(--space-3, 12px);
  font-size: var(--fs-xl, 1.25rem);
  color: #fff;
}

html.certlink-portal-route .certlink-annex-restricted-panel__text {
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  line-height: var(--lh-normal, 1.5);
}


html.certlink-portal-route .certlink-settings-field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5, 20px);
  margin-bottom: var(--space-5, 20px);
}

html.certlink-portal-route .certlink-settings-field-row + .certlink-settings-field {
  margin-top: var(--space-2, 8px);
}

html.certlink-portal-route .certlink-settings-field-row .certlink-settings-field {
  margin-bottom: 0;
}

html.certlink-portal-route .certlink-settings-form-panel label.field-label,
html.certlink-portal-route .certlink-settings-form-panel .form-item label,
html.certlink-portal-route .certlink-settings-form-panel .form-item__label {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-sm, 0.875rem);
  letter-spacing: var(--tracking-caps, 0.06em);
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: var(--space-2, 8px);
}

html.certlink-portal-route .certlink-settings-form-panel .input-wrap {
  position: relative;
}

html.certlink-portal-route .certlink-settings-form-panel .input-wrap input,
html.certlink-portal-route .certlink-settings-form-panel .input-wrap select,
html.certlink-portal-route .certlink-settings-form-panel .input-wrap textarea,
html.certlink-portal-route .certlink-settings-form-panel .form-item input.form-text,
html.certlink-portal-route .certlink-settings-form-panel .form-item input.form-email,
html.certlink-portal-route .certlink-settings-form-panel .form-item input.form-control,
html.certlink-portal-route .certlink-settings-form-panel .form-item select,
html.certlink-portal-route body.path-settings-general .certlink-settings-form-panel .input-wrap input[readonly],
html.certlink-portal-route body.path-settings-general .certlink-settings-form-panel .input-wrap select[disabled] {
  width: 100% !important;
  max-width: 100% !important;
  min-height: 48px !important;
  height: auto !important;
  line-height: 1.4 !important;
  font-family: var(--font-sans);
  font-size: var(--fs-md, 1rem);
  color: var(--al-navy, #013753);
  background: var(--al-white, #fff) !important;
  border: 1px solid var(--border-1, #e2e8f0) !important;
  border-radius: var(--radius-md, 8px) !important;
  padding: 13px var(--space-4, 16px) !important;
  box-sizing: border-box !important;
  box-shadow: none !important;
}

html.certlink-portal-route .certlink-settings-form-panel .input-wrap input:focus,
html.certlink-portal-route .certlink-settings-form-panel .input-wrap select:focus,
html.certlink-portal-route .certlink-settings-form-panel .form-item input:focus,
html.certlink-portal-route body.path-settings-general .certlink-settings-form-panel .input-wrap input[readonly]:focus,
html.certlink-portal-route body.path-settings-general .certlink-settings-form-panel .input-wrap select[disabled]:focus {
  outline: none !important;
  border-color: var(--al-orange, #e8722e) !important;
  box-shadow: var(--shadow-focus, 0 0 0 3px rgba(232, 114, 46, 0.35)) !important;
}

html.certlink-portal-route body.path-settings-general .certlink-settings-form-panel .certlink-settings-choice .field-label,
html.certlink-portal-route body.path-settings-general .certlink-settings-form-panel label.field-label {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-sm, 0.875rem);
  letter-spacing: var(--tracking-caps, 0.06em);
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: var(--space-2, 8px);
}

html.certlink-portal-route .certlink-settings-form-panel .input-wrap.is-select select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 44px !important;
  cursor: pointer;
}

html.certlink-portal-route .certlink-settings-form-panel .select-caret {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  min-width: 18px;
  min-height: 18px;
  max-width: 18px;
  max-height: 18px;
  color: var(--al-navy-500, #5a8fad);
  pointer-events: none;
  display: grid;
  place-items: center;
  flex: none;
  overflow: hidden;
  line-height: 0;
}

html.certlink-portal-route .certlink-settings-form-panel .select-caret svg {
  display: block;
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  min-height: 18px !important;
  max-width: 18px !important;
  max-height: 18px !important;
  flex: none !important;
}

html.certlink-portal-route .certlink-settings-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  /* Filas iguales: con 3 opciones la tarjeta inferior iguala la altura de las de arriba. */
  grid-auto-rows: 1fr;
  align-items: stretch;
  gap: var(--space-4, 16px);
  width: 100%;
}

html.certlink-portal-route .certlink-settings-choice {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-3, 12px);
  /* Reserva espacio de título a 2 líneas + meta (caso «Incluyendo todos…»). */
  min-height: 5.75rem;
  height: 100%;
  box-sizing: border-box;
  padding: var(--space-4, 16px) var(--space-5, 20px);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-lg, 12px);
  cursor: pointer;
  transition: background var(--dur-1, 0.15s) var(--ease-out, ease), border-color var(--dur-1, 0.15s) var(--ease-out, ease), box-shadow var(--dur-1, 0.15s) var(--ease-out, ease);
}

html.certlink-portal-route .certlink-settings-choice:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.3);
}

html.certlink-portal-route .certlink-settings-choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

html.certlink-portal-route .certlink-settings-choice .dot {
  flex: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.4);
  display: grid;
  place-items: center;
  transition: border-color var(--dur-1, 0.15s) var(--ease-out, ease);
}

html.certlink-portal-route .certlink-settings-choice .dot::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--al-orange, #e8722e);
  transform: scale(0);
  transition: transform var(--dur-1, 0.15s) var(--ease-out, ease);
}

html.certlink-portal-route .certlink-settings-choice .choice-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

html.certlink-portal-route .certlink-settings-choice .choice-title {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: var(--fs-md, 1rem);
  color: var(--al-white, #fff);
  line-height: var(--lh-snug, 1.35);
}

html.certlink-portal-route .certlink-settings-choice .choice-meta {
  font-size: var(--fs-xs, 0.75rem);
  font-weight: 700;
  letter-spacing: var(--tracking-caps, 0.06em);
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

html.certlink-portal-route .certlink-settings-choice:has(input:checked) {
  background: rgba(232, 114, 46, 0.14);
  border-color: var(--al-orange, #e8722e);
  box-shadow: 0 2px 14px rgba(232, 114, 46, 0.18);
}

html.certlink-portal-route .certlink-settings-choice:has(input:checked) .dot {
  border-color: var(--al-orange, #e8722e);
}

html.certlink-portal-route .certlink-settings-choice:has(input:checked) .dot::after {
  transform: scale(1);
}

html.certlink-portal-route .certlink-settings-choice:has(input:checked) .choice-meta {
  color: var(--al-orange-300, #f3c483);
}

html.certlink-portal-route .certlink-settings-choice:has(input:focus-visible) {
  box-shadow: var(--shadow-focus, 0 0 0 3px rgba(232, 114, 46, 0.35));
}

html.certlink-portal-route .certlink-settings-choice.choice--disabled,
html.certlink-portal-route .certlink-settings-choice.choice--xtrf-readonly {
  cursor: not-allowed;
  opacity: 0.88;
}

html.certlink-portal-route .certlink-settings-choice.choice--disabled:hover,
html.certlink-portal-route .certlink-settings-choice.choice--xtrf-readonly:hover {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
}

html.certlink-portal-route body.path-settings-general .certlink-settings-field-hint.field-hint {
  margin: var(--space-2, 8px) 0 0;
  font-size: var(--fs-sm, 0.875rem);
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.45;
}

html.certlink-portal-route .certlink-download-row .download-btn.is-unavailable {
  opacity: 0.72;
  cursor: default;
  pointer-events: none;
}

html.certlink-portal-route body.path-settings-general .certlink-settings-panel .contact-notice {
  margin-top: var(--space-8, 32px);
}

html.certlink-portal-route body.path-settings-general .certlink-settings-form-panel .certlink-settings-section + .certlink-settings-section {
  margin-top: var(--space-8, 32px);
  padding-top: var(--space-8, 32px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Anula altura 40px genérica de portal-base en campos maqueta General Settings. */
html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-form-panel .input-wrap input[readonly],
html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-form-panel .input-wrap select[disabled] {
  height: auto !important;
  min-height: 48px !important;
  line-height: 1.4 !important;
  padding: 13px var(--space-4, 16px) !important;
  background: var(--al-white, #fff) !important;
  color: var(--al-navy, #013753) !important;
  border: 1px solid var(--border-1, #e2e8f0) !important;
  border-radius: var(--radius-md, 8px) !important;
  box-shadow: none !important;
}

html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-shell,
html.certlink-portal-route body.path-settings-user .certlink-custom-page .certlink-settings-shell {
  max-width: 100% !important;
  margin: 0 !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

html.certlink-portal-route body.path-settings-general .certlink-custom-page > .shell,
html.certlink-portal-route body.path-settings-user .certlink-custom-page > .shell {
  padding: 0 0 var(--space-10, 40px) 0 !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  overflow: visible;
}

html.certlink-portal-route .certlink-settings-page.certlink-settings-panel.panel,
html.certlink-portal-route body.path-settings-general .certlink-settings-panel.panel,
html.certlink-portal-route body.path-settings-user .certlink-settings-panel.panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02)) !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  border-radius: var(--radius-2xl, 20px) !important;
  padding: var(--space-8, 32px) !important;
  box-shadow: var(--shadow-lg, 0 12px 40px rgba(0, 0, 0, 0.2)) !important;
  overflow: visible !important;
  margin-top: 0 !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 100% !important;
  box-sizing: border-box !important;
}

html.certlink-portal-route .certlink-settings-form-panel .input-wrap.is-readonly input {
  background: rgba(255, 255, 255, 0.55) !important;
  color: var(--al-navy-600, #1e4a6e);
  border-color: rgba(255, 255, 255, 0.2) !important;
  cursor: default;
  padding-right: 42px !important;
}

html.certlink-portal-route .certlink-settings-form-panel .input-wrap.is-readonly input:focus {
  box-shadow: none !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

/*
 * User Settings — perfil readonly (maqueta: fondo #97A8B3, sin candado).
 * Anula certlink-fixes.less (Bootstrap) que fuerza fondo blanco, altura 34px y max-width 640px.
 */
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field-row {
  width: 100%;
  max-width: 100%;
}

html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field-row .certlink-settings-field {
  min-width: 0;
}

html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap {
  width: 100%;
  max-width: 100%;
}

html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap input[readonly],
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap input[readonly][type="email"],
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap.is-readonly input[type="text"],
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap.is-readonly input[type="email"] {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  min-height: 48px !important;
  height: auto !important;
  line-height: 1.4 !important;
  padding: 13px var(--space-4, 16px) !important;
  font-family: var(--font-sans);
  font-size: var(--fs-md, 1rem);
  color: var(--al-navy-600, #1e4a6e) !important;
  background: #97a8b3 !important;
  background-color: #97a8b3 !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  border-radius: var(--radius-md, 8px) !important;
  box-shadow: none !important;
  cursor: default;
}

html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap input[readonly]:focus,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap input[readonly][type="email"]:focus,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap.is-readonly input[type="text"]:focus,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap.is-readonly input[type="email"]:focus {
  outline: none !important;
  box-shadow: none !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
}

html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .lock-ico {
  display: none !important;
}

html.certlink-portal-route .certlink-settings-form-panel .lock-ico {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--al-navy-300, #5a8fad);
  pointer-events: none;
  display: grid;
  place-items: center;
}

html.certlink-portal-route .certlink-settings-form-panel .lock-ico svg {
  width: 16px;
  height: 16px;
}

html.certlink-portal-route .certlink-settings-form-panel .form-item__description,
html.certlink-portal-route .certlink-settings-form-panel .description {
  margin-top: var(--space-2, 8px);
  font-size: var(--fs-sm, 0.875rem);
  color: rgba(255, 255, 255, 0.6) !important;
  line-height: 1.45;
}

html.certlink-portal-route .certlink-settings-form-panel .form-item__description a {
  color: var(--al-orange-300, #f3c483);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(243, 196, 131, 0.45);
}

html.certlink-portal-route .certlink-settings-form-panel fieldset.account {
  border: none;
  margin: 0;
  padding: 0;
  min-width: 0;
}

html.certlink-portal-route .certlink-settings-form-panel fieldset.account > legend {
  display: none;
}

html.certlink-portal-route .certlink-settings-notice {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: var(--space-5, 20px) !important;
  padding: var(--space-4, 16px) var(--space-5, 20px) !important;
  background: rgba(255, 255, 255, 0.05) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: var(--radius-lg, 12px) !important;
  margin-bottom: var(--space-4, 16px) !important;
}

html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-notice {
  background: rgba(151, 168, 179, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: var(--space-4, 16px);
}

html.certlink-portal-route .certlink-settings-notice:last-child {
  margin-bottom: 0;
}

html.certlink-portal-route .certlink-settings-notice__text {
  margin: 0 !important;
  flex: 1 !important;
  min-width: 0 !important;
  text-align: justify !important;
  color: rgba(255, 255, 255, 0.78) !important;
  font-size: var(--fs-md, 1rem);
  line-height: 1.5 !important;
}

html.certlink-portal-route .certlink-settings-notice__btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  flex: none !important;
  width: 200px !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  font-family: var(--font-display) !important;
  font-weight: 700 !important;
  font-size: var(--fs-md, 1rem) !important;
  border-radius: var(--radius-md, 8px) !important;
  padding: 12px 10px !important;
  background: var(--al-orange, #e8722e) !important;
  color: #fff !important;
  text-decoration: none !important;
  border: none !important;
  box-shadow: 0 2px 10px rgba(232, 114, 46, 0.35) !important;
  cursor: pointer !important;
}

html.certlink-portal-route .certlink-settings-notice__btn:hover,
html.certlink-portal-route .certlink-settings-notice__btn:focus-visible {
  background: var(--al-orange-600, #d4651f);
  color: #fff !important;
  text-decoration: none !important;
}

html.certlink-portal-route .certlink-settings-notice__btn svg {
  width: 16px;
  height: 16px;
  flex: none;
}

html.certlink-portal-route .certlink-settings-notice__btn.certlink-user-pin-btn {
  width: auto !important;
  min-width: 200px;
  padding-left: 16px !important;
  padding-right: 16px !important;
  white-space: nowrap;
}

html.certlink-portal-route .certlink-settings-notice__btn.is-sent {
  background: #3f9d6a;
  box-shadow: none;
  pointer-events: none;
}

html.certlink-portal-route .certlink-settings-pin-ack,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-pin-ack {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  margin-top: 16px !important;
  padding-left: 2px !important;
}

html.certlink-portal-route .certlink-settings-pin-ack__label,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-pin-ack__label {
  display: inline-flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 16px !important;
  cursor: default !important;
  user-select: none !important;
  width: auto !important;
  margin: 0 !important;
}

html.certlink-portal-route .certlink-settings-pin-ack__checkbox,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-pin-ack__checkbox {
  appearance: none !important;
  -webkit-appearance: none !important;
  width: 18px !important;
  height: 18px !important;
  border: 2px solid rgba(255, 255, 255, 0.5) !important;
  border-radius: 4px !important;
  background-color: transparent !important;
  outline: none !important;
  cursor: default !important;
  display: inline-grid !important;
  place-content: center !important;
  flex: 0 0 18px !important;
  margin: 0 16px 0 0 !important;
  vertical-align: middle !important;
}

html.certlink-portal-route .certlink-settings-pin-ack__checkbox:checked {
  background-color: var(--al-orange, #e8722e) !important;
  border-color: var(--al-orange, #e8722e) !important;
}

html.certlink-portal-route .certlink-settings-pin-ack__checkbox:checked::before {
  content: "" !important;
  width: 10px !important;
  height: 10px !important;
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%) !important;
  background-color: #ffffff !important;
}

html.certlink-portal-route .certlink-settings-pin-ack__text,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-pin-ack__text {
  display: inline-block !important;
  font-size: var(--fs-md, 1rem) !important;
  color: rgba(255, 255, 255, 0.78) !important;
  font-weight: 400 !important;
  line-height: 1.5 !important;
  margin: 0 !important;
  vertical-align: middle !important;
}

html.certlink-portal-route .certlink-contact-notice {
  display: flex;
  align-items: center;
  gap: var(--space-5, 20px);
  margin-top: var(--space-8, 32px);
  padding: var(--space-6, 24px);
  background: rgba(232, 114, 46, 0.1);
  border: 1px solid rgba(232, 114, 46, 0.4);
  border-radius: var(--radius-xl, 16px);
  flex-wrap: wrap;
}

html.certlink-portal-route .certlink-contact-notice .contact-ico {
  flex: none;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-lg, 12px);
  background: var(--al-orange, #e8722e);
  color: #fff;
}

html.certlink-portal-route .certlink-contact-notice .contact-ico svg {
  width: 24px;
  height: 24px;
}

html.certlink-portal-route .certlink-contact-notice .contact-copy {
  flex: 1;
  min-width: 240px;
}

html.certlink-portal-route .certlink-contact-notice .contact-copy h4 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-lg, 1.125rem);
  color: #fff;
  margin: 0 0 4px;
}

html.certlink-portal-route .certlink-contact-notice .contact-copy p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: var(--fs-sm, 0.875rem);
  line-height: 1.5;
  max-width: 52ch;
}

html.certlink-portal-route .certlink-contact-notice .contact-btn {
  flex: none;
  flex-shrink: 0;
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-md, 1rem);
  border-radius: var(--radius-md, 8px);
  padding: 13px var(--space-5, 20px);
  background: var(--al-orange, #e8722e);
  color: #fff !important;
  text-decoration: none !important;
  box-shadow: 0 2px 10px rgba(232, 114, 46, 0.35);
  white-space: nowrap;
}

html.certlink-portal-route .certlink-contact-notice .contact-btn .contact-btn-label {
  line-height: 1.2;
}

html.certlink-portal-route .certlink-contact-notice .contact-btn:hover {
  background: var(--al-orange-600, #d4651f);
  color: #fff !important;
}

html.certlink-portal-route .certlink-contact-notice .contact-btn svg {
  width: 17px;
  height: 17px;
}

/*
 * Vista cliente General Settings: chips Certificate language (maqueta Clients).
 * Staff sigue usando .lang-templates / .lang-tick de portal-general-settings-save.
 */
html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--space-3, 12px);
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-2, 8px);
  padding: 12px var(--space-3, 12px);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-md, 8px);
  cursor: default;
  transition: background 0.15s ease-out, border-color 0.15s ease-out;
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip.is-readonly,
html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip.certlink-lang-chip--disabled {
  cursor: not-allowed;
  opacity: 0.88;
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip input {
  position: absolute !important;
  opacity: 0 !important;
  pointer-events: none !important;
  width: 0 !important;
  height: 0 !important;
  margin: 0 !important;
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip .box {
  flex: none;
  width: 18px;
  height: 18px;
  border-radius: 5px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  display: grid;
  place-items: center;
  color: #fff;
  transition: border-color 0.15s ease-out, background 0.15s ease-out;
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip .box svg {
  width: 12px;
  height: 12px;
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.15s ease-out, transform 0.15s ease-out;
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip .lang-name {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: var(--fs-sm, 0.875rem);
  color: #fff;
  line-height: 1.3;
  white-space: nowrap;
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip:has(input:checked) {
  background: rgba(232, 114, 46, 0.14);
  border-color: var(--al-orange, #e8722e);
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip:has(input:checked) .box {
  border-color: var(--al-orange, #e8722e);
  background: var(--al-orange, #e8722e);
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-chip:has(input:checked) .box svg {
  opacity: 1;
  transform: scale(1);
}

html.certlink-portal-route body.path-settings-general .certlink-certificate-language-field .field-hint {
  margin-top: var(--space-2, 8px);
}

@media (max-width: 720px) {
  html.certlink-portal-route body.path-settings-general .certlink-certificate-lang-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

html.certlink-portal-route .certlink-download-row {
  display: flex;
  align-items: center;
  gap: var(--space-5, 20px);
  padding: var(--space-4, 16px) var(--space-5, 20px);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg, 12px);
  flex-wrap: wrap;
  margin-bottom: 0;
}

html.certlink-portal-route .certlink-settings-field .certlink-download-row {
  margin-bottom: 0;
}

/* Los .template-entry en General Settings no tienen recuadro propio:
 * el recuadro lo da el contenedor padre #certlinkTemplateBlocksContainer.
 * Separación entre idiomas = solo línea horizontal (maqueta AdministratorPM).
 * IMPORTANTE: border-top NO lleva !important para que el inline style del JS
 * pueda sobreescribirlo y dibujar la línea separadora entre grupos. */
html.certlink-portal-route body.path-settings-general #certlinkTemplateBlocksContainer > .template-entry.certlink-download-row,
html.certlink-portal-route body.path-settings-general #certlinkTemplateBlocksContainer > .template-entry.certlink-download-row--manage,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .template-entry.certlink-download-row,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .template-entry.certlink-download-row--manage {
  background: none !important;
  border-top: none;
  border-right: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  margin: 0 !important;
}

/* Línea única entre idiomas (sin tarjeta por fila). */
html.certlink-portal-route body.path-settings-general #certlinkTemplateBlocksContainer > .template-entry.certlink-download-row + .template-entry.certlink-download-row,
html.certlink-portal-route body.path-settings-general #certlinkTemplateBlocksContainer > .template-entry + .template-entry {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

html.certlink-portal-route .certlink-download-row .download-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

html.certlink-portal-route .certlink-download-row .download-file {
  display: flex;
  align-items: center;
  gap: var(--space-4, 16px);
  flex: 1;
  min-width: 220px;
}

html.certlink-portal-route .certlink-download-row .doc-ico {
  flex: none;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-md, 8px);
  background: var(--al-navy-50, #e8f2f8);
  color: var(--al-navy, #013753);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

html.certlink-portal-route .certlink-download-row .doc-ico svg {
  width: 22px;
  height: 22px;
}

html.certlink-portal-route .certlink-download-row .download-name {
  font-weight: 600;
  font-size: var(--fs-md, 1rem);
  color: #fff;
  overflow-wrap: anywhere;
  word-break: break-word;
}

html.certlink-portal-route .certlink-download-row .download-sub {
  display: block;
  font-size: var(--fs-xs, 0.75rem);
  font-weight: 700;
  letter-spacing: normal;
  text-transform: none;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
  text-align: justify;
  text-wrap: pretty;
  hyphens: auto;
  max-width: 100%;
}

/* Plantilla de cliente que no encaja con la modalidad de emisión vigente:
   tono ámbar suave para avisar de que se usará la plantilla del sistema. */
html.certlink-portal-route .certlink-download-row[data-template-applies="0"] .download-sub,
html.certlink-portal-route .download-row[data-template-applies="0"] .download-sub {
  color: rgba(224, 144, 48, 0.9);
  text-align: justify;
}

html.certlink-portal-route .certlink-download-row .download-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  margin-left: auto;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-md, 1rem);
  border-radius: var(--radius-md, 8px);
  padding: 12px var(--space-6, 24px);
  background: var(--al-orange, #e8722e) !important;
  background-color: var(--al-orange, #e8722e) !important;
  color: #fff !important;
  text-decoration: none !important;
  border: none !important;
  box-shadow: 0 2px 10px rgba(232, 114, 46, 0.35);
  cursor: pointer;
}

html.certlink-portal-route .certlink-download-row .download-btn.btn-primary {
  background: var(--al-orange, #e8722e) !important;
  background-color: var(--al-orange, #e8722e) !important;
  border-color: transparent !important;
  color: #fff !important;
}

html.certlink-portal-route .certlink-download-row .download-btn:hover {
  background: var(--al-orange-600, #d4651f);
  color: #fff !important;
}

html.certlink-portal-route .certlink-download-row .download-btn.is-done {
  background: #3f9d6a;
  box-shadow: none;
  pointer-events: none;
}

html.certlink-portal-route .certlink-download-row .download-btn svg {
  width: 17px;
  height: 17px;
}

/* General Settings — gestores/admin: fila plantilla con subida (maqueta AdministratorPM).
 * Fichero a la izquierda; columna .download-actions a la derecha (Upload arriba, Download abajo). */
html.certlink-portal-route .certlink-general-settings--staff .certlink-download-row,
html.certlink-portal-route .certlink-download-row--manage {
  flex-direction: row !important;
  align-items: center !important;
  justify-content: space-between;
  gap: var(--space-4, 16px);
  flex-wrap: nowrap;
}

html.certlink-portal-route .certlink-download-row--manage .download-file {
  flex: 1 1 0;
  min-width: 0;
}

html.certlink-portal-route .certlink-download-row--manage .download-meta {
  min-width: 0;
  flex: 1 1 auto;
}

html.certlink-portal-route .certlink-download-row--manage .download-actions,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .download-actions {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  justify-content: center;
  gap: 8px !important;
  flex: 0 0 auto !important;
  margin-left: auto !important;
}

/*
 * Plantilla DOCX (AdministratorPM): upload y download comparten tamaño compacto
 * (maqueta: padding 10px + space-4, min-width 200px). Ambos en la columna derecha.
 */
html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .upload-btn,
html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .download-btn,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .upload-btn,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .download-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  flex: none !important;
  box-sizing: border-box !important;
  min-width: 200px !important;
  width: 200px !important;
  max-width: 100% !important;
  min-height: 0 !important;
  height: auto !important;
  margin-left: 0 !important;
  padding: 10px var(--space-4, 16px) !important;
  white-space: nowrap !important;
  font-family: var(--font-display, inherit) !important;
  font-weight: 700 !important;
  font-size: var(--fs-md, 1rem) !important;
  line-height: 1.2 !important;
  border-radius: var(--radius-md, 8px) !important;
  transform: none !important;
  filter: none !important;
}

html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .upload-btn,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .upload-btn {
  background: transparent !important;
  color: rgba(255, 255, 255, 0.9) !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  text-decoration: none !important;
  box-shadow: none !important;
}

html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .upload-btn:hover,
html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .upload-btn:focus-visible,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .upload-btn:hover,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .upload-btn:focus-visible {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #fff !important;
  text-decoration: none !important;
  transform: none !important;
  filter: none !important;
}

html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .download-btn,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .download-btn {
  align-self: stretch !important;
  background: var(--al-orange, #e8722e) !important;
  background-color: var(--al-orange, #e8722e) !important;
  color: #fff !important;
  border: none !important;
  box-shadow: 0 2px 10px rgba(232, 114, 46, 0.35) !important;
}

html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .download-btn:hover,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .download-btn:hover {
  background: var(--al-orange-600, #d4651f) !important;
  color: #fff !important;
  transform: none !important;
  filter: none !important;
}

html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .upload-btn svg,
html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .download-btn svg,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .upload-btn svg,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .download-btn svg {
  width: 17px !important;
  height: 17px !important;
  flex: none !important;
}

html.certlink-portal-route .certlink-download-row--manage .download-filename {
  font-weight: 400;
}

@media (max-width: 720px) {
  html.certlink-portal-route .certlink-download-row--manage,
  html.certlink-portal-route .certlink-general-settings--staff .certlink-download-row {
    flex-direction: column !important;
    align-items: stretch !important;
  }

  html.certlink-portal-route .certlink-download-row--manage .download-actions,
  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .download-actions {
    width: 100%;
    margin-left: 0 !important;
  }

  html.certlink-portal-route .certlink-download-row--manage .upload-btn,
  html.certlink-portal-route .certlink-download-row--manage .download-btn {
    width: 100% !important;
    min-width: 0 !important;
  }
}

html.certlink-portal-route .certlink-template-manage-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: var(--space-4, 16px);
}

html.certlink-portal-route .certlink-user-settings-page .certlink-settings-form-actions,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-4, 16px);
  margin-top: var(--space-8, 32px);
  padding-top: var(--space-6, 24px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  flex-wrap: nowrap;
}

/* Cancel + Guardar siempre en la misma fila (maqueta AdministratorPM). */
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions__buttons {
  display: inline-flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-4, 16px);
  flex: 0 0 auto;
  margin-left: auto;
}

/*
 * Pie del formulario (AdministratorPM): .btn con padding 12px + space-6 (más alto
 * que upload/download de plantilla). Anula portal-base form-actions fill (5px/14px).
 */
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button.btn,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button[type="submit"],
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button[type="reset"] {
  appearance: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
  font-family: var(--font-display) !important;
  font-weight: 700 !important;
  font-size: var(--fs-md, 1rem) !important;
  line-height: 1.2 !important;
  border-radius: var(--radius-md, 8px) !important;
  padding: 12px var(--space-6, 24px) !important;
  min-width: 0 !important;
  width: auto !important;
  min-height: 0 !important;
  height: auto !important;
  cursor: pointer !important;
  border: 1px solid transparent !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  transform: none !important;
  filter: none !important;
  box-shadow: none !important;
}

html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button.btn-ghost,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button[type="reset"] {
  background: transparent !important;
  background-color: transparent !important;
  color: rgba(255, 255, 255, 0.85) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button.btn-ghost:hover,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button[type="reset"]:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #fff !important;
  transform: none !important;
  filter: none !important;
}

html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button.btn-primary,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button[type="submit"] {
  background: var(--al-orange, #e8722e) !important;
  background-color: var(--al-orange, #e8722e) !important;
  color: #fff !important;
  box-shadow: 0 2px 10px rgba(232, 114, 46, 0.35) !important;
  border-color: transparent !important;
}

html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button.btn-primary:hover,
html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button[type="submit"]:hover {
  background: var(--al-orange-600, #d4651f) !important;
  background-color: var(--al-orange-600, #d4651f) !important;
  color: #fff !important;
  transform: none !important;
  filter: none !important;
}

html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-saved-note {
  margin-right: auto;
  display: none;
  align-items: center;
  gap: 8px;
  font-size: var(--fs-sm, 0.875rem);
  color: #7ed9a6;
  font-weight: 600;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-saved-note.is-visible {
  display: inline-flex;
  opacity: 1;
  transform: translateY(0);
}

html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-saved-note svg {
  width: 16px;
  height: 16px;
}

html.certlink-portal-route .certlink-user-settings-page .certlink-settings-saved-note {
  margin-right: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: var(--fs-sm, 0.875rem);
  color: #7ed9a6;
  font-weight: 600;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

html.certlink-portal-route .certlink-user-settings-page .certlink-settings-saved-note.is-visible {
  opacity: 1;
  transform: translateY(0);
}

html.certlink-portal-route .certlink-user-settings-page .certlink-settings-saved-note svg {
  width: 16px;
  height: 16px;
}

html.certlink-portal-route .certlink-template-download-hint.field-hint {
  margin: var(--space-2, 8px) 0 var(--space-5, 20px);
  font-size: var(--fs-sm, 0.875rem);
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.45;
}

html.certlink-portal-route .certlink-template-manage-page .certlink-template-in-use {
  margin-bottom: var(--space-5, 20px);
  padding: var(--space-4, 16px) var(--space-5, 20px);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg, 12px);
}

html.certlink-portal-route .certlink-user-settings-page .form-actions {
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
}

html.certlink-portal-route .certlink-user-settings-page .form-actions [data-drupal-selector="edit-delete"] {
  display: none !important;
}
/* Sobrescribir fondo blanco de inputs readonly en General Settings cuando son is-readonly */
html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-form-panel .input-wrap.is-readonly input[readonly],
html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-form-panel .input-wrap.is-readonly select[disabled] {
  background: rgba(255, 255, 255, 0.55) !important;
  color: var(--al-navy-600, #1e4a6e) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}


/*
 * Laptops ≤1400px (14"): misma densidad tipográfica y de controles que /projects.
 */
@media (max-width: 1400px) {
  html.certlink-portal-route .certlink-settings-shell {
    max-width: 100% !important;
  }

  html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-shell {
    max-width: 100% !important;
  }

  html.certlink-portal-route body.path-settings-user .certlink-custom-page .certlink-settings-shell {
    max-width: 100% !important;
  }

  html.certlink-portal-route .certlink-settings-page-head {
    margin: var(--space-2, 8px) 0 var(--space-4, 16px);
  }

  html.certlink-portal-route .certlink-settings-page-head h2,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page h2 {
    font-size: 19px !important;
    margin-bottom: 4px !important;
  }

  html.certlink-portal-route .certlink-settings-page-head p,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page > p {
    font-size: 12px !important;
    line-height: 1.45 !important;
    margin-bottom: 10px !important;
  }

  html.certlink-portal-route .certlink-settings-panel {
    padding: 16px 18px !important;
    border-radius: var(--radius-xl, 14px) !important;
  }

  html.certlink-portal-route .certlink-settings-section + .certlink-settings-section {
    margin-top: var(--space-5, 20px);
    padding-top: var(--space-5, 20px);
  }

  html.certlink-portal-route .certlink-settings-section-head h3 {
    font-size: 15px !important;
  }

  html.certlink-portal-route .certlink-settings-section-head .ico {
    width: 28px;
    height: 28px;
  }

  html.certlink-portal-route .certlink-settings-section-head .ico svg {
    width: 14px;
    height: 14px;
  }

  html.certlink-portal-route .certlink-settings-section-sub {
    padding-left: 40px;
    margin-bottom: var(--space-4, 16px);
    font-size: 11px !important;
  }

  html.certlink-portal-route .certlink-settings-field {
    margin-bottom: var(--space-4, 16px);
  }

  html.certlink-portal-route .certlink-settings-form-panel label.field-label,
  html.certlink-portal-route .certlink-settings-form-panel .form-item label,
  html.certlink-portal-route .certlink-settings-form-panel .form-item__label {
    font-size: 11px !important;
    margin-bottom: 6px !important;
  }

  html.certlink-portal-route .certlink-settings-form-panel .input-wrap input,
  html.certlink-portal-route .certlink-settings-form-panel .input-wrap select,
  html.certlink-portal-route .certlink-settings-form-panel .input-wrap textarea,
  html.certlink-portal-route .certlink-settings-form-panel .form-item input.form-text,
  html.certlink-portal-route .certlink-settings-form-panel .form-item input.form-email,
  html.certlink-portal-route .certlink-settings-form-panel .form-item input.form-control,
  html.certlink-portal-route .certlink-settings-form-panel .form-item select,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page input.form-text,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page input.form-email,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page input.form-control,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page input[type="text"],
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page input[type="email"],
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page input[type="password"] {
    min-height: 36px !important;
    font-size: 13px !important;
    padding: 6px 10px !important;
  }

  html.certlink-portal-route .certlink-settings-choice-grid {
    gap: var(--space-3, 12px);
  }

  html.certlink-portal-route .certlink-settings-choice {
    padding: 10px 12px;
    gap: var(--space-2, 8px);
    min-height: 4.75rem;
  }

  html.certlink-portal-route .certlink-settings-choice .dot {
    width: 16px;
    height: 16px;
  }

  html.certlink-portal-route .certlink-settings-choice .dot::after {
    width: 8px;
    height: 8px;
  }

  html.certlink-portal-route .certlink-settings-choice .choice-title {
    font-size: 13px !important;
  }

  html.certlink-portal-route .certlink-settings-choice .choice-meta {
    font-size: 10px !important;
  }

  html.certlink-portal-route .certlink-download-row {
    gap: var(--space-3, 12px);
    padding: 10px 12px;
  }

  html.certlink-portal-route .certlink-download-row .download-file {
    gap: var(--space-3, 12px);
    min-width: 0;
  }

  html.certlink-portal-route .certlink-download-row .doc-ico {
    width: 32px;
    height: 32px;
  }

  html.certlink-portal-route .certlink-download-row .doc-ico svg {
    width: 18px;
    height: 18px;
  }

  html.certlink-portal-route .certlink-download-row .download-name {
    font-size: 13px !important;
  }

  html.certlink-portal-route .certlink-download-row .download-sub {
    font-size: 10px !important;
  }

  html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .upload-btn,
  html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .download-btn,
  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .upload-btn,
  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .download-btn,
  html.certlink-portal-route .certlink-download-row .download-btn {
    min-width: 0 !important;
    padding: 8px 12px !important;
    font-size: 12px !important;
  }

  html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .upload-btn svg,
  html.certlink-portal-route body.path-settings-general .certlink-download-row--manage .download-btn svg,
  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .upload-btn svg,
  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-download-row .download-btn svg,
  html.certlink-portal-route .certlink-download-row .download-btn svg {
    width: 14px !important;
    height: 14px !important;
    flex: none !important;
  }

  html.certlink-portal-route .lang-templates {
    margin-top: var(--space-3, 12px);
    padding-top: var(--space-3, 12px);
    gap: var(--space-2, 8px);
  }

  html.certlink-portal-route .lang-templates-label {
    font-size: 11px !important;
  }

  html.certlink-portal-route .lang-grid {
    gap: var(--space-2, 8px);
  }

  html.certlink-portal-route .lang-chip {
    padding: 6px 10px;
    gap: var(--space-2, 8px);
  }

  html.certlink-portal-route .lang-tick {
    width: 14px;
    height: 14px;
  }

  html.certlink-portal-route .lang-code {
    font-size: 11px !important;
  }

  html.certlink-portal-route .certlink-user-settings-page .certlink-settings-form-actions,
  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions {
    margin-top: var(--space-5, 20px);
    padding-top: var(--space-4, 16px);
    gap: var(--space-3, 12px);
    flex-wrap: wrap;
  }

  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions__buttons {
    gap: var(--space-3, 12px);
    flex-wrap: nowrap;
  }

  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button.certlink-general-settings-save-btn,
  html.certlink-portal-route body.path-settings-general .certlink-general-settings--staff .certlink-settings-form-actions button.certlink-general-settings-cancel-btn {
    padding: 8px 14px !important;
    font-size: 12px !important;
  }

  html.certlink-portal-route .certlink-user-settings-page .form-actions button#edit-submit.certlink-portal-fill-btn,
  html.certlink-portal-route .certlink-user-settings-page .form-actions button#edit-submit.button--primary.btn.btn-primary {
    min-height: 34px !important;
    height: 34px !important;
    width: auto !important;
    min-width: 132px !important;
    padding: 0 14px !important;
    font-size: 12px !important;
  }
}

@media (max-width: 720px) {
  html.certlink-portal-route .certlink-settings-field-row {
    grid-template-columns: 1fr;
  }

  html.certlink-portal-route .certlink-settings-choice-grid {
    grid-template-columns: 1fr;
  }

  html.certlink-portal-route .certlink-contact-notice {
    flex-direction: column;
    align-items: flex-start;
  }
}

/**
 * Aumento del tamaño de la fuente de los inputs y textos solicitado por el usuario (ajustado -25% de la escala anterior).
 * Factor aplicado: 1.3125 (1.75 * 0.75).
 */
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap.is-readonly input[type="text"],
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap.is-readonly input[type="email"],
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap input[readonly],
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap input[readonly][type="email"],
html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-form-panel .input-wrap.is-readonly input[readonly] {
  font-size: 1.3125rem !important;
}

html.certlink-portal-route .certlink-settings-page-head h2,
html.certlink-portal-route .certlink-page-head h2,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page h2 {
  font-size: calc(1.3125 * var(--fs-4xl, 2rem)) !important; /* ~2.625rem */
}

html.certlink-portal-route .certlink-settings-page-head p,
html.certlink-portal-route .certlink-page-head p,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page > p,
html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-section-head + .certlink-settings-section-sub {
  font-size: calc(1.3125 * var(--fs-md, 1rem)) !important; /* 1.3125rem */
}

/* Eliminar el margin-bottom (margen marrón) bajo la descripción de cabecera en Clients y Projects */
html.certlink-portal-route .certlink-page-head p {
  margin-bottom: 0 !important;
}


html.certlink-portal-route .certlink-settings-notice__text {
  font-size: 18px !important;
}

html.certlink-portal-route .certlink-settings-section-head h3 {
  font-size: calc(1.3125 * var(--fs-xl, 1.25rem)) !important; /* ~1.64rem */
}

@media (max-width: 1400px) {
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap.is-readonly input[type="text"],
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap.is-readonly input[type="email"],
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap input[readonly],
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-field .input-wrap input[readonly][type="email"],
  html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-form-panel .input-wrap.is-readonly input[readonly] {
    font-size: 17px !important; /* 13px * 1.3125 */
  }

  html.certlink-portal-route .certlink-settings-page-head h2,
  html.certlink-portal-route .certlink-page-head h2,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page h2 {
    font-size: 25px !important; /* 19px * 1.3125 */
  }

  html.certlink-portal-route .certlink-settings-page-head p,
  html.certlink-portal-route .certlink-page-head p,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page > p,
  html.certlink-portal-route body.path-settings-user .certlink-user-settings-page .certlink-settings-section-head + .certlink-settings-section-sub {
    font-size: 16px !important; /* 12px * 1.3125 */
  }

  html.certlink-portal-route .certlink-settings-section-head h3 {
    font-size: 20px !important; /* 15px * 1.3125 */
  }


  html.certlink-portal-route .certlink-settings-notice__text {
    font-size: 15px !important;
  }
}

/* En móviles (≤720px), permitimos que el shell ocupe el 100% de la columna para evitar problemas de espacio. */
@media (max-width: 720px) {
  html.certlink-portal-route .certlink-settings-shell {
    max-width: 100% !important;
  }
}

/**
 * Ajustes visuales premium solicitados para el listado de clientes (/clients).
 */

/* 1. Botón de settings redondo y 30% más pequeño */
html.certlink-portal-route body.certlink-portal-route .certlink-custom-page a.setup-btn.setup-btn--icon {
  width: calc(0.7 * var(--certlink-btn-fill-primary-min-height, 40px)) !important;
  min-width: calc(0.7 * var(--certlink-btn-fill-primary-min-height, 40px)) !important;
  max-width: calc(0.7 * var(--certlink-btn-fill-primary-min-height, 40px)) !important;
  min-height: calc(0.7 * var(--certlink-btn-fill-primary-min-height, 40px)) !important;
  height: calc(0.7 * var(--certlink-btn-fill-primary-min-height, 40px)) !important;
  border-radius: 50% !important;
  font-size: calc(0.7 * 1.375rem) !important;
}

/* 2. Espaciado simétrico del buscador (márgenes verticales iguales) */
html.certlink-portal-route body.path-clients .view-client-list .view-filters {
  margin-top: 20px !important;
  margin-bottom: 20px !important;
}

/* 3. Margen izquierdo en las filas de la tabla (primera columna) para evitar que esté pegado */
html.certlink-portal-route body.path-clients .certlink-custom-page .view-client-list table th:first-child,
html.certlink-portal-route body.path-clients .certlink-custom-page .view-client-list table td:first-child {
  padding-left: 28px !important;
}

/* 5. Unificar la separación superior del título de página con el menú del header (igual a Certificates) */
html.certlink-portal-route body.path-settings-user .certlink-custom-page > .shell,
html.certlink-portal-route body.path-settings-general .certlink-custom-page > .shell,
html.certlink-portal-route body.path-settings-user .certlink-custom-page .certlink-settings-shell,
html.certlink-portal-route body.path-settings-general .certlink-custom-page .certlink-settings-shell {
  padding-top: 0 !important;
}
html.certlink-portal-route body.path-settings-user .certlink-settings-page-head,
html.certlink-portal-route body.path-settings-general .certlink-settings-page-head,
html.certlink-portal-route .certlink-settings-page-head {
  margin-top: 0 !important;
}

html.certlink-portal-route body.path-clients .certlink-custom-page,
html.certlink-portal-route body.path-projects .certlink-custom-page,
html.certlink-portal-route body.path-settings-user .certlink-custom-page {
  padding-top: 14px !important;
}

@media (max-width: 1400px) {
  html.certlink-portal-route body.path-clients .certlink-custom-page,
  html.certlink-portal-route body.path-projects .certlink-custom-page,
  html.certlink-portal-route body.path-settings-user .certlink-custom-page {
    padding-top: 12px !important;
  }
}

/* 6. Unificar tamaño de las tablas con los placeholders de búsqueda en Clients y Projects */
html.certlink-portal-route body.path-clients .view-client-list table th,
html.certlink-portal-route body.path-clients .view-client-list table td,
html.certlink-portal-route body.path-clients .view-client-list .view-filters input[type="text"],
html.certlink-portal-route body.path-projects .certlink-projects-panel table th,
html.certlink-portal-route body.path-projects .certlink-projects-panel table td,
html.certlink-portal-route body.path-projects .certlink-projects-controls .search-wrap input {
  font-size: 16px !important;
}

html.certlink-portal-route body.path-clients .view-client-list .view-filters input[type="text"]::placeholder,
html.certlink-portal-route body.path-projects .certlink-projects-controls .search-wrap input::placeholder {
  font-size: 16px !important;
}

@media (max-width: 1400px) {
  html.certlink-portal-route body.path-clients .view-client-list table th,
  html.certlink-portal-route body.path-clients .view-client-list table td,
  html.certlink-portal-route body.path-clients .view-client-list .view-filters input[type="text"],
  html.certlink-portal-route body.path-projects .certlink-projects-panel table th,
  html.certlink-portal-route body.path-projects .certlink-projects-panel table td,
  html.certlink-portal-route body.path-projects .certlink-projects-controls .search-wrap input {
    font-size: 13px !important;
  }

  html.certlink-portal-route body.path-clients .view-client-list .view-filters input[type="text"]::placeholder,
  html.certlink-portal-route body.path-projects .certlink-projects-controls .search-wrap input::placeholder {
    font-size: 13px !important;
  }
}

/* 7. Reducir el botón de engranaje de configuración (settings) un 25% en la tabla de Clients */
html.certlink-portal-route body.path-clients .certlink-custom-page td.views-field-nothing a.setup-btn.setup-btn--icon {
  width: 27px !important;
  height: 27px !important;
  min-width: 27px !important;
  max-width: 27px !important;
  min-height: 27px !important;
  border-radius: 6px !important;
}

html.certlink-portal-route body.path-clients .certlink-custom-page td.views-field-nothing a.setup-btn.setup-btn--icon svg {
  width: 18px !important;
  height: 18px !important;
}

/* 8. Unificar la distancia inferior de la cabecera al panel en Clients y Projects (exactamente 10px como en PM Settings) */
html.certlink-portal-route body.path-clients .certlink-page-head,
html.certlink-portal-route body.path-projects .certlink-page-head {
  margin-bottom: 10px !important;
}

html.certlink-portal-route body.path-clients .certlink-custom-page > .shell > .panel,
html.certlink-portal-route body.path-projects .certlink-custom-page > .shell > .panel {
  margin-top: 0 !important;
}

/**
 * Modal Provider Information Notice (maqueta User Settings 24-08-26).
 *
 * Debe vivir en document.body (JS) y superar el z-index del masthead (6500) y
 * de .certlink-custom-page (6000). Si queda dentro de la página, el overlay se
 * recorta y el título «Provider Information Notice» se pinta encima.
 */
html.certlink-portal-route #certlink-pin-notice-modal,
body > #certlink-pin-notice-modal.certlink-pin-modal-overlay {
  position: fixed !important;
  inset: 0 !important;
  top: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  left: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  max-width: none !important;
  margin: 0 !important;
  z-index: 10050 !important;
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--space-6, 24px);
  box-sizing: border-box;
  background: rgba(6, 28, 42, 0.72);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  opacity: 1;
  visibility: visible;
  pointer-events: none;
  transform: none !important;
}

html.certlink-portal-route #certlink-pin-notice-modal[hidden]:not(.is-open),
body > #certlink-pin-notice-modal.certlink-pin-modal-overlay[hidden]:not(.is-open) {
  display: none !important;
}

html.certlink-portal-route #certlink-pin-notice-modal.is-open,
body > #certlink-pin-notice-modal.certlink-pin-modal-overlay.is-open {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

html.certlink-portal-route .certlink-pin-modal {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  max-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-2xl, 20px);
  box-shadow: var(--shadow-xl, 0 20px 50px rgba(0, 0, 0, 0.35));
  overflow: hidden;
  transform: translateY(14px) scale(0.98);
  background: linear-gradient(180deg, #114062, #0d3450);
  transition: transform 0.2s ease-out;
}

html.certlink-portal-route #certlink-pin-notice-modal.is-open .certlink-pin-modal,
html.certlink-portal-route .certlink-pin-modal-overlay.is-open .certlink-pin-modal {
  transform: translateY(0) scale(1);
}

html.certlink-portal-route .certlink-pin-modal__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-4, 16px);
  padding: var(--space-6, 24px) var(--space-6, 24px) var(--space-4, 16px);
  flex: none;
}

html.certlink-portal-route .certlink-pin-modal__head h3 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--fs-2xl, 1.5rem);
  line-height: 1.15;
  color: #fff;
  margin: 0 0 4px;
}

html.certlink-portal-route .certlink-pin-modal__head p {
  margin: 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: var(--fs-sm, 0.875rem);
  line-height: var(--lh-normal, 1.5);
  max-width: 42ch;
}

html.certlink-portal-route .certlink-pin-modal__close {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-md, 8px);
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  padding: 0;
}

html.certlink-portal-route .certlink-pin-modal__close:hover,
html.certlink-portal-route .certlink-pin-modal__close:focus-visible {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

html.certlink-portal-route .certlink-pin-modal__close svg {
  width: 17px;
  height: 17px;
}

html.certlink-portal-route .certlink-pin-modal__doc {
  max-height: 46vh;
  overflow-y: auto;
  padding: 0 var(--space-6, 24px) var(--space-5, 20px);
}

html.certlink-portal-route .certlink-pin-modal__doc h4 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-md, 1rem);
  color: #fff;
  margin: var(--space-5, 20px) 0 var(--space-2, 8px);
}

html.certlink-portal-route .certlink-pin-modal__doc h4:first-child {
  margin-top: 0;
}

html.certlink-portal-route .certlink-pin-modal__doc p {
  margin: 0 0 var(--space-3, 12px);
  font-size: var(--fs-sm, 0.875rem);
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.74);
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
}

html.certlink-portal-route .certlink-pin-modal__doc ul {
  margin: 0 0 var(--space-3, 12px);
  padding-left: 20px;
  list-style-type: disc;
}

html.certlink-portal-route .certlink-pin-modal__doc li {
  margin: 0 0 var(--space-2, 8px);
  font-size: var(--fs-sm, 0.875rem);
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.74);
  text-align: justify;
}

html.certlink-portal-route .certlink-pin-modal__doc a,
html.certlink-portal-route .certlink-pin-modal__annex-link {
  color: #f59e0b;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

html.certlink-portal-route .certlink-pin-modal__doc a:hover,
html.certlink-portal-route .certlink-pin-modal__doc a:focus-visible,
html.certlink-portal-route .certlink-pin-modal__annex-link:hover,
html.certlink-portal-route .certlink-pin-modal__annex-link:focus-visible {
  color: #fbbf24;
  text-decoration: underline;
}

html.certlink-portal-route .certlink-pin-modal__actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-3, 12px);
  padding: 0 var(--space-6, 24px) var(--space-6, 24px);
  flex: none;
}

html.certlink-portal-route .certlink-pin-modal__done {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-md, 1rem);
  border-radius: var(--radius-md, 8px);
  padding: 12px var(--space-6, 24px);
  background: var(--al-orange, #e8722e);
  color: #fff;
  border: none;
  box-shadow: 0 2px 10px rgba(232, 114, 46, 0.35);
  cursor: pointer;
}

html.certlink-portal-route .certlink-pin-modal__done:hover,
html.certlink-portal-route .certlink-pin-modal__done:focus-visible {
  background: var(--al-orange-600, #d4651f);
  color: #fff;
}

@media (max-width: 720px) {
  html.certlink-portal-route .certlink-settings-notice__btn.certlink-user-pin-btn {
    width: 100% !important;
    white-space: normal;
  }

  html.certlink-portal-route .certlink-pin-modal__head h3 {
    font-size: var(--fs-xl, 1.25rem);
  }
}

/**
 * Modal PIN de primer acceso (maqueta Certificates 24-08-26).
 *
 * Overlay fijo por encima del masthead (6500) y de .certlink-custom-page (6000).
 * El JS lo mueve a document.body. No se cierra con Escape ni clic en el fondo.
 */
html.certlink-portal-route #certlink-pin-first-visit-modal,
body > #certlink-pin-first-visit-modal.certlink-pin-first-visit {
  position: fixed !important;
  inset: 0 !important;
  z-index: 10060 !important;
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--space-6, 24px);
  box-sizing: border-box;
  background: rgba(0, 20, 34, 0.62);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

html.certlink-portal-route #certlink-pin-first-visit-modal.is-open,
body > #certlink-pin-first-visit-modal.certlink-pin-first-visit.is-open {
  display: flex !important;
}

html.certlink-portal-route .certlink-pin-first-visit__card {
  width: 100%;
  max-width: 660px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  background: var(--al-white, #fff);
  border-radius: var(--radius-2xl, 20px);
  box-shadow: var(--shadow-xl, 0 28px 56px rgba(0, 48, 80, 0.18));
  overflow: hidden;
}

html.certlink-portal-route .certlink-pin-first-visit__head {
  position: relative;
  padding: var(--space-8, 32px) var(--space-10, 40px) var(--space-6, 24px);
  background: var(--al-navy, #003050);
  color: var(--al-white, #fff);
  flex: none;
}

html.certlink-portal-route .certlink-pin-first-visit__head::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--al-orange, #e09030) 0 34%, rgba(255, 255, 255, 0.14) 34%);
}

html.certlink-portal-route .certlink-pin-first-visit__eyebrow {
  display: block;
  font-family: var(--font-display);
  font-size: var(--fs-xs, 12px);
  font-weight: 700;
  letter-spacing: var(--tracking-caps, 0.08em);
  text-transform: uppercase;
  color: var(--al-orange, #e09030);
  margin-bottom: 8px;
}

html.certlink-portal-route .certlink-pin-first-visit__head h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--fs-2xl, 24px);
  line-height: 1.15;
  color: var(--al-white, #fff);
  letter-spacing: var(--tracking-tight, -0.01em);
}

html.certlink-portal-route .certlink-pin-first-visit__body {
  padding: var(--space-8, 32px) var(--space-10, 40px) var(--space-6, 24px);
  overflow-y: auto;
  color: var(--fg-2, #3d5568);
  font-size: var(--fs-md, 15px);
  line-height: 1.55;
  text-align: justify;
}

html.certlink-portal-route .certlink-pin-first-visit__body p {
  margin: 0 0 var(--space-5, 20px);
}

html.certlink-portal-route .certlink-pin-first-visit__lede {
  color: var(--fg-1, #1a3344);
}

html.certlink-portal-route .certlink-pin-first-visit__ack-intro {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-sm, 13px);
  letter-spacing: var(--tracking-caps, 0.08em);
  text-transform: uppercase;
  color: var(--al-navy-600, #1e4a6e);
  margin-bottom: var(--space-4, 16px);
  text-align: left;
}

html.certlink-portal-route .certlink-pin-first-visit__body ul {
  list-style: none;
  margin: 0 0 var(--space-6, 24px);
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-4, 16px);
}

html.certlink-portal-route .certlink-pin-first-visit__body li {
  position: relative;
  padding-left: var(--space-6, 24px);
  text-align: justify;
}

html.certlink-portal-route .certlink-pin-first-visit__body li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--al-orange, #e09030);
}

html.certlink-portal-route .certlink-pin-first-visit__body strong {
  color: var(--al-navy, #003050);
  font-weight: 700;
}

html.certlink-portal-route .certlink-pin-first-visit__annex-note {
  background: var(--al-navy-50, #f3f6fa);
  border-left: 3px solid var(--al-navy-300, #98add3);
  border-radius: var(--radius-sm, 6px);
  padding: var(--space-4, 16px) var(--space-5, 20px);
  font-size: var(--fs-sm, 13px);
  margin-bottom: var(--space-5, 20px);
}

html.certlink-portal-route .certlink-pin-first-visit__final {
  margin-bottom: 0;
  font-weight: 700;
  color: var(--al-navy, #003050);
  font-size: var(--fs-md, 15px);
}

html.certlink-portal-route .certlink-pin-first-visit__foot {
  padding: var(--space-6, 24px) var(--space-10, 40px) var(--space-8, 32px);
  border-top: 1px solid var(--border-1, #e4ecf3);
  background: var(--al-off-white, #f6f7f8);
  display: flex;
  flex-direction: column;
  gap: var(--space-5, 20px);
  flex: none;
}

html.certlink-portal-route .certlink-pin-first-visit__agree {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3, 12px);
  padding: var(--space-4, 16px) var(--space-5, 20px);
  background: var(--al-white, #fff);
  border: 1px solid var(--border-1, #e4ecf3);
  border-radius: var(--radius-md, 8px);
}

html.certlink-portal-route .certlink-pin-first-visit__agree:has(input:checked) {
  border-color: var(--al-orange, #e09030);
}

html.certlink-portal-route .certlink-pin-first-visit__agree input[type="checkbox"] {
  margin-top: 3px;
  width: 18px;
  height: 18px;
  accent-color: var(--al-orange, #e09030);
  cursor: pointer;
  flex: none;
}

html.certlink-portal-route .certlink-pin-first-visit__agree label {
  font-size: var(--fs-sm, 13px);
  font-weight: 600;
  color: var(--fg-1, #1a3344);
  cursor: pointer;
  line-height: 1.4;
}

html.certlink-portal-route .certlink-pin-first-visit__actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-4, 16px);
}

html.certlink-portal-route .certlink-pin-first-visit__continue {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-md, 15px);
  color: var(--al-white, #fff);
  background: var(--al-orange, #e09030);
  border: 0;
  border-radius: var(--radius-md, 8px);
  padding: 13px var(--space-8, 32px);
  cursor: pointer;
  width: 100%;
  max-width: 360px;
}

html.certlink-portal-route .certlink-pin-first-visit__continue:hover:not(:disabled) {
  background: var(--al-orange-700, #b9701a);
}

html.certlink-portal-route .certlink-pin-first-visit__continue:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

html.certlink-portal-route .certlink-pin-first-visit__annex {
  font-family: var(--font-sans);
  font-size: var(--fs-xs, 12px);
  color: var(--fg-muted, #6b8299);
  text-align: center;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--border-2, #d4dde6);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

html.certlink-portal-route .certlink-pin-first-visit__annex:hover {
  color: var(--al-navy-600, #1e4a6e);
  text-decoration-color: var(--al-navy-300, #98add3);
}

@media (max-width: 720px) {
  html.certlink-portal-route .certlink-pin-first-visit__head,
  html.certlink-portal-route .certlink-pin-first-visit__body,
  html.certlink-portal-route .certlink-pin-first-visit__foot {
    padding-left: var(--space-6, 24px);
    padding-right: var(--space-6, 24px);
  }

  html.certlink-portal-route .certlink-pin-first-visit__head h3 {
    font-size: var(--fs-xl, 20px);
  }
}









