﻿@import url("/XMLModelProvider/Templates/PageTemplates/Chess/ChessStyles/ChessTypography.css");
@font-face {
  font-family: fontawesome;
  src: url(../../../../../fonts/fa-solid-900.woff);
}
@font-face {
  font-family: "Bebas Neue ChessFace";
  src: url("/fonts/BebasNeue-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --color-button: #36c56b;
  --color-fondo: white;
  --border-radius: 1.5rem;
  --cf-root-font-size: 10px;
  --font-size-base: 17px;
  --ancho-principal: 1200px;
  --dark-color: #555351;
  --panel-bg: rgba(11, 25, 35, 0.86);
  --input-bg: #3c3b39;
  --input-fg: rgba(255, 255, 255, 0.85);
  --ancho-principal: 120rem;
  --ancho-secundario: 120rem;
  --color-bg-inicio: #061018;
  --color-box: rgba(0, 0, 0, 0.15);
  font-size: var(--cf-root-font-size);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-size: var(--font-size-base);
  line-height: 1.6;
}

/* System typography scale by viewport width. */
@media (max-width: 359px) {
  :root {
    --cf-root-font-size: 8.75px;
    --font-size-base: 12.5px;
  }
}

@media (min-width: 360px) and (max-width: 424px) {
  :root {
    --cf-root-font-size: 9.25px;
    --font-size-base: 13px;
  }
}

@media (min-width: 425px) and (max-width: 767px) {
  :root {
    --cf-root-font-size: 9.5px;
    --font-size-base: 13.5px;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  :root {
    --cf-root-font-size: 9.75px;
    --font-size-base: 14.5px;
  }
}

@media (min-width: 1024px) and (max-width: 1279px) {
  :root {
    --cf-root-font-size: 10px;
    --font-size-base: 15px;
  }
}

@media (min-width: 1280px) and (max-width: 1439px) {
  :root {
    --cf-root-font-size: 10px;
    --font-size-base: 16px;
  }
}

@media (min-width: 1440px) and (max-width: 1919px) {
  :root {
    --cf-root-font-size: 10px;
    --font-size-base: 17px;
  }
}

@media (min-width: 1920px) and (max-width: 2559px) {
  :root {
    --cf-root-font-size: 10.5px;
    --font-size-base: 18px;
  }
}

@media (min-width: 2560px) and (max-width: 3839px) {
  :root {
    --cf-root-font-size: 11px;
    --font-size-base: 19px;
  }
}

@media (min-width: 3840px) {
  :root {
    --cf-root-font-size: 12px;
    --font-size-base: 20px;
  }
}

/* Standard button typography scale by viewport width. */
:root {
  --cf-button-font-size: 16px;
  --cf-button-compact-font-size: 13px;
}

@media (max-width: 359px) {
  :root {
    --cf-button-font-size: 12px;
    --cf-button-compact-font-size: 11px;
  }
}

@media (min-width: 360px) and (max-width: 424px) {
  :root {
    --cf-button-font-size: 12.5px;
    --cf-button-compact-font-size: 11.5px;
  }
}

@media (min-width: 425px) and (max-width: 767px) {
  :root {
    --cf-button-font-size: 13px;
    --cf-button-compact-font-size: 12px;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  :root {
    --cf-button-font-size: 14px;
    --cf-button-compact-font-size: 12.5px;
  }
}

@media (min-width: 1024px) and (max-width: 1279px) {
  :root {
    --cf-button-font-size: 15px;
    --cf-button-compact-font-size: 13px;
  }
}

@media (min-width: 1280px) and (max-width: 1439px) {
  :root {
    --cf-button-font-size: 16px;
    --cf-button-compact-font-size: 13.5px;
  }
}

@media (min-width: 1440px) and (max-width: 1919px) {
  :root {
    --cf-button-font-size: 17px;
    --cf-button-compact-font-size: 14px;
  }
}

@media (min-width: 1920px) and (max-width: 2559px) {
  :root {
    --cf-button-font-size: 18px;
    --cf-button-compact-font-size: 15px;
  }
}

@media (min-width: 2560px) and (max-width: 3839px) {
  :root {
    --cf-button-font-size: 19px;
    --cf-button-compact-font-size: 16px;
  }
}

@media (min-width: 3840px) {
  :root {
    --cf-button-font-size: 20px;
    --cf-button-compact-font-size: 17px;
  }
}

.xt-header {
  position: fixed;
  top: 0;
  width: 100%;
  border-bottom: 1px solid #6a6868;
  background-color: var(--color-fondo);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

.xt-cont-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--ancho-principal);
  height: 6rem;
  padding: 0 2rem;
  margin: 0 auto;
}

.xt-header-option {
  display: flex;
  gap: 2rem;
}

.xt-logo {
  width: 20%;
  max-width: 10rem;
  height: auto;
  display: block;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.6));
}

.xt-cont-header a img {
  width: 100%;
  height: auto;
  max-width: 10rem;
  display: block;
}

.xt-button {
  margin: 0 1.5rem;
  cursor: pointer;
}

.xt-button:hover {
  background-color: #757577;
  color: var(--color-fondo);
}

.xt-btn-color {
  background-color: var(--color-button);
  color: white;
  padding: 0.5rem 3rem;
  border-radius: var(--border-radius);
  font-size: 1.6rem;
  transition: all 0.3s ease;
  border: 1px solid var(--color-button);
}

.xt-btn-color:hover {
  background-color: var(--color-fondo);
  color: var(--color-button);
}

.xt-title {
  font-size: 3.3rem;
  font-weight: bold;
  color: var(--color-title);
  text-align: center;
  margin-top: 0rem;
}

.xt-subtitle {
  font-size: 2.5rem;
  margin-top: 1rem;
  color: var(--color-subtitle);
  text-align: center;
  display: flex;
  justify-content: center;
}

.xt-comment {
  font-size: 1.5rem;
  margin-top: 1rem;
  color: var(--color-subtitle);
  text-align: center;
}

.xt-image img {
  border-radius: 10rem;
  margin: 0rem 5rem;
}

.ui-widget-header {
  border: none !important;
  background: #000000 !important;
  font-size: 3rem !important;
}

.ui-widget-header button {
  display: none;
}

.ui-dialog-buttonset button {
  color: white;
  width: 15rem;
  padding: 2rem;
  border: none;
  border-radius: 10px;
  background-color: #302f2e;
  font-size: 1.5rem !important;
}

.ui-dialog-buttonset button:nth-child(2) {
  background-color: #36c56b;
}

.ui-dialog-buttonset button:hover {
  background-color: #4a4947;
}

.ui-dialog-buttonset button:nth-child(2):hover {
  background-color: #43d878;
}

/*FOOTER*/
.xt-footer {
  width: 100%;
  background-color: #000000;
  padding: 2rem 0;
  font-size: 1.6rem;
  box-shadow: 0 -1px 5px rgba(0, 0, 0, 0.1);
}

.xt-footer-container {
  max-width: 80rem;
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  padding: 0 1rem;
}

.xt-footer-section {
  min-width: 150px;
}

.xt-section-title {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--color-fondo);
}

.xt-footer-section ul {
  list-style-type: none;
  padding: 0;
  margin: 0;
}

.xt-footer-section li {
  margin-bottom: 0.5rem;
}

.xt-footer-section a {
  color: var(--color-fondo);
  text-decoration: none;
  transition: color 0.3s;
}

.xt-footer-section a:hover {
  color: var(--color-button);
}

.xt-footer-bottom {
  text-align: center;
  padding-top: 3rem;
  font-size: 1.4rem;
  color: var(--color-fondo);
  width: 100%;
}

.xt-body {
  background-color: var(--color-bg-inicio);
  color: white;
  background-image:
    linear-gradient(45deg, var(--color-box) 25%, transparent 25%),
    linear-gradient(-45deg, var(--color-box) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75% 75%, var(--color-box) 75%),
    linear-gradient(-45deg, transparent 75%, var(--color-box) 75%);
  background-size: 3rem 3rem;
  background-position:
    0 0,
    0 15px,
    15px -15px,
    -15px 0px;
}

/* Media Query para pantallas pequeñas (menos de 48rem) */
@media (max-width: 48rem) {
  .xt-footer-container {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .xt-footer-section {
    flex: 1 1 100%;
    min-width: auto;
    margin-bottom: 1rem;
  }
}

.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-toggle {
  cursor: pointer;
  padding: 10px 20px;
  background-color: var(--color-button);
  color: white;
  border-radius: var(--border-radius);
  font-size: var(--font-size-base);
  display: inline-block;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background-color: white;
  min-width: 200px;
  border: 1px solid #ddd;
  border-radius: var(--border-radius);
  box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
  z-index: 200;
}

.dropdown-toggle span:hover {
  /* background-color: #f1f1f1; */
  background-color: white;
  color: var(--color-button);
  border-radius: var(--border-radius);
}

.dropdown-menu a {
  color: black;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
}

.dropdown-menu a:hover {
  background-color: #f1f1f1;
}

.dropdown:hover .dropdown-menu {
  display: block;
}

/* Menu center hover underline styles */
.xt-menu-center .dropdown {
  display: inline-block;
  width: auto;
}

.xt-menu-center .dropdown-toggle {
  display: inline;
  text-decoration: none;
}

.xt-menu-center .dropdown-toggle:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
  background-color: transparent !important;
}

/* Estilo para el elemento del menú de la página actual */
.xt-menu-center .dropdown-toggle.menu-active {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}

/* ================================================
   Dark Theme Header (used by renderHeader)
   ================================================ */
.xt-header-inicio {
  top: 0;
  width: 100%;
  border-bottom: 1px solid #6a6868;
  background-color: var(--color-bg-inicio);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

.xt-cont-header-inicio {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--ancho-principal);
  height: 7rem;
  padding: 0 2rem;
  margin: 0 auto;
}

.xt-media-sm-dn .xt-cont-header-inicio {
  flex-direction: column;
  flex-wrap: wrap;
  padding: 0;
  align-content: space-between;
  justify-content: space-around;
}

.xt-cont-header-inicio a:not(.cf-brand) img {
  width: 100%;
  height: auto;
  display: block;
}

.xt-cont-header-inicio .dropdown-toggle {
  background-color: transparent;
  border-radius: 0;
  padding: 10px 0;
}

.xt-header-inicio .dropdown-toggle {
  padding: 10px 5px;
  color: white;
  cursor: pointer;
  background-color: transparent;
  border-radius: 0;
  font-size: 1.6rem;
}

span.dropdown-toggle.xt-menu-right {
  background-repeat: no-repeat;
  padding-left: 50px;
  background-size: 40px 40px;
}

/* --- Dark Dropdown overrides for header-inicio --- */
.xt-header-inicio .dropdown-menu {
  background-color: #0b1822;
  border: 1px solid #6a6868;
  border-radius: 0.8rem;
  padding: 0.5rem 0;
  min-width: 16rem;
  box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.5);
}

.xt-header-inicio .dropdown-menu a {
  color: white;
  padding: 1rem 1.5rem;
  font-size: 1.4rem;
  cursor: pointer;
}

.xt-header-inicio .dropdown-menu a:hover {
  background-color: rgba(255, 140, 0, 0.15);
}

.menu-active {
  color: #d8a63b !important;
  border-bottom: 2px solid #d8a63b;
}

/* ================================================
   MENU HAMBURGUESA Y RESPONSIVE HEADER
   ================================================ */

.xt-hamburger {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 1rem;
  z-index: 1001;
  width: 4rem;
  height: 4rem;
  position: relative;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.6rem;
}

.xt-hamburger span {
  display: block;
  width: 2.5rem;
  height: 0.3rem;
  background-color: white;
  border-radius: 0.3rem;
  transition: all 0.3s ease;
}

