/* Modern WMS Login Styles */

body {
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  min-height: 100vh;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.container {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 1200px;
  padding: 15px;
  box-sizing: border-box;
}

.login-card {
  width: 360px;
  padding: 40px;
  border-radius: 12px;
  background-color: #ffffff;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
}

.login-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.12);
}

.card-header {
  text-align: center;
  margin-bottom: 30px;
}

.card-header .log {
  font-size: 42px;
  font-weight: 700;
  color: #3a7bd5;
  margin: 0;
  letter-spacing: 1px;
  position: relative;
  display: inline-block;
}

.card-header .log:after {
  content: '';
  position: absolute;
  width: 50%;
  height: 4px;
  background: linear-gradient(90deg, #3a7bd5, #00d2ff);
  bottom: -10px;
  left: 25%;
  border-radius: 2px;
}

.card-header .subtitle {
  font-size: 14px;
  color: #666;
  margin-top: 20px;
  margin-bottom: 0;
}

.form-group {
  margin-bottom: 24px;
  position: relative;
}

label {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
  color: #666;
  font-weight: 500;
  transition: color 0.3s;
}

input[type="text"], 
input[type="password"],
select {
  width: 100%;
  padding: 12px 16px;
  font-size: 16px;
  border: 1px solid #e1e1e1;
  border-radius: 6px;
  background-color: #f9fafc;
  box-sizing: border-box;
  transition: all 0.3s;
  color: #333;
}

input[type="text"]:focus, 
input[type="password"]:focus,
select:focus {
  border-color: #3a7bd5;
  background-color: #fff;
  box-shadow: 0 0 0 3px rgba(58, 123, 213, 0.1);
  outline: none;
}

input[type="submit"] {
  width: 100%;
  background: linear-gradient(90deg, #3a7bd5, #00d2ff);
  color: white;
  padding: 14px 20px;
  margin: 8px 0;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all 0.3s;
  box-shadow: 0 4px 6px rgba(58, 123, 213, 0.12);
}

input[type="submit"]:hover {
  background: linear-gradient(90deg, #3a7bd5, #3a9bd5);
  transform: translateY(-2px);
  box-shadow: 0 7px 14px rgba(58, 123, 213, 0.2);
}

input[type="submit"]:active {
  transform: translateY(1px);
  box-shadow: 0 2px 4px rgba(58, 123, 213, 0.2);
}

select {
  appearance: none;
  padding-right: 30px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 16px;
}

option {
  font-size: 16px;
  padding: 10px;
}

/* Estilo para campos obrigatórios */
input:required, select:required {
  background-image: linear-gradient(to right, transparent, transparent);
  background-position: right top;
  background-repeat: no-repeat;
}

/* Animação de foco nos campos */
.form-group:focus-within label {
  color: #3a7bd5;
}

.form-group i {
  color: #3a7bd5;
  margin-right: 5px;
}

.form-footer {
  text-align: center;
  margin-top: 15px;
}

.forgot-password {
  color: #666;
  font-size: 14px;
  text-decoration: none;
  transition: color 0.3s;
}

.forgot-password:hover {
  color: #3a7bd5;
  text-decoration: underline;
}

@media (max-width: 768px) {
  .login-card {
    width: 320px;
    padding: 35px;
  }
  
  .card-header .log {
    font-size: 38px;
  }
}

@media (max-width: 480px) {
  .login-card {
    width: 280px;
    padding: 25px;
  }
  
  .card-header .log {
    font-size: 34px;
  }
  
  .card-header .subtitle {
    font-size: 13px;
  }
  
  label {
    font-size: 13px;
  }
  
  input[type="text"], 
  input[type="password"],
  select,
  input[type="submit"] {
    padding: 10px 14px;
    font-size: 14px;
  }
}

@media (max-width: 320px) {
  .login-card {
    width: 240px;
    padding: 20px;
  }
  
  .card-header .log {
    font-size: 28px;
  }
  
  .form-group {
    margin-bottom: 16px;
  }
}

/* Orientação paisagem em dispositivos móveis */
@media (max-height: 500px) and (orientation: landscape) {
  body {
    align-items: flex-start;
    padding: 20px 0;
  }
  
  .login-card {
    margin: 0 auto;
  }
}

/* Loading overlay */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  color: white;
}

.spinner {
  border: 4px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top: 4px solid white;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin-bottom: 10px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.btn-gradiente {
  background: linear-gradient(to right, #3b82f6, #00cfff);
  color: white;
  border: none;
  padding: 12px 20px;
  font-size: 16px;
  font-weight: bold;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  width: 100%;
}

.btn-gradiente i {
  font-size: 18px;
}

.btn-gradiente:hover {
  transform: scale(1.02);
  box-shadow: 0 6px 12px rgba(0, 123, 255, 0.4);
}

.btn-gradiente:disabled {
  background: #ccc;
  cursor: not-allowed;
  box-shadow: none;
}
