/* Variables globales */
:root {
  --gjs-t-color-primary: #0ea5e9;
  --gjs-t-color-secondary: #64748b;
  --gjs-t-color-accent: #1e40af;
  --gjs-t-color-success: #16a34a;
  --gjs-t-color-warning: #f59e0b;
  --gjs-t-color-error: #ef4444;
}
/* Ocultar por defecto las tarjetas extra */
.state-card--extra {
  display: none;
}
.theme-training { background: linear-gradient(135deg, #fbbf24, #f59e0b); }
.theme-workout { background: linear-gradient(135deg, #f87171, #ef4444); }
.theme-feedback { background: linear-gradient(135deg, #a78bfa, #8b5cf6); }

/* Mostrar cuando JS les pone is-visible */
.state-card--extra.is-visible {
  display: flex; /* o block según tu layout actual */
}


.extra-states-wrapper {
  display: none;
  margin-top: 0.75rem;
}

.extra-states-wrapper.is-visible {
  display: block;
}

.more-states-btn {
  margin-top: 0.75rem;
  font-size: 0.875rem;
  color: #2563eb;
  background: transparent;
  border: none;
  cursor: pointer;
  text-decoration: underline;
}

/* Estilo del botón Ver más */
.more-states-btn {
  margin-top: 0.75rem;
  font-size: 0.875rem;
  color: #2563eb;
  background: transparent;
  border: none;
  cursor: pointer;
  text-decoration: underline;
}


/* Reset y estilos base */
*, ::before, ::after {
  box-sizing: border-box;
  border-width: 0;
  border-style: solid;
  border-color: #e5e7eb;
}

html, :host {
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  -moz-tab-size: 4;
  tab-size: 4;
  font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", 
    "Segoe UI Symbol", "Noto Color Emoji";
  font-feature-settings: normal;
  font-variation-settings: normal;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  line-height: inherit;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Elementos tipográficos */
h1, h2, h3, h4, h5, h6 {
  font-size: inherit;
  font-weight: inherit;
}

.gjs-t-h1 {
  color: #0f172a;
  font-size: 36px;
  line-height: 1.2;
}

.gjs-t-h2 {
  color: #0f172a;
  font-size: 24px;
  line-height: 1.3;
}

b, strong {
  font-weight: bolder;
}

small {
  font-size: 80%;
}

code, kbd, samp, pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", 
    "Courier New", monospace;
  font-feature-settings: normal;
  font-variation-settings: normal;
  font-size: 1em;
}

sub, sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

/* Enlaces */
a {
  color: inherit;
  text-decoration: inherit;
}

.gjs-t-link {
  color: #0ea5e9;
  text-decoration: none;
}

/* Tablas */
table {
  text-indent: 0;
  border-color: inherit;
  border-collapse: collapse;
}

/* Formularios y controles */
button, input, optgroup, select, textarea {
  font-family: inherit;
  font-feature-settings: inherit;
  font-variation-settings: inherit;
  font-size: 100%;
  font-weight: inherit;
  line-height: inherit;
  letter-spacing: inherit;
  color: inherit;
  margin: 0;
  padding: 0;
}

button, select {
  text-transform: none;
}

button, input[type='button'], input[type='reset'], input[type='submit'] {
  /* -webkit-appearance: button; */
  background-color: transparent;
  background-image: none;
}

button, [role="button"] {
  cursor: pointer;
}

:disabled {
  cursor: default;
}

input::placeholder, textarea::placeholder {
  opacity: 1;
  color: #9ca3af;
}

textarea {
  resize: vertical;
}

/* Imágenes y multimedia */
img, svg, video, canvas, audio, iframe, embed, object {
  display: block;
  /* vertical-align: middle; */
}

img, video {
  max-width: 100%;
  height: auto;
}

[hidden] {
  display: none;
}

/* Elementos específicos */
.gjs-t-body {
  background-color: #f0f6ff;
  color: #0f172a;
  font-size: 16px;
  line-height: 1.6;
}

.gjs-t-button {
  background-color: #1f2937;
  color: #ffffff;
  border-radius: 12px;
}

.gjs-t-border {
  border-radius: 16px;
  border-color: #e5e7eb;
}

/* Layout y estructura */
.main-wrapper {
  background-image: linear-gradient(to bottom, #f0f9ff, rgba(240, 249, 255, 0));
}

.page-container {
  max-width: 80rem;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
  padding-top: 6rem;
  padding-bottom: 6rem;
}

.auth-section {
  max-width: 28rem;
  margin-left: auto;
  margin-right: auto;
}

.login-card {
  background-color: rgb(255, 255, 255);
  border-width: 1px;
  box-shadow: 0 1px 2px 0 rgba(0,0,0,0.05);
  border-radius: 1rem;
  padding: 2rem;
}

.card-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.user-icon-wrapper {
  width: 5rem;
  height: 5rem;
  border-radius: 9999px;
  background-color: rgb(29, 78, 216);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 0px #fff, 0 0 0 4px rgba(59, 130, 246, 0.5);
  outline-style: solid;
  outline-width: 1px;
  outline-color: #dbeafe;
}

.user-icon {
  width: 2.5rem;
  height: 2.5rem;
}

.title-group {
  text-align: center;
}

.organization-name {
  font-family: Poppins;
  font-weight: 600;
  letter-spacing: -0.025em;
}

.system-subtitle {
  margin-top: 0.25rem;
  font-size: 0.875rem;
  line-height: 1.25rem;
  color: rgb(107, 114, 128);
}

/* Divider */
.divider-area {
  margin-top: 2rem;
}

.subtle-divider {
  height: 1px;
  width: 100%;
  background-color: rgb(243, 244, 246);
}

/* Form sections */
.login-form {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.user-type-fieldset {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.fieldset-legend {
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-weight: 500;
  color: rgb(55, 65, 81);
}

.user-type-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.radio-input-usuario,
.radio-input-administrador,
.identification-label {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Buttons for user types */
.user-type-button-usuario {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.75rem;
  border-width: 1px;
  border-color: rgb(17, 24, 39);
  background-color: rgb(0, 0, 0);
  color: rgb(255, 255, 255);
  padding: 0.75rem 1rem;
  cursor: pointer;
  user-select: none;
  transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

.user-type-button-usuario:hover {
  outline-color: #d1d5db;
}

.user-type-button-usuario:focus-within {
  outline-color: #93c5fd;
}

.icon-usuario {
  width: 1.25rem;
  height: 1.25rem;
}

.label-usuario {
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-weight: 500;
}

.user-type-button-administrador {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.75rem;
  border-width: 1px;
  border-color: rgb(229, 231, 235);
  background-color: rgb(255, 255, 255);
  color: rgb(17, 24, 39);
  padding: 0.75rem 1rem;
  cursor: pointer;
  user-select: none;
  transition-property: all;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

.user-type-button-administrador:hover {
  border-color: rgb(209, 213, 219);
  outline-color: #e5e7eb;
}

.icon-administrador {
  width: 1.25rem;
  height: 1.25rem;
}

.label-administrador {
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-weight: 500;
}

/* Identification input */
.identification-field-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.identification-input {
  width: 100%;
  border-radius: 0.75rem;
  border-width: 1px;
  border-color: rgb(229, 231, 235);
  background-color: rgb(249, 250, 251);
  padding: 0.75rem 1rem;
  text-align: center;
  color: rgb(17, 24, 39);
  transition-property: box-shadow;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

.identification-input::placeholder {
  color: rgb(107, 114, 128);
}

.identification-input:focus {
  background-color: rgb(255, 255, 255);
  border-color: rgb(96, 165, 250);
  outline: 2px solid transparent;
  outline-offset: 2px;
  box-shadow: 0 0 0 0px #fff, 0 0 0 4px rgba(59, 130, 246, 0.5);
}

.submit-area {
  padding-top: 0.5rem;
}

/* Primary continue button */
.primary-continue-button {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.75rem;
  background-color: rgb(31, 41, 55);
  color: rgb(255, 255, 255);
  padding: 0.875rem 1rem;
  font-weight: 500;
  letter-spacing: 0.025em;
  transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

.primary-continue-button:hover {
  background-color: rgb(17, 24, 39);
}

.primary-continue-button:focus {
  outline: 2px solid transparent;
  outline-offset: 2px;
  box-shadow: 0 0 0 0px #fff, 0 0 0 4px rgba(59, 130, 246, 0.5);
}

/* Footer helper */
.footer-helper {
  margin-top: 1.5rem;
}

.helper-text {
  text-align: center;
  font-size: 0.75rem;
  line-height: 1rem;
  color: rgb(156, 163, 175);
}

/* User type toggles */
#tipo_usuario_usuario:checked + #ibzvm {
  border-color: rgb(17, 24, 39);
  background-color: rgb(0, 0, 0);
  color: #ffffff;
}

#tipo_usuario_usuario:not(:checked) + #ibzvm {
  border-color: rgb(229, 231, 235);
  background-color: #ffffff;
  color: rgb(17, 24, 39);
}

#tipo_usuario_admin:checked + #ihbme {
  border-color: rgb(17, 24, 39);
  background-color: rgb(0, 0, 0);
  color: #ffffff;
}

#tipo_usuario_admin:not(:checked) + #ihbme {
  border-color: rgb(229, 231, 235);
  background-color: #ffffff;
  color: rgb(17, 24, 39);
}

/* Option card */
.option-card {
  max-width: 32rem;
  margin: 2.5rem auto 0 auto;
  background-color: #ffffff;
  border-width: 1px;
  border-color: #e5e7eb;
  border-radius: 1rem;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  padding: 2rem;
  text-align: center;
}

.option-title {
  margin-top: 1.5rem;
  color: var(--gjs-t-color-secondary);
  font-size: 1rem;
  line-height: 1.5rem;
  font-weight: 500;
}

.option-actions {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

.option-button {
  width: 100%;
  max-width: 22rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border-radius: 9999px;
  padding: 1.25rem;
  border-width: 1px;
  transition: background-color 0.15s cubic-bezier(0.4, 0, 0.2, 1), 
    color 0.15s cubic-bezier(0.4, 0, 0.2, 1), 
    border-color 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.option-button--primary {
  background-color: #1f2937;
  color: #ffffff;
  border-color: #1f2937;
}

.option-button--primary:hover {
  background-color: #111827;
}

.option-button--secondary {
  background-color: #ffffff;
  color: #0f172a;
  border-color: #e5e7eb;
}

.option-button--secondary:hover {
  border-color: #d1d5db;
  background-color: #fafafa;
}

.option-icon {
  width: 28px;
  height: 28px;
}

.option-text {
  font-weight: 600;
  letter-spacing: 0.015em;
  font-size: 0.95rem;
  line-height: 1.3rem;
}

.option-link {
  margin-top: 1.25rem;
  font-size: 0.9rem;
  color: #374151;
  text-decoration: none;
}

.option-link:hover {
  text-decoration: underline;
}

#iw8m4 {
  font-weight: 500;
  color: #0f172a;
}

/* Horario semanal */
.horario-semanal {
  max-width: 80rem;
  margin: 2.5rem auto 0 auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.schedule-container {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
  padding: 2rem;
  max-width: 64rem;
  margin: 0 auto;
}

.schedule-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.days-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.day-card {
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  background-color: #ffffff;
  padding: 1rem;
}

.day-card--rest {
  background-color: #f9fafb;
}

.day-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.day-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.day-name {
  font-family: Inter, system-ui, sans-serif;
  font-weight: 600;
  font-size: 1.05rem;
  line-height: 1.35rem;
  color: #0f172a;
}

.day-tag {
  display: inline-flex;
  align-items: center;
  border-radius: 0.5rem;
  padding: 0.125rem 0.5rem;
  background-color: #e0f2fe;
  color: #1e40af;
  border: 1px solid #bfdbfe;
  font-size: 0.75rem;
  line-height: 1rem;
  font-weight: 500;
  white-space: nowrap;
}

.work-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.625rem 0.75rem;
  border: 1px dashed #e5e7eb;
  border-radius: 0.5rem;
  background-color: #fafafa;
  margin-bottom: 0.75rem;
}

.work-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #0f172a;
  font-weight: 500;
}

.work-duration {
  color: #9ca3af;
  font-size: 0.9rem;
}

.breaks-label {
  color: #64748b;
  font-size: 0.9rem;
  margin-top: 0.25rem;
  margin-bottom: 0.5rem;
}

.breaks-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.break-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  border: 1px solid #fcd9bd;
  background-color: #FFF9F1;
  border-radius: 0.75rem;
  padding: 0.75rem 0.875rem;
}

.break-left {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  color: #0f172a;
}

.break-meta {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.break-name {
  font-weight: 600;
  letter-spacing: 0.01em;
  font-size: 0.95rem;
  color: #1f2937;
}

.break-time {
  font-size: 0.85rem;
  color: #374151;
}

.break-duration {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  border-radius: 9999px;
  border: 1px solid #e5e7eb;
  background-color: #ffffff;
  color: #374151;
  font-size: 0.8rem;
  padding: 0.2rem 0.5rem;
  line-height: 1rem;
  height: fit-content;
}

.rest-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #94a3b8;
  font-weight: 600;
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
}

.rest-sub {
  color: #cbd5e1;
  font-size: 0.95rem;
}

.info-note {
  margin-top: 1.5rem;
  max-width: 64rem;
  margin-left: auto;
  margin-right: auto;
  background-color: #e0f2fe;
  border: 1px solid #bfdbfe;
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
  color: #1e40af;
}

.info-note strong {
  font-weight: 700;
}

#i8b2t {
  font-weight: 600;
}

.role-active {
  background-color: rgb(0 0 0);
  color: #ffffff;
  border-color: rgb(17 24 39);
}

.role-inactive {
  background-color: #ffffff;
  color: rgb(17 24 39);
  border-color: rgb(229 231 235);
}

/* Media queries */
@media (max-width: 992px) {
  .page-container {
    padding-top: 4rem;
    padding-bottom: 4rem;
  }
  .login-card {
    padding: 1.75rem;
  }
  .option-card {
    padding: 1.75rem;
    margin-top: 2rem;
  }
  .option-title {
    margin-top: 1.25rem;
  }
  .schedule-container {
    padding: 1.75rem;
  }
  .day-name {
    font-size: 1rem;
  }
  .work-row {
    padding: 0.5rem 0.625rem;
  }
  .info-note {
    padding: 1.125rem 1.25rem;
  }
}

@media (max-width: 480px) {
  .page-container {
    padding-top: 3rem;
    padding-bottom: 3rem;
  }
  .login-card {
    padding: 1.5rem;
  }
  .card-header {
    gap: 1.25rem;
  }
  .divider-area {
    margin-top: 1.75rem;
  }
  .login-form {
    gap: 1.25rem;
  }
  .option-card {
    padding: 1.5rem;
    margin-top: 1.75rem;
  }
  .option-actions {
    gap: 0.875rem;
  }
  .schedule-container {
    padding: 1.5rem;
  }
  .day-card {
    padding: 0.875rem;
  }
  .day-header {
    gap: 0.75rem;
  }
  .work-row {
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  .work-duration {
    width: 100%;
    text-align: right;
  }
  .break-card {
    align-items: flex-start;
  }
  .break-duration {
    margin-left: auto;
  }
}