/* ==========================================================================
   YKS Tercih — Modern UI Design System
   Prefix: --m-  (avoids collision with site.css --brand etc.)
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. DESIGN TOKENS — Light mode
   -------------------------------------------------------------------------- */
:root {
  /* Brand */
  --m-brand:        #4f46e5;
  --m-brand-hover:  #4338ca;
  --m-brand-active: #3730a3;
  --m-brand-soft:   #eef2ff;
  --m-brand-border: #c7d2fe;

  /* Accent (violet gradient partner) */
  --m-accent: #7c3aed;

  /* Surfaces */
  --m-bg:              #f8fafc;
  --m-bg-subtle:       #f1f5f9;
  --m-surface:         #ffffff;
  --m-surface-raised:  #ffffff;
  --m-surface-overlay: rgba(255, 255, 255, 0.92);

  /* Text */
  --m-text:          #0f172a;
  --m-text-2:        #334155;
  --m-text-muted:    #64748b;
  --m-text-faint:    #94a3b8;
  --m-text-inverse:  #ffffff;

  /* Borders */
  --m-border:        #e2e8f0;
  --m-border-strong: #cbd5e1;

  /* Semantic — success */
  --m-success:        #16a34a;
  --m-success-bg:     #f0fdf4;
  --m-success-border: #bbf7d0;
  --m-success-text:   #166534;

  /* Semantic — warning */
  --m-warning:        #d97706;
  --m-warning-bg:     #fffbeb;
  --m-warning-border: #fde68a;
  --m-warning-text:   #92400e;

  /* Semantic — danger */
  --m-danger:        #dc2626;
  --m-danger-bg:     #fef2f2;
  --m-danger-border: #fecaca;
  --m-danger-text:   #991b1b;

  /* Semantic — info */
  --m-info:        #0284c7;
  --m-info-bg:     #f0f9ff;
  --m-info-border: #bae6fd;
  --m-info-text:   #075985;

  /* Radius */
  --m-r-xs:   4px;
  --m-r-sm:   6px;
  --m-r:      10px;
  --m-r-lg:   14px;
  --m-r-xl:   20px;
  --m-r-full: 9999px;

  /* Shadows */
  --m-shadow-xs: 0 1px 2px rgba(15, 23, 42, .04);
  --m-shadow-sm: 0 1px 3px rgba(15, 23, 42, .06), 0 1px 2px rgba(15, 23, 42, .04);
  --m-shadow:    0 4px 6px rgba(15, 23, 42, .05), 0 2px 4px rgba(15, 23, 42, .03);
  --m-shadow-md: 0 10px 15px rgba(15, 23, 42, .07), 0 4px 6px rgba(15, 23, 42, .04);
  --m-shadow-lg: 0 20px 25px rgba(15, 23, 42, .10), 0 8px 10px rgba(15, 23, 42, .06);
  --m-shadow-brand: 0 4px 14px rgba(79, 70, 229, .28);

  /* Z-index layers */
  --m-z-below:   -1;
  --m-z-base:     0;
  --m-z-raised:  10;
  --m-z-dropdown: 1000;
  --m-z-sticky:   1020;
  --m-z-navbar:   1030;
  --m-z-modal:    1050;
  --m-z-toast:    1090;

  /* Spacing (multiples of 4px) */
  --m-sp-1: 0.25rem;
  --m-sp-2: 0.5rem;
  --m-sp-3: 0.75rem;
  --m-sp-4: 1rem;
  --m-sp-5: 1.25rem;
  --m-sp-6: 1.5rem;
  --m-sp-8: 2rem;
  --m-sp-10: 2.5rem;
  --m-sp-12: 3rem;

  /* Typography */
  --m-font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --m-font-mono: ui-monospace, "JetBrains Mono", "Fira Code", monospace;
  --m-font-size: 15px;

  /* Transitions */
  --m-ease: 150ms ease;
  --m-ease-md: 250ms ease;
  --m-ease-lg: 350ms cubic-bezier(0.4, 0, 0.2, 1);

  /* Navbar height */
  --m-navbar-h: 56px;
}

/* --------------------------------------------------------------------------
   2. DARK MODE TOKENS
   -------------------------------------------------------------------------- */
[data-theme="dark"] {
  --m-bg:              #0f172a;
  --m-bg-subtle:       #1e293b;
  --m-surface:         #1e293b;
  --m-surface-raised:  #263348;
  --m-surface-overlay: rgba(15, 23, 42, 0.94);

  --m-text:       #f1f5f9;
  --m-text-2:     #cbd5e1;
  --m-text-muted: #64748b;
  --m-text-faint: #475569;

  --m-border:        #334155;
  --m-border-strong: #475569;

  --m-brand-soft:   #1e1b4b;
  --m-brand-border: #3730a3;

  --m-success-bg:     #052e16;
  --m-warning-bg:     #1c1400;
  --m-danger-bg:      #1f0808;
  --m-info-bg:        #0c1e2e;

  --m-shadow-xs: 0 1px 2px rgba(0, 0, 0, .25);
  --m-shadow-sm: 0 1px 3px rgba(0, 0, 0, .35), 0 1px 2px rgba(0, 0, 0, .25);
  --m-shadow:    0 4px 6px rgba(0, 0, 0, .30), 0 2px 4px rgba(0, 0, 0, .20);
  --m-shadow-md: 0 10px 15px rgba(0, 0, 0, .35), 0 4px 6px rgba(0, 0, 0, .25);
  --m-shadow-lg: 0 20px 25px rgba(0, 0, 0, .45), 0 8px 10px rgba(0, 0, 0, .30);
}

/* --------------------------------------------------------------------------
   3. BASE
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  font-size: var(--m-font-size);
  overflow-x: hidden;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body.m-body {
  font-family: var(--m-font);
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--m-text);
  background: var(--m-bg);
  -webkit-font-smoothing: antialiased;
  margin: 0;
  display: flex;
  flex-direction: column;
  min-height: 100svh;
}

/* Scrollbar (Chromium) */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--m-border-strong); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--m-text-faint); }

