/* ============================================
   VARIABLES Y CONFIGURACIÓN
   ============================================ */
:root {
    --color-sky: #F0F3F6;
    --color-white: #FFFFFF;
    --color-lime: #6FBB1C;
    --color-slate: #3A4651;
    --color-shadow: rgba(58, 70, 81, 0.25);
    --color-muted: rgba(58, 70, 81, 0.55);
    --color-light: rgba(240, 243, 246, 0.7);
    --radius-lg: 32px;
    --radius-md: 18px;
    --radius-sm: 12px;
    --transition: 240ms ease;
    --transition-slow: 420ms ease;
    --font-body: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}
/* PERSONALIZADO */
.loader {
  border: 16px solid #f3f3f3;
  /* Light grey */
  border-top: 16px solid #85ce36;
  /* Blue */
  border-radius: 50%;
  width: 80px;
  height: 80px;
  animation: spin 2s linear infinite;
  margin: auto;
}
.loader-contenedor {
  text-align: center;
}

html {
    background-color: var(--color-sky);
    scrollbar-color: var(--color-lime) rgba(111, 187, 28, 0.08);
    scrollbar-width: thin;
}

html::-webkit-scrollbar {
    width: 10px;
}

html::-webkit-scrollbar-track {
    background: rgba(111, 187, 28, 0.08);
    border-radius: 10px;
}

html::-webkit-scrollbar-thumb {
    background: var(--color-lime);
    border-radius: 10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

html::-webkit-scrollbar-thumb:hover {
    background: #5da317;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

/* ============================================
   BODY Y BACKGROUND
   ============================================ */
body {
    min-height: 100vh;
    font-family: var(--font-body);
    color: var(--color-slate);
    padding: 32px;
    position: relative;
    overflow-y: auto;
}

/* Hacer más compactos los gaps de Bootstrap */
.row.g-3 {
    --bs-gutter-y: 0.6rem;
}

body::before,
body::after {
    content: "";
    position: fixed;
    border-radius: 50%;
    filter: blur(90px);
    opacity: 0.25;
    pointer-events: none;
    z-index: 0;
}

body::before {
    width: 420px;
    height: 420px;
    background-color: rgba(111, 187, 28, 0.35);
    top: -160px;
    right: -120px;
    animation: drift 16s infinite alternate ease-in-out;
}

body::after {
    width: 360px;
    height: 360px;
    background-color: rgba(58, 70, 81, 0.28);
    bottom: -140px;
    left: -100px;
    animation: drift 18s infinite alternate-reverse ease-in-out;
}

.background-orbs {
    position: fixed;
    inset: 0;
    overflow: hidden;
    z-index: 0;
}

.background-orbs span {
    position: absolute;
    width: 320px;
    height: 320px;
    background-color: rgba(111, 187, 28, 0.24);
    filter: blur(40px);
    border-radius: 50%;
    animation: float 14s infinite ease-in-out;
    opacity: 0.55;
}

.background-orbs span:nth-child(1) {
    top: -120px;
    left: -120px;
}

.background-orbs span:nth-child(2) {
    bottom: -140px;
    right: -100px;
    animation-delay: 3s;
}

.background-orbs span:nth-child(3) {
    top: 40%;
    right: 30%;
    animation-delay: 6s;
    background-color: rgba(58, 70, 81, 0.22);
}

/* ============================================
   REGISTRATION SHELL
   ============================================ */
.registration-shell {
    width: min(1050px, 95vw);
    min-height: 680px;
    max-height: 88vh;
    height: calc(100vh - 60px);
    background: rgba(255, 255, 255, 0.92);
    border-radius: 32px;
    box-shadow: 0 40px 80px -32px rgba(58, 70, 81, 0.45);
    backdrop-filter: blur(26px);
    position: relative;
    z-index: 1;
    overflow: hidden;
    margin: auto;
    flex-direction: row;
}

/* Se desactiva el overlay interno para evitar un fondo blanco sin bordes */
.registration-shell::before { display: none; }

/* ============================================
   SIDE GALLERY
   ============================================ */
.side-gallery {
    width: clamp(260px, 30%, 340px);
    background-color: rgba(58, 70, 81, 0.95);
    color: var(--color-white);
    padding: 32px;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    border-radius: 32px 0 0 32px;
    overflow: hidden;
    max-height: 100%;
}

.side-gallery__title {
    font-weight: 600;
    color: var(--color-white);
    text-align: center;
}

.side-gallery__header {
    text-align: center;
}

.side-gallery__header h5 {
    text-align: center;
}

.side-gallery::after {
    content: "";
    position: absolute;
    inset: 12px;
    border: 1px solid rgba(240, 243, 246, 0.18);
    border-radius: 24px;
    pointer-events: none;
}

.side-gallery__frame {
    background: transparent;
    border-radius: 24px;
    padding: 32px 24px;
    position: relative;
    box-shadow: none;
    transition: box-shadow var(--transition-slow);
    overflow: visible;
    cursor: pointer;
    animation: frameFloat 12s infinite ease-in-out;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 20px;
    flex: 1;
    min-height: 260px;
    max-height: 450px;
    order: 1;
    margin: 0 auto;
    width: 100%;
}

.side-gallery__frame:focus,
.side-gallery__frame:focus-within {
    outline: none;
    box-shadow: inset 0 0 0 1px rgba(240, 243, 246, 0.25), 0 18px 36px -26px rgba(0, 0, 0, 0.35);
}

/* ============================================
   AVATAR
   ============================================ */
.avatar {
    position: relative;
    width: 220px;
    height: 220px;
    min-width: 220px;
    min-height: 220px;
    flex-shrink: 0;
    aspect-ratio: 1;
    border-radius: 50%;
    background-color: rgba(240, 243, 246, 0.96);
    border: 3px solid rgba(111, 187, 28, 0.35);
    overflow: visible;
    box-shadow: 0 28px 64px -26px rgba(58, 70, 81, 0.65);
    transition: transform var(--transition-slow), box-shadow var(--transition);
    cursor: pointer;
    order: 1;
    margin: 0 auto;
}

.avatar::after {
    content: "";
    position: absolute;
    inset: 18px;
    border-radius: 50%;
    border: 1px solid rgba(111, 187, 28, 0.35);
    opacity: 0.5;
    transition: opacity var(--transition), transform 2.2s ease-in-out;
    pointer-events: none;
    animation: avatarBreath 7s infinite ease-in-out;
}

.avatar:hover .avatar__overlay {
    opacity: 1;
}

.avatar__overlay {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.7);
    opacity: 0;
    transition: opacity var(--transition);
    pointer-events: none;
    z-index: 2;
}

.avatar__name {
    display: none;
}

.avatar-name-section {
    display: flex !important;
    flex-direction: column;
    align-items: center !important;
 
    flex: 1;
    gap: 8px;
    order: 2;
    margin: 0;
    max-height: 120px;
    overflow: hidden;
    min-height: 80px;
}

.user-full-name {
    display: flex;
    flex-direction: column;
    gap: 6px;
    text-align: center;
    width: 100%;
}

.user-first-name,
.user-last-name {
    font-size: clamp(1.2rem, 2.3vw, 2.05rem);
    font-weight: 700;
    color: var(--color-white);
    line-height: 1.1;
    text-align: center;
    word-break: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    max-width: 100%;
}

/* Ajuste automático para nombres muy largos */
.user-first-name {
    font-size: clamp(1rem, 1.8vw, 1.8rem);
}

.user-last-name {
    font-size: clamp(0.9rem, 1.6vw, 1.6rem);
}

/* Alternativa con media queries para nombres largos */
@media (max-width: 400px) {
    .user-first-name {
        font-size: clamp(0.85rem, 1.4vw, 1.4rem);
        line-height: 1.05;
    }
    .user-last-name {
        font-size: clamp(0.8rem, 1.3vw, 1.3rem);
        line-height: 1.05;
    }
}

.user-email-display {
    display: none;
}

.avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    position: relative;
    z-index: 1;
}

