/* ==========================================================================
   HEXARISE AUTHENTICATION PORTAL STYLES
   ========================================================================== */

body.auth-body {
  background-color: var(--bg-surface);
  color: var(--text-on-surface);
  min-height: 100vh;
  font-family: var(--font-editorial);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-md);
}

.auth-main {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
}

.auth-wrapper {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  width: 100%;
}

.auth-brand-logo {
  display: inline-block;
  margin-bottom: var(--space-sm);
  transition: transform 0.2s ease;
}

.auth-brand-logo:hover {
  transform: scale(1.05);
}

.auth-title {
  font-size: clamp(24px, 4vw, 32px);
  font-weight: 700;
  color: #ffffff;
  margin-bottom: var(--space-xs);
}

.auth-subtitle {
  font-size: 14px;
  color: var(--text-variant);
  line-height: 1.6;
  max-width: 380px;
  margin: 0 auto;
}

/* Auth Card */
.auth-card {
  background-color: var(--bg-card-dark);
  border: 1px solid var(--bg-elevated-dark);
  border-radius: var(--radius-xl);
  padding: clamp(20px, 5vw, 32px);
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

/* Tabs */
.auth-tabs {
  display: flex;
  border-bottom: 1px solid var(--bg-elevated-dark);
  width: 100%;
}

.tab-btn {
  flex: 1;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  padding-bottom: var(--space-sm);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-variant);
  cursor: pointer;
  transition: all 0.2s ease;
}

.tab-btn:hover {
  color: var(--primary-yellow);
}

.tab-btn.active {
  color: var(--primary-yellow);
  border-bottom-color: var(--primary-yellow);
}

/* Status Alert Box */
.auth-status-box {
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-md);
  font-size: 13px;
  line-height: 1.5;
}

/* Tab Content */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.form-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-variant);
}

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
  background-color: var(--bg-container-low);
  border: 1px solid var(--bg-elevated-dark);
  border-radius: var(--radius-lg);
  padding: 0 var(--space-md);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-with-icon:focus-within {
  border-color: var(--accent-smart);
  box-shadow: 0 0 0 2px rgba(45, 189, 182, 0.3);
}

.input-with-icon .icon {
  color: var(--text-variant);
  font-size: 20px;
  margin-right: var(--space-xs);
  flex-shrink: 0;
}

.input-with-icon .form-input {
  width: 100%;
  background: transparent;
  border: none;
  outline: none;
  color: #ffffff;
  font-size: 14px;
  padding: var(--space-md) 0;
}

.btn-toggle-pwd {
  background: none;
  border: none;
  color: var(--text-variant);
  cursor: pointer;
  padding: 0;
  margin-left: var(--space-xs);
  display: flex;
  align-items: center;
}

.btn-toggle-pwd:hover {
  color: #ffffff;
}

/* Checkbox & Forgot Pwd Row */
.form-row-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: var(--space-xxs);
}

.checkbox-container {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  cursor: pointer;
  user-select: none;
}

.checkbox-container input[type="checkbox"] {
  display: none;
}

.checkbox-mark {
  width: 18px;
  height: 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--bg-elevated-dark);
  background-color: var(--bg-container-low);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.checkbox-container input[type="checkbox"]:checked + .checkbox-mark {
  background-color: var(--primary-yellow);
  border-color: var(--primary-yellow);
}

.check-mark-icon {
  font-size: 14px;
  color: var(--text-ink);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.checkbox-container input[type="checkbox"]:checked + .checkbox-mark .check-mark-icon {
  opacity: 1;
}

.checkbox-text {
  font-size: 13px;
  color: var(--text-variant);
}

.forgot-link {
  font-size: 13px;
  color: var(--primary-yellow);
  text-decoration: none;
  transition: color 0.2s ease;
}

.forgot-link:hover {
  text-decoration: underline;
}

.auth-submit-btn {
  width: 100%;
  margin-top: var(--space-xs);
  min-height: 48px;
  font-size: 15px;
}

/* Divider */
.auth-divider {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin: var(--space-xs) 0;
}

.divider-line {
  flex: 1;
  height: 1px;
  background-color: var(--bg-elevated-dark);
}

.divider-text {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.08em;
}

/* Social Auth Buttons Grid */
.social-auth-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-sm);
}