/* --------------------------------------------------------------------------
   4. SKIP LINK
   -------------------------------------------------------------------------- */
.m-skip-link {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  z-index: calc(var(--m-z-toast) + 10);
  padding: 0.4rem 0.8rem;
  background: var(--m-surface);
  border: 2px solid var(--m-brand);
  border-radius: var(--m-r);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--m-brand);
  text-decoration: none;
  transform: translateY(-200%);
  transition: transform var(--m-ease);
}
.m-skip-link:focus { transform: translateY(0); }

/* --------------------------------------------------------------------------
   5. PROGRESS BAR (page navigation indicator)
   -------------------------------------------------------------------------- */
.m-progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2px;
  z-index: calc(var(--m-z-navbar) + 5);
  pointer-events: none;
  opacity: 0;
  transition: opacity 200ms;
}
.m-progress.is-running { opacity: 1; }
.m-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--m-brand), var(--m-accent));
  transition: width var(--m-ease-lg);
  border-radius: 0 2px 2px 0;
  box-shadow: 0 0 8px rgba(79, 70, 229, .5);
}

/* --------------------------------------------------------------------------
   6. NAVBAR
   -------------------------------------------------------------------------- */
.m-header {
  position: sticky;
  top: 0;
  z-index: var(--m-z-navbar);
  flex: 0 0 auto;
}

.m-navbar {
  height: var(--m-navbar-h);
  background: var(--m-surface-overlay);
  backdrop-filter: blur(12px) saturate(160%);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  border-bottom: 1px solid var(--m-border);
  box-shadow: var(--m-shadow-xs);
}

.m-navbar-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  height: 100%;
  gap: 0.5rem;
}

/* Brand */
.m-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--m-text);
  flex-shrink: 0;
  letter-spacing: -0.01em;
}
.m-brand:hover { color: var(--m-brand); text-decoration: none; }

.m-brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--m-brand), var(--m-accent));
  color: var(--m-text-inverse);
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 0.82rem;
  flex-shrink: 0;
  box-shadow: var(--m-shadow-brand);
}
.m-brand-mark--sm { width: 24px; height: 24px; font-size: 0.72rem; border-radius: 6px; }

/* Nav list */
.m-nav-list {
  list-style: none;
  margin: 0 0 0 1.25rem;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 0.125rem;
}

.m-nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.72rem;
  border-radius: var(--m-r-sm);
  font-size: 0.84rem;
  font-weight: 550;
  color: var(--m-text-muted);
  text-decoration: none;
  transition: color var(--m-ease), background var(--m-ease);
  white-space: nowrap;
  position: relative;
}
.m-nav-link:hover { color: var(--m-text); background: var(--m-bg-subtle); text-decoration: none; }
.m-nav-link.active { color: var(--m-brand); background: var(--m-brand-soft); }

/* Right-side actions */
.m-nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

/* Icon button */
.m-icon-btn {
  width: 34px;
  height: 34px;
  border-radius: var(--m-r-sm);
  border: 1px solid var(--m-border);
  background: transparent;
  color: var(--m-text-muted);
  display: grid;
  place-items: center;
  cursor: pointer;
  padding: 0;
  transition: color var(--m-ease), background var(--m-ease), border-color var(--m-ease);
  flex-shrink: 0;
}
.m-icon-btn:hover { color: var(--m-text); background: var(--m-bg-subtle); border-color: var(--m-border-strong); }
.m-icon-btn:focus-visible {
  outline: 2px solid var(--m-brand);
  outline-offset: 1px;
  border-color: transparent;
}
.m-icon-btn svg { pointer-events: none; }

/* Badge (notification count) */
.m-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: var(--m-r-full);
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1;
}
.m-badge--brand { background: var(--m-brand); color: var(--m-text-inverse); }
.m-badge--muted { background: var(--m-bg-subtle); color: var(--m-text-muted); border: 1px solid var(--m-border); }
.m-badge[data-count="0"] { display: none; }

/* Mobile nav */
.m-mobile-nav {
  display: none;
  padding: 0.5rem 1rem 0.75rem;
  border-top: 1px solid var(--m-border);
  background: var(--m-surface-overlay);
  backdrop-filter: blur(12px);
}
.m-mobile-nav.is-open { display: block; }
.m-mobile-nav .m-nav-list { flex-direction: column; align-items: stretch; margin: 0; gap: 0.25rem; }
.m-mobile-nav .m-nav-link { padding: 0.55rem 0.75rem; }

/* --------------------------------------------------------------------------
   7. PAGE LAYOUT
   -------------------------------------------------------------------------- */
.m-page {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
}

.m-main {
  flex: 1 0 auto;
  padding: 1.5rem 0 3rem;
}

.m-shell {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
}

/* --------------------------------------------------------------------------
   8. FOOTER
   -------------------------------------------------------------------------- */
.m-footer {
  flex: 0 0 auto;
  border-top: 1px solid var(--m-border);
  background: var(--m-surface);
}

.m-footer-grid {
  max-width: 1400px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 1.5rem;
  display: grid;
  grid-template-columns: 2fr 1fr 1.5fr;
  gap: 2.5rem;
}

.m-footer-brand-name {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--m-text);
  margin-bottom: 0.5rem;
}

.m-footer-tagline {
  font-size: 0.82rem;
  color: var(--m-text-muted);
  line-height: 1.5;
  margin: 0 0 1rem;
  max-width: 26rem;
}

.m-footer-col h3 {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--m-text-muted);
  margin: 0 0 0.75rem;
}

.m-footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.m-footer-col a {
  font-size: 0.83rem;
  color: var(--m-text-2);
  text-decoration: none;
  transition: color var(--m-ease);
}
.m-footer-col a:hover { color: var(--m-brand); }

.m-footer-bottom {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--m-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.76rem;
  color: var(--m-text-faint);
}

