/* ============================================================
   STEINWEG HUB — LIGHT CORPORATE THEME
   C. Steinweg Oman LLC
   ============================================================ */

/* ---- DESIGN TOKENS ---- */
:root {
  --steinweg-teal:      #006B7F;
  --steinweg-dark-navy: #003F59;
  --steinweg-gold:      #D9AA27;
  --background:         #FFFFFF;
  --background-alt:     #F2F6F9;
  --surface:            #FFFFFF;
  --border:             #E2E8F0;
  --border-light:       #EEF2F7;
  --text-primary:       #1E293B;
  --text-secondary:     #5A5C65;
  --text-tertiary:      #94A3B8;
  --success:            #16A34A;
  --success-bg:         #F0FDF4;
  --success-border:     #BBF7D0;
  --warning:            #D97706;
  --warning-bg:         #FFFBEB;
  --danger:             #DC2626;
  --sidebar-width:      240px;
  --topbar-height:      60px;
  --radius:             8px;
  --radius-lg:          12px;
  --radius-xl:          16px;
  --shadow-sm:          0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md:          0 4px 12px rgba(0,0,0,0.08), 0 2px 4px rgba(0,0,0,0.04);
  --shadow-lg:          0 8px 24px rgba(0,0,0,0.10), 0 3px 8px rgba(0,0,0,0.05);
  --transition:         0.18s ease;
}

/* ---- RESET & BASE ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  font-family: "Source Sans 3", sans-serif;
  font-size: 15px;
  color: var(--text-primary);
  background: var(--background);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { text-decoration: none; color: inherit; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input { font-family: inherit; }

/* ============================================================
   PAGE SYSTEM
   ============================================================ */
.page {
  width: 100%;
  height: 100%;
}

/* ============================================================
   LOGIN PAGE
   ============================================================ */
.login-wrapper {
  display: flex;
  height: 100vh;
  min-height: 600px;
}

/* ---- LEFT PANEL ---- */
.login-left {
  position: relative;
  width: 44%;
  min-width: 320px;
  background: linear-gradient(145deg, var(--steinweg-dark-navy) 0%, var(--steinweg-teal) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

.login-left-pattern {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 20% 80%, rgba(255,255,255,0.04) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(255,255,255,0.06) 0%, transparent 50%),
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 40px,
      rgba(255,255,255,0.015) 40px,
      rgba(255,255,255,0.015) 42px
    );
  pointer-events: none;
}

.login-left-inner {
  position: relative;
  z-index: 1;
  padding: 3rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 400px;
}

.login-logo-wrap {
  display: flex;
  align-items: center;
}

.login-logo {
  height: 52px;
  width: auto;
  display: block;
  border-radius: 6px;
  /* Light overlay to help readability on dark gradient */
  filter: brightness(1.1) contrast(1.05);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.login-brand-title {
  font-size: 2.4rem;
  font-weight: 700;
  line-height: 1.12;
  color: #FFFFFF;
  letter-spacing: -0.02em;
}

.login-brand-sub {
  font-size: 0.97rem;
  line-height: 1.65;
  color: rgba(255,255,255,0.72);
  font-weight: 400;
}

.login-location {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: rgba(255,255,255,0.55);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 1.5rem;
}

.login-location-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--steinweg-gold);
  display: inline-block;
  flex-shrink: 0;
}

/* ---- RIGHT PANEL ---- */
.login-right {
  flex: 1;
  background: var(--background);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.login-card {
  width: 100%;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.login-card-header {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.login-heading {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--steinweg-teal);
  letter-spacing: -0.02em;
}

.login-subheading {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.form-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.01em;
}

.form-input {
  height: 44px;
  padding: 0 0.9rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.95rem;
  color: var(--text-primary);
  background: var(--background);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
  width: 100%;
}

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

.form-input:focus {
  border-color: var(--steinweg-teal);
  box-shadow: 0 0 0 3px rgba(0, 107, 127, 0.1);
}

.input-wrap {
  position: relative;
}

.input-wrap .form-input {
  padding-right: 2.8rem;
}

.toggle-pw {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  padding: 0.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--transition);
  cursor: pointer;
  background: none;
  border: none;
}
.toggle-pw:hover { color: var(--steinweg-teal); }

.form-row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
  cursor: pointer;
}

.checkbox-input {
  width: 15px;
  height: 15px;
  accent-color: var(--steinweg-teal);
  cursor: pointer;
}

