/* ===== LE SOMMELIER DE POCHE - Auth Layout Styles (Restaurant & Admin) ===== */

/* ===== Background Pattern ===== */
.auth-bg {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.auth-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.4;
}

.auth-orb-1 {
  width: 500px;
  height: 500px;
  top: -200px;
  right: -150px;
}

.auth-orb-2 {
  width: 400px;
  height: 400px;
  bottom: -150px;
  left: -100px;
}

.auth-orb-3 {
  width: 200px;
  height: 200px;
  top: 40%;
  left: 20%;
  opacity: 0.2;
}

/* Restaurant specific colors */
.auth-layout-restaurant .auth-orb-1 {
  background: linear-gradient(135deg, var(--victor-grape), var(--victor-wine));
}

.auth-layout-restaurant .auth-orb-2 {
  background: linear-gradient(135deg, var(--victor-coral), var(--victor-grape));
}

.auth-layout-restaurant .auth-orb-3 {
  background: var(--victor-gold);
}

/* Admin specific colors */
.auth-layout-admin .auth-orb-1 {
  background: linear-gradient(135deg, var(--victor-gold), var(--victor-gold-dark));
}

.auth-layout-admin .auth-orb-2 {
  background: linear-gradient(135deg, var(--victor-wine), var(--victor-gold));
}

.auth-layout-admin .auth-orb-3 {
  background: var(--victor-gold);
}

/* ===== Main Container ===== */
.auth-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  z-index: 1;
}

.auth-wrapper {
  width: 100%;
  max-width: 440px;
}

/* ===== Logo ===== */
.auth-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 32px;
}

.auth-logo-img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  margin-bottom: 16px;
  border-radius: 20px;
}

.auth-layout-restaurant .auth-logo-img {
  box-shadow: 0 12px 40px rgba(107, 63, 160, 0.3);
}

.auth-layout-admin .auth-logo-img {
  box-shadow: 0 12px 40px rgba(212, 175, 55, 0.3);
}

.auth-logo-icon {
  width: 80px;
  height: 80px;
  object-fit: contain;
  margin-bottom: 16px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--victor-gold), var(--victor-gold-dark));
  box-shadow: 0 12px 40px rgba(212, 175, 55, 0.3);
}

.auth-logo-text {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 28px;
  color: var(--bo-text);
  font-weight: 400;
  text-align: center;
  line-height: 1.2;
}

.auth-logo-subtitle {
  font-size: 14px;
  margin-top: 4px;
}

.auth-layout-restaurant .auth-logo-subtitle {
  color: var(--bo-text-muted);
}

.auth-layout-admin .auth-logo-subtitle {
  color: var(--victor-gold-dark);
}

.admin-badge-auth {
  display: inline-block;
  padding: 4px 10px;
  background: rgba(212, 175, 55, 0.15);
  color: var(--victor-gold-dark);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  border-radius: 6px;
  margin-bottom: 8px;
}

/* ===== Card ===== */
.auth-card {
  background: white;
  border-radius: 24px;
  padding: 40px;
  box-shadow: 
    0 4px 6px rgba(0, 0, 0, 0.02),
    0 12px 24px rgba(0, 0, 0, 0.04),
    0 24px 48px rgba(107, 63, 160, 0.08);
}

.auth-layout-admin .auth-card {
  box-shadow: 
    0 4px 6px rgba(0, 0, 0, 0.02),
    0 12px 24px rgba(0, 0, 0, 0.04),
    0 24px 48px rgba(212, 175, 55, 0.08);
}

.auth-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--bo-text);
  text-align: center;
  margin: 0 0 8px 0;
}

.auth-subtitle {
  font-size: 15px;
  color: var(--bo-text-muted);
  text-align: center;
  margin: 0 0 32px 0;
}

/* ===== Form Elements ===== */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--bo-text-secondary);
  margin-bottom: 8px;
}

.form-input {
  width: 100%;
  padding: 14px 16px;
  background: var(--bo-bg);
  border: 1px solid var(--bo-border);
  border-radius: 12px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  color: var(--bo-text);
  transition: all 0.2s ease;
  outline: none;
}

.form-input::placeholder {
  color: var(--bo-text-muted);
}

.form-input:hover {
  border-color: var(--bo-border-hover);
}

.form-input:focus {
  background: white;
  box-shadow: 0 0 0 3px rgba(107, 63, 160, 0.1);
}

.auth-layout-restaurant .form-input:focus {
  border-color: var(--victor-grape);
}

.auth-layout-admin .form-input:focus {
  border-color: var(--victor-gold);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.form-input-icon {
  position: relative;
}

.form-input-icon .form-input {
  padding-left: 48px;
}

.form-input-icon > svg {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: var(--bo-text-muted);
  pointer-events: none;
}

.form-input-icon .toggle-password {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  padding: 4px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--bo-text-muted);
  transition: color 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.form-input-icon .toggle-password:hover {
  color: var(--bo-text-secondary);
}

.form-input-icon .toggle-password svg {
  width: 20px;
  height: 20px;
  display: block;
}

.form-hint {
  font-size: 12px;
  color: var(--bo-text-muted);
  margin-top: 6px;
}

/* ===== Checkbox ===== */
.form-checkbox {
  display: flex;
  align-items: center;
  gap: 12px;
}

.form-checkbox input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
}

