/* ==========================================================================
   İDÜ CAMPUS — Kişisel Hesap ve Bulut Arayüz Stilleri (account.css)
   ========================================================================== */

/* 1. Sol Kenar Çubuğu (Sidebar) & Çekmece Hesap Butonu */
.flow-sidebar-account {
  margin-top: auto;
  padding: 0.75rem 0.5rem 0.5rem;
  border-top: 1px solid var(--line, rgba(255, 255, 255, 0.08));
}

.flow-account-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 0.6rem;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 12px;
  color: var(--text, #f1f5f9);
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  transition: all 0.15s ease;
}

.flow-account-btn:hover,
.flow-account-btn:focus-visible {
  background: var(--soft, rgba(255, 255, 255, 0.05));
  border-color: var(--line, rgba(255, 255, 255, 0.1));
}

.flow-account-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #06b6d4);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  border: 2px solid var(--surface, #1e293b);
  overflow: hidden;
}

.flow-account-avatar.is-guest {
  background: var(--line, #334155);
  color: var(--muted, #94a3b8);
}

.flow-account-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.flow-account-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.flow-account-text strong {
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text, #f1f5f9);
}

.flow-account-text small {
  font-size: 0.72rem;
  color: var(--muted, #94a3b8);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.2s ease;
}

.flow-account-text small[data-sync-state="synced"] {
  color: #10b981;
}

.flow-account-text small[data-sync-state="syncing"] {
  color: #38bdf8;
}

.flow-account-text small[data-sync-state="offline"] {
  color: #f59e0b;
}

.flow-account-badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.6);
  flex-shrink: 0;
}

/* Mobil Çekmece Hesap Alanı */
.drawer-account-box {
  padding: 0.85rem 1rem;
  background: var(--soft, rgba(255, 255, 255, 0.04));
  border-bottom: 1px solid var(--line, rgba(255, 255, 255, 0.08));
}

.drawer-account-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: transparent;
  border: none;
  padding: 0;
  color: inherit;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
}

/* 2. Hesap Diyaloğu (#user-profile-dialog) */
.user-profile-dialog {
  width: 100%;
  max-width: 480px;
  border-radius: 18px;
  padding: 0;
  border: 1px solid var(--line, rgba(255, 255, 255, 0.12));
  background: var(--surface, #1e293b);
  color: var(--text, #f1f5f9);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
  overflow: hidden;
}

.user-profile-dialog::backdrop {
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(4px);
}

.profile-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 1.25rem 1rem;
  border-bottom: 1px solid var(--line, rgba(255, 255, 255, 0.08));
}

.profile-modal-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0;
}

.profile-modal-body {
  padding: 1.25rem;
  max-height: 80vh;
  overflow-y: auto;
}

/* 3. Giriş / Kayıt Geçiş Sekmeleri (Tab Switcher) */
.account-auth-nav {
  display: flex;
  gap: 0.4rem;
  background: var(--soft, rgba(255, 255, 255, 0.05));
  padding: 0.3rem;
  border-radius: 10px;
  margin-bottom: 1.25rem;
}

