/**
 * DRLTEC ERP - Temel Stiller (Base CSS)
 * Reset, Body, Mobil dokunmatik optimizasyonları ve genel yardımcı sınıflar
 */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  color: var(--text-main);
  background-color: var(--bg-app);
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-top: var(--safe-area-top);
  padding-bottom: var(--safe-area-bottom);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--primary-hover);
}

img, svg {
  display: inline-block;
  vertical-align: middle;
  max-width: 100%;
}

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  touch-action: manipulation;
}

/* Düzen Kapsayıcıları (Containers) */
.app-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  width: 100%;
}

.main-content {
  flex: 1;
  padding: var(--spacing-md);
  max-width: 1000px;
  margin: 0 auto;
  width: 100%;
}

.container {
  width: 100%;
  padding-left: var(--spacing-md);
  padding-right: var(--spacing-md);
  margin-left: auto;
  margin-right: auto;
}

/* Tipografi ve Başlıklar */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-main);
  font-weight: 600;
  line-height: 1.25;
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.text-muted { color: var(--text-muted); }
.text-danger { color: var(--danger); }
.text-success { color: var(--success); }
.text-primary { color: var(--primary); }

.text-xs { font-size: var(--font-size-xs); }
.text-sm { font-size: var(--font-size-sm); }
.text-base { font-size: var(--font-size-base); }
.text-lg { font-size: var(--font-size-lg); }

.fw-normal { font-weight: 400; }
.fw-medium { font-weight: 500; }
.fw-semibold { font-weight: 600; }
.fw-bold { font-weight: 700; }

/* Esnek Yerleşim Yardımcıları (Flex Utilities) */
.d-flex { display: flex; }
.flex-1 { flex: 1; }
.flex-column { flex-direction: column; }
.align-items-center { align-items: center; }
.justify-content-between { justify-content: space-between; }
.justify-content-center { justify-content: center; }
.gap-xs { gap: var(--spacing-xs); }
.gap-sm { gap: var(--spacing-sm); }
.gap-md { gap: var(--spacing-md); }
.gap-lg { gap: var(--spacing-lg); }

/* Spacing Helpers */
.m-0 { margin: 0 !important; }
.mb-0 { margin-bottom: 0 !important; }
.mb-sm { margin-bottom: var(--spacing-sm); }
.mb-md { margin-bottom: var(--spacing-md); }
.p-0 { padding: 0 !important; }

/* Sayfa Üst Bilgi Başlığı (Page Header) */
.page-title-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--spacing-md);
  padding: var(--spacing-sm) 0;
}

.page-title {
  font-size: var(--font-size-lg);
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.page-back-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  box-shadow: var(--shadow-xs);
  transition: all var(--transition-fast);
}

.page-back-btn:hover {
  background: var(--bg-subtle);
  border-color: var(--primary);
  color: var(--primary);
}
