/* =============================================
   MISIÓN DIARIA — styles.css
   ============================================= */

/* --- RESET & BASE --- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  font-size: 15px;
  background: #050d1a;
}

/* --- SCREENS --- */
.screen {
  display: none;
  min-height: 100vh;
  background: linear-gradient(160deg, #050d1a 0%, #0a1628 40%, #0d2240 70%, #0a2a3a 100%);
  position: relative;
}

.screen.active {
  display: block;
}

.stars-layer {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  pointer-events: none;
  z-index: 0;
}

.star {
  position: absolute;
  background: #fff;
  border-radius: 50%;
}

.screen-content {
  position: relative;
  z-index: 1;
  max-width: 480px;
  margin: 0 auto;
  padding: 16px;
}

/* --- HEADER --- */
.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.app-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 11px;
  color: #5DDEDE;
  letter-spacing: 1px;
  text-shadow: 0 0 12px rgba(93, 222, 222, 0.5);
}

.header-date {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 16px;
}

.btn-parent-top {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.6);
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 7px 13px;
  border-radius: 20px;
  cursor: pointer;
}

.btn-parent-top:active {
  transform: scale(0.97);
}

/* --- MAIN NAV --- */
.main-nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 4px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: all 0.2s;
}

.nav-btn.active {
  border-color: #1ABFBF;
  background: rgba(26, 191, 191, 0.12);
}

.nav-btn .icon {
  font-size: 24px;
}

.nav-btn .label {
  font-family: 'Press Start 2P', monospace;
  font-size: 14px;        /* <-- CAMBIA AQUÍ EL TAMAÑO DE TAREAS/PROGRESO/CALENDARIO */
  color: rgba(255, 255, 255, 0.35);
  text-transform: uppercase;
  text-align: center;
  line-height: 1.6;
  letter-spacing: 0.5px;
}

.nav-btn.active .label {
  color: #5DDEDE;
}

/* --- CHILD TABS --- */
.child-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 16px;
}

.child-tab {
  flex: 1;
  text-align: center;
  padding: 10px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: all 0.2s;
}

.child-tab.active {
  border-color: #1ABFBF;
  background: rgba(26, 191, 191, 0.12);
}

.child-tab-name {
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.child-tab.active .child-tab-name {
  color: #fff;
}

/* --- SECTION TITLE --- */
.section-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  color: #5DDEDE;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 16px 0 10px;
  text-shadow: 0 0 10px rgba(93, 222, 222, 0.3);
}

/* --- TASKS --- */
.moment-label {
  font-size: 9px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 14px 0 6px;
}

.task-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.15s;
}

.task-item:active {
  transform: scale(0.99);
}

.task-item.done {
  opacity: 0.45;
}

.task-item.paused-day {
  opacity: 0.5;
  cursor: default;
}

.check {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  flex-shrink: 0;
  position: relative;
  transition: all 0.2s;
}

.check.checked {
  background: #1ABFBF;
  border-color: #1ABFBF;
}

.check.checked::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 8px; height: 5px;
  border-left: 2.5px solid #fff;
  border-bottom: 2.5px solid #fff;
  transform: translate(-50%, -65%) rotate(-45deg);
}

.task-name {
  flex: 1;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.85);
}

.task-name.done-text {
  text-decoration: line-through;
  color: rgba(255, 255, 255, 0.3);
}

.pts-badge {
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  padding: 4px 8px;
  border-radius: 20px;
}

.pts-exp {
  background: rgba(255, 215, 0, 0.12);
  color: #FFD700;
  border: 1px solid rgba(255, 215, 0, 0.25);
}

.pts-screen {
  background: rgba(93, 222, 222, 0.12);
  color: #5DDEDE;
  border: 1px solid rgba(93, 222, 222, 0.25);
}

