/* ==========================================================================
   HOMME SMART HOME — LUXURY LIQUID GLASS AUTH SYSTEM
   Architecture: Split Luxury Card Layout, Holographic Lighting, Dynamic Validation
   Typography: Shoor Rounded (Full Weight Scale: Regular, Medium, Bold, Heavy)
   Colors: Obsidian Abyss (#03060a), Cyber Cyan (#00e5d4), Deep Void Slate
   ========================================================================== */

/* Page Outer Structure */
.auth-page-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
  background: radial-gradient(circle at 50% 0%, rgba(0, 229, 212, 0.08) 0%, transparent 60%),
              radial-gradient(circle at 10% 80%, rgba(8, 145, 178, 0.06) 0%, transparent 50%),
              var(--bg-abyss);
}

/* Subtle Animated Ambient Mesh */
.auth-page-wrapper::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 40%, transparent 80%);
  z-index: -1;
}

/* Header Floating Navigation Strip */
.auth-header-strip {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 24px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.auth-brand-link {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  transition: transform var(--transition-fast);
}

.auth-brand-link:hover {
  transform: translateY(-1px);
}

.auth-brand-logo-wrap {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--glass-border-crisp);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6), 0 0 16px rgba(0, 229, 212, 0.2);
  background: #02060b;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.auth-brand-logo-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.35);
  pointer-events: none;
}

.auth-brand-logo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.auth-brand-text {
  display: flex;
  flex-direction: column;
}

.auth-brand-title {
  font-size: 1.45rem;
  font-weight: 900;
  letter-spacing: 2.5px;
  color: var(--text-white);
  line-height: 1.1;
  text-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

.auth-brand-subtitle {
  font-size: 0.78rem;
  color: var(--brand-primary);
  font-weight: 600;
  letter-spacing: 0.5px;
}

.auth-back-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  background: rgba(14, 25, 40, 0.6);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border-subtle);
  transition: all var(--transition-fast);
}

.auth-back-link:hover {
  color: var(--text-white);
  border-color: var(--brand-primary);
  background: rgba(0, 229, 212, 0.1);
  box-shadow: 0 0 20px rgba(0, 229, 212, 0.2);
  transform: translateX(-3px);
}

.auth-back-link svg {
  transition: transform var(--transition-fast);
}

.auth-back-link:hover svg {
  transform: translateX(3px);
}

/* Main Split Stage */
.auth-main-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 24px 60px;
}

.auth-master-shell {
  width: 100%;
  max-width: 1020px;
  background: rgba(10, 19, 32, 0.82);
  backdrop-filter: blur(36px) saturate(190%);
  -webkit-backdrop-filter: blur(36px) saturate(190%);
  border: 1px solid var(--glass-border-crisp);
  border-radius: 28px;
  box-shadow: 0 30px 80px -15px rgba(0, 0, 0, 0.85),
              0 0 1px 1px rgba(255, 255, 255, 0.12),
              0 0 45px rgba(0, 229, 212, 0.12);
  display: grid;
  grid-template-columns: 1fr 1.08fr;
  overflow: hidden;
  position: relative;
}

/* Liquid Specular Top Border */
.auth-master-shell::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, 
    transparent 0%, 
    rgba(255, 255, 255, 0.4) 20%, 
    var(--brand-primary) 50%, 
    var(--brand-accent) 80%, 
    transparent 100%
  );
  z-index: 2;
}

/* ==========================================================================
   SIDEBAR SHOWCASE COLUMN (Brand Value Proposition, Trust Badges, Live Pulse)
   ========================================================================== */
.auth-showcase-column {
  padding: 48px 40px;
  background: linear-gradient(145deg, rgba(8, 16, 28, 0.92) 0%, rgba(5, 11, 20, 0.98) 100%);
  border-left: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.auth-showcase-column::before {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 240px;
  height: 240px;
  background: radial-gradient(circle, rgba(0, 229, 212, 0.18) 0%, transparent 70%);
  filter: blur(40px);
  pointer-events: none;
}

.auth-showcase-column::after {
  content: '';
  position: absolute;
  bottom: -40px;
  left: -40px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(8, 145, 178, 0.15) 0%, transparent 70%);
  filter: blur(35px);
  pointer-events: none;
}

.auth-showcase-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: rgba(0, 229, 212, 0.08);
  border: 1px solid rgba(0, 229, 212, 0.25);
  color: var(--brand-primary);
  font-size: 0.78rem;
  font-weight: 700;
  width: fit-content;
  margin-bottom: 24px;
}

.auth-pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand-primary);
  box-shadow: 0 0 8px var(--brand-primary);
  animation: pulseDot 2s infinite ease-in-out;
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.auth-showcase-title {
  font-size: 1.7rem;
  font-weight: 900;
  color: var(--text-white);
  line-height: 1.35;
  margin-bottom: 14px;
}

.auth-showcase-title .highlight {
  background: linear-gradient(135deg, #22d3ee 0%, #00e5d4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.auth-showcase-desc {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.75;
  margin-bottom: 32px;
}

/* Feature Checkpoints */
.auth-features-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 36px;
}