.avatar__halo {
    display: none;
}

.avatar.avatar--default img {
    filter: none;
    opacity: 1;
}

.avatar__edit-icon {
    position: absolute;
    top: 0px;
    right: 0px;
    width: 35px;
    height: 35px;
    background: var(--color-white);
    border: 2px solid var(--color-lime);
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.28);
    transition: all var(--transition);
}

.avatar__edit-icon svg {
    color: var(--color-slate);
    transition: color var(--transition);
}

.avatar__edit-icon:hover {
    background: var(--color-lime);
    transform: scale(1.03);
    box-shadow: 0 10px 22px rgba(111, 187, 28, 0.4);
}

.avatar__edit-icon:hover svg {
    color: var(--color-white);
}

/* Mostrar el nuevo ícono solo en móvil */
@media (max-width: 900px) {
    .avatar__edit-icon {
        display: flex;
    }
}

/* ============================================
   SIDE GALLERY ACTIONS
   ============================================ */
.side-gallery__actions {
    display: none;
}

.side-gallery__actions-desktop {
    order: 3;
    margin-top: auto;
    flex-shrink: 0;
}

.side-gallery__actions-desktop .side-gallery__upload {
    border-radius: 999px;
    padding: 10px 18px;
    font-weight: 500;
    color: var(--color-slate);
    background: var(--color-white);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    text-align: center;
}

.side-gallery__actions-desktop .side-gallery__upload::before {
    content: "";
    position: absolute;
    inset: 0;
    background-color: rgba(111, 187, 28, 0.16);
    opacity: 0;
    transition: opacity var(--transition);
}

.side-gallery__actions-desktop .side-gallery__upload:hover::before {
    opacity: 1;
}

.side-gallery__reset {
    border: none;
    border-radius: 999px;
    padding: 10px 20px;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.14);
    color: rgba(255, 255, 255, 0.85);
    cursor: pointer;
    transition: var(--transition);
}

.side-gallery__reset:hover {
    background: rgba(240, 243, 246, 0.3);
    color: var(--color-white);
}


/* ============================================
   FORM STAGE
   ============================================ */
.form-stage {
    background: var(--color-white);
    padding: 24px 32px;
    position: relative;
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 0;
    max-height: 100%;
    border-radius: 0 32px 32px 0;
}

.form-stage::-webkit-scrollbar {
    width: 10px;
    transition: opacity 0.3s ease;
    animation: scrollbar-show-hide 3s ease-in-out;
}

.form-stage::-webkit-scrollbar-track {
    background: rgba(111, 187, 28, 0.08);
    border-radius: 10px;
    margin: 8px 0;
}

.form-stage::-webkit-scrollbar-thumb {
    background: var(--color-lime);
    border-radius: 10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.form-stage::-webkit-scrollbar-thumb:hover {
    background: #5da317;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

/* Comportamiento de auto-hide para barra de scroll */
.form-stage {
    scrollbar-width: thin;
    scrollbar-color: var(--color-lime) rgba(111, 187, 28, 0.08);
}

/* Inicialmente visible, luego se oculta */

@keyframes scrollbar-show-hide {
    0% { width: 10px; opacity: 1; }
    70% { width: 10px; opacity: 1; }
    100% { width: 0px; opacity: 0; }
}

@keyframes scrollbar-show-hide-thin {
    0% { width: 6px; opacity: 1; }
    70% { width: 6px; opacity: 1; }
    100% { width: 0px; opacity: 0; }
}

.form-stage:not(:hover):not(:focus-within) {
    scrollbar-width: none;
}

.form-stage:not(:hover):not(:focus-within)::-webkit-scrollbar {
    width: 0px;
    opacity: 0;
}

.form-stage:hover::-webkit-scrollbar,
.form-stage:focus-within::-webkit-scrollbar,
.form-stage:active::-webkit-scrollbar {
    width: 10px;
    opacity: 1;
    animation: none;
}

.form-stage h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-slate);
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
}

/* Reducir espacios del header del form */
.form-stage__header {
    margin-bottom: 1rem;
}


.form-stage__note {
    color: var(--color-muted);
    font-size: 0.86rem;
}

.form-stage__note sup {
    color: #dc2626;
    font-size: 1.1em;
}

/* ============================================
   FORM INPUTS
   ============================================ */
.form-label {
    width: 100%;
}

.form-label > span {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--color-slate);
    margin-bottom: 8px;
    display: block;
}

.form-label sup {
    color: #dc2626;
    font-size: 1em;
    margin-left: 2px;
}

