:root {
  --app-bg: #f6f8fa;
  --app-surface: #ffffff;
  --app-border: #d0d7de;
  --app-text: #1f2328;
  --app-muted: #57606a;
  --app-link: #0969da;
  --app-header-bg: #ffffff;
  --app-shadow: 0 1px 0 rgba(31, 35, 40, 0.04);
  --app-radius: 6px;
  --app-font: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
}

html, body {
  height: 100%;
}

/* Scrollbar genişliği için yer ayır - layout shift'i önle */
html {
  overflow-y: scroll;
}

body {
  font-family: var(--app-font);
  background: var(--app-bg);
  color: var(--app-text);
}

a {
  color: var(--app-link);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 1030;
  background: var(--app-header-bg);
  border-bottom: 1px solid var(--app-border);
  box-shadow: var(--app-shadow);
}

.app-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 56px;
}

.app-header__brand {
  font-weight: 600;
  color: var(--app-text);
  letter-spacing: 0.2px;
  display: inline-flex;
  align-items: center;
  max-width: 160px;
  overflow: hidden;
}

.app-header__logo {
  max-height: 32px;
  max-width: 160px;
  width: auto;
  height: auto;
  display: block;
  object-fit: contain;
}

.app-login__logo {
  display: inline-block;
  max-width: 100%;
  width: 260px;
  height: auto;
  object-fit: contain;
}

@media (max-width: 420px) {
  .app-login__logo {
    width: 210px;
  }
}

.app-header__nav {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.app-nav__link {
  display: inline-flex;
  align-items: center;
  height: 32px;
  padding: 0 10px;
  border-radius: var(--app-radius);
  color: var(--app-muted);
  font-weight: 500;
}

.app-nav__link:hover {
  background: rgba(208, 215, 222, 0.35);
  color: var(--app-text);
  text-decoration: none;
}

.app-nav__link.active {
  background: rgba(9, 105, 218, 0.10);
  color: var(--app-link);
}

.app-header__actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.app-header__user {
  color: var(--app-muted);
  font-size: 0.9rem;
}

/* Horizontal overflow hint for grids/tables */
.table-responsive,
.e-grid {
  position: relative;
}

.arc-overflow-hint {
  position: absolute;
  top: 6px;
  right: 12px;
  padding: 4px 10px;
  font-size: 12px;
  color: #fff;
  background: rgba(0, 0, 0, 0.55);
  border-radius: 12px;
  backdrop-filter: blur(2px);
  pointer-events: none;
  z-index: 5;
}

.arc-overflow-fade-right {
  position: absolute;
  top: 0;
  right: 0;
  width: 36px;
  height: 100%;
  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.9) 100%);
  pointer-events: none;
  z-index: 4;
}

.app-main {
  padding: 24px 0;
}

.app-content .dashboard-header {
  background: transparent !important;
  color: var(--app-text) !important;
  padding: 0 !important;
  margin: 0 0 16px 0 !important;
  border-radius: 0 !important;
}

.app-content .dashboard-header h1 {
  font-size: 1.35rem;
  margin: 0;
  font-weight: 600;
}

.app-page-title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  line-height: 1.2;
}

.app-page-title i {
  color: var(--app-muted);
  font-size: 1.1em;
}

.app-content .dashboard-header p {
  margin: 6px 0 0 0;
  color: var(--app-muted);
  font-size: 0.95rem;
}

.card {
  border: 1px solid var(--app-border);
  border-radius: var(--app-radius);
  box-shadow: none;
}

.card-header {
  background: var(--app-surface) !important;
  border-bottom: 1px solid var(--app-border);
  color: var(--app-text) !important;
}

.app-card-header {
  background: var(--app-surface) !important;
  border-bottom: 1px solid var(--app-border) !important;
  color: var(--app-text) !important;
}

.app-card-header i {
  color: var(--app-muted);
}

.table thead,
.table thead th {
  background: #f6f8fa;
  color: var(--app-text);
  border-bottom-color: var(--app-border);
}

.table thead.table-dark,
.table thead.table-dark th {
  background: #f6f8fa !important;
  color: var(--app-text) !important;
}

.app-table-header th {
  background: #f6f8fa !important;
}

.table thead.table-dark {
  --bs-table-bg: #24292f;
}

.table {
  background: var(--app-surface);
  table-layout: fixed;
  width: 100%;
}

.table td, 
.table th {
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.table-responsive {
  border: 1px solid var(--app-border);
  border-radius: var(--app-radius);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.app-footer {
  border-top: 1px solid var(--app-border);
  padding: 16px 0;
  color: var(--app-muted);
}

.grid-toolbar {
    margin-bottom: 0.5rem;
}

.arc-grid-toolbar {
    flex-wrap: wrap;
}
.arc-overflow-fade-right {
    position: absolute;
    top: 0;
    right: 0;
    width: 48px;
    height: 100%;
    pointer-events: none;
    background: linear-gradient(to right, rgba(255,255,255,0), rgba(255,255,255,0.95));
    opacity: 1;
    transition: opacity 150ms ease-in-out;
    z-index: 5;
}

.arc-overflow-hint {
    position: absolute;
    top: 10px;
    right: 10px;
    pointer-events: none;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    border-radius: 12px;
    padding: 4px 10px;
    font-size: 12px;
    line-height: 1.2;
    z-index: 6;
}