.xt-hamburger.active span:nth-child(1) {
  transform: translateY(0.9rem) rotate(45deg);
}

.xt-hamburger.active span:nth-child(2) {
  opacity: 0;
}

.xt-hamburger.active span:nth-child(3) {
  transform: translateY(-0.9rem) rotate(-45deg);
}

.xt-header-inicio {
  position: relative; /* Contexto para el menú absoluto */
  z-index: 1000;
}

@media (max-width: 48rem) {
  .xt-hamburger {
    display: flex;
  }

  .xt-menu-center {
    display: none;
    position: absolute;
    top: 6rem; /* Altura del header en móvil */
    left: 0;
    width: 100%;
    background-color: #0b1822;
    flex-direction: column;
    padding: 1.5rem 0;
    z-index: 2000; /* Por encima de todo */
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.6);
    border-bottom: 2px solid #d8a63b;
  }

  .xt-menu-center.xt-menu-open {
    display: flex !important;
  }

  .xt-menu-center .dropdown {
    width: 100%;
    text-align: center;
    padding: 1.2rem 0;
  }

  .xt-menu-center .dropdown-toggle {
    font-size: 1.8rem !important;
    display: block !important;
    width: 100%;
    text-decoration: none !important;
  }

  .xt-cont-header-inicio {
    padding: 0 1.5rem;
    height: 6rem !important;
  }

  .xt-logo {
    max-width: 7rem !important;
  }
}

.ui-dialog {
  background: none !important;
  background-color: var(--dark-color) !important;
}

.ui-dialog .ui-dialog-buttonpane {
  background: none !important;
}

.xt-group-panel {
  display: grid;
  grid-template-rows: min-content;
  gap: 0.7rem 0;
}

.xt-group-panel.xt-full-height {
  height: 100%;
}

.xt-group-panel .xt-title {
  font-size: unset;
  font-weight: bold;
  color: white;
  background-color: rgba(11, 25, 35, 0.86);
  padding: 0.5rem 1rem;
  border-radius: 0.5rem 0.5rem 0 0;
}

.xt-group-panel .xt-body {
  padding: 1rem;
  background-color: rgba(11, 25, 35, 0.86);
  border-radius: 0 0 0.5rem 0.5rem;
}

.xt-group-panel .xt-full-width {
  width: 100%;
}

.xt-input {
  background-color: var(--input-bg);
  color: var(--input-fg);
  padding: 1rem;
  border: none;
  border-radius: 0.5rem;
}

/* Custom Facebook Button */
.btn-facebook {
  background-color: #1877f2;
  color: white;
  border: 1px solid #1877f2;
  border-radius: 4px;
  padding: 0 10px;
  font-family: Roboto, arial, sans-serif;
  font-weight: 500;
  font-size: 14px;
  height: 40px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 240px;
  transition: background-color 0.2s;
}

.btn-facebook:hover {
  background-color: #166fe5;
}

.fb-icon {
  background: white;
  color: #1877f2;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 16px;
  font-family: sans-serif;
}

.ui-dialog.ui-corner-all.ui-widget.ui-widget-content.ui-front.xt-panel-dialog.noclose.undefined.ui-dialog-buttons.ui-draggable {
  z-index: 1001 !important;
}

/* Password Visibility Toggle */
.xt-password-container {
  position: relative;
  width: 100%;
  display: block;
}

.xt-password-container input {
  width: 100% !important;
  padding-right: 4.5rem !important; /* Espacio para el ojo */
}

/* Clases manuales para FontAwesome si no están en el framework */
.fa,
.fas {
  font-family: "fontawesome" !important;
  font-style: normal;
  font-weight: 900;
  display: inline-block;
  text-decoration: inherit;
}

.fa-eye::before {
  content: "\f06e";
}
.fa-eye-slash::before {
  content: "\f070";
}
.fa-user::before {
  content: "\f007";
}
.fa-clock-o::before {
  content: "\f017";
}
.fa-calendar::before {
  content: "\f073";
}
.fa-trophy::before {
  content: "\f091";
}
.fa-users::before,
.fa-group::before {
  content: "\f0c0";
}
.fa-bolt::before,
.fa-flash::before {
  content: "\f0e7";
}
.fa-desktop::before {
  content: "\f108";
}
.fa-circle::before {
  content: "\f111";
}
.fa-shield::before {
  content: "\f132";
}
.fa-user-plus::before {
  content: "\f234";
}

.toggle-password {
  position: absolute;
  right: 1.5rem;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  color: #888;
  font-size: 2.2rem; /* Un poco más grande para que se vea mejor */
  z-index: 99;
  transition:
    color 0.2s,
    transform 0.2s;
  background: transparent;
  border: none;
  display: flex !important;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.toggle-password:hover {
  color: #d8a63b; /* Color naranja para resaltar */
  transform: translateY(-50%) scale(1.1);
}

/* Ocultar iconos nativos de navegadores (Edge/Chrome/IE) */
input::-ms-reveal,
input::-ms-clear {
  display: none !important;
}

input::-webkit-contacts-auto-fill-button,
input::-webkit-credentials-auto-fill-button {
  visibility: hidden;
  pointer-events: none;
  position: absolute;
  right: 0;
}

/* ChessFace visual system */
:root {
  --color-button: #36c56b;
  --color-fondo: #061018;
  --border-radius: 0.8rem;
  --dark-color: #0b1822;
  --panel-bg: rgba(11, 25, 35, 0.86);
  --input-bg: rgba(255, 255, 255, 0.055);
  --input-fg: rgba(247, 245, 239, 0.92);
  --color-bg-inicio: #061018;
  --color-box: rgba(255, 255, 255, 0.026);
  --cf-bg: #061018;
  --cf-bg-2: #0b1822;
  --cf-panel: rgba(11, 25, 35, 0.88);
  --cf-panel-soft: rgba(255, 255, 255, 0.055);
  --cf-border: rgba(255, 255, 255, 0.14);
  --cf-text: #f7f5ef;
  --cf-muted: #9daab5;
  --cf-green: #36c56b;
  --cf-green-soft: rgba(54, 197, 107, 0.16);
  --cf-gold: #d8a63b;
  --cf-danger: #ef5350;
  --cf-shadow: 0 2rem 5rem rgba(0, 0, 0, 0.34);
}

body {
  background:
    linear-gradient(
      90deg,
      rgba(6, 16, 24, 0.96) 0%,
      rgba(6, 16, 24, 0.78) 36%,
      rgba(6, 16, 24, 0.96) 100%
    ),
    radial-gradient(
      circle at 14% 12%,
      rgba(54, 197, 107, 0.1),
      transparent 32rem
    ),
    linear-gradient(
      135deg,
      var(--cf-bg) 0%,
      var(--cf-bg-2) 55%,
      var(--cf-bg) 100%
    );
  color: var(--cf-text);
}

body,
.xt-body,
.chess-body,
.chess-main-container,
.xt-cont-body,
.xt-cont-sect,
.xt-modal-content,
.ui-dialog,
.ui-widget {
}

.xt-body {
  background:
    linear-gradient(
      90deg,
      rgba(6, 16, 24, 0.96) 0%,
      rgba(6, 16, 24, 0.78) 36%,
      rgba(6, 16, 24, 0.96) 100%
    ),
    radial-gradient(
      circle at 16% 12%,
      rgba(54, 197, 107, 0.1),
      transparent 34rem
    ),
    linear-gradient(
      135deg,
      var(--cf-bg) 0%,
      var(--cf-bg-2) 55%,
      var(--cf-bg) 100%
    ) !important;
  color: var(--cf-text);
}

.xt-header,
.xt-header-inicio {
  border-bottom: 1px solid rgba(255, 255, 255, 0.12) !important;
  background: rgba(4, 13, 20, 0.92) !important;
  box-shadow: 0 1.2rem 3rem rgba(0, 0, 0, 0.28) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.xt-cont-header,
.xt-cont-header-inicio {
  height: 7.2rem;
}

.xt-logo,
.xt-cont-header a img,
.xt-cont-header-inicio a img {
  filter: drop-shadow(0 0.8rem 1.8rem rgba(0, 0, 0, 0.4));
}

.xt-menu-center {
  display: flex;
  align-items: center;
  gap: 3rem;
}

.xt-header-inicio .dropdown-toggle,
.xt-menu-center .dropdown-toggle,
.dropdown-toggle {
  border: 1px solid transparent;
  border-radius: 0.7rem;
  background: transparent !important;
  color: var(--cf-text) !important;
  font-weight: 750;
  transition:
    color 0.2s ease,
    border-color 0.2s ease,
    background 0.2s ease;
}

.xt-header-inicio .dropdown-toggle:hover,
.xt-menu-center .dropdown-toggle:hover,
.menu-active {
  color: var(--cf-green) !important;
  background: rgba(54, 197, 107, 0.08) !important;
  border-color: rgba(54, 197, 107, 0.28) !important;
}

.xt-header-inicio .dropdown-menu,
.dropdown-menu {
  overflow: hidden;
  border: 1px solid var(--cf-border) !important;
  border-radius: 1rem !important;
  background: rgba(8, 20, 30, 0.98) !important;
  box-shadow: var(--cf-shadow) !important;
}

.xt-header-inicio .dropdown-menu a,
.dropdown-menu a {
  color: var(--cf-text) !important;
}

.xt-header-inicio .dropdown-menu a:hover,
.dropdown-menu a:hover {
  color: var(--cf-green) !important;
  background: rgba(54, 197, 107, 0.12) !important;
}

.xt-btn-color,
.xt-button.xt-btn-color,
button.xt-btn-color,
input.xt-btn-color,
.ui-dialog-buttonset button:nth-child(2) {
  border: 1px solid rgba(101, 255, 152, 0.55) !important;
  border-radius: 0.7rem !important;
  background: linear-gradient(180deg, #43d878, #1b944b) !important;
  color: #fff !important;
  box-shadow: 0 1.2rem 2.4rem rgba(30, 180, 83, 0.22) !important;
  font-weight: 800;
}

.xt-btn-color:hover,
.xt-button.xt-btn-color:hover,
button.xt-btn-color:hover,
input.xt-btn-color:hover,
.ui-dialog-buttonset button:nth-child(2):hover {
  color: #fff !important;
  filter: brightness(1.08);
  transform: translateY(-0.2rem);
}

.xt-btn-secondary,
.ui-dialog-buttonset button {
  border: 1px solid var(--cf-border) !important;
  border-radius: 0.8rem !important;
  background: rgba(255, 255, 255, 0.07) !important;
  color: var(--cf-text) !important;
}

.xt-title,
.xt-titulo-principal,
.xt-standard-title {
  color: var(--cf-text) !important;
  font-family: var(--cf-serif);
  letter-spacing: -0.03em;
}

.xt-subtitle,
.xt-comment,
.xt-results-count,
.xt-page-info {
  color: var(--cf-muted) !important;
}

.xt-cont-body,
.xt-section-box,
.xt-group-panel .xt-title,
.xt-group-panel .xt-body,
.xt-academia,
.xt-option,
.xt-destacado,
.xt-transmision,
.xt-academia-seccion-grupo,
.xt-chess-title {
  border: 1px solid var(--cf-border) !important;
  border-radius: 1.2rem !important;
  background: var(--cf-panel) !important;
  box-shadow: var(--cf-shadow);
}

.xt-option,
.xt-academia,
.xt-destacado,
.xt-transmision {
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease,
    background 0.25s ease !important;
}

.xt-option:hover,
.xt-academia:hover,
.xt-destacado:hover,
.xt-transmision:hover {
  border-color: rgba(54, 197, 107, 0.48) !important;
  background: rgba(15, 35, 48, 0.96) !important;
  box-shadow:
    0 2.4rem 5.5rem rgba(0, 0, 0, 0.42),
    0 0 2.6rem rgba(54, 197, 107, 0.12);
  transform: translateY(-0.8rem) !important;
}

.xt-section-title {
  color: var(--cf-text) !important;
  border-bottom: 1px solid rgba(54, 197, 107, 0.25) !important;
}

.xt-section-title i,
.xt-standard-title i,
.toggle-password:hover {
  color: var(--cf-green) !important;
}

.xt-input,
.xt-filter-input,
input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
select,
textarea {
  border: 1px solid rgba(255, 255, 255, 0.13) !important;
  border-radius: 0.7rem !important;
  background: var(--input-bg) !important;
  color: var(--input-fg) !important;
}

.xt-input:focus,
.xt-filter-input:focus,
input:focus,
select:focus,
textarea:focus {
  border-color: rgba(54, 197, 107, 0.65) !important;
  box-shadow: 0 0 0 0.3rem rgba(54, 197, 107, 0.1);
  outline: none;
}

.ui-dialog,
.xt-modal-content,
.xt-premium-modal {
  border: 1px solid var(--cf-border) !important;
  border-radius: 1.4rem !important;
  background: linear-gradient(
    180deg,
    rgba(16, 31, 43, 0.98),
    rgba(8, 20, 30, 0.98)
  ) !important;
  color: var(--cf-text) !important;
  box-shadow: var(--cf-shadow) !important;
}

.ui-widget-header,
.xt-modal-header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
  background: rgba(255, 255, 255, 0.035) !important;
  color: var(--cf-text) !important;
}

.system-table th,
.xt-table-container th {
  background: rgba(54, 197, 107, 0.09) !important;
  color: var(--cf-text) !important;
}

.system-table td,
.xt-table-container td {
  color: #dfe7ec !important;
  border-bottom-color: rgba(255, 255, 255, 0.07) !important;
}

.system-table tr:hover td,
.xt-table-container tr:hover td {
  background: rgba(54, 197, 107, 0.07) !important;
}

.xt-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  background: #07121b !important;
}

.cf-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
  color: #fff;
  text-decoration: none !important;
  cursor: pointer;
}