.m-footer-bottom a { color: var(--m-text-faint); text-decoration: none; }
.m-footer-bottom a:hover { color: var(--m-text-muted); }

/* --------------------------------------------------------------------------
   9. TOAST NOTIFICATIONS
   -------------------------------------------------------------------------- */
.m-toast-region {
  position: fixed;
  top: calc(var(--m-navbar-h) + 0.75rem);
  right: 1rem;
  z-index: var(--m-z-toast);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: min(360px, calc(100vw - 2rem));
  pointer-events: none;
}

.m-toast {
  background: var(--m-surface);
  border: 1px solid var(--m-border);
  border-radius: var(--m-r-lg);
  box-shadow: var(--m-shadow-md);
  padding: 0.75rem 1rem 0.75rem 0.9rem;
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  pointer-events: all;
  position: relative;
  overflow: hidden;
  animation: mToastIn var(--m-ease-md) both;
}

/* Left accent stripe */
.m-toast::after {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
}
.m-toast--success::after { background: var(--m-success); }
.m-toast--error::after   { background: var(--m-danger);  }
.m-toast--warning::after { background: var(--m-warning); }
.m-toast--info::after    { background: var(--m-brand);   }

.m-toast__icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: 1px;
}
.m-toast--success .m-toast__icon { color: var(--m-success); }
.m-toast--error   .m-toast__icon { color: var(--m-danger);  }
.m-toast--warning .m-toast__icon { color: var(--m-warning); }
.m-toast--info    .m-toast__icon { color: var(--m-brand);   }

.m-toast__body { flex: 1; min-width: 0; }
.m-toast__title {
  font-size: 0.82rem;
  font-weight: 650;
  color: var(--m-text);
  margin: 0 0 0.1rem;
  line-height: 1.3;
}
.m-toast__msg {
  font-size: 0.78rem;
  color: var(--m-text-muted);
  margin: 0;
  line-height: 1.4;
}

.m-toast__close {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border: none;
  background: transparent;
  color: var(--m-text-faint);
  cursor: pointer;
  display: grid;
  place-items: center;
  border-radius: var(--m-r-sm);
  padding: 0;
  transition: color var(--m-ease), background var(--m-ease);
  margin: -2px -4px 0 0;
}
.m-toast__close:hover { color: var(--m-text); background: var(--m-bg-subtle); }

.m-toast.is-leaving { animation: mToastOut var(--m-ease-md) forwards; }

@keyframes mToastIn {
  from { opacity: 0; transform: translateX(20px) scale(0.96); }
  to   { opacity: 1; transform: translateX(0)    scale(1); }
}
@keyframes mToastOut {
  from { opacity: 1; transform: translateX(0);    max-height: 120px; margin-bottom: 0; }
  to   { opacity: 0; transform: translateX(20px); max-height: 0;     margin-bottom: -0.5rem; }
}

/* --------------------------------------------------------------------------
   10. CARD / PANEL
   -------------------------------------------------------------------------- */
.m-card {
  background: var(--m-surface);
  border: 1px solid var(--m-border);
  border-radius: var(--m-r-lg);
  box-shadow: var(--m-shadow-sm);
  padding: 1.25rem;
}

.m-card--raised { box-shadow: var(--m-shadow); }
.m-card--flat   { box-shadow: none; }

.m-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  gap: 0.75rem;
}

.m-card-title {
  font-size: 0.9rem;
  font-weight: 650;
  color: var(--m-text);
  margin: 0;
}

/* --------------------------------------------------------------------------
   11. CHIP / FILTER TAG
   -------------------------------------------------------------------------- */
.m-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.28rem 0.6rem;
  border-radius: var(--m-r-full);
  font-size: 0.75rem;
  font-weight: 550;
  border: 1px solid var(--m-border);
  background: var(--m-surface);
  color: var(--m-text-2);
  white-space: nowrap;
  transition: border-color var(--m-ease), background var(--m-ease);
}

.m-chip--active {
  background: var(--m-brand-soft);
  border-color: var(--m-brand-border);
  color: var(--m-brand);
}

.m-chip__remove {
  width: 14px; height: 14px;
  border: none; background: none; padding: 0;
  display: grid; place-items: center;
  color: inherit; opacity: 0.7; cursor: pointer;
  border-radius: 50%;
  transition: opacity var(--m-ease), background var(--m-ease);
}
.m-chip__remove:hover { opacity: 1; background: rgba(0,0,0,.08); }

.m-chip-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.375rem;
}

/* --------------------------------------------------------------------------
   12. BUTTONS
   -------------------------------------------------------------------------- */
.m-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.46rem 0.95rem;
  border-radius: var(--m-r-sm);
  font-family: var(--m-font);
  font-size: 0.83rem;
  font-weight: 550;
  line-height: 1.3;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--m-ease), color var(--m-ease),
              border-color var(--m-ease), box-shadow var(--m-ease),
              transform 80ms ease;
  white-space: nowrap;
  user-select: none;
}
.m-btn:focus-visible { outline: 2px solid var(--m-brand); outline-offset: 2px; }
.m-btn:active { transform: scale(0.97); }

.m-btn--primary {
  background: var(--m-brand);
  color: var(--m-text-inverse);
  border-color: var(--m-brand);
  box-shadow: 0 1px 2px rgba(79,70,229,.2);
}
.m-btn--primary:hover {
  background: var(--m-brand-hover);
  border-color: var(--m-brand-hover);
  box-shadow: var(--m-shadow-brand);
  color: var(--m-text-inverse);
  text-decoration: none;
}

.m-btn--secondary {
  background: var(--m-surface);
  color: var(--m-text-2);
  border-color: var(--m-border-strong);
}
.m-btn--secondary:hover {
  background: var(--m-bg-subtle);
  border-color: var(--m-border-strong);
  color: var(--m-text);
  text-decoration: none;
}