.pts-paused {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* --- PAUSED BANNER --- */
.paused-banner {
  background: rgba(255, 193, 7, 0.1);
  border: 1px solid rgba(255, 193, 7, 0.25);
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.paused-banner-text {
  font-size: 12px;
  color: rgba(255, 193, 7, 0.9);
  flex: 1;
}

/* --- PROGRESS / ROCKET --- */
.rocket-card {
  background: rgba(26, 191, 191, 0.07);
  border: 1px solid rgba(26, 191, 191, 0.2);
  border-radius: 18px;
  padding: 18px;
  margin-bottom: 14px;
}

.rocket-child-label {
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  color: #5DDEDE;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.rocket-xp {
  font-family: 'Press Start 2P', monospace;
  font-size: 20px;
  color: #fff;
  margin-bottom: 14px;
}

.rocket-track {
  position: relative;
  height: 40px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.rocket-bar {
  position: absolute;
  top: 0; left: 0; bottom: 0;
  background: linear-gradient(90deg, rgba(26,191,191,0.2), rgba(26,191,191,0.5));
  border-radius: 20px;
  transition: width 0.6s ease;
}

.rocket-ship {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 24px;
  transition: left 0.6s ease;
  filter: drop-shadow(0 0 8px rgba(93, 222, 222, 0.9));
}

.rocket-planet {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 22px;
}

.rocket-next {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.35);
}

/* --- PUNTOS CARDS --- */
.pts-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 16px;
}

.pts-card {
  border-radius: 14px;
  padding: 14px;
  border: 1px solid;
}

.pts-card-exp {
  background: rgba(255, 215, 0, 0.07);
  border-color: rgba(255, 215, 0, 0.2);
}

.pts-card-screen {
  background: rgba(93, 222, 222, 0.07);
  border-color: rgba(93, 222, 222, 0.2);
}

.pts-card-lbl {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 6px;
}

.pts-card-val {
  font-family: 'Press Start 2P', monospace;
  font-size: 18px;
  color: #fff;
}

/* --- REWARDS --- */
.reward-item {
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.reward-item.ok-exp {
  border-color: rgba(255, 215, 0, 0.35);
  background: rgba(255, 215, 0, 0.06);
}

.reward-item.ok-screen {
  border-color: rgba(93, 222, 222, 0.35);
  background: rgba(93, 222, 222, 0.06);
}

.reward-name {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
}

.reward-sub {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 2px;
}

.badge {
  font-size: 10px;
  padding: 4px 10px;
  border-radius: 20px;
  white-space: nowrap;
}

.badge-exp {
  background: rgba(255, 215, 0, 0.15);
  color: #FFD700;
  border: 1px solid rgba(255, 215, 0, 0.3);
}

.badge-screen {
  background: rgba(93, 222, 222, 0.15);
  color: #5DDEDE;
  border: 1px solid rgba(93, 222, 222, 0.3);
}

.badge-locked {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.3);
}

.screen-info-card {
  background: rgba(93, 222, 222, 0.07);
  border: 1px solid rgba(93, 222, 222, 0.2);
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 12px;
}

/* --- CALENDAR --- */
.cal-view-tabs {
  display: flex;
  gap: 3px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  padding: 3px;
  margin-bottom: 12px;
}

.cal-view-tab {
  flex: 1;
  text-align: center;
  padding: 7px;
  border-radius: 8px;
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.35);
  text-transform: uppercase;
}

.cal-view-tab.active {
  background: rgba(26, 191, 191, 0.15);
  color: #5DDEDE;
  border: 1px solid rgba(26, 191, 191, 0.3);
}

.cal-nav-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.cal-nav-btn {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 16px;
  color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.05);
}

.cal-day-label {
  font-family: 'Press Start 2P', monospace;
  font-size: 8px;
  color: #fff;
  flex: 1;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Vista mes */
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.cal-day-name {
  text-align: center;
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  color: rgba(255, 255, 255, 0.3);
  padding: 4px 0;
}

.cal-cell {
  min-height: 46px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 4px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.03);
  transition: all 0.15s;
}