.forgot-link {
  font-size: 0.875rem;
  color: var(--steinweg-teal);
  font-weight: 500;
  transition: opacity var(--transition);
}
.forgot-link:hover { opacity: 0.75; }

.btn-login {
  height: 46px;
  width: 100%;
  background: var(--steinweg-teal);
  color: #FFFFFF;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
  cursor: pointer;
  border: none;
  letter-spacing: 0.01em;
}
.btn-login:hover {
  background: var(--steinweg-dark-navy);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}
.btn-login:active { transform: translateY(0); }

.btn-login.loading {
  opacity: 0.8;
  pointer-events: none;
}

.btn-login.loading::after {
  content: '';
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  margin-left: 0.4rem;
}

.login-footer {
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-tertiary);
  border-top: 1px solid var(--border);
  padding-top: 1.25rem;
}

/* ============================================================
   APP SHELL — DASHBOARD
   ============================================================ */
.app-shell {
  display: flex;
  height: 100vh;
  background: var(--background-alt);
}

/* ---- SIDEBAR ---- */
.sidebar {
  width: var(--sidebar-width);
  background: var(--steinweg-dark-navy);
  color: #fff;
  border-right: none;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  height: 100%;
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 10;
}

.sidebar-top {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
}

.sidebar-logo-wrap {
  padding: 1.1rem 1.25rem 0.75rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 0.6rem;
}

.sidebar-logo {
  height: 45px;
  width: auto;
  display: block;
  border-radius: 4px;
}

.sidebar-nav {
  padding: 0.25rem 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  color: rgba(255,255,255,0.7);
  transition: background var(--transition), color var(--transition);
  cursor: pointer;
  position: relative;
}

.nav-item:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
}

.nav-item.active {
  background: rgba(255,255,255,0.12);
  color: #fff;
  font-weight: 600;
}

.nav-item.active .nav-icon {
  color: #fff;
}

.nav-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 20px;
  color: rgba(255,255,255,0.5);
  transition: color var(--transition);
}

.nav-item.active .nav-icon svg { stroke: #fff; }
.nav-item:hover .nav-icon svg { stroke: #fff; }

.sidebar-bottom {
  padding: 1rem 1.25rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.system-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-dot.online {
  background: var(--success);
  box-shadow: 0 0 0 2px rgba(22, 163, 74, 0.2);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 2px rgba(22, 163, 74, 0.2); }
  50%       { box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.12); }
}

.status-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #4ade80;
}

.sidebar-company {
  font-size: 0.73rem;
  color: rgba(255,255,255,0.5);
  font-weight: 500;
}

/* ---- MAIN AREA ---- */
.main-area {
  margin-left: var(--sidebar-width);
  display: flex;
  flex-direction: column;
  height: 100vh;
  flex: 1;
  overflow: hidden;
}

/* ---- TOPBAR ---- */
.topbar {
  height: var(--topbar-height);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.75rem;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  z-index: 5;
}

.topbar-left {}

.topbar-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--steinweg-teal);
  letter-spacing: -0.01em;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.icon-btn {
  position: relative;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: background var(--transition), color var(--transition);
  cursor: pointer;
}
.icon-btn:hover {
  background: var(--background-alt);
  color: var(--text-primary);
}

.notif-badge {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 16px;
  height: 16px;
  background: var(--danger);
  color: #fff;
  font-size: 0.6rem;
  font-weight: 700;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.3rem 0.75rem 0.3rem 0.4rem;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--background);
  cursor: pointer;
  transition: border-color var(--transition);
  margin-left: 0.25rem;
}
.user-chip:hover { border-color: var(--steinweg-teal); }

.avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--steinweg-teal), var(--steinweg-dark-navy));
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}

.user-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.logout-btn {
  color: var(--text-tertiary);
}
.logout-btn:hover { color: var(--danger); }

/* ---- CONTENT ---- */
.content {
  flex: 1;
  overflow-y: auto;
  padding: 1.75rem 2rem 2.5rem;
  background: var(--background-alt);
}

/* ---- CONTENT HEADER ---- */
.content-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1.75rem;
  gap: 1rem;
}

.welcome-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.welcome-date {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-top: 0.2rem;
}

.header-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--success-bg);
  border: 1px solid var(--success-border);
  color: var(--success);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.4rem 0.85rem;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  flex-shrink: 0;
  animation: pulse-dot 2s ease-in-out infinite;
}

/* ---- KPI GRID ---- */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}