.m-btn--ghost {
  background: transparent;
  color: var(--m-text-muted);
  border-color: transparent;
}
.m-btn--ghost:hover { background: var(--m-bg-subtle); color: var(--m-text); text-decoration: none; }

.m-btn--danger-ghost {
  background: transparent;
  color: var(--m-danger);
  border-color: var(--m-border);
}
.m-btn--danger-ghost:hover { background: var(--m-danger-bg); border-color: var(--m-danger-border); color: var(--m-danger); text-decoration: none; }

.m-btn--sm { padding: 0.3rem 0.65rem; font-size: 0.77rem; }
.m-btn--lg { padding: 0.6rem 1.2rem; font-size: 0.9rem; }
.m-btn--full { width: 100%; justify-content: center; }

/* --------------------------------------------------------------------------
   13. FORM ELEMENTS
   -------------------------------------------------------------------------- */
.m-field-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--m-text-muted);
  margin-bottom: 0.3rem;
}

.m-input,
.m-select {
  display: block;
  width: 100%;
  padding: 0.4rem 0.7rem;
  font-family: var(--m-font);
  font-size: 0.85rem;
  color: var(--m-text);
  background: var(--m-surface);
  border: 1px solid var(--m-border-strong);
  border-radius: var(--m-r-sm);
  transition: border-color var(--m-ease), box-shadow var(--m-ease);
  line-height: 1.5;
  -webkit-appearance: none;
}

.m-input:focus,
.m-select:focus {
  outline: none;
  border-color: var(--m-brand);
  box-shadow: 0 0 0 3px var(--m-brand-soft);
}

.m-input::placeholder { color: var(--m-text-faint); }

/* --------------------------------------------------------------------------
   14. TABLE
   -------------------------------------------------------------------------- */
.m-table-wrap {
  background: var(--m-surface);
  border: 1px solid var(--m-border);
  border-radius: var(--m-r-lg);
  box-shadow: var(--m-shadow-sm);
  overflow: hidden;
}

.m-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.83rem;
}

.m-table thead th {
  background: var(--m-bg-subtle);
  color: var(--m-text-muted);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.65rem 0.9rem;
  border-bottom: 1px solid var(--m-border);
  white-space: nowrap;
  text-align: left;
}

.m-table thead th a {
  color: inherit;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  transition: color var(--m-ease);
}
.m-table thead th a:hover { color: var(--m-brand); }
.m-table thead th.is-sorted a { color: var(--m-brand); }

.m-table tbody td {
  padding: 0.6rem 0.9rem;
  border-bottom: 1px solid var(--m-border);
  vertical-align: middle;
  color: var(--m-text);
}

.m-table tbody tr:last-child td { border-bottom: none; }
.m-table tbody tr { transition: background var(--m-ease); }
.m-table tbody tr:hover td { background: var(--m-bg-subtle); }

/* Placement row states */
.m-row--high td  { background: #ecfdf3 !important; }
.m-row--likely td { background: #f2fbf5 !important; }
.m-row--border td { background: #fefbea !important; }
.m-row--est td   { background: #d3f8df !important; font-weight: 600; }
.m-row--near td  { background: #ffedd5 !important; }
.m-row--broken td { background: #ffcccc !important; }
.m-row--added td { background: #fff9e6 !important; }

[data-theme="dark"] .m-row--high td   { background: rgba(22,163,74,.15)  !important; }
[data-theme="dark"] .m-row--likely td { background: rgba(22,163,74,.08)  !important; }
[data-theme="dark"] .m-row--border td { background: rgba(217,119,6,.12)  !important; }
[data-theme="dark"] .m-row--est td    { background: rgba(22,163,74,.22)  !important; }
[data-theme="dark"] .m-row--near td   { background: rgba(217,119,6,.18)  !important; }
[data-theme="dark"] .m-row--broken td { background: rgba(220,38,38,.18)  !important; }
[data-theme="dark"] .m-row--added td  { background: rgba(217,119,6,.10)  !important; }

/* --------------------------------------------------------------------------
   15. PAGINATION
   -------------------------------------------------------------------------- */
.m-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  flex-wrap: wrap;
  margin-top: 1.25rem;
}

.m-page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  padding: 0 0.5rem;
  border-radius: var(--m-r-sm);
  font-size: 0.8rem;
  font-weight: 550;
  color: var(--m-text-muted);
  text-decoration: none;
  border: 1px solid var(--m-border);
  background: var(--m-surface);
  transition: all var(--m-ease);
}
.m-page-link:hover { background: var(--m-bg-subtle); color: var(--m-text); text-decoration: none; }
.m-page-link.is-active { background: var(--m-brand); border-color: var(--m-brand); color: var(--m-text-inverse); }
.m-page-link.is-disabled { opacity: 0.4; pointer-events: none; }
.m-page-link.is-ellipsis { border-color: transparent; background: transparent; pointer-events: none; color: var(--m-text-faint); }

/* --------------------------------------------------------------------------
   16. EMPTY STATE
   -------------------------------------------------------------------------- */
.m-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3.5rem 1.5rem;
  gap: 0.75rem;
}

.m-empty__icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--m-bg-subtle);
  display: grid;
  place-items: center;
  color: var(--m-text-faint);
  margin-bottom: 0.25rem;
}

.m-empty__title {
  font-size: 0.95rem;
  font-weight: 650;
  color: var(--m-text);
  margin: 0;
}

.m-empty__desc {
  font-size: 0.83rem;
  color: var(--m-text-muted);
  max-width: 30rem;
  margin: 0;
  line-height: 1.5;
}

/* --------------------------------------------------------------------------
   17. SKELETON LOADER
   -------------------------------------------------------------------------- */
.m-skeleton {
  border-radius: var(--m-r-sm);
  background: linear-gradient(
    90deg,
    var(--m-bg-subtle) 25%,
    var(--m-border) 37%,
    var(--m-bg-subtle) 63%
  );
  background-size: 400% 100%;
  animation: mSkeleton 1.4s ease infinite;
}

@keyframes mSkeleton {
  0%   { background-position: 100% 50%; }
  100% { background-position: 0%   50%; }
}

.m-skeleton-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.9rem;
  border-bottom: 1px solid var(--m-border);
}

/* --------------------------------------------------------------------------
   18. SCROLL TO TOP
   -------------------------------------------------------------------------- */
.m-scroll-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.25rem;
  z-index: var(--m-z-fixed);
  width: 44px;
  height: 44px;
  border-radius: var(--m-r-full);
  border: none;
  background: linear-gradient(135deg, var(--m-brand), var(--m-accent));
  color: var(--m-text-inverse);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: var(--m-shadow-brand), var(--m-shadow-md);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(10px) scale(0.9);
  transition: opacity var(--m-ease-md), transform var(--m-ease-md), visibility var(--m-ease-md);
}
.m-scroll-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}
.m-scroll-top:hover { transform: translateY(-2px) scale(1.05); box-shadow: 0 6px 20px rgba(79,70,229,.4); }
.m-scroll-top:active { transform: scale(0.95); }