.cf-brand:hover {
  color: #fff;
  text-decoration: none !important;
}

.cf-brand-mark {
  width: 64px;
  height: 65px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  overflow: hidden;
  background: #fff;
  border: 2px solid rgba(216, 166, 59, 0.9);
  border-radius: 12px;
  box-shadow: 0 0.8rem 1.8rem rgba(0, 0, 0, 0.28);
}

.cf-brand-mark img {
  width: 128%;
  height: 128%;
  object-fit: cover;
  margin-top: -10px;
  display: block;
}

.cf-brand-text {
  font-family: var(--cf-serif);
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-shadow: 0 8px 22px rgba(0, 0, 0, 0.42);
  line-height: 1;
  color: #fff;
}

.cf-brand-text span {
  color: var(--cf-gold);
}

/* User menu polish */
.xt-header-right-side {
  display: flex !important;
  align-items: center !important;
  gap: 1rem !important;
  flex-shrink: 0;
}

#header-container,
#xt-templex-chess-header-container,
.cf-templex-header-wrapper,
.chess-main-container > .tx-wrapper:first-child,
.xt-header,
.xt-header-inicio {
  position: relative !important;
  z-index: 10050 !important;
  overflow: visible !important;
}

.xt-cont-header,
.xt-cont-header-inicio,
.xt-header-right-side,
.xt-header-right-side .dropdown {
  overflow: visible !important;
}

.xt-cont-main > #header-container,
.chess-main-container > #xt-templex-chess-header-container,
.chess-main-container > .cf-templex-header-wrapper,
.chess-main-container > .tx-wrapper:first-child {
  z-index: 10050 !important;
}

.xt-header-right-side .dropdown,
.xt-cont-header-inicio > .dropdown,
.xt-cont-header > .dropdown {
  position: relative;
  z-index: 10060 !important;
}

.xt-header-right-side .dropdown::after {
  content: "";
  position: absolute;
  top: 100%;
  right: 0;
  width: 100%;
  min-width: 12rem;
  height: 1rem;
}

.xt-header-right-side .dropdown-toggle.xt-menu-right,
.xt-header-inicio span.dropdown-toggle.xt-menu-right,
span.dropdown-toggle.xt-menu-right {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 6.8rem;
  max-width: 15rem;
  height: 4.4rem;
  padding: 0 1.6rem !important;
  overflow: hidden;
  border: 1px solid rgba(54, 197, 107, 0.32) !important;
  border-radius: 0.8rem !important;
  background: rgba(54, 197, 107, 0.06) !important;
  background-image: none !important;
  color: var(--cf-green) !important;
  font-size: 1.55rem;
  font-weight: 850;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
  box-shadow: inset 0 0 0 1px rgba(54, 197, 107, 0.02);
}

.xt-header-right-side .dropdown:hover .dropdown-toggle.xt-menu-right,
.xt-header-right-side .dropdown-toggle.xt-menu-right:hover {
  background: rgba(54, 197, 107, 0.14) !important;
  border-color: rgba(54, 197, 107, 0.58) !important;
  box-shadow: 0 0.9rem 2.4rem rgba(54, 197, 107, 0.14);
  text-decoration: none !important;
}

.xt-header-right-side .dropdown-menu {
  top: calc(100% + 0.1rem) !important;
  right: 0 !important;
  left: auto !important;
  display: none;
  min-width: 21rem;
  width: max-content;
  max-width: min(28rem, calc(100vw - 2.4rem));
  padding: 0.7rem !important;
  overflow: hidden;
  border: 1px solid rgba(54, 197, 107, 0.3) !important;
  border-radius: 1rem !important;
  background: rgba(5, 16, 24, 0.98) !important;
  box-shadow:
    0 1.8rem 4.2rem rgba(0, 0, 0, 0.42),
    0 0 0 1px rgba(255, 255, 255, 0.04) !important;
  z-index: 10020 !important;
}

.xt-header-right-side .dropdown.is-open .dropdown-menu,
.cf-user-dropdown.is-open .dropdown-menu {
  display: block !important;
}

.xt-header-right-side .dropdown-menu::before {
  content: "";
  position: absolute;
  top: -0.6rem;
  right: 2rem;
  width: 1rem;
  height: 1rem;
  border-left: 1px solid rgba(54, 197, 107, 0.3);
  border-top: 1px solid rgba(54, 197, 107, 0.3);
  background: rgba(5, 16, 24, 0.98);
  transform: rotate(45deg);
}

.xt-header-right-side .dropdown-menu a {
  display: flex !important;
  align-items: center;
  min-height: 3.8rem;
  padding: 0.95rem 1.2rem !important;
  border-radius: 0.7rem;
  color: var(--cf-text) !important;
  font-size: 1.35rem;
  font-weight: 700;
  text-decoration: none !important;
  white-space: nowrap;
}

.xt-header-right-side .dropdown-menu a:hover {
  color: var(--cf-green) !important;
  background: rgba(54, 197, 107, 0.12) !important;
}

@media (max-width: 48rem) {
  .xt-menu-center {
    display: none !important;
    position: absolute;
    top: 6.8rem;
    left: 0;
    width: 100%;
    max-height: calc(100vh - 6.8rem);
    overflow-y: auto;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.45rem 0;
    border-bottom: 1px solid rgba(54, 197, 107, 0.35);
    background: rgba(4, 13, 20, 0.98) !important;
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.6);
    z-index: 2000;
  }

  .xt-menu-center.xt-menu-open {
    display: flex !important;
  }

  .xt-menu-center .dropdown {
    width: 100%;
    padding: 0.2rem 0.8rem;
    text-align: center;
  }

  .xt-menu-center .dropdown-toggle {
    display: block !important;
    width: 100%;
    padding: 0.65rem 1rem !important;
    font-size: 1.5rem !important;
    line-height: 1.25;
    text-decoration: none !important;
  }

  .xt-cont-header-inicio {
    padding: 0 0.8rem !important;
  }

  .cf-brand {
    gap: 8px;
    min-width: 0;
  }

  .cf-brand-mark {
    width: 50px;
    height: 56px;
    border-radius: 9px;
  }

  .cf-brand-text {
    font-size: clamp(18px, 5.5vw, 22px);
    max-width: none;
    overflow: visible;
  }

  .xt-header-right-side .dropdown-toggle.xt-menu-right,
  .xt-header-inicio span.dropdown-toggle.xt-menu-right,
  span.dropdown-toggle.xt-menu-right {
    display: block !important;
    min-width: 7.6rem;
    max-width: min(34vw, 13rem);
    height: 4rem;
    padding: 0 0.8rem !important;
    overflow: hidden !important;
    font-size: clamp(0.92rem, 2.9vw, 1.12rem);
    line-height: 4rem;
    text-align: center;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .xt-header-right-side .dropdown-toggle.xt-menu-right.xt-menu-right-multiline,
  .xt-header-inicio span.dropdown-toggle.xt-menu-right.xt-menu-right-multiline,
  span.dropdown-toggle.xt-menu-right.xt-menu-right-multiline {
    align-content: center;
    display: -webkit-box !important;
    line-height: 1.15;
    text-overflow: clip !important;
    white-space: normal !important;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .xt-header-right-side .dropdown-menu {
    right: 0 !important;
    min-width: 19rem;
  }
}

/* Ambient animated background bubbles */
@keyframes cfBubbleDrift {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
    opacity: 0.18;
  }

  45% {
    transform: translate3d(3.5rem, -6rem, 0) scale(1.08);
    opacity: 0.32;
  }

  100% {
    transform: translate3d(-2rem, -12rem, 0) scale(0.96);
    opacity: 0.16;
  }
}

@keyframes cfBubbleFloat {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }

  50% {
    transform: translate3d(-4rem, 5rem, 0) scale(1.06);
  }

  100% {
    transform: translate3d(2rem, -4rem, 0) scale(0.98);
  }
}

@keyframes cfSmallBubblesMove {
  0% {
    background-position:
      8% 82%,
      18% 22%,
      31% 70%,
      46% 34%,
      59% 78%,
      72% 20%,
      84% 60%,
      94% 38%;
    opacity: 0.36;
  }

  50% {
    background-position:
      10% 74%,
      21% 16%,
      34% 62%,
      43% 27%,
      62% 70%,
      69% 15%,
      87% 52%,
      91% 30%;
    opacity: 0.55;
  }

  100% {
    background-position:
      7% 66%,
      24% 10%,
      29% 54%,
      49% 20%,
      56% 62%,
      75% 9%,
      82% 44%,
      96% 24%;
    opacity: 0.38;
  }
}

body::before,
body::after,
.xt-body::before,
.xt-body::after {
  content: "";
  position: fixed;
  inset: auto;
  pointer-events: none;
  z-index: 0;
  border-radius: 999rem;
  background: radial-gradient(
    circle at 35% 35%,
    rgba(255, 255, 255, 0.24),
    rgba(54, 197, 107, 0.11) 42%,
    rgba(54, 197, 107, 0) 70%
  );
  filter: blur(0.2rem);
  mix-blend-mode: screen;
}

body::before,
.xt-body::before {
  width: 34rem;
  height: 34rem;
  left: 5%;
  top: 14%;
  animation: cfBubbleDrift 18s ease-in-out infinite alternate;
}

body::after,
.xt-body::after {
  width: 24rem;
  height: 24rem;
  right: 8%;
  bottom: 10%;
  animation: cfBubbleFloat 22s ease-in-out infinite alternate;
  animation-delay: -7s;
  opacity: 0.18;
}