.kpi-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.35rem;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid transparent;
  transition: box-shadow var(--transition), transform var(--transition);
  position: relative;
  overflow: hidden;
}

.kpi-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  opacity: 0;
  transition: opacity var(--transition);
}

.kpi-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.kpi-teal   { border-left-color: var(--steinweg-teal); }
.kpi-gold   { border-left-color: var(--steinweg-gold); }
.kpi-navy   { border-left-color: var(--steinweg-dark-navy); }
.kpi-success { border-left-color: var(--success); }

.kpi-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-tertiary);
  margin-bottom: 0.4rem;
}

.kpi-value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 0.5rem;
}

.kpi-trend {
  font-size: 0.78rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  color: var(--text-tertiary);
}

.kpi-trend.up   { color: var(--success); }
.kpi-trend.down { color: var(--warning); }

/* ---- SECTION HEADERS ---- */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.section-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--steinweg-teal);
  letter-spacing: -0.01em;
}

.section-count {
  font-size: 0.8rem;
  color: var(--text-tertiary);
  background: var(--background-alt);
  border: 1px solid var(--border);
  padding: 0.2rem 0.65rem;
  border-radius: 12px;
}

.view-all-btn {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--steinweg-teal);
  cursor: pointer;
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
  transition: background var(--transition);
}
.view-all-btn:hover { background: #E8F4F6; }

/* ---- APPS GRID ---- */
.apps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.app-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.35rem 1.1rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
}

.app-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
  border-color: rgba(0, 107, 127, 0.2);
}

.app-card-top {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
}

.app-icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.icon-teal {
  background: rgba(0, 107, 127, 0.1);
  color: var(--steinweg-teal);
}
.icon-teal svg { stroke: var(--steinweg-teal); }

.app-title-wrap {
  flex: 1;
  min-width: 0;
}

.app-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
  margin-bottom: 0.15rem;
}