.form-control,
.form-select {
    border-radius: 12px !important;
    border: 2px solid rgba(58, 70, 81, 0.12) !important;
    padding: 10px 16px !important;
    font-size: 0.9rem !important;
    transition: all var(--transition) !important;
    background: var(--color-white) !important;
    color: var(--color-slate) !important;
    width: 100%;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--color-lime) !important;
    box-shadow: 0 0 0 4px rgba(111, 187, 28, 0.1) !important;
    outline: none !important;
}

.form-control::placeholder {
    color: rgba(58, 70, 81, 0.4);
    font-weight: 400;
}

.form-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath fill='%233A4651' d='M8 11L3 6h10z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 14px center !important;
    background-size: 14px !important;
    padding-right: 40px !important;
}
#paso3Titulo, #paso2Titulo, #paso1Titulo, #paso4Titulo {
    font-weight: 900;
}

/* ============================================
   PROGRESS STEPS
   ============================================ */
.progress-steps {
    gap: 0;
    position: relative;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    position: relative;
    z-index: 2;
    opacity: 0.6;
    transition: var(--transition);
}

.progress-step.is-active,
.progress-step.is-completed {
    opacity: 1;
}

.progress-step__circle {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: var(--color-sky);
    color: var(--color-slate);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    transition: all var(--transition);
    box-shadow: 0 2px 8px rgba(58, 70, 81, 0.1);
}

.progress-step.is-active .progress-step__circle {
    background: var(--color-lime);
    color: var(--color-white);
    box-shadow: 0 8px 20px -8px rgba(111, 187, 28, 0.8);
    transform: scale(1.08);
}

.progress-step.is-completed .progress-step__circle {
    background: rgba(111, 187, 28, 0.2);
    color: var(--color-lime);
}

.progress-step__label {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--color-slate);
    text-align: center;
    line-height: 1.2;
    max-width: 95px;
}

.progress-step.is-active .progress-step__label {
    color: var(--color-lime);
    font-weight: 700;
}

.progress-step.is-completed .progress-step__label {
    color: var(--color-lime);
}

.progress-step__line {
    flex: 1;
    height: 3px;
    background: rgba(58, 70, 81, 0.15);
    border-radius: 999px;
    position: relative;
    margin: 0 8px;
    min-width: 20px;
    align-self: flex-start;
    margin-top: 20px;
}

.progress-step__line::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 0%;
    background: var(--color-lime);
    border-radius: 999px;
    transition: width var(--transition-slow);
}

.progress-step.is-completed + .progress-step__line::before {
    width: 100%;
}

@media (max-width: 900px) {
    .progress-step.is-completed + .progress-step__line::before {
        width: 100%;
    }
}

/* ============================================
   SMART FORM
   ============================================ */
.smart-form {
    overflow-y: auto;
    overflow-x: hidden;
    max-height: 100%;
    padding-right: 8px;
}

.smart-form::-webkit-scrollbar {
    width: 10px;
    transition: opacity 0.3s ease;
    animation: scrollbar-show-hide 3s ease-in-out;
}

.smart-form::-webkit-scrollbar-track {
    background: rgba(111, 187, 28, 0.08);
    border-radius: 10px;
    margin: 8px 0;
}

.smart-form::-webkit-scrollbar-thumb {
    background: var(--color-lime);
    border-radius: 10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.smart-form::-webkit-scrollbar-thumb:hover {
    background: #5da317;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

/* Comportamiento de auto-hide para smart-form */
.smart-form {
    scrollbar-width: thin;
    scrollbar-color: var(--color-lime) rgba(111, 187, 28, 0.08);
}

/* Inicialmente visible, luego se oculta */

.smart-form:not(:hover):not(:focus-within)::-webkit-scrollbar {
    width: 0px;
    opacity: 0;
}

.smart-form:hover::-webkit-scrollbar,
.smart-form:focus-within::-webkit-scrollbar,
.smart-form:active::-webkit-scrollbar {
    width: 10px;
    opacity: 1;
    animation: none;
}

.smart-form__panel {
    display: none !important;
    position: relative;
    padding: 4px 0;
}

.smart-form__panel::before {
    content: "";
    position: absolute;
    inset: -14px;
    border-radius: var(--radius-md);
    background-color: rgba(111, 187, 28, 0.08);
    opacity: 0;
    transform: scale(0.97);
    transition: opacity var(--transition), transform var(--transition-slow);
    pointer-events: none;
}

.smart-form__panel.is-visible {
    display: flex !important;
    flex-direction: column;
    animation: fadeSlideIn 420ms ease forwards;
}



/* ============================================
   POLICY QUESTIONS
   ============================================ */
.policy-questions {
    max-height: 250px;
    overflow-y: auto;
    overflow-x: visible;
    padding: 16px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(240, 243, 246, 0.7));
    border: 2px solid rgba(111, 187, 28, 0.2);
    border-radius: var(--radius-md);
    gap: 10px;
    box-shadow: 0 8px 24px -12px rgba(58, 70, 81, 0.25);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
}

.policy-questions::-webkit-scrollbar {
    width: 6px;
    transition: opacity 0.3s ease;
    animation: scrollbar-show-hide-thin 3s ease-in-out;
}

.policy-questions::-webkit-scrollbar-track {
    background: rgba(111, 187, 28, 0.04);
    border-radius: 10px;
    margin: 8px 0;
}

.policy-questions::-webkit-scrollbar-thumb {
    background: rgba(111, 187, 28, 0.3);
    border-radius: 10px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.policy-questions::-webkit-scrollbar-thumb:hover {
    background: rgba(111, 187, 28, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Comportamiento de auto-hide para policy-questions */

.policy-questions:not(:hover):not(:focus-within)::-webkit-scrollbar {
    width: 0px;
    opacity: 0;
}

.policy-questions:hover::-webkit-scrollbar,
.policy-questions:focus-within::-webkit-scrollbar,
.policy-questions:active::-webkit-scrollbar {
    width: 6px;
    opacity: 1;
    animation: none;
}


.policy-question {
    background: linear-gradient(135deg, rgba(111, 187, 28, 0.08), rgba(111, 187, 28, 0.04));
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    gap: 8px;
    border: 1px solid rgba(111, 187, 28, 0.12);
    transition: all var(--transition);
    position: relative;
    overflow: visible;
}

.policy-question::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(111, 187, 28, 0.05), transparent);
    opacity: 0;
    transition: opacity var(--transition);
    border-radius: var(--radius-sm);
    pointer-events: none;
    z-index: 0;
}

.policy-question:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px -6px rgba(111, 187, 28, 0.3);
    border-color: rgba(111, 187, 28, 0.2);
}

.policy-question:hover::before {
    opacity: 1;
}

.policy-question p {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-slate);
    margin: 0;
    line-height: 1.3;
    position: relative;
    z-index: 2;
}

