/* ==========================================================================
   VOZOL CENTER - RAPOR PANELİ
   Tek parça, düzen toparlayıcı master CSS
   ========================================================================== */

/* ---- Reset / Base ---- */
*,
*::before,
*::after { box-sizing: border-box; }

html, body {
  height: 100%;
}

body {
  margin: 0;
  background: #f4f6fb;
  color: #0f172a;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  line-height: 1.45;
}

/* ---- Root Tokens ---- */
:root {
  --bg: #f4f6fb;
  --panel-bg: #ffffff;
  --sidebar-bg: #3b3f55;
  --sidebar-bg-2: #2f3346;

  --accent: #ff7a1a;
  --accent-2: #ff9b4a;

  --text: #0f172a;
  --muted: #6b7280;
  --white: #ffffff;

  --border: #e5e7eb;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;

  --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
}

/* ---- Layout Shell ---- */
.app {
  display: flex;
  min-height: 100vh;
  background: var(--bg);
}

/* ---- Sidebar ---- */
.sidebar {
  width: 260px;
  background: linear-gradient(180deg, var(--sidebar-bg), var(--sidebar-bg-2));
  color: var(--white);
  padding: 22px 18px;
  position: sticky;
  top: 0;
  height: 100vh;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 6px 18px 6px;
  border-bottom: 1px dashed rgba(255,255,255,0.12);
  margin-bottom: 18px;
}

.sidebar-brand .dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #ffcf9d, var(--accent));
  box-shadow: 0 0 0 3px rgba(255,122,26,0.2);
}

.sidebar-brand .title {
  font-weight: 700;
  letter-spacing: 0.4px;
  font-size: 15px;
  text-transform: uppercase;
}

/* Sidebar menu */
.sidebar-menu {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 10px;
}

.sidebar-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  padding: 11px 12px;
  border-radius: 10px;
  transition: 0.15s ease;
  font-weight: 500;
  font-size: 14px;
}

.sidebar-menu a:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
}

.sidebar-menu a.active {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  color: #fff;
  box-shadow: 0 6px 18px rgba(255, 122, 26, 0.28);
}

/* If icons are used */
.sidebar-menu i,
.sidebar-menu svg {
  width: 18px;
  height: 18px;
  opacity: 0.9;
}

/* ---- Main Content ---- */
.main {
  flex: 1;
  padding: 26px 28px 60px 28px;
}

/* Topbar row (optional) */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.page-title {
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 14px 0;
}

/* ---- Filter Row ---- */
.filter-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 6px 0 18px 0;
}

.filter-row label {
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
}

select, input[type="month"], input[type="date"], input[type="text"] {
  height: 36px;
  padding: 0 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  outline: none;
  transition: 0.12s ease;
}

select:focus,
input:focus {
  border-color: rgba(255, 122, 26, 0.45);
  box-shadow: 0 0 0 3px rgba(255, 122, 26, 0.12);
}

.btn {
  height: 36px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  color: #fff;
  font-weight: 600;
  font-size: 12.5px;
  letter-spacing: 0.2px;
  cursor: pointer;
  transition: 0.15s ease;
}

.btn:hover {
  transform: translateY(-1px);
  filter: brightness(0.98);
}

.btn.secondary {
  background: #fff;
  color: var(--text);
  border-color: var(--border);
}

/* ---- Cards / Info Boxes ---- */
.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.card {
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  box-shadow: var(--shadow-sm);
}

.card-title {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 6px 0;
}

.card-value {
  font-size: 18px;
  font-weight: 800;
  margin: 0 0 2px 0;
}

.card-sub {
  font-size: 12.5px;
  color: var(--muted);
  margin: 0;
}

/* Highlight card (monthly summary style) */
.card.highlight {
  border-color: rgba(255, 122, 26, 0.25);
  background:
    linear-gradient(0deg, rgba(255, 122, 26, 0.04), rgba(255, 122, 26, 0.04)),
    #fff;
}

/* ---- KPI Row (if you use 2 columns later) ---- */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 14px;
}

@media (max-width: 900px) {
  .sidebar { width: 230px; }
  .kpi-grid { grid-template-columns: 1fr; }
}

/* ---- Chart Section ---- */
.section {
  margin-top: 18px;
}

.section-title {
  font-size: 16px;
  font-weight: 800;
  margin: 0 0 6px 0;
}

.section-sub {
  font-size: 12.5px;
  color: var(--muted);
  margin: 0 0 10px 0;
}

.chart-card {
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 18px 22px 18px;
  box-shadow: var(--shadow-sm);
  min-height: 260px;
}

/* Canvas chart fix */
.chart-card canvas {
  max-width: 100% !important;
}

/* ---- Tables (if used in Sales / Expenses) ---- */
.table-wrap {
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.8px;
}