/* --------------------------------------------------------------------------
   19. SECTION / PAGE HEADER
   -------------------------------------------------------------------------- */
.m-page-header {
  margin-bottom: 1.5rem;
}

.m-page-title {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--m-text);
  margin: 0 0 0.3rem;
  line-height: 1.2;
}

.m-page-sub {
  font-size: 0.84rem;
  color: var(--m-text-muted);
  margin: 0;
}

/* --------------------------------------------------------------------------
   20. TOOLBAR ROW
   -------------------------------------------------------------------------- */
.m-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.m-toolbar-left  { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; min-width: 0; }
.m-toolbar-right { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; flex-shrink: 0; }

/* --------------------------------------------------------------------------
   21. ALERTS / INLINE FEEDBACK
   -------------------------------------------------------------------------- */
.m-alert {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.75rem 1rem;
  border-radius: var(--m-r);
  border: 1px solid;
  font-size: 0.83rem;
  line-height: 1.45;
}
.m-alert--success { background: var(--m-success-bg); border-color: var(--m-success-border); color: var(--m-success-text); }
.m-alert--warning { background: var(--m-warning-bg); border-color: var(--m-warning-border); color: var(--m-warning-text); }
.m-alert--danger  { background: var(--m-danger-bg);  border-color: var(--m-danger-border);  color: var(--m-danger-text);  }
.m-alert--info    { background: var(--m-info-bg);    border-color: var(--m-info-border);    color: var(--m-info-text);    }

/* --------------------------------------------------------------------------
   22. ANIMATIONS
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
  }
}

/* --------------------------------------------------------------------------
   23. FOCUS RING
   -------------------------------------------------------------------------- */
:focus-visible {
  outline: 2px solid var(--m-brand);
  outline-offset: 2px;
}

a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--m-brand);
  outline-offset: 2px;
  border-radius: var(--m-r-sm);
}

/* --------------------------------------------------------------------------
   24. RESPONSIVE
   -------------------------------------------------------------------------- */
@media (max-width: 991.98px) {
  .m-footer-grid { grid-template-columns: 1fr 1fr; }
  .m-footer-grid > :first-child { grid-column: 1 / -1; }
}

@media (max-width: 767.98px) {
  :root { --m-navbar-h: 52px; }

  .m-main { padding-top: 1rem; }
  .m-shell { padding: 0 0.9rem; }
  .m-navbar-inner { padding: 0 0.9rem; }

  /* Hide nav list on mobile; shown in .m-mobile-nav */
  .m-nav-list { display: none; }
  .m-mobile-menu-btn { display: grid !important; }

  .m-footer-grid {
    grid-template-columns: 1fr;
    padding: 1.75rem 0.9rem 1rem;
    gap: 1.5rem;
  }

  .m-toast-region { right: 0.5rem; width: calc(100vw - 1rem); }
  .m-scroll-top { bottom: 1rem; right: 0.75rem; width: 40px; height: 40px; }

  /* Mobile table → stacked cards */
  .m-table-mobile thead { display: none; }
  .m-table-mobile, .m-table-mobile tbody { display: block; width: 100%; }
  .m-table-wrap.m-table-mobile-wrap { overflow: visible; border: none; background: transparent; box-shadow: none; }
  .m-table-mobile tr {
    display: block;
    background: var(--m-surface);
    border: 1px solid var(--m-border);
    border-radius: var(--m-r-lg);
    margin-bottom: 0.875rem;
    overflow: hidden;
    box-shadow: var(--m-shadow-sm);
  }
  .m-table-mobile td {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.65rem 0.9rem;
    border-bottom: 1px solid var(--m-border);
    font-size: 0.88rem;
    background: transparent !important;
  }
  .m-table-mobile td:last-child { border-bottom: none; }
  .m-table-mobile td::before {
    content: attr(data-label);
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--m-text-muted);
    flex: 0 0 36%;
    padding-top: 0.1rem;
  }
}

@media (max-width: 575.98px) {
  .m-shell { padding: 0 0.75rem; }
  .m-navbar-inner { padding: 0 0.75rem; }
}

/* --------------------------------------------------------------------------
   25. PRINT
   -------------------------------------------------------------------------- */
@media print {
  .m-header, .m-toast-region, .m-scroll-top, .m-progress,
  .m-nav-actions, .m-footer { display: none !important; }
  .m-main { padding: 0; }
}

/* --------------------------------------------------------------------------
   26. DARK MODE — Bootstrap / accordion overrides
   -------------------------------------------------------------------------- */
[data-theme="dark"] .accordion-button {
  color: var(--m-text);
  background: transparent;
}
[data-theme="dark"] .accordion-button:not(.collapsed) {
  color: var(--m-brand);
  background: var(--m-brand-soft);
  box-shadow: none;
}
[data-theme="dark"] .accordion-button::after {
  filter: invert(1);
}
[data-theme="dark"] .modal-content {
  background: var(--m-surface);
  border-color: var(--m-border-strong);
}
[data-theme="dark"] .btn-close { filter: invert(1); }