.policy-question__options {
    gap: 8px;
    flex-wrap: wrap;
    position: relative;
    z-index: 2;
}

.policy-checkbox {
    gap: 8px;
    padding: 8px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.95);
    color: var(--color-slate);
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    box-shadow: 0 4px 12px -8px rgba(58, 70, 81, 0.3);
    transition: all var(--transition);
    border: 2px solid transparent;
    position: relative;
    overflow: visible;
    z-index: 3;
}

.policy-checkbox::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(111, 187, 28, 0.1), rgba(111, 187, 28, 0.05));
    opacity: 0;
    transition: opacity var(--transition);
    border-radius: 999px;
    pointer-events: none;
    z-index: -1;
}

.policy-checkbox:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px -12px rgba(58, 70, 81, 0.4);
    border-color: rgba(111, 187, 28, 0.3);
}

.policy-checkbox:hover::before {
    opacity: 1;
}

.policy-checkbox input {
    accent-color: var(--color-lime);
    width: 18px;
    height: 18px;
    margin: 0;
    position: relative;
    z-index: 1;
}

.policy-checkbox span {
    position: relative;
    z-index: 1;
}

.policy-checkbox input:checked + span {
    color: var(--color-lime);
    font-weight: 600;
}

.policy-checkbox:has(input:checked) {
    background: rgba(111, 187, 28, 0.1);
    border-color: var(--color-lime);
    color: var(--color-lime);
    box-shadow: 0 6px 16px -8px rgba(111, 187, 28, 0.4);
}

.policy-checkbox:has(input:checked)::before {
    opacity: 1;
    background: linear-gradient(135deg, rgba(111, 187, 28, 0.15), rgba(111, 187, 28, 0.08));
    border-radius: 999px;
}

/* ============================================
   FORM ACTIONS
   ============================================ */
    .form-footer-wrapper {
        position: sticky;
        bottom: 0;
        background: var(--color-white);
        margin-top: auto;
        z-index: 10;
        border-top: 1px solid rgba(58, 70, 81, 0.08);
    }

.smart-form__actions {
    padding-top: 12px;
    margin-top: 0;
    border-top: none;
}

.smart-form__actions .btn {
    min-width: 105px;
    padding: 9px 20px;
}

/* ============================================
   CAPTCHA
   ============================================ */
.captcha {
    background: linear-gradient(135deg, rgba(111, 187, 28, 0.05), rgba(111, 187, 28, 0.02));
    border: 2px solid rgba(111, 187, 28, 0.15);
    border-radius: var(--radius-md);
    padding: 16px;
    box-shadow: 0 8px 24px -12px rgba(58, 70, 81, 0.2);
}

.captcha > span {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--color-slate);
}

.captcha__container {
    gap: 14px;
}

.captcha__display {
    gap: 8px;
    padding: 20px;
    border-radius: var(--radius-sm);
    min-height: 70px;
    overflow: hidden;
    background: rgba(240, 243, 246, 0.95);
    border: 2px solid rgba(111, 187, 28, 0.25);
    box-shadow: 0 4px 12px -6px rgba(111, 187, 28, 0.3);
    transition: all var(--transition);
}



.captcha__code {
    padding: 0 14px;
    font-family: "Fira Code", "Roboto Mono", monospace;
    font-weight: 700;
    font-size: 1.3rem;
    letter-spacing: 8px;
    color: var(--color-slate);
    text-transform: uppercase;
}

.captcha__refresh {
    border: none;
    background: rgba(111, 187, 28, 0.2);
    color: var(--color-lime);
    padding: 0;
    min-height: 38px;
    min-width: 38px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    border-radius: 50%;
    top: 20px;
    right: 20px;
    box-shadow: 0 2px 8px rgba(111, 187, 28, 0.2);
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
}



.captcha__container > input[type="text"] {
    text-transform: uppercase;
    letter-spacing: 6px;
    text-align: center;
    font-family: "Fira Code", "Roboto Mono", monospace;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 16px 20px !important;
    border: 2px solid rgba(111, 187, 28, 0.25) !important;
    background: rgba(255, 255, 255, 0.95) !important;
    transition: all var(--transition) !important;
}

.captcha__container > input[type="text"]:focus {
    border-color: var(--color-lime) !important;
    box-shadow: 0 0 0 4px rgba(111, 187, 28, 0.15) !important;
    letter-spacing: 7px;
}

.captcha__container > input[type="text"]::placeholder {
    letter-spacing: normal;
    font-weight: 400;
    font-size: 0.9rem;
}

.captcha__input.is-valid {
    border-color: var(--color-lime) !important;
    background: rgba(111, 187, 28, 0.08) !important;
    box-shadow: 0 0 0 4px rgba(111, 187, 28, 0.15) !important;
}

.captcha__input.is-error {
    border-color: rgba(220, 38, 38, 0.75) !important;
    background: rgba(220, 38, 38, 0.05) !important;
    box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.15) !important;
}

/* ============================================
   TOGGLE SWITCH
   ============================================ */
.stack-field__addon {
    border-radius: var(--radius-sm);
    padding: 14px 16px;
    background: var(--color-light);
    gap: 12px;
    min-height: 56px;
    box-shadow: inset 0 0 0 1px transparent;
    transition: var(--transition);
}

.stack-field__addon:hover {
    box-shadow: inset 0 0 0 1px rgba(111, 187, 28, 0.35);
}

.stack-field__addon span {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--color-slate);
}

.toggle {
    position: relative;
    width: 58px;
    height: 30px;
    cursor: pointer;
}

.toggle input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.toggle__rail {
    width: 100%;
    height: 100%;
    border-radius: 999px;
    background: rgba(58, 70, 81, 0.18);
    position: relative;
    transition: var(--transition);
    pointer-events: none;
}

.toggle__rail::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--color-white);
    box-shadow: 0 6px 18px -10px rgba(58, 70, 81, 0.9);
    transition: var(--transition);
    pointer-events: none;
}

.toggle input:checked + .toggle__rail {
    background: rgba(111, 187, 28, 0.35);
}