.xt-cont-main::before,
.xt-cont-body::before,
.chess-main-container::before,
.cf-landing::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    radial-gradient(
      circle,
      rgba(255, 255, 255, 0.38) 0 0.35rem,
      rgba(54, 197, 107, 0.14) 0.36rem 0.9rem,
      transparent 1rem
    ),
    radial-gradient(
      circle,
      rgba(255, 255, 255, 0.3) 0 0.28rem,
      rgba(54, 197, 107, 0.16) 0.29rem 0.7rem,
      transparent 0.8rem
    ),
    radial-gradient(
      circle,
      rgba(216, 166, 59, 0.3) 0 0.3rem,
      rgba(216, 166, 59, 0.12) 0.31rem 0.75rem,
      transparent 0.9rem
    ),
    radial-gradient(
      circle,
      rgba(255, 255, 255, 0.32) 0 0.25rem,
      rgba(54, 197, 107, 0.12) 0.26rem 0.62rem,
      transparent 0.72rem
    ),
    radial-gradient(
      circle,
      rgba(255, 255, 255, 0.24) 0 0.32rem,
      rgba(54, 197, 107, 0.11) 0.33rem 0.8rem,
      transparent 0.95rem
    ),
    radial-gradient(
      circle,
      rgba(216, 166, 59, 0.26) 0 0.24rem,
      rgba(216, 166, 59, 0.12) 0.25rem 0.66rem,
      transparent 0.78rem
    ),
    radial-gradient(
      circle,
      rgba(255, 255, 255, 0.34) 0 0.3rem,
      rgba(54, 197, 107, 0.15) 0.31rem 0.72rem,
      transparent 0.86rem
    ),
    radial-gradient(
      circle,
      rgba(255, 255, 255, 0.26) 0 0.22rem,
      rgba(54, 197, 107, 0.11) 0.23rem 0.6rem,
      transparent 0.72rem
    );
  background-repeat: no-repeat;
  background-size:
    2.4rem 2.4rem,
    1.8rem 1.8rem,
    2rem 2rem,
    1.5rem 1.5rem,
    2.2rem 2.2rem,
    1.6rem 1.6rem,
    2rem 2rem,
    1.4rem 1.4rem;
  animation: cfSmallBubblesMove 16s ease-in-out infinite alternate;
  mix-blend-mode: screen;
}

.xt-body,
.xt-cont-main,
.xt-cont-body,
.chess-main-container,
.cf-landing {
  position: relative;
  isolation: isolate;
}

.xt-body > *,
.xt-cont-main > *,
.xt-cont-body > *,
.chess-main-container > *,
.cf-landing > * {
  position: relative;
  z-index: 1;
}

@media (prefers-reduced-motion: reduce) {
  body::before,
  body::after,
  .xt-body::before,
  .xt-body::after,
  .xt-cont-main::before,
  .xt-cont-body::before,
  .chess-main-container::before,
  .cf-landing::before {
    animation: none;
  }
}

/* ChessFace SweetAlert2 theme */
.swal2-container {
  pointer-events: none !important;
}

.swal2-container:empty,
.swal2-container:not(.swal2-shown):not(.swal2-toast-shown) {
  display: none !important;
  background: transparent !important;
  pointer-events: none !important;
}

.swal2-container.swal2-shown,
.swal2-container.swal2-toast-shown {
  pointer-events: auto !important;
}

.swal2-container.swal2-backdrop-show {
  background:
    radial-gradient(
      circle at 50% 12%,
      rgba(216, 166, 59, 0.22),
      transparent 22rem
    ),
    rgba(2, 8, 12, 0.74) !important;
}

.swal2-popup,
.cf-swal-popup {
  pointer-events: auto !important;
  width: min(calc(100vw - 2rem), 31rem) !important;
  padding: 0 !important;
  overflow: hidden !important;
  border: 0.0625rem solid rgba(216, 166, 59, 0.62) !important;
  border-radius: 0.9rem !important;
  color: #eef6f2 !important;
  background:
    radial-gradient(
      circle at 18% 0%,
      rgba(216, 166, 59, 0.24),
      transparent 15rem
    ),
    radial-gradient(
      circle at 92% 12%,
      rgba(255, 219, 128, 0.12),
      transparent 13rem
    ),
    linear-gradient(155deg, #0c1f26, #051016) !important;
  box-shadow:
    0 1.5rem 3.6rem rgba(0, 0, 0, 0.58),
    0 0 2rem rgba(216, 166, 59, 0.16),
    inset 0 0.0625rem 0 rgba(255, 255, 255, 0.08) !important;
}

.swal2-popup .swal2-header,
.cf-swal-popup .swal2-header {
  padding: 1.35rem 1.35rem 0 !important;
}

.swal2-popup .swal2-icon,
.cf-swal-popup .swal2-icon {
  margin: 0.4rem auto 0.9rem !important;
}

.swal2-title,
.cf-swal-title {
  margin: 0 !important;
  color: #f6fbf8 !important;
  font-family: var(--cf-font-family, var(--cf-sans, inherit)) !important;
  font-size: clamp(1.35rem, 4vw, 1.75rem) !important;
  font-weight: 900 !important;
  line-height: 1.12 !important;
  letter-spacing: 0 !important;
}

.swal2-html-container,
.swal2-content,
.cf-swal-html {
  margin: 0 !important;
  padding: 0.75rem 1.35rem 0 !important;
  color: rgba(232, 238, 244, 0.78) !important;
  font-size: 0.98rem !important;
  line-height: 1.55 !important;
}

.swal2-content #swal2-content {
  color: rgba(232, 238, 244, 0.78) !important;
}

.cf-swal-loading .swal2-actions {
  display: none !important;
}

.cf-swal-loading-content {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  width: 100%;
  min-height: 2.6rem;
  color: rgba(232, 238, 244, 0.82);
  font-weight: 750;
}

.cf-swal-spinner {
  width: 1.65rem;
  height: 1.65rem;
  flex: 0 0 auto;
  border: 0.18rem solid rgba(216, 166, 59, 0.24);
  border-top-color: #d8a63b;
  border-radius: 50%;
  animation: cfSwalSpin 0.8s linear infinite;
}

@keyframes cfSwalSpin {
  to {
    transform: rotate(360deg);
  }
}

.swal2-icon {
  width: 4.2rem !important;
  height: 4.2rem !important;
  margin: 1.35rem auto 0.3rem !important;
  border-width: 0.18rem !important;
}

.swal2-actions,
.cf-swal-actions {
  width: 100% !important;
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem !important;
  margin: 1.25rem 0 0 !important;
  padding: 0 1.35rem 1.35rem !important;
}

.swal2-actions button:only-child {
  grid-column: 1 / -1;
}

.cf-swal-single-action .swal2-actions,
.cf-swal-single-action .cf-swal-actions {
  grid-template-columns: minmax(0, 1fr) !important;
  justify-items: stretch !important;
}

.cf-swal-single-action .swal2-styled,
.cf-swal-single-action .cf-swal-confirm {
  grid-column: 1 / -1 !important;
  width: 100% !important;
}

.cf-swal-single-action .swal2-cancel,
.cf-swal-single-action .swal2-deny {
  display: none !important;
}

.swal2-styled,
.cf-swal-confirm,
.cf-swal-cancel,
.cf-swal-deny {
  width: 100% !important;
  min-height: 2.95rem !important;
  margin: 0 !important;
  border: 0.0625rem solid transparent !important;
  border-radius: 0.55rem !important;
  box-shadow: none !important;
  font-family: var(--cf-font-family, var(--cf-sans, inherit)) !important;
  font-size: 0.95rem !important;
  font-weight: 900 !important;
  line-height: 1.1 !important;
}

.swal2-confirm,
.cf-swal-confirm {
  border-color: rgba(255, 219, 128, 0.62) !important;
  color: #071018 !important;
  background: linear-gradient(180deg, #f1c95a, #d8a63b) !important;
  text-shadow: none !important;
}

.swal2-cancel,
.cf-swal-cancel {
  border-color: rgba(255, 255, 255, 0.14) !important;
  color: rgba(232, 238, 244, 0.9) !important;
  background: rgba(255, 255, 255, 0.07) !important;
}

.swal2-deny,
.cf-swal-deny {
  border-color: rgba(255, 90, 105, 0.5) !important;
  color: #ffffff !important;
  background: linear-gradient(180deg, #ff5a69, #a92633) !important;
}

@media (max-width: 48rem) {
  .swal2-popup,
  .cf-swal-popup {
    width: min(calc(100vw - 1.6rem), 27rem) !important;
    border-radius: 0.8rem !important;
  }

  .swal2-popup .swal2-header,
  .cf-swal-popup .swal2-header {
    padding: 1.1rem 1rem 0 !important;
  }

  .swal2-html-container,
  .swal2-content,
  .cf-swal-html {
    padding: 0.65rem 1rem 0 !important;
    font-size: 0.9rem !important;
  }

  .swal2-actions,
  .cf-swal-actions {
    gap: 0.65rem !important;
    padding: 0 1rem 1.1rem !important;
  }
}

/* ChessLogin / Landing visual background for PageTemplates and Templex */
body,
.xt-body {
  background:
    linear-gradient(
      90deg,
      rgba(6, 16, 24, 0.96) 0%,
      rgba(6, 16, 24, 0.78) 36%,
      rgba(6, 16, 24, 0.96) 100%
    ),
    radial-gradient(
      circle at 16% 12%,
      rgba(54, 197, 107, 0.1),
      transparent 34rem
    ),
    linear-gradient(
      135deg,
      var(--cf-bg) 0%,
      var(--cf-bg-2) 55%,
      var(--cf-bg) 100%
    ) !important;
  color: var(--cf-text);
}

/* Unified Chess header for PageTemplates and Templex */
.cf-unified-header {
  position: sticky;
  top: 0;
  z-index: 10050;
  width: 100%;
  min-height: 4.75rem;
  border-bottom: 0.0625rem solid rgba(255, 255, 255, 0.12);
  background: rgba(4, 13, 20, 0.94) !important;
  box-shadow: 0 1rem 2.4rem rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding-top: env(safe-area-inset-top, 0);
}

.cf-unified-header .xt-cont-header-inicio {
  width: min(76rem, calc(100% - 3rem));
  max-width: 76rem;
  min-height: 4.75rem;
  height: auto;
  margin: 0 auto;
  padding: 0.65rem 0;
  display: flex;
  align-items: center;
  gap: 1.4rem;
}

.cf-unified-header .cf-brand,
.cf-unified-header .cf-system-brand {
  flex: 0 0 auto;
  min-width: 0;
  text-decoration: none;
  cursor: pointer;
}

.cf-unified-header .cf-brand-mark,
.cf-unified-header .cf-system-brand-mark {
  width: 3.25rem !important;
  height: 3.25rem !important;
  border-radius: 0.75rem !important;
}

.cf-unified-header .cf-brand-text,
.cf-unified-header .cf-system-brand-text {
  font-size: clamp(1.55rem, 1rem + 1vw, 1.95rem) !important;
  line-height: 1 !important;
  white-space: nowrap;
}

.cf-unified-header .xt-menu-center {
  position: static;
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  height: auto;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(0.7rem, 1.4vw, 1.9rem);
  background: transparent;
  box-shadow: none;
}

.cf-unified-header .xt-menu-center .dropdown {
  list-style: none;
}

.cf-unified-header .dropdown-toggle {
  min-height: 2.35rem;
  padding: 0.55rem 0.85rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.65rem;
  color: rgba(247, 245, 239, 0.9) !important;
  line-height: 1.1;
  text-decoration: none;
  white-space: nowrap;
}

.cf-unified-header .dropdown-toggle:hover,
.cf-unified-header .dropdown-toggle.menu-active {
  color: #ffffff !important;
  background: rgba(66, 199, 116, 0.13) !important;
}

.cf-unified-header .xt-header-right-side {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  flex: 0 0 auto;
  min-width: 0;
}

.cf-unified-header .cf-auth-actions {
  margin-left: 0;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
  flex-wrap: nowrap;
}

.cf-unified-header .cf-auth-btn,
.cf-unified-header .cf-register {
  min-height: 2.45rem;
  padding: 0.65rem 1rem;
  border-radius: 0.65rem;
  border: 0.0625rem solid rgba(255, 255, 255, 0.16);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(247, 245, 239, 0.94);
  font-size: 0.9rem;
  font-weight: 850;
  line-height: 1.05;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}

.cf-unified-header .cf-auth-login {
  background: rgba(255, 255, 255, 0.08);
}

.cf-unified-header .cf-auth-home,
.cf-unified-header .cf-auth-register {
  border-color: rgba(66, 199, 116, 0.5);
  background: linear-gradient(180deg, #42c774, #23844e);
  color: #ffffff;
}

.cf-unified-header .cf-header-back {
  margin: 0;
  width: auto;
}

.cf-unified-header .cf-header-back .xt-button {
  width: auto;
  min-width: 6.2rem;
  margin: 0;
  white-space: nowrap;
}

.cf-header-auth .xt-cont-header-inicio {
  justify-content: space-between;
}

.cf-header-auth {
  position: fixed !important;
  top: 0 !important;
  right: 0 !important;
  left: 0 !important;
  bottom: auto !important;
}

.cf-header-landing {
  position: fixed !important;
  top: 0 !important;
  right: 0 !important;
  left: 0 !important;
  bottom: auto !important;
}

.cf-header-landing + main,
#header-container + main {
  scroll-margin-top: 5.5rem;
}

@media (max-width: 64rem) {
  .cf-unified-header .xt-cont-header-inicio {
    width: min(100% - 2rem, 58rem);
    gap: 0.9rem;
  }

  .cf-unified-header .xt-hamburger {
    display: inline-flex !important;
  }

  .cf-unified-header .xt-menu-center {
    position: absolute;
    top: calc(100% + 0.6rem);
    left: 1rem;
    right: 1rem;
    width: auto;
    max-height: min(70vh, 28rem);
    padding: 0.75rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0.35rem;
    border: 0.0625rem solid rgba(255, 255, 255, 0.12);
    border-radius: 0.9rem;
    background: rgba(5, 18, 27, 0.98);
    box-shadow: 0 1.2rem 2.6rem rgba(0, 0, 0, 0.28);
    overflow-y: auto;
  }

  .cf-unified-header .xt-menu-center.xt-menu-open {
    display: flex;
  }

  .cf-unified-header .xt-menu-center .dropdown,
  .cf-unified-header .xt-menu-center .dropdown-toggle {
    width: 100%;
  }

  .cf-unified-header .dropdown-toggle {
    justify-content: flex-start;
    padding: 0.75rem 0.85rem;
  }
}

@media (max-width: 40rem) {
  .cf-unified-header .xt-cont-header-inicio {
    width: calc(100% - 1.25rem);
    min-height: 4.35rem;
    gap: 0.55rem;
  }

  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    gap: 0.55rem !important;
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: 2.75rem !important;
    height: 2.75rem !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    font-size: 1.45rem !important;
  }

  .cf-unified-header .xt-header-right-side {
    gap: 0.45rem;
  }

  .cf-unified-header .cf-auth-actions {
    gap: 0.4rem;
  }

  .cf-unified-header .cf-auth-btn,
  .cf-unified-header .cf-register {
    min-height: 2.25rem;
    padding: 0.55rem 0.65rem;
    font-size: 0.78rem;
  }

  .cf-unified-header .cf-header-back .xt-button {
    min-width: 5.4rem;
    padding: 0.6rem 0.75rem;
    font-size: 0.86rem;
  }
}

@media (max-width: 24rem) {
  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    display: none;
  }

  .cf-unified-header .cf-auth-btn,
  .cf-unified-header .cf-register {
    padding-inline: 0.5rem;
  }
}