.btn-social {
  background-color: var(--bg-container-low);
  border: 1px solid var(--bg-elevated-dark);
  border-radius: var(--radius-lg);
  padding: var(--space-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  color: #ffffff;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-social:hover {
  background-color: var(--bg-elevated-dark);
  border-color: var(--primary-yellow);
  transform: translateY(-1px);
}

.social-svg-icon {
  flex-shrink: 0;
}

.social-btn-label {
  font-size: 13px;
  font-weight: 500;
}

/* Error, Warning & Success Box Variations */
.auth-status-box.error-box {
  background-color: rgba(246, 70, 93, 0.15);
  color: #f6465d;
  border: 1px solid rgba(246, 70, 93, 0.3);
}

.auth-status-box.warning-box {
  background-color: rgba(252, 213, 53, 0.15);
  color: #fcd535;
  border: 1px solid rgba(252, 213, 53, 0.3);
}

.auth-status-box.success-box {
  background-color: rgba(14, 203, 129, 0.15);
  color: #0ecb81;
  border: 1px solid rgba(14, 203, 129, 0.3);
}

.input-with-icon.input-error {
  border-color: #f6465d !important;
  box-shadow: 0 0 0 2px rgba(246, 70, 93, 0.25) !important;
}

/* Trust Footer */
.auth-trust-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
}

.trust-badges-row {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.badge-pill {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background-color: var(--bg-container);
  border: 1px solid var(--bg-elevated-dark);
  font-size: 12px;
  color: var(--text-on-surface);
}

.gold-star {
  color: var(--primary-yellow);
  font-size: 16px;
  font-variation-settings: 'FILL' 1;
}

.teal-shield {
  color: var(--accent-smart);
  font-size: 16px;
}

.legal-links-row {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 12px;
  color: var(--text-muted);
}

.legal-links-row a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.legal-links-row a:hover {
  color: #ffffff;
}

/* ==========================================================================
   AUTH MODALS STYLING
   ========================================================================== */
.auth-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-md);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.auth-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.auth-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 20, 33, 0.85);
  backdrop-filter: blur(8px);
}

.auth-modal-card {
  position: relative;
  width: 100%;
  max-width: 440px;
  background-color: #121e2e;
  border: 1px solid var(--bg-elevated-dark);
  border-radius: var(--radius-xl);
  padding: 32px 28px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
  z-index: 2;
  transform: translateY(12px) scale(0.97);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.auth-modal.active .auth-modal-card {
  transform: translateY(0) scale(1);
}

.auth-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  color: var(--text-variant);
  cursor: pointer;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.auth-modal-close:hover {
  background-color: var(--bg-elevated-dark);
  color: #ffffff;
}

.auth-modal-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px auto;
}

.auth-modal-icon span {
  font-size: 28px;
}

.auth-modal-icon.warning {
  background: rgba(252, 213, 53, 0.15);
  color: #fcd535;
  border: 1px solid rgba(252, 213, 53, 0.3);
}

.auth-modal-icon.info {
  background: rgba(45, 189, 182, 0.15);
  color: #2dbdb6;
  border: 1px solid rgba(45, 189, 182, 0.3);
}

.auth-modal-icon.success {
  background: rgba(14, 203, 129, 0.15);
  color: #0ecb81;
  border: 1px solid rgba(14, 203, 129, 0.3);
}

.auth-modal-title {
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
  text-align: center;
  margin-bottom: 8px;
}

.auth-modal-desc {
  font-size: 14px;
  color: var(--text-variant);
  text-align: center;
  line-height: 1.5;
  margin-bottom: 8px;
}

.auth-modal-subdesc {
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 24px;
}

.highlight-text {
  color: var(--primary-yellow);
}

.auth-modal-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}

.full-width {
  width: 100%;
}

.btn-secondary {
  background-color: var(--bg-container-low);
  color: var(--text-on-surface);
  border: 1px solid var(--bg-elevated-dark);
  padding: 12px 20px;
  border-radius: var(--radius-lg);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background-color: var(--bg-elevated-dark);
  color: #ffffff;
}

.field-hint {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
  display: block;
}

.margin-bottom-sm {
  margin-bottom: 12px;
}

.margin-bottom-md {
  margin-bottom: 18px;
}

/* Google Modal Styles */
.google-modal-card {
  border-top: 3px solid #4285F4;
}

.google-modal-header {
  text-align: center;
  margin-bottom: 20px;
}

.google-logo-large {
  margin-bottom: 12px;
}

.google-modal-title {
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 4px;
}

.google-modal-subtitle {
  font-size: 13px;
  color: var(--text-variant);
}

.google-accounts-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.google-account-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  background: var(--bg-container-low);
  border: 1px solid var(--bg-elevated-dark);
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
  text-align: left;
}

.google-account-item:hover {
  background: var(--bg-elevated-dark);
  border-color: #4285F4;
}

.google-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  color: #ffffff;
  flex-shrink: 0;
}

.avatar-blue {
  background: #4285F4;
}

.avatar-purple {
  background: #a855f7;
}

.google-account-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.google-account-name {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
}

.google-account-email {
  font-size: 12px;
  color: var(--text-muted);
}

.check-icon {
  color: var(--text-variant);
  font-size: 20px;
}

.google-custom-account {
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--bg-elevated-dark);
}

.custom-account-label {
  font-size: 12px;
  color: var(--text-variant);
  margin-bottom: 8px;
}

.google-custom-row {
  display: flex;
  gap: 8px;
}

.custom-google-input {
  flex: 1;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
  min-height: auto;
}