.toggle input:checked + .toggle__rail::after {
    transform: translateX(28px);
    background: var(--color-lime);
    box-shadow: 0 12px 18px -10px rgba(111, 187, 28, 0.75);
}

/* ============================================
   CHECKBOXES
   ============================================ */
.check input {
    width: 20px;
    height: 20px;
    accent-color: var(--color-lime);
}

.policy-consent {
    background: linear-gradient(135deg, rgba(111, 187, 28, 0.08), rgba(111, 187, 28, 0.04));
    border: 2px solid rgba(111, 187, 28, 0.15);
    border-radius: var(--radius-sm);
    padding: 16px 20px;
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
    padding-left: 40px;
}

.policy-consent::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(111, 187, 28, 0.05), transparent);
    opacity: 0;
    transition: opacity var(--transition);
}

.policy-consent:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px -6px rgba(111, 187, 28, 0.3);
    border-color: rgba(111, 187, 28, 0.25);
}

.policy-consent:hover::before {
    opacity: 1;
}

.policy-consent .form-check-label {
    font-weight: 500;
    color: var(--color-slate);
    position: relative;
    z-index: 1;
}

.policy-consent .form-check-input {
    position: relative;
    z-index: 1;
}

/* ============================================
   VERIFICATION MODAL
   ============================================ */
.verification-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-slow);
}

.verification-modal.is-visible {
    display: flex;
    opacity: 1;
}

.verification-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(58, 70, 81, 0.85);
    backdrop-filter: blur(8px);
}

.verification-modal__content {
    position: relative;
    z-index: 2;
    background: var(--color-white);
    border-radius: var(--radius-lg);
    padding: 48px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 40px 80px -32px rgba(58, 70, 81, 0.6);
    transform: scale(0.9);
    transition: transform var(--transition-slow);
}

.verification-modal.is-visible .verification-modal__content {
    transform: scale(1);
}

/* Loading state */
.verification-loading {
    text-align: center;
}

.verification-loading__spinner {
    width: 60px;
    height: 60px;
    margin: 0 auto 24px;
    border: 4px solid rgba(111, 187, 28, 0.2);
    border-top-color: var(--color-lime);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.verification-loading h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-slate);
    margin-bottom: 12px;
}

.verification-loading p {
    color: var(--color-muted);
    margin: 0;
}

/* Captcha state */
.verification-captcha h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-slate);
    text-align: center;
}

.verification-captcha__actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.verification-captcha__actions .btn {
    min-width: 120px;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn-primary {
    background-color: var(--color-lime);
    border-color: var(--color-lime);
    color: var(--color-white);
    box-shadow: 0 24px 40px -24px rgba(111, 187, 28, 0.9);
    padding: 12px 28px;
    border-radius: 999px;
    letter-spacing: 0.4px;
    font-size: 1rem;
    font-weight: 600;
    transition: transform var(--transition), box-shadow var(--transition);
}

.btn-primary:hover {
    background-color: var(--color-lime);
    border-color: var(--color-lime);
    transform: translateY(-3px) scale(1.01);
    box-shadow: 0 30px 48px -24px rgba(111, 187, 28, 0.95);
}

.btn-primary:active,
.btn-primary:focus,
.btn-primary:focus-visible {
    background-color: #5da317 !important;
    border-color: #5da317 !important;
    transform: translateY(-1px) scale(0.99);
    box-shadow: 0 18px 32px -24px rgba(111, 187, 28, 0.85) !important;
    outline: none !important;
}

.btn-outline-secondary {
    border-color: rgba(58, 70, 81, 0.3);
    color: var(--color-slate);
    padding: 12px 28px;
    border-radius: 999px;
    font-size: 1rem;
    font-weight: 600;
    transition: var(--transition);
}

.btn-outline-secondary:hover {
    background-color: rgba(58, 70, 81, 0.05);
    border-color: rgba(58, 70, 81, 0.5);
    color: var(--color-slate);
}

.btn-success {
    background-color: var(--color-lime);
    border-color: var(--color-lime);
    color: var(--color-white);
    box-shadow: 0 24px 40px -24px rgba(111, 187, 28, 0.9);
    padding: 12px 28px;
    border-radius: 999px;
    letter-spacing: 0.4px;
    font-size: 1rem;
    font-weight: 600;
    transition: transform var(--transition), box-shadow var(--transition);
}

.btn-success:hover {
    background-color: var(--color-lime);
    border-color: var(--color-lime);
    transform: translateY(-3px) scale(1.01);
    box-shadow: 0 30px 48px -24px rgba(111, 187, 28, 0.95);
}

.btn-success:active,
.btn-success:focus,
.btn-success:focus-visible {
    background-color: #5da317 !important;
    border-color: #5da317 !important;
    transform: translateY(-1px) scale(0.99);
    box-shadow: 0 18px 32px -24px rgba(111, 187, 28, 0.85) !important;
    outline: none !important;
}

.btn:disabled {
    cursor: not-allowed;
    opacity: 0.5;
    transform: none;
    filter: grayscale(0.3);
}

.btn:disabled:hover {
    transform: none;
    box-shadow: none;
}

#submitBtn {
    display: none;
}

/* ============================================
   ANIMACIONES
   ============================================ */
@keyframes float {
    0%, 100% {
        transform: translate3d(0, 0, 0) scale(1);
    }
    50% {
        transform: translate3d(20px, -30px, 0) scale(1.05);
    }
}

@keyframes drift {
    0% {
        transform: translate3d(0, 0, 0) scale(1);
    }
    100% {
        transform: translate3d(40px, 20px, 0) scale(1.07);
    }
}

@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateY(18px) scale(0.99);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes panelGlow {
    0%, 100% {
        opacity: 0.18;
    }
    50% {
        opacity: 0.32;
    }
}

@keyframes frameFloat {
    0%, 100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-4px) scale(1.006);
    }
}

@keyframes avatarBreath {
    0%, 100% {
        transform: scale(1);
        opacity: 0.36;
    }
    50% {
        transform: scale(0.98);
        opacity: 0.55;
    }
}

/* ============================================
   MEDIA QUERIES
   ============================================ */
@media (max-width: 1200px) {
    .registration-shell {
        width: 98vw;
        min-height: 480px;
        max-height: 90vh;
    }
}