.auth-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.auth-feature-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(0, 229, 212, 0.08);
  border: 1px solid rgba(0, 229, 212, 0.2);
  color: var(--brand-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.auth-feature-text {
  display: flex;
  flex-direction: column;
}

.auth-feature-heading {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--text-white);
  margin-bottom: 2px;
}

.auth-feature-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Quote/Trust Testimonial Box */
.auth-showcase-trust {
  padding: 16px 20px;
  border-radius: var(--radius-md);
  background: rgba(14, 25, 42, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.auth-trust-kpi {
  display: flex;
  flex-direction: column;
}

.auth-trust-kpi-val {
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--brand-primary);
  line-height: 1.2;
}

.auth-trust-kpi-lbl {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ==========================================================================
   FORM INTERACTION COLUMN
   ========================================================================== */
.auth-form-column {
  padding: 48px 44px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: rgba(10, 18, 30, 0.65);
}

/* Form Header */
.auth-form-header {
  margin-bottom: 28px;
}

.auth-form-header-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.auth-form-title {
  font-size: 1.7rem;
  font-weight: 900;
  color: var(--text-white);
  margin-bottom: 8px;
  letter-spacing: -0.3px;
}

.auth-form-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Dynamic Alert Banners */
.auth-alert {
  display: none;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  margin-bottom: 24px;
  font-size: 0.88rem;
  line-height: 1.65;
  animation: fadeInDown 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.auth-alert.visible {
  display: flex;
}

.auth-alert.info {
  background: rgba(8, 145, 178, 0.15);
  border: 1px solid rgba(34, 211, 238, 0.38);
  color: #a5f3fc;
}

.auth-alert.success {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(52, 211, 153, 0.38);
  color: #6ee7b7;
}

.auth-alert.error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(248, 113, 113, 0.38);
  color: #fca5a5;
}

.auth-alert-icon {
  flex-shrink: 0;
  margin-top: 2px;
}

.auth-alert-text {
  flex: 1;
  font-weight: 500;
}

/* Form Element Layout */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.auth-field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
}

.auth-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-primary);
}

.auth-label-tag {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
}

.auth-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.auth-input-icon {
  position: absolute;
  right: 16px;
  color: var(--text-muted);
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--transition-fast);
}

.auth-input {
  width: 100%;
  height: 52px;
  background: rgba(13, 23, 38, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-md);
  padding: 0 46px 0 16px;
  color: var(--text-white);
  font-size: 0.95rem;
  font-weight: 500;
  outline: none;
  transition: all var(--transition-fast);
}

.auth-input.no-start-icon {
  padding-right: 16px;
}

.auth-input.has-toggle {
  padding-left: 48px;
}

.auth-input:focus {
  border-color: var(--brand-primary);
  background: rgba(15, 27, 44, 0.95);
  box-shadow: 0 0 0 3px rgba(0, 229, 212, 0.16),
              0 0 20px rgba(0, 229, 212, 0.1);
}

.auth-input:focus ~ .auth-input-icon {
  color: var(--brand-primary);
}

.auth-input::placeholder {
  color: #52657e;
  font-size: 0.88rem;
}

/* Visibility Password Toggle */
.auth-toggle-pwd {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.auth-toggle-pwd:hover {
  color: var(--brand-primary);
  background: rgba(0, 229, 212, 0.08);
}

/* Real-Time Inline Field Validation Errors */
.auth-field-error {
  display: none;
  font-size: 0.8rem;
  font-weight: 600;
  color: #f87171;
  margin-top: 4px;
  animation: fadeIn 0.2s ease-in;
}

.auth-field-error.visible {
  display: flex;
  align-items: center;
  gap: 6px;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Submit Action Button */
.auth-submit-btn {
  width: 100%;
  height: 52px;
  background: linear-gradient(135deg, var(--brand-primary) 0%, #0891b2 100%);
  border: none;
  border-radius: var(--radius-md);
  color: #03080e;
  font-size: 1.02rem;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 10px 28px rgba(0, 229, 212, 0.32),
              inset 0 1px 1px rgba(255, 255, 255, 0.4);
  transition: all var(--transition-smooth);
  margin-top: 10px;
  position: relative;
  overflow: hidden;
}

.auth-submit-btn::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: skewX(-20deg);
  transition: left 0.75s ease;
}

.auth-submit-btn:hover::after {
  left: 140%;
}

.auth-submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 38px rgba(0, 229, 212, 0.48),
              inset 0 1px 1px rgba(255, 255, 255, 0.6);
}

.auth-submit-btn:active {
  transform: translateY(0);
}

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

.auth-submit-btn svg {
  transition: transform var(--transition-fast);
}

.auth-submit-btn:hover svg {
  transform: translateX(-4px);
}

/* Secondary Navigation Switcher */
.auth-footer-switch {
  text-align: center;
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.auth-switch-link {
  color: var(--brand-primary);
  font-weight: 800;
  text-decoration: none;
  margin-right: 6px;
  position: relative;
  transition: color var(--transition-fast);
}

.auth-switch-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  right: 0;
  left: 0;
  height: 1px;
  background: var(--brand-primary);
  opacity: 0.4;
  transition: opacity var(--transition-fast);
}

.auth-switch-link:hover {
  color: var(--brand-primary-hover);
}

.auth-link-subtle {
  background: none;
  border: none;
  color: var(--brand-primary);
  font-family: inherit;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 6px;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.auth-link-subtle:hover {
  color: var(--brand-primary-hover);
  text-decoration: underline;
  background: rgba(0, 229, 212, 0.08);
}

/* Security Trust Strip */
.auth-security-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-top: 22px;
  font-size: 0.78rem;
  color: #72849a;
}

.auth-security-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Password Strength Indicator (Register) */
.auth-pwd-strength {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
}

.auth-strength-meter {
  flex: 1;
  height: 4px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  gap: 3px;
}

.auth-strength-bar {
  flex: 1;
  height: 100%;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.1);
  transition: background 0.3s ease;
}