.app-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.app-status-badge {
  flex-shrink: 0;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.app-status-badge.online {
  background: var(--success-bg);
  color: var(--success);
  border: 1px solid var(--success-border);
}

.app-status-badge.warning {
  background: var(--warning-bg);
  color: var(--warning);
  border: 1px solid #FDE68A;
}

.app-stats {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem 0;
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.app-stat {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.stat-val {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stat-lbl {
  font-size: 0.71rem;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 500;
}

.btn-open {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: 100%;
  height: 34px;
  background: transparent;
  border: 1.5px solid var(--steinweg-teal);
  color: var(--steinweg-teal);
  border-radius: var(--radius);
  font-size: 0.84rem;
  font-weight: 600;
  transition: background var(--transition), color var(--transition);
  cursor: pointer;
}

.btn-open:hover {
  background: var(--steinweg-teal);
  color: #fff;
}

.btn-open svg { transition: transform var(--transition); }
.btn-open:hover svg { transform: translateX(2px); }

/* ---- ACTIVITY CARD ---- */
.activity-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.activity-list {
  display: flex;
  flex-direction: column;
}

.activity-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem 1.35rem;
  border-bottom: 1px solid var(--border-light);
  transition: background var(--transition);
}

.activity-item:last-child { border-bottom: none; }
.activity-item:hover { background: var(--background-alt); }

.activity-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}

.act-teal   { background: rgba(0,107,127,0.1); color: var(--steinweg-teal); }
.act-teal   svg { stroke: var(--steinweg-teal); }
.act-gold   { background: rgba(217,170,39,0.12); color: var(--steinweg-gold); }
.act-gold   svg { stroke: var(--steinweg-gold); }
.act-navy   { background: rgba(0,63,89,0.1); color: var(--steinweg-dark-navy); }
.act-navy   svg { stroke: var(--steinweg-dark-navy); }
.act-success { background: var(--success-bg); color: var(--success); }
.act-success svg { stroke: var(--success); }

.activity-body {
  flex: 1;
  min-width: 0;
}

.activity-text {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0.3rem;
}

.activity-text strong {
  color: var(--text-primary);
  font-weight: 600;
}

.activity-time {
  font-size: 0.76rem;
  color: var(--steinweg-teal);
  font-weight: 600;
  letter-spacing: 0.01em;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.animate-in {
  animation: fadeInUp 0.35s ease both;
}

/* Staggered children */
.kpi-grid .kpi-card:nth-child(1) { animation: fadeInUp 0.3s 0.05s ease both; }
.kpi-grid .kpi-card:nth-child(2) { animation: fadeInUp 0.3s 0.10s ease both; }
.kpi-grid .kpi-card:nth-child(3) { animation: fadeInUp 0.3s 0.15s ease both; }
.kpi-grid .kpi-card:nth-child(4) { animation: fadeInUp 0.3s 0.20s ease both; }

.apps-grid .app-card:nth-child(1) { animation: fadeInUp 0.3s 0.10s ease both; }
.apps-grid .app-card:nth-child(2) { animation: fadeInUp 0.3s 0.15s ease both; }
.apps-grid .app-card:nth-child(3) { animation: fadeInUp 0.3s 0.20s ease both; }
.apps-grid .app-card:nth-child(4) { animation: fadeInUp 0.3s 0.25s ease both; }
.apps-grid .app-card:nth-child(5) { animation: fadeInUp 0.3s 0.30s ease both; }
.apps-grid .app-card:nth-child(6) { animation: fadeInUp 0.3s 0.35s ease both; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1200px) {
  .apps-grid { grid-template-columns: repeat(2, 1fr); }
  .kpi-grid  { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .login-left { display: none; }
  .apps-grid  { grid-template-columns: 1fr; }
  .sidebar { width: 200px; }
  .main-area { margin-left: 200px; }
}

/* ============================================================
   NOTIFICATION DROPDOWN
   ============================================================ */
.notif-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 380px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.12), 0 4px 12px rgba(0,0,0,0.06);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
}
.notif-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.notif-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--text-primary);
}
.notif-mark-read {
  background: none;
  border: none;
  color: var(--steinweg-teal);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background 0.15s;
}
.notif-mark-read:hover {
  background: var(--background-alt);
}
.notif-list {
  max-height: 320px;
  overflow-y: auto;
}
.notif-item {
  display: flex;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-light);
  transition: background 0.15s;
  cursor: pointer;
}
.notif-item:hover {
  background: var(--background-alt);
}
.notif-item:last-child {
  border-bottom: none;
}
.notif-item.unread {
  background: #F8FCFF;
}
.notif-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  margin-top: 6px;
  flex-shrink: 0;
}
.notif-item.unread .notif-dot {
  background: var(--steinweg-teal);
}
.notif-content {
  flex: 1;
  min-width: 0;
}
.notif-text {
  font-size: 0.82rem;
  color: var(--text-primary);
  line-height: 1.45;
  margin: 0;
}
.notif-text strong {
  color: var(--steinweg-teal);
}
.notif-time {
  font-size: 0.72rem;
  color: var(--text-tertiary);
  margin-top: 4px;
  display: block;
}
.notif-footer {
  border-top: 1px solid var(--border);
  padding: 10px 18px;
  text-align: center;
}
.notif-view-all {
  background: none;
  border: none;
  color: var(--steinweg-teal);
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background 0.15s;
}
.notif-view-all:hover {
  background: var(--background-alt);
}

/* ============================================================
   TOAST NOTIFICATIONS
   ============================================================ */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.12);
  z-index: 10000;
  font-size: 0.88rem;
  color: var(--text-primary);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.3s, transform 0.3s;
  font-family: 'Source Sans 3', sans-serif;
}
.toast.show {
  opacity: 1;
  transform: translateY(0);
}
.toast-info {
  border-left: 4px solid var(--steinweg-teal);
}
.toast-info svg {
  color: var(--steinweg-teal);
}
.toast-success {
  border-left: 4px solid var(--success);
}
.toast-success svg {
  color: var(--success);
}
.toast-warning {
  border-left: 4px solid var(--steinweg-gold);
}

/* ============================================================
   SIDEBAR SECTIONS (users, settings, apps pages)
   ============================================================ */
.dashboard-section { animation: fadeIn 0.2s ease; }

/* Users section */
.users-section,
.settings-section,
.apps-section {
  padding: 0;
}
.section-empty {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--text-secondary);
}
.section-empty-icon {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: var(--background-alt);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  color: var(--text-tertiary);
}
.section-empty h3 {
  color: var(--text-primary);
  font-size: 1.1rem;
  margin: 0 0 0.5rem;
}
.section-empty p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  max-width: 400px;
  margin: 0 auto;
}

/* ============================================================
   APP CARD CLICK STATES
   ============================================================ */
.app-card {
  transition: transform 0.15s, box-shadow 0.15s;
}
.app-card:active {
  transform: scale(0.98);
}
