* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  display: flex; justify-content: center; align-items: flex-start;
  min-height: 100vh; background: #000;
  font-family: 'Exo 2', sans-serif;
}

.zenlav-app {
  width: 100%; max-width: 480px;
  min-height: 100vh;
  background: #011730;
  position: relative; overflow: hidden;
}

.hex-bg {
  position: fixed; top: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; height: 100vh;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='64'%3E%3Cpath d='M28 2 L54 17 L54 47 L28 62 L2 47 L2 17 Z' fill='none' stroke='%23267DDD' stroke-width='0.4' opacity='0.18'/%3E%3C/svg%3E");
  background-size: 56px 64px; pointer-events: none; z-index: 0;
}

.screen { position: relative; z-index: 1; display: none; min-height: 100vh; }
.screen.active { display: flex; flex-direction: column; }

.app-title {
  font-family: 'Rajdhani', sans-serif;
  font-size: 50px; font-weight: 700; color: #FFFFFF;
  text-align: center; letter-spacing: 3px; padding: 48px 0 8px;
  text-shadow: 0 0 20px rgba(38,125,221,0.4); flex-shrink: 0;
}

.btn-glossy {
  background: linear-gradient(180deg, rgba(60,70,90,0.9) 0%, rgba(30,40,60,0.85) 40%, rgba(15,25,45,0.9) 70%, rgba(40,50,70,0.85) 100%);
  border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; height: 44px;
  font-family: 'Rajdhani', sans-serif;
  font-size: 15px; font-weight: 700; color: #FFFFFF; letter-spacing: 2px;
  cursor: pointer; width: 100%; position: relative; overflow: hidden; outline: none;
}
.btn-glossy::after {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0.04) 100%);
  pointer-events: none;
}
.btn-glossy:disabled { opacity: 0.6; cursor: not-allowed; }

