/**
 * PMA — kurumsal arayüz
 */
:root {
  --pma-bg: #f1f3f5;
  --pma-surface: #ffffff;
  --pma-ink: #0c1220;
  --pma-ink-muted: #5c6578;
  --pma-border: rgba(12, 18, 32, 0.08);
  --pma-sidebar-0: #0b1220;
  --pma-sidebar-1: #111a2e;
  --pma-accent: #3d8bfd;
  --pma-accent-dim: rgba(61, 139, 253, 0.14);
  --pma-radius: 0.75rem;
  --pma-radius-lg: 1rem;
  --pma-shadow: 0 1px 2px rgba(12, 18, 32, 0.04), 0 4px 16px rgba(12, 18, 32, 0.06);
  --pma-shadow-lg: 0 4px 6px -1px rgba(12, 18, 32, 0.05), 0 12px 24px -4px rgba(12, 18, 32, 0.08);
  --bs-primary: #2563eb;
  --bs-primary-rgb: 37, 99, 235;
  --bs-link-color: #2563eb;
  --bs-link-hover-color: #1d4ed8;
  --pma-topbar-h: 3.5rem;
  --pma-desktop-header-h: 4.75rem;
}

html {
  overflow-x: hidden;
}

body.pma-app {
  margin: 0;
  min-height: 100vh;
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-feature-settings: "cv02", "cv03", "cv04", "ss01";
  color: var(--pma-ink);
  background-color: var(--pma-bg);
  background-image:
    radial-gradient(ellipse 80% 50% at 100% 0%, rgba(37, 99, 235, 0.06) 0%, transparent 50%),
    radial-gradient(ellipse 60% 40% at 0% 100%, rgba(12, 18, 32, 0.04) 0%, transparent 45%);
}

body.pma-app .h1, body.pma-app .h2, body.pma-app .h3, body.pma-app .h4, body.pma-app .h5,
body.pma-app h1, body.pma-app h2, body.pma-app h3, body.pma-app h4, body.pma-app h5 {
  font-weight: 600;
  letter-spacing: -0.02em;
}

/* Üst şeritler: viewport’a sabit (.navbar position:relative ile çakışmasın diye !important) */
.pma-topbar.fixed-top,
.pma-headerbar.fixed-top {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
}