/* Bootstrap form-select in dark mode */
[data-theme="dark"] .form-select,
[data-theme="dark"] .form-control {
  background-color: var(--m-surface);
  border-color: var(--m-border-strong);
  color: var(--m-text);
}
[data-theme="dark"] .form-select option { background: var(--m-surface); }
[data-theme="dark"] .form-check-input {
  background-color: var(--m-surface);
  border-color: var(--m-border-strong);
}
[data-theme="dark"] .input-group .form-control { border-color: var(--m-border-strong); }

/* --------------------------------------------------------------------------
   27. BUTTON — additional variants
   -------------------------------------------------------------------------- */
.m-btn[aria-disabled="true"],
.m-btn:disabled {
  opacity: 0.5;
  pointer-events: none;
}

/* Loading state — spinner via pseudo-element */
.m-btn.is-loading {
  pointer-events: none;
  position: relative;
  color: transparent !important;
}
.m-btn.is-loading::after {
  content: '';
  position: absolute;
  width: 14px; height: 14px;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  animation: mSpin 600ms linear infinite;
  color: var(--m-text-inverse);
}
@keyframes mSpin { to { transform: rotate(360deg); } }

/* --------------------------------------------------------------------------
   28. ADMIN-SPECIFIC
   -------------------------------------------------------------------------- */
.m-admin-card {
  max-width: 420px;
  margin: 6rem auto;
}

.m-admin-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.m-admin-stat {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.8rem;
  color: var(--m-text-muted);
}

.m-admin-stat strong { color: var(--m-danger); }

/* Highlight rows with missing city */
.m-row--warn td { background: var(--m-warning-bg) !important; }
[data-theme="dark"] .m-row--warn td { background: rgba(217,119,6,.10) !important; }

/* --------------------------------------------------------------------------
   29. TABLE — aria-sort indicator via CSS
   -------------------------------------------------------------------------- */
.m-table thead th[aria-sort="ascending"] a::after  { content: ' ↑'; color: var(--m-brand); }
.m-table thead th[aria-sort="descending"] a::after { content: ' ↓'; color: var(--m-brand); }

/* --------------------------------------------------------------------------
   30. CHIP BAR — dark mode + hover tweaks
   -------------------------------------------------------------------------- */
.m-chip {
  cursor: pointer;
  text-decoration: none;
  transition: background var(--m-ease), border-color var(--m-ease), color var(--m-ease), transform 80ms ease;
}
.m-chip:hover { text-decoration: none; transform: translateY(-1px); }
.m-chip--active:hover { background: var(--m-brand-soft); border-color: var(--m-brand); color: var(--m-brand); }

[data-theme="dark"] .m-chip {
  background: var(--m-surface);
  border-color: var(--m-border-strong);
  color: var(--m-text-2);
}
[data-theme="dark"] .m-chip--active {
  background: var(--m-brand-soft);
  border-color: var(--m-brand-border);
  color: var(--m-brand);
}

/* --------------------------------------------------------------------------
   31. UX MICRO-INTERACTIONS
   -------------------------------------------------------------------------- */
/* Smooth row highlight when added to list */
@keyframes mRowAdded {
  0%   { background-color: var(--m-brand-soft); }
  100% { background-color: transparent; }
}
.m-row--added td { animation: none; }

/* Page-level fade-in on load */
.m-page { animation: mFadeUp 200ms ease both; }
@keyframes mFadeUp {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .m-page { animation: none; }
}

/* ==========================================================================
   32. VISUAL REFRESH — Aydınlık modda görsel ayrışma
   ========================================================================== */

/* Arka plan: Bootstrap'ın soğuk grisinden ayrışan çok hafif indigo tonu */
:root {
  --m-bg:        #f5f4ff;
  --m-bg-subtle: #eceafd;
}

/* --- Navbar: koyu marka gradienti ---------------------------------------- */
.m-navbar {
  background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: none;
  box-shadow: 0 2px 24px rgba(79, 70, 229, .28);
}