/* Media query específica para Galaxy Z Fold 5 plegado (344x882) */
@media (max-width: 400px) and (min-height: 800px) {
    .registration-shell {
        width: 100vw;
        min-height: auto;
        max-height: 95vh;
        border-radius: 32px;
        margin: 0;
    }
    
    body {
        padding: 16px 8px;
    }
    
    .side-gallery {
        width: 100%;
        padding: 16px;
        min-height: auto;
        background: transparent !important;
    }
    
    .side-gallery__frame {
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 16px;
        padding: 16px;
        min-height: auto;
        max-width: 100%;
    }
    
    .avatar {
        width: 100px;
        height: 100px;
        min-width: 100px;
        min-height: 100px;
    }
    
    .avatar-name-section {
        align-items: flex-start !important;
        text-align: left !important;
    }
    
    .user-first-name {
        font-size: 1.1rem !important;
        text-align: left !important;
        color: var(--color-slate) !important;
    }
    
    .user-last-name {
        font-size: 0.9rem !important;
        text-align: left !important;
        color: #4a5568 !important;
    }
    
    .user-email-display {
        font-size: 0.8rem !important;
        display: block !important;
        text-align: left !important;
        color: #718096 !important;
    }
    
    .form-stage {
        padding: 16px;
        overflow-y: auto;
    }
}

/* Media query específica para Nest Hub (1024x600) */
@media (min-width: 1000px) and (max-width: 1100px) and (min-height: 500px) and (max-height: 650px) {
    .registration-shell {
        width: 100vw;
        min-height: auto;
        max-height: 90vh;
        border-radius: 32px;
        margin: 0;
    }
    
    body {
        padding: 20px 16px;
    }
    
    .side-gallery {
        width: 32%;
        padding: 20px;
    }
    
    .side-gallery__frame {
        gap: 16px;
        padding: 20px 16px;
        min-height: 200px;
    }
    
    .avatar {
        width: 140px;
        height: 140px;
        min-width: 140px;
        min-height: 140px;
    }
    
    .form-stage {
        padding: 20px 24px;
        overflow-y: auto;
    }
    
    .form-stage h2 {
        font-size: 1.5rem;
        margin-bottom: 16px;
    }
    
    .progress-steps {
        margin-bottom: 16px;
    }
    
    .progress-step__circle {
        width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }
    
    .progress-step__label {
        font-size: 0.7rem;
    }
}

/* Media query para pantallas muy anchas y bajas (como Nest Hub) */
@media (min-width: 1000px) and (max-height: 700px) {
    .registration-shell {
        width: 100vw;
        min-height: auto;
        max-height: 90vh;
        border-radius: 32px;
        margin: 0;
    }
    
    body {
        padding: 20px 16px;
    }
    
    .side-gallery {
        width: 30%;
        padding: 20px;
    }
    
    .form-stage {
        padding: 20px 24px;
        overflow-y: auto;
    }
    
    .avatar {
        width: 160px;
        height: 160px;
        min-width: 160px;
        min-height: 160px;
    }
}

/* Media query para dispositivos plegables en modo vertical */
@media (max-width: 400px) and (min-height: 700px) {
    .registration-shell {
        width: 100vw;
        min-height: auto;
        max-height: 95vh;
        border-radius: 0;
        margin: 0;
    }
    
    body {
        padding: 16px 8px;
    }
    
    .side-gallery {
        width: 100%;
        padding: 16px;
        min-height: auto;
        background: transparent !important;
    }
    
    .side-gallery__frame {
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 16px;
        padding: 16px;
        min-height: auto;
        max-width: 100%;
    }
    
    .avatar {
        width: 100px;
        height: 100px;
        min-width: 100px;
        min-height: 100px;
    }
    
    .avatar-name-section {
        align-items: flex-start !important;
        text-align: left !important;
    }
    
    .user-first-name {
        font-size: 1.1rem !important;
        text-align: left !important;
    }
    
    .user-last-name {
        font-size: 0.9rem !important;
        text-align: left !important;
    }
    
    .user-email-display {
        font-size: 0.8rem !important;
        display: block !important;
        text-align: left !important;
    }
    
    .form-stage {
        padding: 16px;
        overflow-y: auto;
    }
}

@media (max-width: 1200px) {
    .side-gallery {
        width: 28%;
        padding: 18px 28px;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        margin-bottom: 20px;
    }
    
    .side-gallery__frame {
        gap: clamp(18px, 4vw, 32px);
        padding: 28px 18px;
        min-height: 240px;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: flex-start !important;
    }
    
    .avatar {
        width: 180px;
        height: 180px;
        min-width: 180px;
        min-height: 180px;
        order: 1;
        margin: 0 auto;
    }
    
    .avatar-name-section {
        order: 2;
        align-items: center !important;
        text-align: center !important;
    }
    
    .user-full-name {
        text-align: center !important;
    }
    
    .user-first-name,
    .user-last-name {
        text-align: center !important;
    }
    
    .user-email-display {
        display: none !important;
    }
    
    .form-stage {
        padding: 24px 32px;
        overflow-y: auto;
    }
}

/* Media query específica para el rango 901px-991px (mantener 2 columnas y evitar desbordes) */
@media (max-width: 991px) and (min-width: 901px) {
    /* Evita que las columnas se vayan abajo (solo la fila principal) */
    .registration-shell > .row {
        flex-wrap: nowrap;
        height: 100%;
    }
    .registration-shell {
        width: 95vw;
        height: 85vh;
        max-height: 85vh;
        overflow: hidden;
    }
    /* Forzamos layout 2 columnas a pesar de col-12 */
    .side-gallery {
        flex: 0 0 35% !important;
        max-width: 35% !important;
        width: 35% !important;
        padding: 20px;
        overflow: visible;
        height: 100%;
    }
    .form-stage {
        flex: 0 0 65% !important;
        max-width: 65% !important;
        width: 65% !important;
        padding: 20px 24px 0;
        min-width: 0;
        height: 100%;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }
    .smart-form {
        flex: 1;
        overflow-y: auto;
        padding-right: 8px;
        margin-bottom: 0;
    }
    .form-footer-wrapper {
        flex-shrink: 0;
        position: relative;
        bottom: auto;
        margin-top: 0;
        padding: 12px 0 16px;
        border-top: 1px solid rgba(58, 70, 81, 0.08);
    }
    /* Compactar contenidos para que entren sin cortar */
    .side-gallery__frame {
        gap: 12px;
        padding: 20px;
        min-height: 240px;
    }
    .avatar {
        width: 160px;
        height: 160px;
        min-width: 160px;
        min-height: 160px;
    }
    .form-stage h2 {
        font-size: 1.6rem;
    }
    .progress-step__circle {
        width: 38px;
        height: 38px;
        font-size: 0.95rem;
    }
    .progress-step__label {
        font-size: 0.7rem;
        max-width: 85px;
    }
    .btn {
        padding: 8px 20px;
        font-size: 0.9rem;
    }
    .smart-form__actions .btn {
        min-width: 90px;
        padding: 8px 18px;
    }
}