thead {
  background: #f8fafc;
}

th, td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: middle;
}

th {
  font-size: 12px;
  color: #334155;
  font-weight: 700;
}

tbody tr:hover {
  background: #fafbff;
}

/* ---- Badges (Payment types) ---- */
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2px;
  color: #fff;
}

.badge.havale {
  background: #46cd93;
}

.badge.kapida {
  background: #e66793;
}

/* ---- Forms ---- */
.form-card {
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 12px;
}

.form-row .field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field label {
  font-size: 12px;
  font-weight: 700;
  color: #334155;
}

.field input,
.field select {
  height: 38px;
}

@media (max-width: 720px) {
  .main { padding: 22px 16px 50px 16px; }
  .form-row { grid-template-columns: 1fr; }
}

/* ---- Utility ---- */
.muted { color: var(--muted); }
.hr {
  height: 1px;
  background: var(--border);
  border: 0;
  margin: 14px 0;
}

/* ---- Footer (optional) ---- */
.footer {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 16px;
}

/* ---- Responsive Sidebar Collapse (optional class) ---- */
@media (max-width: 1024px) {
  .sidebar {
    position: fixed;
    left: 0;
    z-index: 50;
    transform: translateX(0);
    transition: 0.2s ease;
  }

  .sidebar.is-collapsed {
    transform: translateX(-100%);
  }

  .main {
    margin-left: 0;
  }
}

/* ---- If your layout uses old class names, map them here ---- */
/* Eski yapıyla uyum için alias sınıfları (istersen silersin) */
.header-desktop-main-div {
  background: #fff;
  border-bottom: 1px solid var(--border);
}

/* Card alias */
.dashboard-card,
.summary-box,
.box {
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  box-shadow: var(--shadow-sm);
}

/* Sidebar alias */
.left-menu,
.side-menu {
  background: linear-gradient(180deg, var(--sidebar-bg), var(--sidebar-bg-2));
  color: #fff;
}

/* Yeni Stok Ekle - Ürün Adı / Toplam Adet satırını düzelt */
.new-stock-box,
.stock-form,
.stock-add-box,
.yeni-stok-ekle {
  /* kutu zaten varsa dokunmaz, yoksa düzenler */
}

/* Form içindeki ilk iki label + input alanını aynı satıra toparlamaya çalış */
.new-stock-box form,
.stock-form form,
.stock-add-box form {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  flex-wrap: wrap;
}

/* Label + input blokları */
.new-stock-box label,
.stock-form label,
.stock-add-box label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-weight: 700;
  font-size: 12px;
  color: #334155;
  min-width: 180px;
}

/* Inputlar */
.new-stock-box input[type="text"],
.new-stock-box input[type="number"],
.stock-form input[type="text"],
.stock-form input[type="number"],
.stock-add-box input[type="text"],
.stock-add-box input[type="number"] {
  height: 36px;
  padding: 0 10px;
  border: 1px solid #dfe5ff;
  border-radius: 10px;
  width: 220px;
  max-width: 100%;
}

/* Ekle butonunu aynı hizaya çek */
.new-stock-box button,
.stock-form button,
.stock-add-box button {
  height: 36px;
  padding: 0 16px;
  border-radius: 999px;
}


.form-row{display:flex;gap:12px;align-items:flex-end;flex-wrap:wrap}
.form-row .form-group{min-width:200px}


/* ============================
   STOK SAYFASI FORM DÜZELTME
   ============================ */

/* Form row hizası */
.form-row.stock-form-row{
  display: flex;
  align-items: flex-end;
  gap: 14px;
  flex-wrap: wrap;
}

/* Form alanları */
.stock-form .form-group{
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 220px;
}

/* Label */
.stock-form .form-group label{
  font-size: 12px;
  font-weight: 700;
  color: #334155;
}

/* Inputlar */
.stock-form .form-group input[type="text"],
.stock-form .form-group input[type="number"]{
  height: 36px;
  padding: 0 10px;
  border: 1px solid #dfe5ff;
  border-radius: 8px;
  width: 240px;
  max-width: 100%;
  background: #fff;
}

/* Buton alanı */
.stock-form .form-actions{
  display: flex;
  align-items: flex-end;
}

/* Buton */
.stock-form .btn-primary{
  height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  font-weight: 700;
  font-size: 12.5px;
  color: #fff;
  background: linear-gradient(90deg, #ff7a1a, #ff9a4a);
  box-shadow: 0 8px 18px rgba(255,122,26,0.20);
}

/* Mobilde alt alta */
@media (max-width: 640px){
  .stock-form .form-group{
    min-width: 100%;
  }

  .stock-form .form-group input{
    width: 100%;
  }

  .stock-form .form-actions,
  .stock-form .btn-primary{
    width: 100%;
  }
}