/* FINAL LOGO OVERRIDE */
.cf-auth-brand .cf-system-brand-mark,
.cf-brand-mark {
  width: 58px !important;
  height: 58px !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  background: #fff !important;
  display: grid !important;
  place-items: center !important;
}
.cf-auth-brand .cf-system-brand-mark img,
.cf-brand-mark img {
  width: 112% !important;
  height: 112% !important;
  object-fit: cover !important;
  object-position: center 25% !important;
  display: block !important;
}
.cf-auth-brand .cf-system-brand-text,
.cf-brand-text {
  font-size: 30px !important;
}
.cf-auth-brand .cf-system-brand-text span,
.cf-brand-text span {
  color: var(--cf-gold) !important;
}
.cf-auth-brand,
.cf-brand {
  display: inline-flex !important;
  align-items: center !important;
  flex-direction: row !important;
  gap: 14px !important;
}

.cf-unified-header .cf-brand,
.cf-unified-header .cf-system-brand {
  gap: 0.85rem !important;
}

.cf-unified-header .cf-brand-mark,
.cf-unified-header .cf-system-brand-mark {
  width: 3.25rem !important;
  height: 3.25rem !important;
}

.cf-unified-header .cf-brand-text,
.cf-unified-header .cf-system-brand-text {
  font-size: clamp(1.55rem, 1rem + 1vw, 1.95rem) !important;
}

.cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
.cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
.cf-unified-header.cf-header-landing
  .cf-auth-actions.cf-auth-logged
  .cf-auth-home {
  width: auto !important;
  min-width: 0 !important;
  flex-basis: auto !important;
  height: auto !important;
  min-height: 2.45rem !important;
  padding: 0.65rem 1rem !important;
  font-size: 0.9rem !important;
}

@media (max-width: 40rem) {
  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    gap: 0.55rem !important;
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: 2.75rem !important;
    height: 2.75rem !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    font-size: 1.45rem !important;
  }

  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
  .cf-unified-header.cf-header-landing
    .cf-auth-actions.cf-auth-logged
    .cf-auth-home {
    min-height: 2.25rem !important;
    padding: 0.55rem 0.65rem !important;
    font-size: 0.78rem !important;
  }
}

@media (max-width: 24rem) {
  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    display: none !important;
  }

  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
  .cf-unified-header.cf-header-landing
    .cf-auth-actions.cf-auth-logged
    .cf-auth-home {
    padding-inline: 0.5rem !important;
  }
}

@media (min-width: 64.01rem) {
  .cf-unified-header {
    min-height: 7.8rem !important;
  }

  .cf-unified-header .xt-cont-header-inicio {
    min-height: 7.8rem !important;
    padding-block: 1rem !important;
    gap: 3.25rem !important;
  }

  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    gap: 1.35rem !important;
    margin-right: 1.2rem !important;
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: 4.8rem !important;
    height: 4.8rem !important;
    border-radius: 1rem !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    font-size: 2.75rem !important;
  }

  .cf-unified-header .xt-menu-center {
    gap: clamp(2.1rem, 3.2vw, 4rem) !important;
  }

  .cf-unified-header.cf-header-landing .xt-menu-center {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    flex: 0 0 auto !important;
    justify-content: center !important;
    margin-left: 0 !important;
  }

  .cf-unified-header .dropdown-toggle {
    min-height: 3.25rem !important;
    padding: 0.8rem 1.15rem !important;
    font-size: 1.18rem !important;
    font-weight: 900 !important;
  }

  .cf-unified-header .xt-header-right-side {
    margin-left: auto !important;
  }

  .cf-unified-header.cf-header-landing .xt-cont-header-inicio {
    position: relative !important;
    width: calc(100% - 3rem) !important;
    max-width: none !important;
  }

  .cf-unified-header.cf-header-landing .cf-brand,
  .cf-unified-header.cf-header-landing .cf-system-brand {
    margin-right: 0 !important;
  }

  .cf-unified-header.cf-header-landing .cf-brand-mark,
  .cf-unified-header.cf-header-landing .cf-system-brand-mark {
    width: 5.25rem !important;
    height: 5.25rem !important;
  }

  .cf-unified-header.cf-header-landing .cf-brand-text,
  .cf-unified-header.cf-header-landing .cf-system-brand-text {
    font-size: 3rem !important;
  }

  .cf-unified-header.cf-header-landing .cf-auth-actions {
    gap: 0.45rem !important;
  }

  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
  .cf-unified-header.cf-header-landing
    .cf-auth-actions.cf-auth-logged
    .cf-auth-home {
    width: 12.8rem !important;
    min-width: 12.8rem !important;
    flex-basis: 12.8rem !important;
    height: 4.2rem !important;
    min-height: 4.2rem !important;
    padding: 0 1.55rem !important;
    font-size: 1.05rem !important;
    border-radius: 0.7rem !important;
  }

  .cf-unified-header .cf-auth-actions {
    gap: 1rem !important;
  }

  .cf-unified-header .cf-auth-btn,
  .cf-unified-header .cf-register,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
  .cf-unified-header.cf-header-landing
    .cf-auth-actions.cf-auth-logged
    .cf-auth-home {
    min-height: 3.25rem !important;
    padding: 0.8rem 1.25rem !important;
    font-size: 1rem !important;
  }
}

@media (min-width: 64.01rem) {
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
  .cf-unified-header.cf-header-landing
    .cf-auth-actions.cf-auth-logged
    .cf-auth-home {
    width: 12.8rem !important;
    min-width: 12.8rem !important;
    flex-basis: 12.8rem !important;
    height: 4.2rem !important;
    min-height: 4.2rem !important;
    padding: 0 1.55rem !important;
    font-size: 1.18rem !important;
    font-weight: 900 !important;
    border-radius: 0.7rem !important;
  }
}

@media (min-width: 40.01rem) and (max-width: 64rem) {
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
  .cf-unified-header.cf-header-landing
    .cf-auth-actions.cf-auth-logged
    .cf-auth-home {
    width: auto !important;
    min-width: 7.8rem !important;
    flex-basis: auto !important;
    height: auto !important;
    min-height: 2.75rem !important;
    padding: 0.62rem 0.85rem !important;
    font-size: 0.88rem !important;
    font-weight: 850 !important;
  }
}

@media (max-width: 40rem) {
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
  .cf-unified-header.cf-header-landing
    .cf-auth-actions.cf-auth-logged
    .cf-auth-home {
    width: auto !important;
    min-width: 0 !important;
    flex-basis: auto !important;
    height: auto !important;
    font-weight: 850 !important;
  }
}

@media (min-width: 64.01rem) {
  .cf-unified-header.cf-header-app .xt-cont-header-inicio {
    position: relative !important;
    width: calc(100% - 3rem) !important;
    max-width: none !important;
  }

  .cf-unified-header.cf-header-app .cf-brand,
  .cf-unified-header.cf-header-app .cf-system-brand {
    margin-right: 0 !important;
  }

  .cf-unified-header.cf-header-app .xt-menu-center {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    flex: 0 0 auto !important;
    justify-content: center !important;
    margin-left: 0 !important;
  }

  .cf-unified-header.cf-header-app .xt-header-right-side {
    margin-left: auto !important;
  }
}

@media (min-width: 64.01rem) and (max-width: 80rem) {
  .cf-unified-header.cf-header-app .xt-menu-center {
    position: static !important;
    transform: none !important;
    flex: 1 1 auto !important;
  }
}