.m-brand           { color: #fff !important; }
.m-brand:hover     { color: rgba(255,255,255,.85) !important; }

.m-nav-link        { color: rgba(255,255,255,.72); }
.m-nav-link:hover  { color: #fff; background: rgba(255,255,255,.10); text-decoration: none; }
.m-nav-link.active { color: #fff; background: rgba(255,255,255,.18); }

.m-icon-btn {
  color: rgba(255,255,255,.72);
  border-color: rgba(255,255,255,.20);
  background: transparent;
}
.m-icon-btn:hover {
  color: #fff;
  background: rgba(255,255,255,.13);
  border-color: rgba(255,255,255,.35);
}

.m-mobile-nav {
  background: linear-gradient(180deg, #312e81 0%, #1e1b4b 100%);
  border-top: 1px solid rgba(255,255,255,.10);
  backdrop-filter: none;
}
.m-mobile-nav .m-nav-link        { color: rgba(255,255,255,.75); }
.m-mobile-nav .m-nav-link:hover  { color: #fff; background: rgba(255,255,255,.10); }
.m-mobile-nav .m-nav-link.active { color: #fff; background: rgba(255,255,255,.18); }

/* Koyu mod — daha derin lacivert */
[data-theme="dark"] .m-navbar {
  background: linear-gradient(135deg, #13112b 0%, #1e1b4b 100%);
  box-shadow: 0 2px 24px rgba(0, 0, 0, .55);
}
[data-theme="dark"] .m-mobile-nav {
  background: linear-gradient(180deg, #1e1b4b 0%, #13112b 100%);
}

/* --- Birincil buton: indigo → mor gradienti -------------------------------- */
.m-btn--primary {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  border-color: transparent;
  box-shadow: 0 2px 8px rgba(79, 70, 229, .35);
}
.m-btn--primary:hover {
  background: linear-gradient(135deg, #4338ca 0%, #6d28d9 100%);
  border-color: transparent;
  box-shadow: 0 4px 18px rgba(79, 70, 229, .48);
  color: #fff;
  text-decoration: none;
}

/* --- Tablo başlığı: marka rengi tonu ------------------------------------- */
.m-table thead th {
  background: #eef2ff;
  color: #4338ca;
}
[data-theme="dark"] .m-table thead th {
  background: rgba(79, 70, 229, .12);
  color: #a5b4fc;
}

/* --- Kart: marka renkli gölge ------------------------------------------- */
.m-card {
  box-shadow: 0 4px 14px rgba(79, 70, 229, .09), 0 1px 3px rgba(15, 23, 42, .05);
}

/* --- Aktif filtre chip: dolu marka rengi --------------------------------- */
.m-chip--active,
.m-chip--active:hover {
  background: var(--m-brand);
  border-color: var(--m-brand);
  color: #fff;
  font-weight: 600;
  transform: none;
}
[data-theme="dark"] .m-chip--active,
[data-theme="dark"] .m-chip--active:hover {
  background: var(--m-brand);
  border-color: var(--m-brand);
  color: #fff;
}

/* --- Sayfa başlığı: gradient hero bandı ---------------------------------- */
.m-page-header--hero {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  border-radius: 14px;
  padding: 1.75rem 2rem;
  margin-bottom: 1.5rem;
  position: relative;
  overflow: hidden;
}
.m-page-header--hero .m-page-title,
.m-page-header--hero .m-page-sub {
  position: relative;
  z-index: 1;
}
.m-page-header--hero .m-page-title { color: #fff; }
.m-page-header--hero .m-page-sub   { color: rgba(255,255,255,.82); margin: 0; }
.m-page-header--hero::before {
  content: '';
  position: absolute;
  top: -55%;
  right: -3%;
  width: 240px;
  height: 240px;
  background: rgba(255,255,255,.06);
  border-radius: 50%;
  pointer-events: none;
}

/* Koyu mod hero header — gradient zaten koyu, daha da koyu gölge */
[data-theme="dark"] .m-page-header--hero {
  background: linear-gradient(135deg, #312e81 0%, #4c1d95 100%);
}

@media (max-width: 767.98px) {
  .m-page-header--hero { padding: 1.25rem; border-radius: 10px; }
}

/* ==========================================================================
   31. AI AMBER TOKENS — Yapay zeka / rehberlik renk sistemi
   ========================================================================== */

:root {
  --m-amber:          #f59e0b;
  --m-amber-hover:    #d97706;
  --m-amber-soft:     #fffbeb;
  --m-amber-border:   #fde68a;
  --m-amber-text:     #92400e;
  --m-surface-tinted: #f8faff;   /* hafif mavi beyaz yüzey */
}

[data-theme="dark"] {
  --m-amber-soft:     rgba(245, 158, 11, .08);
  --m-amber-border:   rgba(245, 158, 11, .20);
  --m-amber-text:     #fbbf24;
  --m-surface-tinted: var(--m-bg);
}

/* ==========================================================================
   32. AI BUTTON
   ========================================================================== */

.m-btn--ai {
  background: var(--m-amber);
  border-color: transparent;
  color: #fff;
}
.m-btn--ai:hover {
  background: var(--m-amber-hover);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 14px rgba(245, 158, 11, .35);
  text-decoration: none;
  transform: translateY(-1px);
}
[data-theme="dark"] .m-btn--ai       { background: #d97706; }
[data-theme="dark"] .m-btn--ai:hover { background: #b45309; }

/* ==========================================================================
   33. SCORE BAND — İmza bileşeni
   ========================================================================== */

.m-score-band {
  background: var(--m-surface);
  border: 1px solid var(--m-border);
  border-radius: var(--m-r-xl);
  padding: 1.375rem 1.5rem;
  box-shadow: var(--m-shadow-md);
}
.m-score-band__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: .5rem;
  margin-bottom: 1rem;
}
.m-score-band__title {
  font-size: .78rem;
  font-weight: 600;
  color: var(--m-text-2);
  letter-spacing: .01em;
}
.m-score-band__legend {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: .75rem;
}
.m-score-band__legend-item {
  display: flex;
  align-items: center;
  gap: .375rem;
  font-size: .73rem;
  color: var(--m-text-muted);
}
.m-score-band__legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ==========================================================================
   34. AI PANEL
   ========================================================================== */

.m-ai-panel {
  background: linear-gradient(135deg, var(--m-amber-soft) 0%, var(--m-brand-soft) 100%);
  border: 1px solid var(--m-border);
  border-left: 3px solid var(--m-amber);
  border-radius: 0 var(--m-r-lg) var(--m-r-lg) 0;
  padding: 1rem 1.25rem 1rem 1.25rem;
}
.m-ai-panel__icon {
  width: 28px;
  height: 28px;
  background: var(--m-amber);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  margin-bottom: .5rem;
}
.m-ai-panel__text {
  font-size: .875rem;
  line-height: 1.7;
  color: var(--m-text);
}
.m-ai-panel__text strong { color: var(--m-brand); font-weight: 700; }
[data-theme="dark"] .m-ai-panel__text strong { color: #a5b4fc; }

/* ==========================================================================
   35. TRUST DOTS — AI Güven Sinyali
   ========================================================================== */

.m-trust {
  display: flex;
  align-items: center;
  gap: .625rem;
  margin-top: .625rem;
  flex-wrap: wrap;
}
.m-trust__label {
  font-size: .65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--m-text-faint);
  flex-shrink: 0;
}
.m-trust__dots {
  display: flex;
  gap: .25rem;
}
.m-trust__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--m-border-strong);
  transition: background var(--m-ease);
}
.m-trust__dot--on  { background: var(--m-amber); }
.m-trust__info {
  font-size: .73rem;
  color: var(--m-text-muted);
}

/* ==========================================================================
   36. SAFETY BADGES — Güvenlik etiketleri
   ========================================================================== */

.m-sbadge {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .2rem .625rem;
  border-radius: var(--m-r-full);
  font-size: .71rem;
  font-weight: 600;
  white-space: nowrap;
}
.m-sbadge--safe   { background: var(--m-success-bg);  color: var(--m-success-text); }
.m-sbadge--border { background: var(--m-warning-bg);  color: var(--m-warning-text); }
.m-sbadge--risk   { background: var(--m-danger-bg);   color: var(--m-danger-text);  }

[data-theme="dark"] .m-sbadge--safe   { background: rgba(22,163,74,.12);  color: #4ade80; }
[data-theme="dark"] .m-sbadge--border { background: rgba(217,119,6,.12);  color: #fbbf24; }
[data-theme="dark"] .m-sbadge--risk   { background: rgba(220,38,38,.12);  color: #f87171; }

/* ==========================================================================
   37. STAT CARDS — Dashboard istatistik kartları
   ========================================================================== */

.m-stat-card {
  background: var(--m-surface);
  border: 1px solid var(--m-border);
  border-radius: var(--m-r-lg);
  padding: 1.125rem 1.25rem;
  box-shadow: var(--m-shadow-sm);
  display: flex;
  flex-direction: column;
}
.m-stat-card__label {
  font-size: .66rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--m-text-faint);
  margin-bottom: .3rem;
}
.m-stat-card__value {
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
  color: var(--m-text);
}
.m-stat-card__sub {
  font-size: .75rem;
  color: var(--m-text-muted);
  margin-top: .2rem;
}
.m-stat-trend {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  font-size: .7rem;
  font-weight: 600;
  padding: .175rem .5rem;
  border-radius: var(--m-r-full);
  margin-top: .5rem;
  width: fit-content;
}
.m-stat-trend--up { background: var(--m-success-bg); color: var(--m-success-text); }
.m-stat-trend--dn { background: var(--m-danger-bg);  color: var(--m-danger-text);  }
[data-theme="dark"] .m-stat-trend--up { background: rgba(22,163,74,.12);  color: #4ade80; }
[data-theme="dark"] .m-stat-trend--dn { background: rgba(220,38,38,.12);  color: #f87171; }

/* ==========================================================================
   38. UNI ROW — Üniversite liste satırı
   ========================================================================== */

.m-uni-row {
  background: var(--m-surface);
  border: 1px solid var(--m-border);
  border-radius: var(--m-r);
  padding: .75rem 1rem;
  display: flex;
  align-items: center;
  gap: .75rem;
  transition: border-color var(--m-ease), box-shadow var(--m-ease), transform var(--m-ease);
  text-decoration: none;
  color: inherit;
}
.m-uni-row + .m-uni-row { margin-top: .5rem; }
.m-uni-row:hover {
  border-color: var(--m-brand);
  box-shadow: var(--m-shadow);
  transform: translateY(-1px);
  color: inherit;
  text-decoration: none;
}
.m-uni-row__logo {
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--m-brand-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  flex-shrink: 0;
}
[data-theme="dark"] .m-uni-row__logo { background: rgba(79,70,229,.15); }
.m-uni-row__body  { flex: 1; min-width: 0; }
.m-uni-row__name  { font-size: .835rem; font-weight: 700; margin-bottom: .1rem; color: var(--m-text); }
.m-uni-row__dept  { font-size: .77rem; color: var(--m-text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m-uni-row__meta  { display: flex; flex-direction: column; align-items: flex-end; gap: .25rem; flex-shrink: 0; }

/* ==========================================================================
   39. STEP INDICATOR
   ========================================================================== */

.m-steps {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
}
.m-step-node {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .68rem;
  font-weight: 700;
  flex-shrink: 0;
}
.m-step-node--done    { background: var(--m-success); color: #fff; }
.m-step-node--active  { background: var(--m-brand);   color: #fff; }
.m-step-node--pending {
  background: var(--m-bg-subtle);
  color: var(--m-text-faint);
  border: 2px solid var(--m-border);
}
.m-step-line          { flex: 1; height: 2px; background: var(--m-border); }
.m-step-line--done    { background: var(--m-success); }

.m-step-item {
  display: flex;
  align-items: flex-start;
  gap: .5rem;
  padding: .3rem 0;
}
.m-step-item__icon  { font-size: .78rem; margin-top: .1rem; flex-shrink: 0; width: 14px; text-align: center; }
.m-step-item__text  { font-size: .815rem; line-height: 1.5; color: var(--m-text-2); }
.m-step-item--active .m-step-item__text  { color: var(--m-text); font-weight: 600; }
.m-step-item--done   .m-step-item__text  { color: var(--m-text-muted); }
.m-step-item--pending .m-step-item__text { color: var(--m-text-faint); }

/* ==========================================================================
   40. SCORE SETUP CARD
   ========================================================================== */

.m-score-setup {
  background: var(--m-surface);
  border: 1px solid var(--m-border);
  border-radius: var(--m-r-xl);
  padding: 2rem 2rem 1.75rem;
  text-align: center;
  box-shadow: var(--m-shadow-md);
  max-width: 500px;
  margin: 0 auto;
}
.m-score-setup__emoji { font-size: 2rem; margin-bottom: .75rem; }
.m-score-setup__title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -.025em;
  color: var(--m-text);
  margin-bottom: .375rem;
}
.m-score-setup__sub {
  font-size: .85rem;
  color: var(--m-text-muted);
  margin-bottom: 1.375rem;
  line-height: 1.6;
}
.m-score-setup__row {
  display: flex;
  gap: .5rem;
  margin-bottom: .625rem;
}

@media (max-width: 767.98px) {
  .m-score-band { padding: 1rem; }
  .m-stat-card  { padding: 1rem; }
  .m-stat-card__value { font-size: 1.75rem; }
  .m-score-setup { padding: 1.5rem 1.25rem; }
}
