/* =====================================================
   base.css — Reset, layout, sidebar, view header
   ===================================================== */
/* Yükleme sırası: BU DOSYA İLK YÜKLENMELİ — diğer CSS'ler buradaki body/.app/.sidebar tabanını override eder. */

/* ============================================
   Rekabet365.com — Modern Sidebar Layout
   ============================================ */

* { box-sizing: border-box; }

:root {
  /* Surface */
  --bg: #f3f4f6;
  --sidebar-bg: #ffffff;
  --card: #ffffff;

  /* Text */
  --text: #111827;
  --text-2: #374151;
  --muted: #6b7280;
  --muted-2: #9ca3af;

  /* Borders */
  --border: #e5e7eb;
  --border-soft: #f3f4f6;
  --border-strong: #d1d5db;

  /* Brand — deep red */
  --primary: #a01e21;
  --primary-hover: #871a1d;
  --primary-soft: #fbe9ea;
  --primary-soft-2: #f7d5d6;
  --primary-text: #ffffff;

  /* Accent palette for cards */
  --c-blue: #3b82f6;
  --c-yellow: #eab308;
  --c-green: #16a34a;
  --c-orange: #f59e0b;
  --c-purple: #a855f7;
  --c-red: #dc2626;

  /* States */
  --success: #16a34a;
  --success-soft: #dcfce7;
  --success-text: #166534;
  --warning: #d97706;
  --warning-soft: #fef3c7;
  --warning-text: #92400e;
  --danger: #dc2626;
  --danger-hover: #b91c1c;
  --danger-soft: #fee2e2;
  --danger-text: #991b1b;
  --info: #2563eb;
  --info-soft: #dbeafe;
  --info-text: #1e40af;

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(15, 30, 50, 0.04);
  --shadow-sm: 0 1px 3px rgba(15, 30, 50, 0.06), 0 1px 2px rgba(15, 30, 50, 0.04);
  --shadow-md: 0 4px 14px -2px rgba(15, 30, 50, 0.10), 0 2px 4px -2px rgba(15, 30, 50, 0.05);
  --shadow-lg: 0 20px 40px -12px rgba(15, 30, 50, 0.20);

  /* Radius */
  --r-sm: 8px;
  --r: 12px;
  --r-lg: 16px;

  /* Sizes */
  --sidebar-w: 250px;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

.hidden { display: none !important; }

/* ============================================
   Modern Date Input (global)
   Tüm <input type="date"> elementleri için ortak modern tasarım.
   Sayfa-spesifik overrides altta, sadece padding/font-size farklı yerler için.
   ============================================ */
input[type="date"] {
  appearance: none;
  -webkit-appearance: none;
  padding: 9px 14px;
  border: 1.5px solid var(--border-strong);
  border-radius: 10px;
  font-size: 13px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text);
  background-color: var(--card);
  cursor: pointer;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease, transform 0.12s ease;
  min-width: 150px;
  letter-spacing: 0.01em;
  box-shadow: var(--shadow-xs);
}
input[type="date"]:hover:not(:disabled) {
  border-color: var(--primary);
  background-color: #fafbfc;
  box-shadow: 0 2px 6px rgba(160, 30, 33, 0.08);
}
input[type="date"]:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-soft);
  background-color: #fff;
}
input[type="date"]:disabled {
  background-color: #f3f4f6;
  color: var(--muted);
  cursor: not-allowed;
  opacity: 0.65;
  box-shadow: none;
}
/* WebKit takvim picker ikonu — daha şık ve interaktif */
input[type="date"]::-webkit-calendar-picker-indicator {
  cursor: pointer;
  padding: 4px;
  margin-left: 6px;
  border-radius: 5px;
  opacity: 0.55;
  transition: opacity 0.15s ease, background-color 0.15s ease, transform 0.12s ease;
}
input[type="date"]:hover::-webkit-calendar-picker-indicator {
  opacity: 1;
  background-color: rgba(160, 30, 33, 0.10);
}
input[type="date"]::-webkit-calendar-picker-indicator:active {
  transform: scale(0.92);
}
input[type="date"]::-webkit-datetime-edit {
  padding: 0;
}
input[type="date"]::-webkit-datetime-edit-text {
  color: var(--muted-2);
  padding: 0 2px;
}
input[type="date"]::-webkit-datetime-edit-day-field:focus,
input[type="date"]::-webkit-datetime-edit-month-field:focus,
input[type="date"]::-webkit-datetime-edit-year-field:focus {
  background-color: var(--primary-soft);
  color: var(--primary);
  border-radius: 3px;
  outline: none;
}

/* ============================================
   App Layout
   ============================================ */
.app {
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr;
  min-height: 100vh;
}

.content {
  padding: 24px 32px;
  min-width: 0;
  overflow-x: hidden;
}

/* ============================================
   Sidebar
   ============================================ */
.sidebar {
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border);
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  gap: 28px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 4px 8px;
}

.brand-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), #c8252a);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 14px -3px rgba(160, 30, 33, 0.45);
}

.brand-text { line-height: 1.15; }

.brand-name {
  font-size: 16px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.01em;
}

.brand-tld {
  color: var(--primary);
  font-weight: 700;
}

.brand-sub {
  font-size: 10px;
  font-weight: 700;
  color: var(--muted);
  letter-spacing: 0.08em;
  margin-top: 2px;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.nav-section {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--muted);
  letter-spacing: 0.1em;
  padding: 4px 12px;
  margin-bottom: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 9px 12px;
  border: none;
  background: transparent;
  color: var(--text-2);
  font-size: 13.5px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  border-radius: var(--r-sm);
  text-align: left;
  transition: background 0.15s, color 0.15s;
  position: relative;
  width: 100%;
}

.nav-item svg {
  flex-shrink: 0;
  opacity: 0.7;
}

.nav-item:hover {
  background: var(--border-soft);
  color: var(--text);
}

.nav-item.active {
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 600;
}

.nav-item.active svg {
  opacity: 1;
}

.nav-item.active::before {
  content: "";
  position: absolute;
  left: -14px;
  top: 6px;
  bottom: 6px;
  width: 3px;
  background: var(--primary);
  border-radius: 0 4px 4px 0;
}

.nav-item.nav-soon {
  color: var(--muted);
  opacity: 0.7;
}
.nav-item.nav-soon svg { opacity: 0.55; }
.nav-item.nav-soon::after {
  content: "Yakında";
  margin-left: auto;
  font-size: 9px;
  font-weight: 700;
  background: var(--border);
  color: var(--muted);
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.nav-item.nav-soon:hover {
  background: var(--border-soft);
  color: var(--text-2);
}

/* ============================================
   View Header
   ============================================ */
.view-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  gap: 16px;
  flex-wrap: wrap;
}

.view-header h1 {
  margin: 0 0 4px;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text);
}

.subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
}

.header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

#hkKargoToggleBtn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
#hkKargoToggleBtn.active {
  background: var(--accent, #b45309);
  color: #fff;
  border-color: var(--accent, #b45309);
}