@media (min-width: 64.01rem) {
  .cf-unified-header.cf-header-auth {
    min-height: 7.8rem !important;
  }

  .cf-unified-header.cf-header-auth .xt-cont-header-inicio {
    width: calc(100% - 3rem) !important;
    max-width: none !important;
    min-height: 7.8rem !important;
    padding-block: 1rem !important;
    gap: 3.25rem !important;
  }

  .cf-unified-header.cf-header-auth .cf-brand,
  .cf-unified-header.cf-header-auth .cf-system-brand {
    gap: 1.35rem !important;
    margin-right: 0 !important;
  }

  .cf-unified-header.cf-header-auth .cf-brand-mark,
  .cf-unified-header.cf-header-auth .cf-system-brand-mark {
    width: 5.25rem !important;
    height: 5.25rem !important;
    border-radius: 1rem !important;
  }

  .cf-unified-header.cf-header-auth .cf-brand-text,
  .cf-unified-header.cf-header-auth .cf-system-brand-text {
    font-size: 3rem !important;
  }

  .cf-unified-header.cf-header-auth .cf-header-back .xt-button {
    width: 12.8rem !important;
    min-width: 12.8rem !important;
    height: 4.2rem !important;
    min-height: 4.2rem !important;
    padding: 0 1.55rem !important;
    font-size: 1.18rem !important;
    font-weight: 900 !important;
    border-radius: 0.7rem !important;
  }
}

/* Unified header desktop typography across PageTemplates and Templex. */
@media (min-width: 64.01rem) {
  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark,
  .cf-unified-header.cf-header-app .cf-brand-mark,
  .cf-unified-header.cf-header-app .cf-system-brand-mark,
  .cf-unified-header.cf-header-landing .cf-brand-mark,
  .cf-unified-header.cf-header-landing .cf-system-brand-mark,
  .cf-unified-header.cf-header-auth .cf-brand-mark,
  .cf-unified-header.cf-header-auth .cf-system-brand-mark {
    width: 5.25rem !important;
    height: 5.25rem !important;
    border-radius: 1rem !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text,
  .cf-unified-header.cf-header-app .cf-brand-text,
  .cf-unified-header.cf-header-app .cf-system-brand-text,
  .cf-unified-header.cf-header-landing .cf-brand-text,
  .cf-unified-header.cf-header-landing .cf-system-brand-text,
  .cf-unified-header.cf-header-auth .cf-brand-text,
  .cf-unified-header.cf-header-auth .cf-system-brand-text {
    font-size: 3rem !important;
    font-weight: 400 !important;
    line-height: 1 !important;
    letter-spacing: 0 !important;
  }

  .cf-unified-header .dropdown-toggle,
  .cf-unified-header .xt-menu-center .dropdown-toggle,
  .cf-unified-header span.dropdown-toggle.xt-menu-right,
  .cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right,
  .cf-unified-header .cf-auth-btn,
  .cf-unified-header .cf-register,
  .cf-unified-header .cf-header-back .xt-button,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
  .cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
  .cf-unified-header.cf-header-landing
    .cf-auth-actions.cf-auth-logged
    .cf-auth-home,
  .cf-unified-header.cf-header-auth .cf-header-back .xt-button {
    font-size: 1.18rem !important;
    font-weight: 900 !important;
    line-height: 1.05 !important;
  }
}

/* Global zoom-safe responsive layer for Chess PageTemplates. */
html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

.cf-page,
.cf-page-shell,
.xt-page,
.xt-body,
.chess-body,
.chess-container,
.xt-chess-container,
[class*="-page"],
[class*="-view"] {
  box-sizing: border-box;
  max-width: 100%;
}

.cf-page *,
.cf-page-shell *,
.xt-page *,
.xt-body *,
.chess-body *,
.chess-container *,
.xt-chess-container * {
  box-sizing: border-box;
}

img,
video,
canvas,
svg,
iframe {
  max-width: 100%;
}

table {
  max-width: 100%;
}

@media (max-width: 74rem) {
  body[class*="responsive-lock"],
  body[class*="page-lock"],
  body[class*="scroll-lock"] {
    height: auto !important;
    min-height: 100vh !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }

  .cf-page,
  .cf-page-shell,
  .xt-body,
  .chess-body,
  .chess-container,
  .xt-chess-container {
    overflow-x: hidden;
    overflow-y: visible;
  }

  .xt-card,
  .xt-panel,
  .cf-card,
  .cf-panel,
  .xt-modal-content,
  .xt-board-container,
  .xt-layout,
  .xt-main-layout,
  .xt-content-layout,
  .xt-dashboard-layout,
  .xt-study-layout,
  .xt-analysis-layout {
    max-width: 100%;
    min-width: 0;
  }

  .xt-board-container,
  .xt-layout,
  .xt-main-layout,
  .xt-content-layout,
  .xt-dashboard-layout,
  .xt-study-layout,
  .xt-analysis-layout,
  .cf-layout,
  .cf-grid {
    gap: clamp(0.75rem, 2vw, 1.25rem);
  }
}

@media (max-width: 64rem) {
  .xt-board-container,
  .xt-layout,
  .xt-main-layout,
  .xt-content-layout,
  .xt-dashboard-layout,
  .xt-study-layout,
  .xt-analysis-layout,
  .cf-layout {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .xt-sidebar,
  .cf-sidebar,
  [class*="-sidebar"],
  [class*="Sidebar"] {
    max-width: 100%;
    min-width: 0;
  }
}

@media (max-width: 48rem) {
  .xt-modal,
  .xt-dialog,
  .swal2-container {
    padding-inline: clamp(0.5rem, 3vw, 1rem) !important;
  }

  .xt-modal-content,
  .xt-dialog-content,
  .swal2-popup {
    max-width: min(100%, calc(100vw - 1rem)) !important;
    max-height: calc(100dvh - 1rem) !important;
    overflow-y: auto !important;
  }
}

/* Facebook/Messenger WebView performance guard. Other browsers keep the full visual layer. */
@media (max-width: 1024px), (hover: none) and (pointer: coarse) {
  html.cf-facebook-webview body::before,
  html.cf-facebook-webview body::after,
  html.cf-facebook-webview .xt-body::before,
  html.cf-facebook-webview .xt-body::after,
  html.cf-facebook-webview .xt-cont-main::before,
  html.cf-facebook-webview .xt-cont-body::before,
  html.cf-facebook-webview .chess-main-container::before,
  html.cf-facebook-webview .chess-main-container::after,
  html.cf-facebook-webview .chess-container::before,
  html.cf-facebook-webview .xt-chess-container::before,
  html.cf-facebook-webview .cf-landing::before {
    display: none !important;
    animation: none !important;
    filter: none !important;
    mix-blend-mode: normal !important;
  }

  html.cf-facebook-webview .xt-header,
  html.cf-facebook-webview .xt-header-inicio,
  html.cf-facebook-webview .cf-unified-header,
  html.cf-facebook-webview .xt-modal-content,
  html.cf-facebook-webview .ui-dialog,
  html.cf-facebook-webview .xt-battle-panel,
  html.cf-facebook-webview .xt-battle-create-game-dialog,
  html.cf-facebook-webview .xt-board-config-dialog {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  html.cf-facebook-webview .xt-board {
    contain: layout style;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transform: translateZ(0);
  }

  html.cf-facebook-webview .xt-board::before,
  html.cf-facebook-webview .xt-board::after {
    will-change: auto !important;
  }

  html.cf-facebook-webview .xt-board .xt-piece,
  html.cf-facebook-webview
    .xt-board.xt-tool-edit
    .xt-edit-toolbar
    .xt-edit-piece,
  html.cf-facebook-webview .xt-drag-image,
  html.cf-facebook-webview .xt-reserve-piece {
    filter: none !important;
    -webkit-filter: none !important;
    transition:
      transform 0.16s linear,
      top 0.16s linear,
      left 0.16s linear !important;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    will-change: transform;
  }

  html.cf-facebook-webview .xt-check:not(.xt-selected)::after,
  html.cf-facebook-webview .xt-candidate.xt-can-capture::after,
  html.cf-facebook-webview .xt-drag-image {
    animation: none !important;
  }

  html.cf-facebook-webview .xt-square,
  html.cf-facebook-webview .xt-selected::before,
  html.cf-facebook-webview .xt-premove-origin::after,
  html.cf-facebook-webview .xt-premove-target::after,
  html.cf-facebook-webview .xt-est-target:not(.xt-candidate)::after,
  html.cf-facebook-webview .xt-est-origin:not(.xt-candidate)::after {
    transition: none !important;
  }
}

/* System menu responsive brand guard. */
.cf-unified-header .xt-cont-header-inicio {
  max-width: 100%;
  min-width: 0;
}

.cf-unified-header .cf-brand,
.cf-unified-header .cf-system-brand {
  flex: 0 1 auto !important;
  min-width: 0 !important;
  max-width: min(42vw, 32rem);
  overflow: visible !important;
}

.cf-unified-header .cf-brand-mark,
.cf-unified-header .cf-system-brand-mark {
  flex: 0 0 auto !important;
  display: grid !important;
  place-items: center !important;
  overflow: hidden !important;
}

.cf-unified-header .cf-brand-mark img,
.cf-unified-header .cf-system-brand-mark img {
  width: 110% !important;
  height: 110% !important;
  max-width: none !important;
  max-height: none !important;
  margin: 0 !important;
  object-fit: contain !important;
  object-position: center center !important;
  display: block !important;
}

@media (min-width: 1024px) {
  .cf-unified-header .cf-brand-mark img,
  .cf-unified-header .cf-system-brand-mark img {
    width: 110% !important;
    height: 110% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover !important;
    transform: translateY(-0.3rem);
  }
}

.cf-unified-header .cf-brand-text,
.cf-unified-header .cf-system-brand-text {
  display: inline-block !important;
  min-width: 0 !important;
  max-width: 100%;
  overflow: visible !important;
  text-overflow: clip !important;
  white-space: nowrap !important;
  font-size: clamp(22px, 2.1vw, 48px) !important;
  line-height: 1 !important;
  letter-spacing: 0 !important;
}

.cf-unified-header .xt-menu-center .dropdown-toggle {
  font-size: clamp(
    calc(var(--font-size-base) * 0.95),
    0.72rem + 0.42vw,
    calc(var(--font-size-base) * 1.18)
  ) !important;
  font-weight: 900 !important;
  text-align: center !important;
}

.cf-unified-header span.dropdown-toggle.xt-menu-right,
.cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right {
  display: inline-grid !important;
  place-items: center !important;
  text-align: center !important;
  line-height: 1.05 !important;
  white-space: normal !important;
  word-break: normal !important;
  overflow-wrap: anywhere !important;
}

@media (min-width: 64.01rem) and (max-width: 90rem) {
  .cf-unified-header {
    min-height: clamp(5.8rem, 7vw, 7rem) !important;
  }

  .cf-unified-header .xt-cont-header-inicio {
    min-height: clamp(5.8rem, 7vw, 7rem) !important;
    gap: clamp(0.85rem, 1.4vw, 1.4rem) !important;
  }

  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    gap: clamp(0.65rem, 1vw, 1rem) !important;
    max-width: min(31vw, 24rem);
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: clamp(3.25rem, 4.4vw, 4.25rem) !important;
    height: clamp(3.25rem, 4.4vw, 4.25rem) !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    font-size: clamp(24px, 2vw, 38px) !important;
  }

  .cf-unified-header .xt-menu-center {
    gap: clamp(0.75rem, 1.7vw, 1.8rem) !important;
  }

  .cf-unified-header .dropdown-toggle,
  .cf-unified-header .xt-menu-center .dropdown-toggle,
  .cf-unified-header span.dropdown-toggle.xt-menu-right,
  .cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right {
    padding-inline: clamp(0.55rem, 1vw, 0.9rem) !important;
  }

  .cf-unified-header .xt-menu-center .dropdown-toggle {
    font-size: clamp(
      calc(var(--font-size-base) * 1),
      0.82rem + 0.5vw,
      calc(var(--font-size-base) * 1.22)
    ) !important;
  }
}

@media (min-width: 40.01rem) and (max-width: 64rem) {
  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    gap: clamp(0.55rem, 1.4vw, 0.8rem) !important;
    max-width: min(42vw, 22rem);
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: clamp(2.95rem, 5.7vw, 3.55rem) !important;
    height: clamp(2.95rem, 5.7vw, 3.55rem) !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    display: inline-block !important;
    font-size: clamp(20px, 3vw, 28px) !important;
  }
}

@media (max-width: 40rem) {
  .cf-unified-header .xt-cont-header-inicio {
    width: calc(100% - 0.75rem) !important;
    gap: clamp(0.25rem, 1.6vw, 0.5rem) !important;
  }

  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    gap: clamp(0.3rem, 1.6vw, 0.55rem) !important;
    max-width: calc(100% - 8.8rem);
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: clamp(2.1rem, 9.6vw, 2.7rem) !important;
    height: clamp(2.1rem, 9.6vw, 2.7rem) !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    display: inline-block !important;
    font-size: clamp(13px, 4.4vw, 18px) !important;
    max-width: calc(100vw - 10rem);
  }

  .cf-unified-header .xt-header-right-side {
    gap: clamp(0.3rem, 1.6vw, 0.45rem) !important;
  }

  .cf-unified-header .xt-hamburger {
    width: clamp(2.15rem, 10vw, 2.6rem) !important;
    height: clamp(2.15rem, 10vw, 2.6rem) !important;
    padding: 0.45rem !important;
  }

  .cf-unified-header span.dropdown-toggle.xt-menu-right,
  .cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right {
    min-width: 0 !important;
    max-width: clamp(4.7rem, 29vw, 8rem) !important;
    height: clamp(2.25rem, 10vw, 3rem) !important;
    padding-inline: clamp(0.5rem, 2vw, 0.75rem) !important;
    font-size: clamp(0.72rem, 2.8vw, 0.95rem) !important;
  }
}