/* Üst bar (mobil): Bootstrap .fixed-top + tonlar; içerik .pma-layout-wrap padding ile */
.pma-topbar {
  background: linear-gradient(135deg, var(--pma-sidebar-0) 0%, var(--pma-sidebar-1) 100%) !important;
  border: none;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
  min-height: var(--pma-topbar-h);
  width: 100%;
  z-index: 1030;
}
.pma-layout-wrap {
  padding-top: var(--pma-topbar-h);
}
@media (min-width: 992px) {
  .pma-layout-wrap {
    padding-top: var(--pma-desktop-header-h);
  }
}
.pma-topbar .navbar-brand,
.pma-topbar .navbar-toggler { color: #fff !important; }
.pma-topbar .navbar-toggler { border-color: rgba(255, 255, 255, 0.2); }

/* Offcanvas = mobil yan panel */
.pma-offcanvas,
.pma-offcanvas .offcanvas-header {
  background: linear-gradient(180deg, var(--pma-sidebar-0) 0%, #0a101c 100%) !important;
  color: #e8eaef;
  border: none;
}
.pma-offcanvas .offcanvas-header { border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important; }
.pma-offcanvas .offcanvas-title { color: #fff; letter-spacing: -0.02em; }
.pma-offcanvas .btn-close { filter: invert(1) grayscale(1); opacity: 0.7; }

/* Masaüstü yan menü */
.pma-sidebar {
  background: linear-gradient(180deg, var(--pma-sidebar-0) 0%, #0a101c 100%) !important;
  color: #e8eaef;
  border-color: rgba(255, 255, 255, 0.06) !important;
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.12);
}
.pma-headerbar.pma-sidebar {
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
/* Masaüstü şerit: .fixed-top + .d-none.d-lg-flex ile yalnız lg+ görünür */
.pma-headerbar.pma-sidebar.fixed-top {
  width: 100%;
  z-index: 1030;
}
.pma-header-nav .pma-nav { font-size: 0.875rem; }
.pma-avatar--sm {
  width: 34px;
  height: 34px;
  min-width: 34px;
  font-size: 0.8125rem;
}
.pma-userbox--inline { margin-top: 0 !important; padding-top: 0.5rem !important; padding-bottom: 0.5rem !important; }
@media (min-width: 992px) {
  .pma-userbox--inline { padding-top: 0.35rem !important; padding-bottom: 0.35rem !important; }
}
.pma-brand-mark {
  background: linear-gradient(135deg, var(--pma-accent) 0%, #1d4ed8 100%);
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
}
.pma-sidebar .pma-brand-text { color: #fff !important; }
.pma-topbar .pma-brand-mark { box-shadow: 0 2px 10px rgba(37, 99, 235, 0.35); }

/* Nav linkleri */
.pma-nav {
  color: rgba(255, 255, 255, 0.72) !important;
  font-size: 0.9375rem;
  font-weight: 500;
  border: 1px solid transparent;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.pma-nav:hover:not(.pma-nav--active) {
  color: #fff !important;
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.04);
}
.pma-nav--active {
  color: #fff !important;
  background: var(--pma-accent-dim) !important;
  border: 1px solid rgba(61, 139, 253, 0.35) !important;
  box-shadow: 0 0 0 1px rgba(61, 139, 253, 0.15) inset;
}
.pma-nav--active i { color: var(--pma-accent); }
.pma-nav i { font-size: 1.1rem; opacity: 0.95; }

/* Kullanıcı kutusu */
.pma-userbox {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--pma-radius-lg);
}
.pma-avatar-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pma-profile-avatar-preview {
  width: 5.5rem;
  height: 5.5rem;
  flex-shrink: 0;
}
.pma-profile-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pma-profile-sidebar .pma-profile-avatar-preview {
  width: 8rem;
  height: 8rem;
  margin-left: auto;
  margin-right: auto;
}
@media (min-width: 992px) {
  .pma-profile-sidebar .pma-profile-avatar-preview {
    width: 9rem;
    height: 9rem;
  }
}
.pma-profile-sidebar {
  background: linear-gradient(165deg, rgba(37, 99, 235, 0.06) 0%, transparent 45%),
    var(--pma-surface);
}

.pma-notifications-btn {
  color: rgba(255, 255, 255, 0.92) !important;
  background: rgba(255, 255, 255, 0.1) !important;
  line-height: 1;
  padding: 0.4rem 0.55rem !important;
}
.pma-notifications-btn:hover {
  color: #fff !important;
  background: rgba(255, 255, 255, 0.18) !important;
}
.pma-notifications-btn:focus-visible {
  outline: 2px solid rgba(147, 197, 253, 0.7);
  outline-offset: 2px;
}
.pma-notifications-panel {
  border-radius: var(--pma-radius-lg);
  border: 1px solid var(--pma-border);
}
.pma-notify-badge {
  font-size: 0.65rem;
  min-width: 1.15rem;
  padding: 0.2em 0.35em !important;
}
.pma-notify-menu--scroll {
  max-height: min(55vh, 20rem);
  overflow-y: auto;
}
.pma-notify-item--unread {
  background: rgba(37, 99, 235, 0.06);
}
.pma-notify-item:focus,
.pma-notify-item:hover {
  background-color: rgba(37, 99, 235, 0.09);
}

.pma-avatar {
  width: 40px; height: 40px; min-width: 40px;
  background: linear-gradient(145deg, #3d8bfd, #1e40af);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 700;
  border: 2px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}
.pma-userbox .pma-user-email { color: rgba(255, 255, 255, 0.5) !important; font-size: 0.7rem !important; }
.pma-userbox .badge {
  background: rgba(61, 139, 253, 0.2) !important;
  color: #93c5fd !important;
  border: 1px solid rgba(61, 139, 253, 0.25) !important;
  font-weight: 600;
}
.pma-btn-logout {
  color: #fca5a5 !important;
  border-color: rgba(252, 165, 165, 0.35) !important;
  background: rgba(127, 29, 29, 0.2) !important;
}
.pma-btn-logout:hover {
  color: #fff !important;
  background: rgba(220, 38, 38, 0.45) !important;
  border-color: rgba(252, 165, 165, 0.5) !important;
}

/* Ana içerik */
.pma-main { padding-top: 1.25rem; }
@media (min-width: 992px) {
  .pma-main { padding-top: 2rem; }
}

.pma-page-head {
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--pma-border);
}
.pma-page-head--hero {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 1.5rem;
}
.pma-page-title { font-size: 1.5rem; line-height: 1.2; }
@media (min-width: 768px) {
  .pma-page-title { font-size: 1.65rem; }
}

/* Proje detay: başlık + ilerleme kartı */
.pma-page-hero {
  box-shadow: var(--pma-shadow-lg) !important;
  border: 1px solid rgba(37, 99, 235, 0.1) !important;
  background: linear-gradient(165deg, #ffffff 0%, #f8fafc 100%);
}
.pma-page-hero__accent {
  height: 3px;
  width: 100%;
  background: linear-gradient(90deg, var(--bs-primary) 0%, #60a5fa 55%, rgba(37, 99, 235, 0.25) 100%);
  opacity: 0.95;
}
.pma-page-hero__body {
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.03) 0%, transparent 40%);
}
.pma-page-hero__title { letter-spacing: -0.03em; }
.pma-page-hero__label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pma-ink-muted);
}
.pma-page-hero__bar {
  height: 12px;
  min-width: 4rem;
  --bs-progress-bg: rgba(12, 18, 32, 0.08);
  --bs-progress-bar-bg: var(--bs-primary);
  box-shadow: inset 0 1px 2px rgba(12, 18, 32, 0.06);
}
.pma-page-hero__bar .progress-bar {
  background: linear-gradient(90deg, #1d4ed8 0%, #3b82f6 100%);
  box-shadow: 0 0 12px rgba(37, 99, 235, 0.35);
}
.pma-page-hero__pct {
  font-size: 1.125rem;
  line-height: 1;
  color: var(--pma-ink);
  min-width: 2.5rem;
  text-align: right;
}
@media (min-width: 992px) {
  .pma-page-hero__progress { min-width: 12rem; max-width: min(100%, 24rem); margin-left: auto; }
}
.letter-spacing-tight { letter-spacing: -0.02em; }

/* Yüzey & kart */
.pma-surface {
  background: var(--pma-surface);
  border: 1px solid var(--pma-border) !important;
  border-radius: var(--pma-radius-lg) !important;
  box-shadow: var(--pma-shadow);
}

/* Stat kartları */
.pma-stat {
  background: var(--pma-surface);
  border: 1px solid var(--pma-border);
  border-radius: var(--pma-radius-lg);
  box-shadow: var(--pma-shadow);
  transition: box-shadow 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.pma-stat:hover {
  box-shadow: var(--pma-shadow-lg);
  border-color: rgba(37, 99, 235, 0.12);
}
.pma-stat .pma-stat-icon { border-radius: 0.7rem; }
button.pma-stat-tile {
  cursor: pointer;
  font: inherit;
  color: inherit;
  -webkit-appearance: none;
  appearance: none;
}
button.pma-stat-tile:focus-visible {
  outline: 2px solid var(--bs-primary);
  outline-offset: 2px;
}
.pma-stat-tile.pma-stat--active {
  border-color: var(--bs-primary) !important;
  box-shadow: 0 0 0 1px var(--bs-primary);
}

/* Geliştirici Kanban (proje görevlerim) */
.pma-kanban-col {
  background: rgba(0, 0, 0, 0.02);
  border: 1px solid var(--pma-border);
  border-radius: var(--pma-radius-lg);
  padding: 0.75rem;
}
.pma-kanban-hd {
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--bs-border-color-translucent);
}
.pma-kanban-list {
  min-height: 5rem;
  padding-top: 0.5rem;
}
.pma-kanban-card {
  background: var(--pma-surface);
  border: 1px solid var(--pma-border);
  border-radius: 0.6rem;
  padding: 0.65rem 0.75rem;
  cursor: grab;
  box-shadow: var(--pma-shadow);
  user-select: none;
}
.pma-kanban-card:active {
  cursor: grabbing;
}
.pma-kanban-card--dragging {
  opacity: 0.75;
}

/* Proje kartları: en fazla 3 sütun (row-cols) */
.pma-project-card {
  min-height: 200px;
  border-radius: var(--pma-radius-lg) !important;
  transition: box-shadow 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}
.pma-project-card:hover {
  box-shadow: var(--pma-shadow-lg);
  border-color: rgba(37, 99, 235, 0.15) !important;
  transform: translateY(-1px);
}
.pma-project-card__title a { color: var(--pma-ink); }
.pma-project-card__title a:hover { color: var(--bs-primary); }

/* Tablo */
.pma-surface .table { --bs-table-bg: transparent; }
.pma-surface .table thead th {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--pma-ink-muted);
  border-bottom: 1px solid var(--pma-border) !important;
  padding-top: 0.85rem; padding-bottom: 0.85rem;
}
.pma-surface .table tbody tr { border-color: rgba(12, 18, 32, 0.05); }
.pma-surface .table-hover tbody tr:hover { background: rgba(37, 99, 235, 0.03) !important; }
.pma-surface-hd { border-bottom: 1px solid var(--pma-border) !important; }
.border-pma { border-color: var(--pma-border) !important; }

/* Giriş sayfası */
.pma-auth {
  font-family: "Inter", system-ui, sans-serif;
  min-height: 100dvh;
  color: #fff;
  background: var(--pma-ink);
  background-image:
    radial-gradient(ellipse 120% 80% at 100% 0%, rgba(37, 99, 235, 0.35) 0%, transparent 55%),
    radial-gradient(ellipse 90% 60% at 0% 100%, rgba(15, 23, 42, 0.9) 0%, transparent 50%),
    linear-gradient(160deg, #0b1220 0%, #111a2e 45%, #0c1a2e 100%);
  background-attachment: fixed;
}
.pma-auth .pma-auth-card {
  background: rgba(255, 255, 255, 0.97);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--pma-shadow-lg);
  border-radius: 1.25rem;
  backdrop-filter: blur(8px);
}
.pma-auth .pma-auth-logo {
  width: 3.5rem; height: 3.5rem;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  border-radius: 1rem;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.4);
}
.pma-auth .pma-auth-tagline { color: rgba(255, 255, 255, 0.55); font-size: 0.9rem; }

.pma-app .btn-primary,
.pma-auth .btn-primary {
  --bs-btn-bg: #2563eb;
  --bs-btn-border-color: #2563eb;
  --bs-btn-hover-bg: #1d4ed8;
  --bs-btn-hover-border-color: #1d4ed8;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.pma-app .btn-outline-primary { --bs-btn-color: #2563eb; --bs-btn-border-color: #2563eb; }

.pma-app .form-control:focus,
.pma-app .form-select:focus { border-color: #93c5fd; box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.15); }

.pma-app .alert-danger {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  border-radius: var(--pma-radius);
}

/* Proje ekibi tablosu: sütunlar tüm satırlarda aynı genişlikte */
.pma-team-table {
  table-layout: fixed;
  width: 100%;
}
.pma-team-table thead th {
  border-bottom: 1px solid var(--bs-border-color-translucent);
}

/* İnce ayar */
.pma-main .pma-surface a.link-dark, .pma-main .table a.text-body { transition: color 0.15s; }
.pma-app .progress { background: rgba(12, 18, 32, 0.06); }
