/* RESTOM_TEMA_V1 - Genel gorunum katmani (en son yuklenir).
   Yalniz renk, kose, golge, yazi agirligi, odak halkasi ve gecis tanimlar; boyut ve yerlesim degistirmez.
   Ust cubuk, bolge sekmeleri ve masa kartlari kendi dosyalarindadir; burada dokunulmaz. */
:root {
  --rt-acc: #10b981; --rt-acc-d: #047857; --rt-acc-soft: rgba(16, 185, 129, .1);
  --rt-grad: linear-gradient(135deg, #10b981, #047857);
  --rt-radius: 12px; --rt-radius-lg: 18px;
  --rt-shadow: 0 1px 3px rgba(16, 24, 40, .06), 0 1px 2px rgba(16, 24, 40, .04);
  --rt-shadow-lg: 0 12px 28px rgba(16, 24, 40, .12);
  --rt-ring: 0 0 0 4px rgba(16, 185, 129, .18);
}
html body { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
html body ::selection { background: rgba(16, 185, 129, .22); }

/* Kaydirma cubugu */
html body * { scrollbar-width: thin; scrollbar-color: rgba(100, 116, 139, .35) transparent; }
html body ::-webkit-scrollbar { width: 8px; height: 8px; }
html body ::-webkit-scrollbar-thumb { background: rgba(100, 116, 139, .32); border-radius: 8px; border: 2px solid transparent; background-clip: padding-box; }
html body ::-webkit-scrollbar-thumb:hover { background-color: rgba(100, 116, 139, .5); }

/* Dugmeler */
html body .btn { border-radius: var(--rt-radius); font-weight: 700; letter-spacing: .01em; transition: transform .12s ease, box-shadow .15s ease, background-color .15s ease, border-color .15s ease; }
html body .btn:not(:disabled):hover { box-shadow: 0 4px 12px rgba(16, 24, 40, .1); }
html body .btn:not(:disabled):active { transform: translateY(1px); }
html body .btn-primary, html body .btn-settings-save { background: var(--rt-grad); border-color: transparent; color: #fff; box-shadow: 0 6px 14px rgba(16, 185, 129, .22); }
html body .btn-primary:not(:disabled):hover, html body .btn-settings-save:not(:disabled):hover { box-shadow: 0 8px 18px rgba(16, 185, 129, .3); filter: saturate(1.05); }
html body .btn-outline { border: 1px solid var(--border-color, #e5e7eb); background: var(--card-bg, #fff); }
html body .btn:focus-visible, html body .icon-btn:focus-visible, html body .nav-item:focus-visible, html body .tab-pill:focus-visible { outline: none; box-shadow: var(--rt-ring); }
html body .icon-btn { border-radius: 10px; transition: background-color .15s ease, color .15s ease; }

/* Formlar */
html body .settings-input, html body .settings-select,
html body .modal-content input[type="text"], html body .modal-content input[type="number"], html body .modal-content input[type="tel"],
html body .modal-content input[type="email"], html body .modal-content input[type="password"], html body .modal-content input[type="date"],
html body .modal-content select, html body .modal-content textarea {
  border-radius: var(--rt-radius); border-width: 1.5px; transition: border-color .15s ease, box-shadow .15s ease;
}
html body .settings-input:focus, html body .settings-select:focus,
html body .modal-content input:focus, html body .modal-content select:focus, html body .modal-content textarea:focus {
  outline: none; border-color: var(--rt-acc); box-shadow: var(--rt-ring);
}
html body .settings-toggle input:checked + .toggle-slider { background: var(--rt-grad); }
html body .settings-toggle input:focus-visible + .toggle-slider { box-shadow: var(--rt-ring); }

/* Kartlar ve paneller */
html body .premium-card, html body .stat-card { border-radius: var(--rt-radius-lg); box-shadow: var(--rt-shadow); border: 1px solid var(--border-color, #e5e7eb); }
html body .stat-icon { border-radius: 13px; }
html body .stat-value { font-weight: 800; letter-spacing: -.02em; }
html body .stat-label { font-weight: 700; letter-spacing: .04em; text-transform: uppercase; font-size: .74rem; }
html body .settings-title { font-weight: 800; letter-spacing: -.01em; }
html body .settings-section-label { font-weight: 800; letter-spacing: .06em; text-transform: uppercase; font-size: .72rem; color: var(--text-muted, #6b7280); }
html body .settings-row { border-radius: var(--rt-radius); transition: background-color .15s ease; }
html body .settings-row:hover { background: var(--rt-acc-soft); }
html body .settings-divider { opacity: .7; }

/* Sekmeler */
html body .tab-pill { border-radius: var(--rt-radius); font-weight: 700; transition: background .15s ease, color .15s ease, box-shadow .15s ease; }
html body .tab-pill.active { background: var(--rt-grad); color: #fff; border-color: transparent; box-shadow: 0 6px 14px rgba(16, 185, 129, .25); }

/* Kenar menu */
html body .nav-item { border-radius: var(--rt-radius); font-weight: 600; transition: background-color .15s ease, color .15s ease; }
html body .nav-item:hover { background: var(--rt-acc-soft); }
html body .nav-item.active { background: var(--rt-acc-soft); color: var(--rt-acc-d); font-weight: 800; box-shadow: inset 3px 0 0 var(--rt-acc); }
html body .settings-nav-item { border-radius: var(--rt-radius); font-weight: 600; transition: background-color .15s ease, color .15s ease; }
html body .settings-nav-item:hover { background: var(--rt-acc-soft); }
html body .settings-nav-item.active { background: var(--rt-acc-soft); color: var(--rt-acc-d); font-weight: 800; }

/* Tablolar */
html body .data-table, html body .settings-table { border-collapse: separate; border-spacing: 0; }
html body .data-table th, html body .settings-table th { font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted, #6b7280); background: var(--bg-main, #f3f4f6); }
html body .data-table th:first-child, html body .settings-table th:first-child { border-top-left-radius: 10px; }
html body .data-table th:last-child, html body .settings-table th:last-child { border-top-right-radius: 10px; }
html body .data-table tbody tr, html body .settings-table tbody tr { transition: background-color .12s ease; }
html body .data-table tbody tr:hover, html body .settings-table tbody tr:hover { background: var(--rt-acc-soft); }

/* Acilir pencereler */
html body .modal { backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
html body .modal-content { border-radius: 20px; box-shadow: 0 30px 70px rgba(15, 23, 42, .28); }

/* Raporlar sayfa basligi */
html body #reportsView .report-header h2 { font-weight: 900; letter-spacing: -.03em; }

/* Tam genislik (RESTOM_TEMA_V2): paket servis ve ayarlar ekrani ortada dar kalmaz, tum genislige yayilir */
html body .package-order-wrapper, html body .package-service-screen .package-order-wrapper { max-width: none; }
html body #tablesGrid.pk-v1 { width: 100%; max-width: none; }
html body .settings-layout { width: 100%; }
@media (min-width: 1025px) { html body .settings-content { padding: 24px 28px; } }
@media (max-width: 768px) { html body .settings-content { padding: 16px 12px; } }

/* Dar kenar bosluklari (RESTOM_TEMA_V3): icerik ekranin kenarlarina kadar uzanir */
@media (min-width: 769px) {
  html body .app-container .main-wrapper, html body.sidebar-hidden .main-wrapper { padding-left: 8px !important; padding-right: 8px !important; padding-bottom: 8px !important; gap: 10px !important; }
  html body.sidebar-hidden .top-bar { margin-top: 8px !important; }
}
@media (max-width: 768px) {
  html body .app-container .main-wrapper, html body.sidebar-hidden .main-wrapper { padding-left: 6px !important; padding-right: 6px !important; gap: 8px !important; }
}

/* Karanlik tema */
body.dark-mode { --rt-acc-soft: rgba(16, 185, 129, .14); }
body.dark-mode .nav-item.active, body.dark-mode .settings-nav-item.active { color: #6ee7b7; }
body.dark-mode .btn-outline { background: transparent; }

@media (prefers-reduced-motion: reduce) {
  html body .btn, html body .nav-item, html body .tab-pill, html body .settings-row { transition: none; }
}