@media (max-width: 24rem) {
  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    display: inline-block !important;
    font-size: clamp(11px, 4.1vw, 14px) !important;
    max-width: calc(100vw - 8.8rem);
  }

  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    max-width: calc(100% - 7.7rem);
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: 2.1rem !important;
    height: 2.1rem !important;
  }

  .cf-unified-header span.dropdown-toggle.xt-menu-right,
  .cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right {
    max-width: 5.5rem !important;
    font-size: 0.7rem !important;
  }
}

@media (max-width: 424px) {
  .xt-media-sm-dn .cf-unified-header .xt-cont-header-inicio,
  .cf-unified-header .xt-cont-header-inicio {
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    align-content: center !important;
    justify-content: space-between !important;
    width: calc(100% - 0.6rem) !important;
    min-height: clamp(4rem, 15vw, 4.6rem) !important;
    height: clamp(4rem, 15vw, 4.6rem) !important;
    padding: 0.3rem 0 !important;
    gap: 0.3rem !important;
  }

  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    flex: 1 1 auto !important;
    max-width: calc(100% - 7.7rem) !important;
    gap: 0.3rem !important;
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: clamp(2.35rem, 10.5vw, 2.8rem) !important;
    height: clamp(2.35rem, 10.5vw, 2.8rem) !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    font-size: clamp(12px, 4.25vw, 15px) !important;
    max-width: calc(100vw - 10rem) !important;
  }

  .cf-unified-header .xt-header-right-side {
    flex: 0 0 auto !important;
    margin-left: auto !important;
    gap: 0.35rem !important;
  }

  .cf-unified-header span.dropdown-toggle.xt-menu-right,
  .cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right {
    max-width: clamp(4.6rem, 26vw, 6.3rem) !important;
    height: clamp(2.15rem, 9vw, 2.55rem) !important;
    padding-inline: 0.45rem !important;
    font-size: clamp(0.68rem, 2.55vw, 0.82rem) !important;
  }

  .cf-unified-header .xt-hamburger {
    width: clamp(2.2rem, 9vw, 2.55rem) !important;
    height: clamp(2.2rem, 9vw, 2.55rem) !important;
    padding: 0.42rem !important;
  }
}

@media (min-width: 760px) and (max-width: 1007px) {
  .xt-media-sm-dn .cf-unified-header .xt-cont-header-inicio,
  .cf-unified-header .xt-cont-header-inicio {
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    align-content: center !important;
    justify-content: space-between !important;
    min-height: clamp(4.7rem, 7vw, 5.6rem) !important;
    width: calc(100% - 1.5rem) !important;
    padding: 0.45rem 0 !important;
    gap: clamp(0.55rem, 1.4vw, 0.9rem) !important;
  }

  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    flex: 0 1 auto !important;
    max-width: calc(100% - 13rem) !important;
    gap: clamp(0.55rem, 1.2vw, 0.8rem) !important;
  }

  .cf-unified-header .cf-brand-mark,
  .cf-unified-header .cf-system-brand-mark {
    width: clamp(2.75rem, 5vw, 3.35rem) !important;
    height: clamp(2.75rem, 5vw, 3.35rem) !important;
  }

  .cf-unified-header .cf-brand-text,
  .cf-unified-header .cf-system-brand-text {
    display: inline-block !important;
    font-size: clamp(20px, 3.2vw, 30px) !important;
    max-width: 100% !important;
  }

  .cf-unified-header .xt-header-right-side {
    flex: 0 0 auto !important;
    margin-left: auto !important;
    gap: clamp(0.45rem, 1.2vw, 0.7rem) !important;
  }

  .cf-unified-header span.dropdown-toggle.xt-menu-right,
  .cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right {
    height: clamp(2.8rem, 5.2vw, 3.5rem) !important;
    max-width: clamp(6.8rem, 16vw, 9.4rem) !important;
    font-size: clamp(0.9rem, 1.55vw, 1.15rem) !important;
    padding-inline: clamp(0.75rem, 1.5vw, 1rem) !important;
  }

  .cf-unified-header .xt-menu-center .dropdown-toggle {
    font-size: clamp(
      calc(var(--font-size-base) * 0.98),
      0.85rem + 0.38vw,
      calc(var(--font-size-base) * 1.12)
    ) !important;
  }

  .cf-unified-header .xt-hamburger {
    width: clamp(2.75rem, 5vw, 3.25rem) !important;
    height: clamp(2.75rem, 5vw, 3.25rem) !important;
    padding: 0.55rem !important;
  }
}

@media (min-width: 1920px) {
  .cf-unified-header .xt-menu-center .dropdown-toggle {
    font-size: clamp(1.25rem, 0.85rem + 0.55vw, 1.8rem) !important;
    padding-inline: clamp(1rem, 1.1vw, 1.6rem) !important;
  }

  .cf-unified-header span.dropdown-toggle.xt-menu-right,
  .cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right {
    font-size: clamp(1.05rem, 0.7rem + 0.5vw, 1.45rem) !important;
  }
}

@media (max-width: 1023px) {
  .cf-unified-header .cf-brand-mark img,
  .cf-unified-header .cf-system-brand-mark img {
    width: 114% !important;
    height: 114% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover !important;
    transform: translateY(-0.18rem);
  }
}

@media (min-width: 1024px) {
  .cf-unified-header .xt-cont-header-inicio {
    width: calc(100% - clamp(32px, 6vw, 96px)) !important;
    max-width: none !important;
    margin-inline: auto !important;
    justify-content: space-between !important;
  }

  .cf-unified-header .cf-brand,
  .cf-unified-header .cf-system-brand {
    margin-left: 0 !important;
  }

  .cf-unified-header .xt-header-right-side {
    margin-left: auto !important;
    margin-right: 0 !important;
  }
}

/* Global board settings shortcut and modal. */
.cf-header-board-settings-trigger {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.45rem !important;
  height: clamp(2.8rem, 4.7vw, 4.4rem) !important;
  min-width: 0 !important;
  padding: 0 clamp(0.7rem, 1.1vw, 1.05rem) !important;
  border: 1px solid rgba(216, 166, 59, 0.48) !important;
  border-radius: 0.8rem !important;
  background: rgba(216, 166, 59, 0.12) !important;
  color: #d8a63b !important;
  font-family: var(--font-sans, inherit) !important;
  font-size: clamp(0.9rem, 0.7rem + 0.45vw, 1.15rem) !important;
  font-weight: 900 !important;
  line-height: 1 !important;
  white-space: nowrap !important;
  cursor: pointer !important;
  box-shadow:
    inset 0 0 0 1px rgba(216, 166, 59, 0.04),
    0 0.8rem 2rem rgba(216, 166, 59, 0.1) !important;
}

.cf-header-board-settings-trigger:hover {
  background: rgba(216, 166, 59, 0.2) !important;
  border-color: rgba(216, 166, 59, 0.72) !important;
  color: #ffd56a !important;
}

.cf-header-board-settings-icon {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: clamp(1.05rem, 0.8rem + 0.55vw, 1.35rem) !important;
  line-height: 1 !important;
}

.cf-board-settings-open {
  overflow: hidden !important;
}

.cf-board-settings-modal {
  position: fixed !important;
  inset: 0 !important;
  z-index: 999999 !important;
  align-items: center !important;
  justify-content: center !important;
  padding: clamp(10px, 2dvh, 18px) !important;
  background: rgba(2, 9, 14, 0.68) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
}

.cf-board-settings-modal:not(.is-open) {
  display: none !important;
}

.cf-board-settings-modal.is-open {
  display: flex !important;
}

.cf-board-settings-dialog {
  display: flex !important;
  flex-direction: column !important;
  width: min(1040px, calc(100vw - 36px)) !important;
  max-height: min(720px, calc(100dvh - 36px)) !important;
  overflow: hidden !important;
  border: 1px solid rgba(216, 166, 59, 0.44) !important;
  border-radius: 12px !important;
  background:
    radial-gradient(
      circle at 12% 0%,
      rgba(216, 166, 59, 0.14),
      transparent 360px
    ),
    radial-gradient(
      circle at 82% 18%,
      rgba(216, 166, 59, 0.08),
      transparent 320px
    ),
    linear-gradient(180deg, rgba(8, 22, 32, 0.98), rgba(3, 11, 17, 0.98)) !important;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.42) !important;
}

.cf-board-settings-header {
  display: flex !important;
  align-items: center !important;
  gap: 9px !important;
  min-height: 54px !important;
  padding: 8px 16px !important;
  border-bottom: 1px solid rgba(216, 166, 59, 0.24) !important;
  background: linear-gradient(
    90deg,
    rgba(216, 166, 59, 0.16),
    rgba(216, 166, 59, 0.07),
    transparent
  ) !important;
}

.cf-board-settings-icon,
.cf-board-settings-close {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 34px !important;
  height: 34px !important;
  min-width: 34px !important;
  border-radius: 8px !important;
}

.cf-board-settings-icon {
  border: 1px solid rgba(216, 166, 59, 0.48) !important;
  background: rgba(216, 166, 59, 0.42) !important;
  color: #fff !important;
  font-size: 18px !important;
}

.cf-board-settings-header h2 {
  margin: 0 !important;
  color: #fff !important;
  font-family: var(--font-display, var(--font-sans, inherit)) !important;
  font-size: clamp(20px, 1.8vw, 26px) !important;
  line-height: 1 !important;
}

.cf-board-settings-close {
  margin-left: auto !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  background: rgba(255, 255, 255, 0.1) !important;
  color: #fff !important;
  font-size: 22px !important;
  cursor: pointer !important;
}

.cf-board-settings-close:hover {
  border-color: rgba(216, 166, 59, 0.68) !important;
  box-shadow: 0 1rem 2.2rem rgba(216, 166, 59, 0.24) !important;
}