.account-auth-tab-btn {
  flex: 1;
  padding: 0.55rem;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--muted, #94a3b8);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.account-auth-tab-btn.is-active {
  background: var(--surface, #1e293b);
  color: var(--text, #f1f5f9);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* 4. Formlar ve Giriş Elemanları */
.account-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.account-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.account-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text, #f1f5f9);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.account-input {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border-radius: 10px;
  border: 1px solid var(--line, rgba(255, 255, 255, 0.14));
  background: var(--soft, rgba(255, 255, 255, 0.04));
  color: var(--text, #f1f5f9);
  font-size: 0.92rem;
  font-family: inherit;
  transition: border-color 0.15s ease;
  box-sizing: border-box;
}

.account-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.account-input.is-pin {
  letter-spacing: 0.35em;
  font-size: 1.3rem;
  text-align: center;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.account-hint {
  font-size: 0.73rem;
  color: var(--muted, #94a3b8);
  margin-top: 0.15rem;
  line-height: 1.35;
}

/* Avatar Seçici Grid */
.avatar-selector-grid {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.25rem;
}

.avatar-choice-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid transparent;
  background: var(--soft, rgba(255, 255, 255, 0.05));
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.avatar-choice-btn:hover {
  transform: scale(1.08);
  background: rgba(59, 130, 246, 0.15);
}

.avatar-choice-btn.is-selected {
  border-color: #3b82f6;
  background: rgba(59, 130, 246, 0.2);
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.4);
}

/* 5. Butonlar */
.account-submit-btn {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  border: none;
  background: #3b82f6;
  color: #fff;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
  margin-top: 0.4rem;
}

.account-submit-btn:hover {
  background: #2563eb;
}

.account-submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* 6. Dashboard (Giriş Yapılmış Görünüm) */
.account-dashboard-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem;
  background: var(--soft, rgba(255, 255, 255, 0.04));
  border: 1px solid var(--line, rgba(255, 255, 255, 0.08));
  border-radius: 14px;
  margin-bottom: 1.2rem;
}

.account-dash-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #06b6d4);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.7rem;
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  border: 2px solid var(--surface, #1e293b);
  overflow: hidden;
}

.account-dash-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.account-dash-info {
  flex: 1;
  min-width: 0;
}

.account-dash-name-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.account-dash-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text, #f1f5f9);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.account-edit-name-btn {
  background: transparent;
  border: none;
  color: var(--muted, #94a3b8);
  cursor: pointer;
  font-size: 0.85rem;
  padding: 2px 4px;
  border-radius: 4px;
}

.account-edit-name-btn:hover {
  color: #3b82f6;
  background: rgba(59, 130, 246, 0.1);
}

.account-dash-handle {
  font-size: 0.82rem;
  color: var(--muted, #94a3b8);
  font-family: monospace;
}

/* Bilgi Kutucukları (Kullanıcı Adı & PIN Kartları) */
.account-detail-box {
  background: var(--soft, rgba(255, 255, 255, 0.03));
  border: 1px solid var(--line, rgba(255, 255, 255, 0.08));
  border-radius: 12px;
  padding: 0.9rem 1rem;
  margin-bottom: 0.85rem;
}

.account-detail-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.35rem;
}

.account-detail-title {
  font-size: 0.76rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted, #94a3b8);
}

.account-detail-action-btn {
  background: transparent;
  border: none;
  color: #3b82f6;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: inherit;
}

.account-detail-action-btn:hover {
  background: rgba(59, 130, 246, 0.12);
}

.account-detail-action-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.account-detail-val-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.account-detail-val {
  font-size: 1.15rem;
  font-weight: 700;
  font-family: monospace;
  color: var(--text, #f1f5f9);
}

.account-detail-meta {
  font-size: 0.74rem;
  color: var(--muted, #94a3b8);
  margin-top: 0.3rem;
}

/* 7. Bildirim & Durum Kutuları */
.account-notice {
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  font-size: 0.82rem;
  margin-top: 0.85rem;
  line-height: 1.4;
}

.account-notice.is-info {
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.25);
  color: #93c5fd;
}

.account-notice.is-success {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: #6ee7b7;
}

.account-notice.is-error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #fca5a5;
}

/* 8. Çıkış & Tehlike Bölgesi */
.account-actions-row {
  display: flex;
  gap: 0.6rem;
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line, rgba(255, 255, 255, 0.08));
}

.account-secondary-btn {
  flex: 1;
  padding: 0.65rem;
  border-radius: 10px;
  border: 1px solid var(--line, rgba(255, 255, 255, 0.14));
  background: var(--soft, rgba(255, 255, 255, 0.04));
  color: var(--text, #f1f5f9);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
}

.account-secondary-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.account-danger-btn {
  padding: 0.65rem 0.85rem;
  border-radius: 10px;
  border: 1px solid rgba(239, 68, 68, 0.25);
  background: rgba(239, 68, 68, 0.06);
  color: #fca5a5;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
}

.account-danger-btn:hover {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
}

/* 9. Yoklama Takip Başlığındaki Minik Hesap Rozeti */
.attendance-account-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  background: var(--soft, rgba(255, 255, 255, 0.06));
  border: 1px solid var(--line, rgba(255, 255, 255, 0.1));
  font-size: 0.78rem;
  color: var(--muted, #94a3b8);
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
}

.attendance-account-pill:hover {
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.3);
  color: #93c5fd;
}

.attendance-account-pill.is-active {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.3);
  color: #6ee7b7;
}

/* Açık Tema Düzeltmeleri */
[data-theme="light"] .user-profile-dialog {
  background: #ffffff;
  color: #0f172a;
  border-color: #e2e8f0;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .flow-account-text strong,
[data-theme="light"] .account-dash-name,
[data-theme="light"] .account-detail-val {
  color: #0f172a;
}

[data-theme="light"] .account-input {
  background: #f8fafc;
  color: #0f172a;
  border-color: #cbd5e1;
}

[data-theme="light"] .account-dashboard-card,
[data-theme="light"] .account-detail-box {
  background: #f8fafc;
  border-color: #e2e8f0;
}

/* 10. Eski 16 Haneli Kod Geçiş Köprüsü */
.account-legacy-bridge {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--line, rgba(255, 255, 255, 0.12));
}

.account-legacy-details {
  border-radius: 10px;
  background: var(--soft, rgba(255, 255, 255, 0.03));
  border: 1px solid var(--line, rgba(255, 255, 255, 0.08));
  overflow: hidden;
  transition: all 0.2s ease;
}

.account-legacy-details[open] {
  background: var(--soft, rgba(255, 255, 255, 0.05));
  border-color: rgba(59, 130, 246, 0.3);
}

.account-legacy-summary {
  padding: 0.65rem 0.85rem;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--muted, #94a3b8);
  cursor: pointer;
  user-select: none;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  outline: none;
}

.account-legacy-summary:hover {
  color: #93c5fd;
}

.account-legacy-content {
  padding: 0.5rem 0.85rem 0.85rem;
  border-top: 1px solid var(--line, rgba(255, 255, 255, 0.06));
}

.account-legacy-hint {
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--muted, #94a3b8);
  margin: 0 0 0.65rem 0;
}

.account-legacy-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.account-legacy-row .account-input {
  flex: 1;
  font-family: monospace;
  font-size: 0.82rem;
  letter-spacing: 0.5px;
}

[data-theme="light"] .account-legacy-bridge {
  border-top-color: #e2e8f0;
}

[data-theme="light"] .account-legacy-details {
  background: #f8fafc;
  border-color: #e2e8f0;
}

[data-theme="light"] .account-legacy-summary {
  color: #64748b;
}

[data-theme="light"] .account-legacy-summary:hover {
  color: #2563eb;
}

[data-theme="light"] .account-legacy-hint {
  color: #64748b;
}