.auth-layout-restaurant .form-checkbox input[type="checkbox"] {
  accent-color: var(--victor-grape);
}

.auth-layout-admin .form-checkbox input[type="checkbox"] {
  accent-color: var(--victor-gold);
}

.form-checkbox label {
  font-size: 14px;
  color: var(--bo-text-muted);
  cursor: pointer;
}

/* ===== Links Row ===== */
.form-links {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.form-link {
  font-size: 14px;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

.auth-layout-restaurant .form-link {
  color: var(--victor-grape);
}

.auth-layout-restaurant .form-link:hover {
  color: var(--victor-grape-light);
  text-decoration: underline;
}

.auth-layout-admin .form-link {
  color: var(--victor-gold);
}

.auth-layout-admin .form-link:hover {
  color: var(--victor-gold-light);
  text-decoration: underline;
}

/* ===== Buttons ===== */
.btn-auth-primary {
  width: 100%;
  padding: 16px 24px;
  border: none;
  border-radius: 12px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.auth-layout-restaurant .btn-auth-primary {
  background: linear-gradient(135deg, var(--victor-grape), var(--victor-grape-light));
}

.auth-layout-admin .btn-auth-primary {
  background: linear-gradient(135deg, var(--victor-gold), var(--victor-gold-dark));
}

.btn-auth-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.btn-auth-primary:hover {
  transform: translateY(-2px);
}

.auth-layout-restaurant .btn-auth-primary:hover {
  box-shadow: var(--shadow-button-grape);
}

.auth-layout-admin .btn-auth-primary:hover {
  box-shadow: var(--shadow-button-gold);
}

.btn-auth-primary:hover::before {
  left: 100%;
}

.btn-auth-primary:active {
  transform: translateY(-1px);
}

.btn-auth-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-auth-secondary {
  width: 100%;
  padding: 16px 24px;
  background: white;
  border: 1px solid var(--bo-border);
  border-radius: 12px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 500;
  color: var(--bo-text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  display: block;
  text-align: center;
}

.btn-auth-secondary:hover {
  border-color: var(--bo-border-hover);
  background: var(--bo-bg);
}

/* ===== Divider ===== */
.auth-divider {
  display: flex;
  align-items: center;
  margin: 24px 0;
  gap: 16px;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--bo-border);
}

.auth-divider span {
  font-size: 13px;
  color: var(--bo-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ===== Footer Text ===== */
.auth-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 14px;
  color: var(--bo-text-muted);
}

.auth-footer a {
  text-decoration: none;
  font-weight: 500;
}

.auth-layout-restaurant .auth-footer a {
  color: var(--victor-grape);
}

.auth-layout-admin .auth-footer a {
  color: var(--victor-gold);
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* ===== Alert Messages ===== */
.auth-alert {
  padding: 14px 16px;
  border-radius: 12px;
  margin-bottom: 20px;
  font-size: 14px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.auth-alert-error {
  background: var(--status-error-bg);
  border: 1px solid var(--status-error-border);
  color: var(--status-error-darker);
}

.auth-alert-success {
  background: var(--status-success-bg);
  border: 1px solid var(--status-success-border);
  color: var(--status-success-darker);
}

.auth-alert-info {
  border: 1px solid;
}

.auth-layout-restaurant .auth-alert-info {
  background: var(--status-info-bg);
  border-color: var(--status-info-border);
  color: var(--victor-grape);
}

.auth-layout-admin .auth-alert-info {
  background: rgba(212, 175, 55, 0.1);
  border-color: rgba(212, 175, 55, 0.3);
  color: var(--victor-gold-dark);
}

.auth-alert svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ===== Back Link ===== */
.auth-back {
  position: fixed;
  top: 24px;
  left: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: white;
  border: 1px solid var(--bo-border);
  border-radius: 10px;
  font-size: 14px;
  color: var(--bo-text-muted);
  text-decoration: none;
  transition: all 0.2s ease;
  z-index: 10;
}

.auth-back:hover {
  border-color: var(--bo-border-hover);
  color: var(--bo-text-secondary);
}

.auth-back svg {
  width: 16px;
  height: 16px;
}

/* ===== Responsive ===== */
@media (max-width: 480px) {
  .auth-card {
    padding: 28px 24px;
    border-radius: 20px;
  }

  .auth-logo-img,
  .auth-logo-icon {
    width: 64px;
    height: 64px;
    border-radius: 16px;
  }

  .auth-logo-text {
    font-size: 24px;
  }

  .auth-title {
    font-size: 22px;
  }

  .auth-back {
    top: 16px;
    left: 16px;
    padding: 8px 12px;
    font-size: 13px;
  }
}

/* ===== Gradient Text ===== */
.gradient-text {
  background: linear-gradient(135deg, var(--victor-coral), var(--victor-grape));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