@media (max-width: 900px) {
    .registration-shell {
        min-height: 450px;
        flex-direction: column;
        max-height: 95vh;
        height: auto;
        overflow-y: auto;
    }
    
    .side-gallery {
        width: 100%;
        padding: 20px;
        flex-direction: row;
        align-items: center !important;
        justify-content: center !important;
        gap: 0;
        min-height: 200px;
        background: transparent !important;
        border-radius: 32px 32px 0 0;
    }
    
    .side-gallery__title {
        display: none;
    }
    
    .side-gallery__frame {
        padding: 24px 18px;
        gap: 20px;
        flex: 0 1 auto;
        position: relative;
        background: transparent !important;
        min-height: 220px;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100%;
        max-width: 600px;
        margin: 0 auto;
    }
    
    .avatar__name {
        display: none;
    }
    
    .avatar-name-section {
        display: flex !important;
        flex: 1;
        gap: 8px;
        padding-top: 0;
        order: 2;
        margin: 0;
        align-items: flex-start !important;
        justify-content: flex-start !important;
    }
    
    .user-full-name {
        display: flex;
        flex-direction: column;
        gap: 4px;
        width: 100%;
        text-align: left !important;
    }
    
    .user-first-name {
        font-size: 1.55rem;
        font-weight: 700;
        color: var(--color-slate) !important;
        line-height: 1.18;
        margin-bottom: 0;
        text-align: left !important;
    }
    
    .user-last-name {
        font-size: 1.25rem;
        font-weight: 600;
        color: #4a5568 !important;
        line-height: 1.18;
        margin-bottom: 0;
        text-align: left !important;
    }
    
    .user-email-display {
        font-size: 0.95rem;
        font-weight: 400;
        color: #718096 !important;
        line-height: 1.3;
        word-break: break-word;
        max-width: 100%;
        text-align: left !important;
        margin-top: 10px;
        display: block !important;
    }
    
    .avatar {
        width: 160px;
        height: 160px;
        min-width: 160px;
        min-height: 160px;
        margin: 0 !important;
        flex-shrink: 0;
        position: relative;
        order: 1;
    }
    
    .side-gallery__frame {
        position: relative;
    }
    
    .avatar {
        position: relative;
    }
    
    .side-gallery__actions {
        display: none !important;
        position: absolute;
        top: 0px;
        right: 0px;
        z-index: 30;
    }
    
    .side-gallery__actions .side-gallery__upload {
        position: relative;
        width: clamp(32px, 4vw, 40px);
        height: clamp(32px, 4vw, 40px);
        border-radius: 50%;
        padding: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(255, 255, 255, 0.95);
        box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3);
        border: 2px solid var(--color-lime);
    }
    
    .side-gallery__actions .side-gallery__upload span {
        display: none;
    }
    
    .side-gallery__actions .side-gallery__upload::before {
        display: none;
    }
    
    .side-gallery__actions .side-gallery__upload::after {
        content: "✎";
        font-size: clamp(16px, 3vw, 20px);
        color: var(--color-slate);
        font-weight: 700;
        line-height: 1;
    }
    
    .side-gallery__actions-desktop {
        display: none !important;
    }
    
    .side-gallery__actions .side-gallery__upload {
        position: relative;
        width: 42px;
        height: 42px;
        border-radius: 50%;
        padding: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(255, 255, 255, 0.98);
        box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
        border: 2px solid var(--color-lime);
    }
    
    .side-gallery__actions .side-gallery__upload span {
        display: none;
    }
    
    .side-gallery__actions .side-gallery__upload::before {
        display: none;
    }
    
    .side-gallery__actions .side-gallery__upload::after {
        content: "✎";
        font-size: 22px;
        color: var(--color-slate);
        font-weight: 700;
        line-height: 1;
    }
    
    .side-gallery__actions-desktop {
        display: none;
    }
    
    .form-stage {
        padding: 20px 24px;
        overflow-y: auto;
        border-radius: 0 0 32px 32px;
        max-height: calc(95vh - 200px);
        min-height: 0;
    }
    
    .progress-steps {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 4px;
        padding: 12px 8px;
        background: rgba(111, 187, 28, 0.05);
        border-radius: var(--radius-md);
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .progress-steps::-webkit-scrollbar {
        height: 4px;
    }

    .progress-steps::-webkit-scrollbar-track {
        background: rgba(58, 70, 81, 0.05);
    }

    .progress-steps::-webkit-scrollbar-thumb {
        background: rgba(111, 187, 28, 0.3);
        border-radius: 10px;
    }
    
    .progress-step {
        flex-direction: column;
        width: auto;
        gap: 6px;
        align-items: center;
        min-width: 70px;
        flex-shrink: 0;
    }
    
    .progress-step__circle {
        width: 36px;
        height: 36px;
        font-size: 0.95rem;
        flex-shrink: 0;
    }
    
    .progress-step__label {
        font-size: 0.65rem;
        text-align: center;
        max-width: 70px;
        line-height: 1.1;
    }
    
    .progress-step__line {
        display: block;
        height: 2px;
        min-width: 10px;
        flex: 0 0 10px;
        margin: 0 2px;
        align-self: center;
        margin-top: 0;
    }
    
    .form-stage h2 {
        font-size: 1.5rem;
    }
    
    .captcha__display {
        min-height: 48px;
    }

    .captcha__code {
        font-size: 1.1rem;
        letter-spacing: 8px;
    }
}