.auth-strength-bar.weak {
  background: #f87171;
}

.auth-strength-bar.medium {
  background: #fbbf24;
}

.auth-strength-bar.strong {
  background: #34d399;
}

.auth-strength-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  min-width: 50px;
  text-align: left;
}

/* ==========================================================================
   RESPONSIVE DESIGN SYSTEM
   ========================================================================== */
@media (max-width: 900px) {
  .auth-master-shell {
    grid-template-columns: 1fr;
    max-width: 520px;
  }

  .auth-showcase-column {
    display: none;
  }

  .auth-form-column {
    padding: 38px 30px;
  }
}

@media (max-width: 480px) {
  .auth-header-strip {
    padding: 16px 20px;
  }

  .auth-main-container {
    padding: 10px 16px 40px;
  }

  .auth-master-shell {
    border-radius: 20px;
  }

  .auth-form-column {
    padding: 30px 20px;
  }

  .auth-form-title {
    font-size: 1.4rem;
  }
}

/* ==========================================================================
   LIGHT THEME OVERRIDES FOR AUTH SYSTEM
   ========================================================================== */
[data-theme="light"] .auth-page-wrapper {
  background: radial-gradient(circle at 50% 0%, rgba(0, 180, 216, 0.12) 0%, transparent 60%),
              radial-gradient(circle at 10% 80%, rgba(56, 189, 248, 0.08) 0%, transparent 50%),
              #f1f5f9;
}

[data-theme="light"] .auth-page-wrapper::before {
  background-image: 
    linear-gradient(rgba(15, 23, 42, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 23, 42, 0.03) 1px, transparent 1px);
}

[data-theme="light"] .auth-brand-logo-wrap {
  background: #ffffff;
  border-color: rgba(15, 23, 42, 0.15);
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.1);
}

[data-theme="light"] .auth-brand-title {
  color: #0f172a;
  text-shadow: none;
}

[data-theme="light"] .auth-back-link {
  background: rgba(255, 255, 255, 0.85);
  border-color: rgba(15, 23, 42, 0.12);
  color: #334155;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
}

[data-theme="light"] .auth-back-link:hover {
  background: #ffffff;
  color: #00b4d8;
  border-color: #00b4d8;
}

[data-theme="light"] .auth-master-shell {
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(15, 23, 42, 0.12);
  box-shadow: 0 25px 60px -15px rgba(15, 23, 42, 0.1),
              0 0 1px 1px rgba(15, 23, 42, 0.08);
}

[data-theme="light"] .auth-showcase-column {
  background: linear-gradient(145deg, #f8fafc 0%, #f1f5f9 100%);
  border-left-color: rgba(15, 23, 42, 0.1);
}

[data-theme="light"] .auth-form-column {
  background: #ffffff;
}

[data-theme="light"] .auth-form-header-badge {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.1);
  color: #475569;
}

[data-theme="light"] .auth-form-title {
  color: #0f172a;
}

[data-theme="light"] .auth-form-desc {
  color: #475569;
}

[data-theme="light"] .auth-label {
  color: #1e293b;
}

[data-theme="light"] .auth-input {
  background: #f8fafc;
  border-color: rgba(15, 23, 42, 0.14);
  color: #0f172a;
}

[data-theme="light"] .auth-input:focus {
  background: #ffffff;
  border-color: #00b4d8;
  box-shadow: 0 0 0 3px rgba(0, 180, 216, 0.18);
}

[data-theme="light"] .auth-input::placeholder {
  color: #94a3b8;
}

[data-theme="light"] .auth-trust-card {
  background: rgba(255, 255, 255, 0.85);
  border-color: rgba(15, 23, 42, 0.08);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
}

[data-theme="light"] .auth-footer-switch {
  border-top-color: rgba(15, 23, 42, 0.08);
  color: #64748b;
}

[data-theme="light"] .auth-switch-link {
  color: #0284c7;
}

[data-theme="light"] .auth-security-strip {
  border-top-color: rgba(15, 23, 42, 0.08);
  color: #64748b;
}