.cal-cell:hover { background: rgba(255, 255, 255, 0.07); }
.cal-cell.today { border-color: #1ABFBF; border-width: 2px; }
.cal-cell.other-month { opacity: 0.2; }
.cal-cell.festivo { background: rgba(255, 100, 100, 0.12); border-color: rgba(255, 100, 100, 0.3); }
.cal-cell.libre { background: rgba(61, 220, 132, 0.1); border-color: rgba(61, 220, 132, 0.25); }
.cal-cell.vacaciones { background: rgba(255, 215, 0, 0.1); border-color: rgba(255, 215, 0, 0.25); }

.cal-num {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 500;
}

/* Vista semana */
.week-cols {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.week-day-col {
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.week-day-head {
  text-align: center;
  padding: 6px 2px;
  font-family: 'Press Start 2P', monospace;
  font-size: 6px;
  color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.04);
  text-transform: uppercase;
}

.week-day-head.today {
  color: #5DDEDE;
  background: rgba(26, 191, 191, 0.1);
}

.week-day-body {
  padding: 3px;
  min-height: 80px;
}

.week-ev {
  font-size: 9px;
  border-radius: 4px;
  padding: 2px 3px;
  margin-bottom: 2px;
  line-height: 1.3;
}

/* Vista día */
.day-view { display: flex; flex-direction: column; }

.day-slot {
  display: flex;
  gap: 10px;
  padding: 7px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.day-slot-time {
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  color: rgba(255, 255, 255, 0.25);
  min-width: 36px;
  padding-top: 4px;
  text-align: right;
}

.day-slot-content { flex: 1; }

.day-event {
  border-radius: 10px;
  padding: 8px 10px;
  margin-bottom: 3px;
}

.day-event-title {
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
}

.day-event-sub {
  font-size: 10px;
  margin-top: 2px;
  opacity: 0.6;
  color: #fff;
}

.day-free {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.18);
  font-style: italic;
  padding: 4px 0;
}

/* Colores eventos */
.ev-school   { background: rgba(55,138,221,0.25); color: #85B7EB; }
.ev-extra    { background: rgba(99,153,34,0.25);  color: #C0DD97; }
.ev-special  { background: rgba(216,90,48,0.25);  color: #F5C4B3; }
.ev-free     { background: rgba(127,119,221,0.25);color: #CECBF6; }
.ev-screen   { background: rgba(186,117,23,0.25); color: #FAC775; }
.ev-reward   { background: rgba(29,158,117,0.25); color: #9FE1CB; }
.ev-festivo  { background: rgba(255,100,100,0.2); color: #F7C1C1; }
.ev-vacaciones { background: rgba(255,215,0,0.15); color: #FAC775; }

/* Leyenda */
.cal-legend {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
}

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
}

/* --- PARENT PANEL --- */
.parent-header {
  background: rgba(0, 0, 0, 0.3);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 1;
}

.parent-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 9px;
  color: #5DDEDE;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.btn-back {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.6);
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 7px 13px;
  border-radius: 20px;
  cursor: pointer;
}

/* --- TAB BAR --- */
.tab-bar {
  display: flex;
  gap: 3px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  padding: 3px;
  margin-bottom: 14px;
}

.tab {
  flex: 1;
  text-align: center;
  font-size: 11px;
  padding: 7px;
  border-radius: 8px;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.4);
}

.tab.active {
  background: rgba(26, 191, 191, 0.15);
  color: #5DDEDE;
  border: 1px solid rgba(26, 191, 191, 0.3);
}

/* --- GLASS CARDS --- */
.glass-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 10px;
}

.glass-card-warn {
  background: rgba(255, 193, 7, 0.07);
  border: 1px solid rgba(255, 193, 7, 0.2);
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 10px;
}

.glass-card-info {
  background: rgba(93, 222, 222, 0.07);
  border: 1px solid rgba(93, 222, 222, 0.2);
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 10px;
}

.child-avatar {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.07);
}

/* --- FORM ELEMENTS --- */
input[type=text],
input[type=number],
input[type=date],
input[type=time],
select {
  width: 100%;
  padding: 9px 12px;
  font-size: 13px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
}

input::placeholder { color: rgba(255, 255, 255, 0.25); }
select option { background: #0a1628; color: #fff; }

.form-row { margin-bottom: 10px; }
.form-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 4px;
}

/* --- BUTTONS --- */
.btn {
  display: inline-block;
  padding: 8px 16px;
  font-size: 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
}

.btn:active { transform: scale(0.97); }

.btn-teal    { background: rgba(26,191,191,0.15);   color: #5DDEDE;  border-color: rgba(26,191,191,0.3); }
.btn-exp     { background: rgba(255,215,0,0.12);    color: #FFD700;  border-color: rgba(255,215,0,0.25); }
.btn-danger  { background: rgba(220,53,69,0.15);    color: #f07080;  border-color: rgba(220,53,69,0.3); }
.btn-success { background: rgba(61,220,132,0.15);   color: #3DDC84;  border-color: rgba(61,220,132,0.3); }
.btn-pause   { background: rgba(255,193,7,0.12);    color: rgba(255,193,7,0.9); border-color: rgba(255,193,7,0.25); }

.btn-sm  { padding: 5px 12px; font-size: 11px; }
.btn-xs  { padding: 3px 9px;  font-size: 10px; }

/* --- MODAL --- */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal {
  background: #0d2240;
  border: 1px solid rgba(26, 191, 191, 0.3);
  border-radius: 20px;
  padding: 20px;
  width: 100%;
  max-width: 360px;
  max-height: 80vh;
  overflow-y: auto;
}

.modal-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 9px;
  color: #5DDEDE;
  margin-bottom: 16px;
  text-transform: uppercase;
}

/* --- TOAST --- */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: #050d1a;
  color: #5DDEDE;
  font-family: 'Press Start 2P', monospace;
  font-size: 8px;
  padding: 12px 20px;
  border-radius: 20px;
  border: 1px solid rgba(93, 222, 222, 0.4);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
  z-index: 200;
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.toast.show { opacity: 1; }

/* --- UTILITIES --- */
.row         { display: flex; align-items: center; gap: 8px; }
.row-between { display: flex; align-items: center; justify-content: space-between; }
.muted       { font-size: 12px; color: rgba(255, 255, 255, 0.35); }

.mt8  { margin-top: 8px; }
.mt12 { margin-top: 12px; }
.mt16 { margin-top: 16px; }
.mb8  { margin-bottom: 8px; }
.mb12 { margin-bottom: 12px; }
.mb16 { margin-bottom: 16px; }
.gap8 { gap: 8px; }
.gap4 { gap: 4px; }