.cf-board-settings-body {
  display: grid !important;
  grid-template-columns: minmax(280px, 0.86fr) minmax(0, 1.14fr) !important;
  align-items: start !important;
  gap: 12px !important;
  flex: 1 1 auto !important;
  min-height: 0 !important;
  max-height: calc(100dvh - 150px) !important;
  overflow: auto !important;
  padding: 12px !important;
}

.cf-board-preview-panel,
.cf-board-field {
  border: 1px solid rgba(146, 169, 177, 0.2) !important;
  background: linear-gradient(
    135deg,
    rgba(22, 43, 52, 0.78),
    rgba(8, 22, 32, 0.82)
  ) !important;
}

.cf-board-preview-panel {
  align-self: start !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 7px !important;
  height: auto !important;
  min-height: 304px !important;
  overflow: hidden !important;
  padding: 10px !important;
  border-radius: 10px !important;
}

.cf-board-preview-stage {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  min-height: 268px !important;
  height: 268px !important;
  max-height: 268px !important;
  overflow: hidden !important;
  padding: 24px 14px 14px !important;
  border-radius: 9px !important;
  background: rgba(2, 11, 17, 0.66) !important;
}

.cf-board-preview-canvas {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  overflow: visible !important;
}

.cf-board-preview-holder.cf-board-preview-board.xt-board {
  position: relative !important;
  display: inline-grid !important;
  flex: 0 0 auto !important;
  width: auto !important;
  height: auto !important;
  margin: calc(var(--size) * 2) !important;
  overflow: visible !important;
  isolation: isolate !important;
  box-sizing: content-box !important;
}

.cf-board-preview-holder.cf-board-preview-board.xt-board::before,
.cf-board-preview-holder.cf-board-preview-board.xt-board::after {
  display: block !important;
  background-size: cover !important;
  z-index: -1 !important;
}

.cf-board-settings-panel {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 10px !important;
  min-width: 0 !important;
}

.cf-board-field {
  display: flex !important;
  flex-direction: column !important;
  gap: 6px !important;
  min-width: 0 !important;
  padding: 9px !important;
  border-radius: 10px !important;
}

.cf-board-field-wide {
  grid-column: 1 / -1 !important;
}

.cf-board-section-title,
.cf-board-field label {
  color: rgba(255, 255, 255, 0.68) !important;
  font-size: 11px !important;
  font-weight: 900 !important;
  letter-spacing: 0.045em !important;
  line-height: 1.1 !important;
  text-transform: uppercase !important;
}

.cf-board-input {
  width: 100% !important;
  min-height: 38px !important;
  height: 38px !important;
  min-width: 0 !important;
  padding: 6px 10px !important;
  border: 1px solid rgba(146, 169, 177, 0.24) !important;
  border-radius: 8px !important;
  background: rgba(3, 12, 18, 0.92) !important;
  color: #fff !important;
  font-size: 13px !important;
  font-weight: 800 !important;
}

.cf-board-input:focus {
  border-color: rgba(216, 166, 59, 0.55) !important;
  box-shadow: 0 0 0 2px rgba(216, 166, 59, 0.12) !important;
  outline: none !important;
}

.cf-board-size-row {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 50px !important;
  align-items: center !important;
  gap: 8px !important;
}

.cf-board-size-row output {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 34px !important;
  border: 1px solid rgba(216, 166, 59, 0.42) !important;
  border-radius: 8px !important;
  background: rgba(216, 166, 59, 0.12) !important;
  color: #e4b441 !important;
  font-size: 12px !important;
  font-weight: 900 !important;
}

.cf-board-range {
  width: 100% !important;
}

.cf-board-toggle {
  position: relative !important;
  width: 46px !important;
  height: 26px !important;
  appearance: none !important;
  border: 1px solid rgba(255, 255, 255, 0.18) !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.16) !important;
  cursor: pointer !important;
}

.cf-board-toggle::after {
  content: "" !important;
  position: absolute !important;
  top: 3px !important;
  left: 3px !important;
  width: 18px !important;
  height: 18px !important;
  border-radius: 50% !important;
  background: #fff !important;
  transition: transform 0.18s ease !important;
}

.cf-board-toggle:checked {
  background: linear-gradient(135deg, #e4b441, #b7851d) !important;
  border-color: rgba(216, 166, 59, 0.58) !important;
}

.cf-board-toggle:checked::after {
  transform: translateX(20px) !important;
  box-shadow:
    0 0 0 2px rgba(216, 166, 59, 0.16),
    0 1px 4px rgba(0, 0, 0, 0.25) !important;
}

.cf-board-settings-footer {
  display: flex !important;
  justify-content: flex-end !important;
  gap: 10px !important;
  flex: 0 0 auto !important;
  padding: 10px 16px !important;
  border-top: 1px solid rgba(216, 166, 59, 0.22) !important;
  background: rgba(2, 9, 14, 0.92) !important;
}

.cf-board-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 146px !important;
  min-height: 38px !important;
  padding: 0 18px !important;
  border-radius: 8px !important;
  font-size: 12px !important;
  font-weight: 900 !important;
  cursor: pointer !important;
}

.cf-board-btn-secondary {
  border: 1px solid rgba(255, 255, 255, 0.18) !important;
  background: rgba(255, 255, 255, 0.08) !important;
  color: #fff !important;
}

.cf-board-btn-primary {
  border: 1px solid rgba(216, 166, 59, 0.58) !important;
  background: linear-gradient(135deg, #e4b441, #b7851d) !important;
  color: #fff !important;
  box-shadow: 0 0.9rem 2rem rgba(216, 166, 59, 0.2) !important;
}

.cf-board-btn-primary:hover {
  border-color: rgba(216, 166, 59, 0.68) !important;
  box-shadow: 0 1rem 2.2rem rgba(216, 166, 59, 0.24) !important;
}

@media (max-width: 1023px) {
  .cf-unified-header.cf-has-board-settings-shortcut .cf-brand,
  .cf-unified-header.cf-has-board-settings-shortcut .cf-system-brand {
    max-width: calc(100% - 16.5rem) !important;
  }

  .cf-header-board-settings-trigger {
    height: clamp(2.8rem, 5.2vw, 3.5rem) !important;
    padding-inline: clamp(0.65rem, 1.5vw, 0.9rem) !important;
    font-size: clamp(0.88rem, 1.45vw, 1.08rem) !important;
  }

  .cf-board-settings-dialog {
    width: min(820px, calc(100vw - 24px)) !important;
    max-height: calc(100dvh - 24px) !important;
  }

  .cf-board-settings-body {
    grid-template-columns: 1fr !important;
    gap: 9px !important;
    padding: 9px !important;
    max-height: calc(100dvh - 128px) !important;
  }

  .cf-board-preview-panel {
    min-height: 244px !important;
  }

  .cf-board-preview-stage {
    min-height: 208px !important;
    height: 208px !important;
    max-height: 208px !important;
    padding: 22px 10px 10px !important;
  }
}

@media (max-width: 640px) {
  .cf-header-board-settings-trigger {
    width: clamp(2.25rem, 10vw, 3rem) !important;
    height: clamp(2.25rem, 10vw, 3rem) !important;
    padding: 0 !important;
  }

  .cf-header-board-settings-text {
    display: none !important;
  }

  .cf-header-board-settings-icon {
    font-size: clamp(1.05rem, 4vw, 1.25rem) !important;
  }

  .cf-unified-header.cf-has-board-settings-shortcut .cf-brand,
  .cf-unified-header.cf-has-board-settings-shortcut .cf-system-brand {
    max-width: calc(100% - 11rem) !important;
  }
}

@media (max-width: 520px) {
  .cf-board-settings-modal {
    padding: 6px !important;
  }

  .cf-board-settings-dialog {
    width: calc(100vw - 12px) !important;
    max-height: calc(100dvh - 12px) !important;
    border-radius: 10px !important;
  }

  .cf-board-settings-header {
    min-height: 46px !important;
    padding: 7px 9px !important;
  }

  .cf-board-settings-icon,
  .cf-board-settings-close {
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
  }

  .cf-board-settings-header h2 {
    font-size: 18px !important;
  }

  .cf-board-settings-body {
    gap: 7px !important;
    padding: 7px !important;
    max-height: calc(100dvh - 106px) !important;
  }

  .cf-board-preview-panel {
    min-height: 196px !important;
    padding: 8px !important;
  }

  .cf-board-preview-stage {
    min-height: 160px !important;
    height: 160px !important;
    max-height: 160px !important;
    padding: 19px 6px 6px !important;
  }

  .cf-board-settings-panel {
    grid-template-columns: 1fr !important;
  }

  .cf-board-field {
    padding: 8px !important;
  }

  .cf-board-input {
    min-height: 33px !important;
    height: 33px !important;
    font-size: 11px !important;
  }

  .cf-board-settings-footer {
    padding: 7px !important;
  }

  .cf-board-btn {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    min-height: 34px !important;
    font-size: 11px !important;
  }
}

@media (max-width: 424px) {
  .cf-header-board-settings-trigger {
    width: clamp(2.15rem, 9vw, 2.55rem) !important;
    height: clamp(2.15rem, 9vw, 2.55rem) !important;
  }

  .cf-unified-header.cf-has-board-settings-shortcut .cf-brand,
  .cf-unified-header.cf-has-board-settings-shortcut .cf-system-brand {
    max-width: calc(100% - 10rem) !important;
  }
}

/* Unified system-menu button typography. */
:root {
  --cf-header-action-font-size: 14px;
}

@media (max-width: 424px) {
  :root {
    --cf-header-action-font-size: 11px;
  }
}

@media (min-width: 425px) and (max-width: 767px) {
  :root {
    --cf-header-action-font-size: 12px;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  :root {
    --cf-header-action-font-size: 13px;
  }
}

@media (min-width: 1024px) and (max-width: 1279px) {
  :root {
    --cf-header-action-font-size: 15px;
  }
}

@media (min-width: 1280px) and (max-width: 1439px) {
  :root {
    --cf-header-action-font-size: 16px;
  }
}

@media (min-width: 1440px) and (max-width: 1919px) {
  :root {
    --cf-header-action-font-size: 17px;
  }
}

@media (min-width: 1920px) and (max-width: 2559px) {
  :root {
    --cf-header-action-font-size: 18px;
  }
}

@media (min-width: 2560px) and (max-width: 3839px) {
  :root {
    --cf-header-action-font-size: 19px;
  }
}

@media (min-width: 3840px) {
  :root {
    --cf-header-action-font-size: 20px;
  }
}

.cf-unified-header .xt-menu-center .dropdown-toggle,
.cf-unified-header span.dropdown-toggle.xt-menu-right,
.cf-unified-header .xt-header-right-side .dropdown-toggle.xt-menu-right,
.cf-unified-header .cf-auth-btn,
.cf-unified-header .cf-register,
.cf-unified-header .cf-auth-home,
.cf-unified-header .cf-header-back .xt-button,
.cf-unified-header.cf-header-landing .cf-auth-actions .cf-auth-btn,
.cf-unified-header.cf-header-landing .cf-auth-actions .cf-register,
.cf-unified-header.cf-header-landing
  .cf-auth-actions.cf-auth-logged
  .cf-auth-home,
.cf-unified-header.cf-header-auth .cf-header-back .xt-button,
.cf-header-board-settings-trigger {
  font-size: var(--cf-header-action-font-size) !important;
}

/* Standard action-button typography. Header/menu buttons keep their own scale above. */
.xt-button,
.xt-btn-color,
.xt-btn-secondary,
.xt-btn-confirm,
.xt-btn-battle,
.xt-retry-btn,
.xt-nav-lesson-btn,
.xt-config-btn,
.xt-time-btn,
.swal2-styled {
  font-size: var(--cf-button-font-size);
  line-height: 1.12;
}
