/* === VARIABLES GLOBALES === */
:root {
  /* Colores Institucionales y Semánticos */
  --color-primary: #E9C52A;
  --color-primary-hover: #ebd13f;
  --color-primary-active: #d4b124;
  --color-accent: #2c3e50;
  --color-hover-link: #2980b9;
  --color-hover-link-dark: #003f7d;

  /* Colores de Texto */
  --text-main: #333;
  --text-dark: #111;
  --text-light: #666;
  --text-white: #fff;

  /* Fondos */
  --bg-body: #fff;
  --bg-light: #f8f8f8;
  --bg-alt: #ececec;
  --bg-header-table: #e0e0e0;
  --bg-hover-card: #eef5fb;
  --bg-total: #f8f9fa;
  --bg-note: #eef;

  /* Bordes */
  --border-color: #ccc;
  --border-light: #eee;
  --focus-ring: #c0a322;

  /* Espaciado */
  --spacing-xs: 4px;
  --spacing-sm: 8px;
  --spacing-md: 12px;
  --spacing-lg: 18px;
  --spacing-xl: 20px;
  --spacing-xxl: 32px;

  /* Tipografía */
  --font-base: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
  --radius-sm: 3px;
  --radius-md: 5px;
  --radius-lg: 6px;
  --radius-xl: 10px;
}

/* === ESTILO GENERAL === */
body {
  font-family: var(--font-base);
  max-width: 950px;
  margin: 0 auto;
  line-height: 1.4;
  padding: var(--spacing-xl);
  color: var(--text-main);
  background-color: var(--bg-body);
}

h1,
h2 {
  color: var(--text-dark);
  text-align: center;
}

h2 {
  font-size: 1.4rem;
}

a {
  text-decoration: none;
  color: inherit;
}

/* === ENCABEZADO === */
.uncuyo-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-xl);
  margin-bottom: var(--spacing-lg);
  padding-bottom: 10px;
  border-bottom: 2px solid var(--color-accent);
}

.uncuyo-header h1 {
  color: var(--text-dark);
  margin: 0;
  font-size: 1.3em;
}

.uncuyo-header p {
  margin: 2px 0 0;
  font-style: italic;
  color: var(--text-light);
  font-size: 0.98em;
}

/* === TABLA DE SIMULADOR === */
.simu-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-bottom: var(--spacing-md);
}

.simu-table th {
  background: var(--bg-header-table);
  color: var(--text-dark);
  font-weight: bold;
  padding: 7px 10px;
  text-align: left;
  font-size: 1em;
}

.simu-table td {
  padding: 7px 10px;
  vertical-align: middle;
  background: var(--bg-light);
}

.simu-table tr:nth-child(even) td {
  background: var(--bg-alt);
}

.simu-table select,
.simu-table input[type="number"] {
  width: 98%;
  padding: 4px 5px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-size: 1em;
  margin-top: 2px;
}

.simu-table input[type="number"]:focus,
.simu-table select:focus {
  border-color: var(--color-primary);
  outline: none;
  box-shadow: 0 0 0 2px var(--focus-ring);
}

/* === GRUPOS ESPECIALES === */
.permanencia-options,
.mayor-dedicacion-group {
  display: flex;
  gap: 6px;
  align-items: center;
}

.mayor-dedicacion-horas {
  min-width: 90px;
}

/* === BOTONES === */
button {
  background-color: var(--color-primary);
  color: #000;
  border: none;
  padding: 7px 15px;
  border-radius: var(--radius-xl);
  cursor: pointer;
  font-size: 15px;
  margin: var(--spacing-lg) auto var(--spacing-md) auto;
  display: block;
  min-width: 120px;
  text-decoration: none;
}

button:hover {
  background-color: var(--color-hover-link);
}

a button {
  padding: 0.6em 1.2em;
  font-size: 1rem;
  border: none;
  border-radius: var(--radius-md);
  background-color: var(--color-primary);
  color: var(--text-white);
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

a button:hover {
  background-color: var(--color-hover-link-dark);
}

/* === RESULTADOS === */
.results, .hidden + .result-section, #results {
  margin-top: var(--spacing-lg);
  border-top: 2px solid var(--border-light);
  padding-top: var(--spacing-md);
}

.result-section {
  margin-bottom: 14px;
}

.result-title {
  font-weight: bold;
  margin-bottom: var(--spacing-sm);
  color: var(--text-dark);
}

.result-row {
  display: flex;
  justify-content: space-between;
  padding: 2px 0;
  border-bottom: 1px solid var(--border-light);
  font-size: 0.98em;
}

.result-total {
  font-weight: bold;
  background-color: var(--bg-total);
  padding: 6px;
  border-radius: 4px;
}

.resumen-cabecera {
  font-size: 1em;
  margin: 0 0 14px 0;
  padding: 9px 8px;
  border-radius: var(--radius-md);
  background: #f7f7f7;
  color: var(--text-dark);
}

.resumen-cabecera span {
  font-weight: bold;
  color: #222;
}

.nota-final {
  text-align: center;
  margin-top: 10px;
  font-size: 1em;
  color: #444;
  background: var(--bg-note);
  border-radius: 4px;
  padding: 7px;
}

.hidden {
  display: none;
}

/* === BOTÓN FLOTANTE === */
#back-button {
  position: fixed;
  bottom: 0px;
  right: 4px;
  z-index: 1000;
  text-align: center;
  margin-top: 40px;
}

#back-button button {
  background-color: var(--color-primary);
  border: none;
  border-radius: var(--radius-xl);
  padding: 10px 8px;
  font-weight: 500;
  font-size: 1rem;
  color: #000;
  cursor: pointer;
  box-shadow: none;
  transition: background-color 0.3s ease;
}
#back-button button:hover {
  background-color: var(--color-primary-hover);
}

/* === INDEX CON TARJETAS === */
.simulador-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 2rem;
}

.simulador-card {
  display: block;
  background-color: var(--bg-light);
  border-left: 4px solid var(--color-primary);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  text-decoration: none;
  color: inherit;
  transition: background-color 0.2s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.simulador-card:hover {
  background-color: var(--bg-hover-card);
}

.simulador-card h3 {
  margin: 0 0 6px;
  font-size: 1.1rem;
  color: var(--text-dark);
}

.simulador-card p {
  margin: 0;
  font-size: 0.95rem;
  color: #444;
}

/* Estilos para el Resumen del Recibo */
#resumen-cabecera {
    background-color: var(--bg-light); 
    border-left: 5px solid var(--color-primary); 
    border-radius: 4px;
    padding: 15px;
    margin-bottom: var(--spacing-xl);
    font-size: 1rem;
    color: var(--text-main);
    line-height: 1.5;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* Items del resumen */
.resumen-item {
    display: inline-block;
    margin-right: var(--spacing-xl); 
    white-space: nowrap;
}

.resumen-label {
    font-weight: bold;
    color: var(--text-dark);
    text-transform: none;
}

.resumen-valor {
    color: #444;
    margin-left: 4px;
}

/* Ocultar si no hay datos */
#resumen-cabecera:empty {
    display: none;
}

.disclaimer-mopre {
    font-size: 0.78rem;
    color: #6c757d; /* Gris sutil */
    margin-top: -4px; /* Acerca el texto al título superior */
    font-weight: normal;
    font-style: italic; /* Opcional: le da aspecto de aclaración */
    line-height: 1.3;
}