.field-plain {
  width: 100%; height: 44px; background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15); border-radius: 8px; padding: 0 16px;
  font-family: 'Rajdhani', sans-serif; font-size: 14px; font-weight: 600;
  letter-spacing: 2px; color: #FFFFFF; outline: none; text-align: center;
}
.field-plain::placeholder { color: rgba(255,255,255,0.5); }
.field-plain::placeholder { color: #CCCBC9; font-weight: 700; }

.btn-secondary {
  background: none; border: none; font-family: 'Rajdhani', sans-serif;
  font-size: 14px; font-weight: 600; color: #4a8fbf; letter-spacing: 2px;
  cursor: pointer; text-align: center; outline: none;
}
.btn-retour { font-size: 16px; }

.msg-box {
  margin-top: 12px; padding: 10px 14px; border-radius: 8px;
  font-family: 'Rajdhani', sans-serif; font-size: 14px; font-weight: 600;
  letter-spacing: 1px; text-align: center; display: none;
}
.msg-box.success { background: rgba(38,125,221,0.15); color: #267DDD; border: 1px solid #267DDD44; display: block; }
.msg-box.error { background: rgba(204,51,51,0.15); color: #cc3333; border: 1px solid #cc333344; display: block; }

/* LOGIN */
#screen-login { justify-content: space-between; }
#screen-login .login-center { flex: 1; display: flex; align-items: center; justify-content: center; }
#screen-login .login-form { width: 100%; padding: 0 40px; display: flex; flex-direction: column; gap: 16px; }
#screen-login .login-footer { padding: 24px; display: flex; justify-content: center; flex-shrink: 0; }

/* INSCRIPTION */
#screen-inscription { justify-content: flex-start; }
#screen-inscription .inscription-form { width: 100%; padding: 40px 32px 0; display: flex; flex-direction: column; }
#screen-inscription .field-group { display: flex; flex-direction: column; gap: 12px; margin-bottom: 56px; }
#screen-inscription .field-row { display: flex; align-items: center; gap: 12px; }
#screen-inscription .field-label {
  font-family: 'Rajdhani', sans-serif; font-size: 12px; font-weight: 600;
  color: #fff; letter-spacing: 1px; width: 110px; text-align: right; flex-shrink: 0;
}
#screen-inscription .field-input {
  flex: 1; height: 36px; background: rgba(255,255,255,0.92);
  border: none; border-radius: 6px; padding: 0 10px; font-size: 14px; color: #011730; outline: none;
}

/* SÉLECTION DE CYCLE */
#screen-cycle { justify-content: flex-start; }
.cycle-content {
  display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 0 32px;
  flex: 1; gap: 24px;
}
.cycle-titre {
  font-family: 'Rajdhani', sans-serif; font-size: 18px; font-weight: 700;
  color: #ffffff; text-align: center; letter-spacing: 2px;
}
.cycle-instruction {
  font-family: 'Exo 2', sans-serif; font-size: 14px;
  color: #CCCBC9; letter-spacing: 1px;
}
.cycle-boutons {
  display: flex; gap: 16px; flex-wrap: wrap; justify-content: center;
  width: 100%;
}
.btn-cycle {
  min-width: 90px; width: auto; padding: 0 24px;
  font-size: 18px; height: 50px;
}

/* MACHINES */
#screen-machines { justify-content: flex-start; }
#screen-machines .machines-content { padding: 0 16px; flex: 1; display: flex; flex-direction: column; }
#screen-machines .machines-group { flex: 1; display: flex; flex-direction: column; justify-content: center; }
#screen-machines .machines-section-washers { display: flex; justify-content: center; gap: 8px; margin-bottom: 80px; }
#screen-machines .machines-section-dryers { display: flex; justify-content: center; gap: 8px; }
.machines-footer { display: flex; justify-content: center; padding: 24px 0; margin-top: auto; }
#screen-machines .machine-slot { display: flex; flex-direction: column; align-items: center; gap: 3px; }
#screen-machines .machine-label {
  font-family: 'Rajdhani', sans-serif; font-size: 12px; font-weight: 600;
  letter-spacing: 1px; height: 18px; display: flex; align-items: center;
}
.label-libre { color: #FFFFFF; }
.label-encours { color: #CCCBC9; }
.label-avider { color: #267DDD; }
.label-panne { color: #cc3333; }

#screen-machines .machine-body {
  width: 88px; height: 100px; background: #e8e8e8; border-radius: 8px;
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; align-items: center;
  border: 2px solid #c8c8c8; cursor: pointer;
}
#screen-machines .machine-panel {
  width: 100%; height: 22px; background: #d0d0d0;
  display: flex; align-items: center; padding: 0 7px; gap: 4px;
  border-bottom: 1px solid #bbb; flex-shrink: 0;
}
.panel-knob { width: 12px; height: 12px; border-radius: 50%; background: linear-gradient(135deg, #bbb 0%, #888 100%); border: 1px solid #999; flex-shrink: 0; }
.panel-slot { flex: 1; height: 5px; background: #bbb; border-radius: 3px; }
.panel-led { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.led-off { background: #aaa; }
.led-on  { background: #267DDD; box-shadow: 0 0 4px #267DDD; }
#screen-machines .machine-number {
  position: absolute; bottom: 5px; right: 7px;
  font-family: 'Rajdhani', sans-serif; font-size: 11px; font-weight: 700; color: #555;
}
#screen-machines .machine-porthole {
  width: 62px; height: 62px; border-radius: 50%; background: #0d0d0d; margin-top: 4px;
  display: flex; align-items: center; justify-content: center; border: 3px solid #888;
}
.porthole-text { font-family: 'Rajdhani', sans-serif; font-size: 20px; font-weight: 700; color: #CCCBC9; }

#screen-machines .dryer-body {
  width: 88px; height: 100px; background: #1a1a1a; border-radius: 8px;
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; border: 2px solid #333;
  cursor: pointer;
}
#screen-machines .dryer-panel {
  width: 100%; height: 22px; background: #222;
  display: flex; align-items: center; padding: 0 7px; gap: 4px;
  border-bottom: 1px solid #333; flex-shrink: 0;
}
.dryer-knob { width: 12px; height: 12px; border-radius: 50%; background: linear-gradient(135deg, #444 0%, #222 100%); border: 1px solid #555; flex-shrink: 0; }
.dryer-slot { flex: 1; height: 5px; background: #333; border-radius: 3px; }
#screen-machines .dryer-porthole {
  width: 62px; height: 62px; border-radius: 50%; background: #111; margin-top: 4px;
  display: flex; align-items: center; justify-content: center; border: 3px solid #444;
}
.linge-svg { width: 32px; height: 22px; }

/* BOUTONS D'ACTION SOUS LES MACHINES */
.btn-action-machine {
  width: 100%; height: 28px; margin-top: 4px;
  font-size: 11px;
}

/* BOUTON STOP */
.btn-stop {
  background: linear-gradient(180deg, #cc4444 0%, #992222 40%, #771111 70%, #993333 100%);
  border: none; border-radius: 8px; height: 28px; width: 100%;
  font-family: 'Rajdhani', sans-serif;
  font-size: 11px; font-weight: 700; color: #FFFFFF; letter-spacing: 2px;
  cursor: pointer; position: relative; overflow: hidden; outline: none;
  margin-top: 4px;
}
.btn-stop::after {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0.04) 100%);
  pointer-events: none;
}

/* NUMÉROS SÉCHOIRS */
#screen-machines .dryer-number {
  color: #CCCBC9;
}