@media (max-width: 600px) {
    body {
        -webkit-overflow-scrolling: touch;
    }
    
    .registration-shell {
        min-height: 440px;
        margin: 10px auto;
        width: 96vw;
        max-height: 90vh;
        overflow-y: auto;
    }
    
    .side-gallery {
        padding: 16px;
        min-height: 180px;
        align-items: center !important;
        justify-content: center !important;
    }
    
    .side-gallery__frame {
        padding: 18px 12px;
        gap: 16px;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        max-width: 550px;
    }
    
    .avatar-name-section {
        gap: 6px;
        align-items: flex-start !important;
    }
    
    .user-first-name {
        font-size: 1.35rem;
        text-align: left !important;
    }
    
    .user-last-name {
        font-size: 1.1rem;
        text-align: left !important;
    }
    
    .user-email-display {
        font-size: 0.82rem;
        margin-top: 6px;
        display: block !important;
        text-align: left !important;
    }
    
    .avatar {
        width: 145px;
        height: 145px;
        min-width: 145px;
        min-height: 145px;
    }
    
    
    .form-stage {
        padding: 20px;
        overflow-y: auto;
        max-height: calc(90vh - 180px);
        min-height: 0;
    }
    
    .progress-steps {
        padding: 10px 6px;
        gap: 3px;
    }
    
    .progress-step {
        min-width: 60px;
    }
    
    .progress-step__circle {
        width: 32px;
        height: 32px;
        font-size: 0.85rem;
    }
    
    .progress-step__label {
        font-size: 0.6rem;
        max-width: 60px;
    }
    
    .progress-step__line {
        flex: 0 0 8px;
        min-width: 8px;
    }

    .captcha__display {
        min-height: 50px;
    }

    .captcha__code {
        font-size: 1rem;
        letter-spacing: 6px;
    }

    .captcha__refresh {
        font-size: 1.15rem;
    }
}

@media (max-width: 480px) {
    body {
        padding: 16px 8px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .registration-shell {
        margin: 5px auto;
        border-radius: 18px;
        width: 98vw;
        max-height: 90vh;
        overflow-y: auto;
    }
    
    /* Hacer más visible la barra de scroll en móvil */
    .form-stage::-webkit-scrollbar {
        width: 8px;
    }
    
    .form-stage::-webkit-scrollbar-thumb {
        background: rgba(111, 187, 28, 0.8);
        border-radius: 10px;
    }
    
    .side-gallery {
        padding: 14px;
        min-height: 170px;
        align-items: center !important;
        justify-content: center !important;
        border-radius: 18px 18px 0 0;
    }
    
    .side-gallery__frame {
        gap: 14px;
        min-height: 170px;
        position: relative;
        width: 100%;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        max-width: 500px;
    }
    
    .avatar-name-section {
        gap: 6px;
        align-items: flex-start !important;
    }
    
    .user-first-name {
        font-size: 1.15rem;
        color: var(--color-slate) !important;
        font-weight: 700;
        text-align: left !important;
    }
    
    .user-last-name {
        font-size: 1.05rem;
        color: #4a5568 !important;
        font-weight: 600;
        text-align: left !important;
    }
    
    .user-email-display {
        font-size: 0.75rem;
        color: #718096 !important;
        display: block !important;
        text-align: left !important;
    }
    
    .avatar {
        width: 130px;
        height: 130px;
        min-width: 130px;
        min-height: 130px;
        position: relative;
    }

    .form-stage {
        padding: 20px 16px;
        overflow-y: auto;
        max-height: calc(90vh - 170px);
        min-height: 0;
    }

    .progress-steps {
        padding: 8px 4px;
        gap: 2px;
    }
    
    .progress-step {
        min-width: 55px;
        gap: 4px;
    }
    
    .progress-step__circle {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }
    
    .progress-step__label {
        font-size: 0.55rem;
        max-width: 55px;
    }
    
    .progress-step__line {
        flex: 0 0 6px;
        min-width: 6px;
    }

    .captcha__display {
        min-height: 46px;
    }

    .captcha__code {
        font-size: 1rem;
        letter-spacing: 4px;
        padding: 0 8px;
    }

    .captcha__refresh {
        padding: 0;
        font-size: 0.9rem;
        min-width: 28px;
        min-height: 28px;
        width: 28px;
        height: 28px;
        top: 6px;
        right: 6px;
    }

    .captcha__container > input[type="text"] {
        padding: 12px 14px;
        font-size: 0.9rem;
        letter-spacing: 4px;
    }

    .toggle__rail {
        width: 48px;
        height: 26px;
    }

    .toggle__rail::after {
        width: 20px;
        height: 20px;
    }

    .toggle input:checked + .toggle__rail::after {
        transform: translateX(22px);
    }
}

@media (max-width: 360px) {
    .side-gallery {
        padding: 12px;
        min-height: 155px;
        align-items: center !important;
        justify-content: center !important;
        border-radius: 18px 18px 0 0;
    }
    
    .side-gallery__frame {
        position: relative;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        max-width: 450px;
        gap: 12px;
    }
    
    .avatar {
        width: 115px;
        height: 115px;
        min-width: 115px;
        min-height: 115px;
        position: relative;
    }

    .avatar-name-section {
        gap: 6px;
        align-items: flex-start !important;
    }

    .user-first-name {
        font-size: 1.05rem;
        color: var(--color-slate) !important;
        font-weight: 700;
        text-align: left !important;
    }
 
    .user-last-name {
        font-size: 0.9rem;
        color: #4a5568 !important;
        font-weight: 600;
        text-align: left !important;
    }
    
    .user-email-display {
        font-size: 0.72rem;
        color: #718096 !important;
        display: block !important;
        text-align: left !important;
    }
}

/* Media query adicional para pantallas muy pequeñas */
@media (max-width: 480px) {
    .side-gallery__actions {
        top: 0px;
        right: 0px;
    }
    
    .side-gallery__actions .side-gallery__upload {
        width: clamp(28px, 3.5vw, 36px);
        height: clamp(28px, 3.5vw, 36px);
    }
    
    .side-gallery__actions .side-gallery__upload::after {
        font-size: clamp(14px, 2.5vw, 18px);
    }
}

/* Media query para pantallas extra pequeñas */
@media (max-width: 360px) {
    .side-gallery__actions {
        top: 0px;
        right: 0px;
    }
    
    .side-gallery__actions .side-gallery__upload {
        width: clamp(24px, 3vw, 32px);
        height: clamp(24px, 3vw, 32px);
    }
    
    .side-gallery__actions .side-gallery__upload::after {
        font-size: clamp(12px, 2vw, 16px);
    }
}
