:root {
  --bg: #0f172a;
  --bg-pattern: #111827;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --border: #e2e8f0;
  --text: #1e293b;
  --text-muted: #64748b;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --accent: #f59e0b;
  --accent-hover: #d97706;
  --brand-dark: #0b1220;
  --brand-mid: #1e3a5f;
  --brand-light: #3b82f6;
  --danger: #dc2626;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.08), 0 4px 12px rgba(15, 23, 42, 0.04);
  --font: "DM Sans", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font);
  background:
    radial-gradient(circle at 20% 0%, rgba(37, 99, 235, 0.18), transparent 42%),
    radial-gradient(circle at 80% 10%, rgba(245, 158, 11, 0.12), transparent 38%),
    linear-gradient(180deg, var(--bg) 0%, #1a2332 220px, #eef2f7 220px, #eef2f7 100%);
  color: var(--text);
  line-height: 1.5;
  min-height: 100vh;
}

.app {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1.5rem;
  padding-bottom: 5.5rem;
}

/* Header — logo / marka paneli */
.header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding: 1.25rem 1.5rem;
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.header-brand-panel {
  background: linear-gradient(135deg, var(--brand-dark) 0%, var(--brand-mid) 55%, #0f2744 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.header-brand-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 12px,
      rgba(255, 255, 255, 0.02) 12px,
      rgba(255, 255, 255, 0.02) 24px
    );
  pointer-events: none;
}

.header-brand-panel .header-brand,
.header-brand-panel .header-toolbar,
.header-brand-panel .header-nav {
  position: relative;
  z-index: 1;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex: 1;
  min-width: 280px;
  padding-right: 11.5rem;
}

.header-titles {
  flex: 1;
  min-width: 0;
}

.header-app-title {
  margin: 0;
  font-size: clamp(1.45rem, 2.8vw, 2.15rem);
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  line-height: 1.08;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
  white-space: nowrap;
}

.logo-icon {
  width: 100px;
  height: 100px;
  padding: 6px;
  border-radius: 16px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  box-shadow:
    0 0 0 3px rgba(37, 99, 235, 0.18),
    0 10px 26px rgba(0, 0, 0, 0.28);
  background: #ffffff;
  flex-shrink: 0;
}

/* logo-placeholder gradient'ini ez; ana logo her zaman beyaz zeminde */
.logo-placeholder.logo-icon {
  width: 100px;
  height: 100px;
  padding: 6px;
  border-radius: 16px;
  background: #ffffff !important;
  background-image: none !important;
  color: inherit;
  overflow: hidden;
}

.logo-icon img,
.logo-placeholder.logo-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: transparent;
  border-radius: 12px;
}

.logo-brand {
  width: auto;
  max-width: 240px;
  height: 76px;
  padding: 8px 12px;
  border-radius: 12px;
  border: none;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28);
  background: #fff;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.logo-placeholder {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  overflow: hidden;
  flex-shrink: 0;
}

.logo-brand img {
  width: auto;
  height: 100%;
  max-width: 100%;
  object-fit: contain;
  background: transparent;
}

.logo-placeholder img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: transparent;
}

.header-brand-panel h1 {
  font-size: 1.55rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.service-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.45rem;
  margin-top: 0.35rem;
  max-width: 720px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.service-tags span {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fef3c7;
  background: rgba(245, 158, 11, 0.18);
  border: 1px solid rgba(245, 158, 11, 0.35);
  white-space: nowrap;
}

.header-brand-panel .nav-btn {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
  color: #e2e8f0;
}

.header-brand-panel .nav-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(245, 158, 11, 0.5);
  color: #fff;
}

.header-brand-panel .nav-btn.active {
  background: linear-gradient(135deg, var(--accent), #ea580c);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.35);
}

.header-brand-panel .btn-outline {
  border-color: rgba(255, 255, 255, 0.25);
  color: #e2e8f0;
}

.header-brand-panel .btn-outline:hover {
  border-color: var(--accent);
  color: #fff;
  background: rgba(245, 158, 11, 0.15);
}

.header-brand-panel .staff-badge {
  background: rgba(34, 197, 94, 0.2);
  color: #bbf7d0;
  border: 1px solid rgba(34, 197, 94, 0.35);
}

.header h1 {
  font-size: 1.35rem;
  font-weight: 700;
}

.subtitle {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.header-nav {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  flex: 1;
  min-width: 0;
}

.header-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.75rem;
  flex: 1 1 100%;
  width: 100%;
}

.header-staff-panel {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  left: auto;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.28rem;
  min-width: 0;
  padding: 0.38rem;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.22);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.22);
}

.header-staff-row {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 0.28rem;
}

.header-staff-row .header-icon-btn,
.header-staff-row .nav-btn {
  flex: 1 1 0;
  width: auto;
  min-width: 72px;
}

.header-icon-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  width: 100%;
  min-width: 68px;
  min-height: 3.15rem;
  padding: 0.42rem 0.35rem;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: #e2e8f0;
  font-family: inherit;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.15;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.header-icon-btn:hover {
  background: rgba(255, 255, 255, 0.11);
  border-color: rgba(245, 158, 11, 0.4);
  color: #fff;
}

.header-icon-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.header-icon-btn span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.header-staff-panel .nav-btn {
  width: auto;
  min-width: 72px;
  min-height: 3.15rem;
  padding: 0.42rem 0.35rem;
  font-size: 0.7rem;
  font-weight: 600;
  border-radius: 9px;
  box-shadow: none;
}

body:not(.staff-authenticated) .header-staff-row-auth #staffLoginBtn {
  flex: 0 0 auto;
}

.header-icon-btn-active {
  cursor: default;
  background: rgba(34, 197, 94, 0.18);
  border-color: rgba(34, 197, 94, 0.4);
  color: #bbf7d0;
}

.header-icon-btn-active:hover {
  background: rgba(34, 197, 94, 0.18);
  border-color: rgba(34, 197, 94, 0.4);
  color: #bbf7d0;
}

.header-staff-panel .nav-btn-settings.active {
  background: linear-gradient(135deg, #64748b 0%, #475569 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.3);
}

.header-staff-panel .nav-btn-raporlama.active {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.35);
}

.header-staff-panel .nav-btn-silinenler.active {
  background: linear-gradient(135deg, #64748b 0%, #475569 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.3);
}

.header-staff-panel .nav-btn-icon-only {
  flex: 0 0 auto;
  min-width: 3.15rem;
  width: 3.15rem;
  padding: 0.42rem;
}

.header-staff-panel .nav-btn-icon-only span {
  display: none;
}

.staff-badge {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: #dcfce7;
  color: #166534;
  font-size: 0.75rem;
  font-weight: 600;
}

body:not(.staff-authenticated) .staff-only {
  display: none !important;
}

body:not(.customer-authenticated) .customer-only {
  display: none !important;
}

body.customer-authenticated .customer-guest-only,
body.staff-authenticated .customer-guest-only {
  display: none !important;
}

body.staff-authenticated .customer-only {
  display: none !important;
}

body:not(.staff-admin) .admin-only {
  display: none !important;
}

body.staff-authenticated #staffLoginBtn {
  display: none !important;
}

.customer-auth-grid,
.customer-dash-grid {
  align-items: start;
}

.musteri-hesap-view {
  display: none;
}

.musteri-hesap-view.active {
  display: block;
}

.company-contact-bar {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 3rem);
  max-width: 1280px;
  bottom: 1rem;
  z-index: 40;
  margin: 0;
  padding: 0.55rem 0.9rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 10px;
  background: rgba(248, 250, 252, 0.92);
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(6px);
  color: #64748b;
}

.company-contact-inner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.company-contact-bar .company-contact-logo,
.company-contact-bar .logo-placeholder.company-contact-logo {
  width: 36px;
  height: 36px;
  padding: 3px;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  box-shadow: none;
  background: #fff !important;
  flex-shrink: 0;
}

.company-contact-bar .company-contact-logo img,
.company-contact-bar .logo-placeholder.company-contact-logo img {
  border-radius: 5px;
}

.company-contact-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.company-contact-line {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 500;
  line-height: 1.35;
  color: #64748b;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.company-contact-line a {
  color: #64748b;
  text-decoration: none;
}

.company-contact-line a:hover {
  color: #475569;
  text-decoration: underline;
}

.company-contact-sep {
  margin: 0 0.35rem;
  color: #cbd5e1;
  font-weight: 400;
}

.app {
  padding-bottom: 5.5rem;
}

.customer-dash-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 1rem 0 0.75rem;
}

.customer-dash-tab {
  border: 1px solid var(--border, #d5dbe5);
  background: #f8fafc;
  color: #334155;
  border-radius: 8px;
  padding: 0.45rem 0.8rem;
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
}

.customer-dash-tab:hover {
  border-color: #94a3b8;
}

.customer-dash-tab.active {
  background: #0f172a;
  border-color: #0f172a;
  color: #fff;
}

.customer-dash-panel {
  margin-top: 0.75rem;
}

.customer-open-total {
  margin-bottom: 0.85rem;
  padding: 0.75rem 0.9rem;
  border-radius: 8px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #9a3412;
}

.customer-claim-box {
  margin-top: 0.85rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border, #e2e8f0);
}

.customer-claim-box summary {
  cursor: pointer;
  font-weight: 600;
  color: #475569;
}

.customer-account-form .btn {
  margin-top: 0.35rem;
}

.customer-dashboard .history-item {
  margin-bottom: 0.65rem;
}

body.customer-authenticated #customerRegisterCard,
body.customer-authenticated #customerAuthPanels,
body.customer-authenticated #customerAccountIntroGuest {
  display: none !important;
}

.login-default-hint {
  margin-bottom: 0.75rem;
}

.login-reset-hint {
  margin-top: 0.85rem;
  margin-bottom: 0;
  text-align: center;
}

.app-users-editor {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin: 1rem 0;
}

.app-user-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.9fr 1.1fr auto auto;
  gap: 0.5rem;
  align-items: center;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2, #f8fafc);
}

.app-user-row input,
.app-user-row select {
  width: 100%;
  min-width: 0;
}

.app-user-active {
  margin: 0;
  white-space: nowrap;
  font-size: 0.82rem;
}

@media (max-width: 900px) {
  .app-user-row {
    grid-template-columns: 1fr 1fr;
  }

  .app-user-row .app-user-remove {
    grid-column: 2;
    justify-self: end;
  }
}

.link-btn {
  background: none;
  border: none;
  padding: 0;
  color: var(--primary);
  font: inherit;
  font-size: 0.85rem;
  cursor: pointer;
  text-decoration: underline;
}

.public-intro {
  background: linear-gradient(135deg, #eff6ff 0%, #fffbeb 100%);
  border-left: 4px solid var(--accent);
}

.baski-subsection {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem 1.1rem;
  margin-bottom: 1rem;
  background: var(--surface-soft);
}

.baski-subsection legend {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--primary);
  padding: 0 0.35rem;
}

.subsection-toggle {
  margin-bottom: 0.75rem;
}

.subsection-body {
  padding-top: 0.25rem;
}

.staff-baski-block {
  margin-top: 0.75rem;
}

.attachment-section {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.attachment-section h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.upload-zone {
  border: 2px dashed #cbd5e1;
  border-radius: 12px;
  background: #f8fafc;
  padding: 1.25rem 1rem;
  text-align: center;
  transition: border-color 0.15s, background 0.15s;
  cursor: pointer;
}

.upload-zone:hover,
.upload-zone.dragover {
  border-color: var(--primary);
  background: #eff6ff;
}

.upload-zone-inner p {
  margin: 0.35rem 0;
  font-size: 0.9rem;
  color: var(--text);
}

.upload-icon {
  display: inline-flex;
  width: 2.5rem;
  height: 2.5rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #dbeafe;
  color: var(--primary);
  font-size: 1.1rem;
  margin-bottom: 0.35rem;
}

.upload-hint {
  font-size: 0.8rem !important;
  margin-top: 0.25rem !important;
}

.attachment-list {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.attachment-list:empty {
  display: none;
}

.attachment-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
}

.attachment-preview {
  width: 52px;
  height: 52px;
  border-radius: 8px;
  object-fit: cover;
  background: #f1f5f9;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.attachment-preview.file-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.attachment-meta {
  flex: 1;
  min-width: 0;
}

.attachment-name {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.attachment-size {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.attachment-remove {
  flex-shrink: 0;
}

.attachment-gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 0.65rem;
}

.attachment-gallery img {
  width: 88px;
  height: 88px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #fff;
}

.attachment-file-list {
  margin: 0.35rem 0 0;
  padding-left: 1rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.attachment-file-list li {
  margin-bottom: 0.2rem;
}

.public-submit-row {
  margin-top: 1rem;
}

.btn-lg {
  padding: 0.85rem 1.5rem;
  font-size: 1rem;
}

.success-msg {
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  border-radius: 8px;
  background: #dcfce7;
  color: #166534;
  font-size: 0.9rem;
  font-weight: 500;
}

.error-msg {
  margin-top: 0.5rem;
  color: var(--danger);
  font-size: 0.85rem;
}

.muracaat-summary-list {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--text);
  font-size: 0.9rem;
}

.muracaat-summary-list li {
  margin-bottom: 0.35rem;
}

.linked-muracaat-preview .print-muracaat-item,
.linked-muracaat-body .print-muracaat-item {
  margin-bottom: 0.75rem;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal[hidden] {
  display: none !important;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  z-index: 0;
}

.modal-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.2);
}

.modal-card h2 {
  margin-bottom: 0.5rem;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 1.25rem;
}

.nav-btn {
  padding: 0.55rem 1rem;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  color: var(--text);
  transition: all 0.15s;
}

.nav-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.nav-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

/* Layout */
.main {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.tab-panel {
  display: none;
  flex-direction: column;
  gap: 1.25rem;
}

.tab-panel.active {
  display: flex;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.25rem;
}

.teklif-services-layout {
  grid-template-columns: minmax(0, 1fr) minmax(260px, 300px);
  align-items: start;
}

.teklif-services-card {
  min-width: 0;
}

.teklif-services-layout .summary-card {
  position: sticky;
  top: 0.75rem;
  max-height: calc(100vh - 1.5rem);
  overflow-y: auto;
  padding: 1rem 1.15rem;
}

.teklif-services-layout .summary-card h2 {
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

.teklif-services-layout .summary-card .form-row {
  margin-bottom: 0.65rem;
}

.teklif-services-layout .summary-card .summary-row {
  padding: 0.45rem 0;
  font-size: 0.85rem;
}

.teklif-services-layout .summary-card .summary-row.total {
  font-size: 1rem;
}

.teklif-services-layout .summary-card .action-buttons-share {
  margin-top: 0.85rem;
  gap: 0.45rem;
}

.teklif-services-layout .summary-card .action-buttons-share .btn {
  padding: 0.45rem 0.65rem;
  font-size: 0.78rem;
}

.teklif-services-layout .summary-card .share-hint {
  font-size: 0.75rem;
  line-height: 1.35;
}

@media (max-width: 1100px) {
  .teklif-services-layout {
    grid-template-columns: 1fr;
  }

  .teklif-services-layout .summary-card {
    position: static;
    max-height: none;
    overflow: visible;
  }
}

.card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.card-wide {
  grid-column: 1 / -1;
}

.card h2 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text);
}

.card-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.card-header-row h2 {
  margin-bottom: 0;
}

/* Forms */
.form-row {
  margin-bottom: 0.85rem;
}

.form-row label {
  display: block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}

.required {
  color: var(--danger);
}

.history-filters {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-select {
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.85rem;
  background: #fff;
  min-width: 200px;
}

.country-badge {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  background: #e0e7ff;
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 600;
}

.form-row input,
.form-row select,
.form-row textarea {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9rem;
  color: var(--text);
  background: #fff;
  transition: border-color 0.15s;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(29, 78, 216, 0.12);
}

.form-row input[readonly] {
  background: #f8fafc;
  color: var(--text-muted);
}

.extra-panel {
  margin: 0.5rem 0 1rem 1.75rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f8fafc;
}

.muracaat-card {
  margin-bottom: 1.25rem;
}

.muracaat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem 1.5rem;
  margin-bottom: 1rem;
}

.muracaat-block {
  min-width: 0;
}

.form-row.inline-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

@media (max-width: 900px) {
  .muracaat-grid {
    grid-template-columns: 1fr;
  }

  .form-row.inline-2 {
    grid-template-columns: 1fr;
  }
}

.extra-hint,
.extra-total {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.extra-total {
  margin-top: 0.75rem;
  color: var(--text);
}

.extra-total strong {
  color: var(--primary);
}

.extra-breakdown {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

.extra-breakdown .breakdown-line {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.2rem 0;
}

.equipment-fieldset {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin: 0.75rem 0;
  background: #fff;
}

.equipment-fieldset legend {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 0 0.35rem;
}

.inline-extra {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.inline-extra input {
  width: 120px;
}

.kargo-panel {
  margin-top: 0.35rem;
}

.kargo-panel textarea,
.kargo-panel select,
.kargo-panel input[type="text"],
.kargo-panel input[type="number"] {
  width: 100%;
}

.kargo-panel .inline-extra label {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  cursor: pointer;
}

.radio-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.45rem;
  font-size: 0.9rem;
  cursor: pointer;
}

.teslimat-block {
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}

.muracaat-subtitle {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  font-weight: 600;
}

.teslimat-options {
  border: none;
  margin: 0;
  padding: 0;
}

.teslimat-expand-btn {
  display: block;
  margin: 0.4rem 0 0.15rem;
  padding: 0.2rem 0;
  border: none;
  background: none;
  color: var(--primary);
  font-family: inherit;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.teslimat-expand-btn:hover {
  color: var(--accent);
}

.teslimat-extra-options {
  margin-top: 0.4rem;
  padding-top: 0.45rem;
  border-top: 1px dashed var(--border);
}

.summary-card .teslimat-expand-btn {
  color: #2563eb;
}

.summary-card .teslimat-expand-btn:hover {
  color: #1d4ed8;
}

.inline-hint {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.78rem;
}

/* Ayarlar sayfası */
.settings-page-hero {
  display: flex;
  align-items: center;
  gap: 1.15rem;
  margin-bottom: 1rem;
  padding: 1.35rem 1.5rem;
  background: linear-gradient(135deg, #f8fafc 0%, #eef2ff 55%, #f0fdf4 100%);
  border: 1px solid rgba(37, 99, 235, 0.15);
  box-shadow: 0 4px 18px rgba(37, 99, 235, 0.08);
}

.settings-page-icon.settings-page-logo,
.settings-page-logo {
  background: #ffffff !important;
  background-image: none !important;
  border: 1px solid rgba(15, 23, 42, 0.1);
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.1);
  padding: 6px;
  width: 96px;
  height: 96px;
  min-width: 96px;
  border-radius: 16px;
  color: inherit;
}

.settings-page-logo img {
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: contain;
  border-radius: 12px;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.settings-logo-row {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.settings-logo-preview {
  width: 132px;
  height: 132px;
  flex-shrink: 0;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #ffffff !important;
  background-image: none !important;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  box-sizing: border-box;
}

.settings-logo-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.settings-logo-fields {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.settings-logo-fields .hint {
  margin: 0;
}

.settings-page-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 16px;
  flex-shrink: 0;
  color: #fff;
  background: linear-gradient(145deg, #475569 0%, #334155 100%);
  box-shadow:
    0 8px 20px rgba(51, 65, 85, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.settings-page-intro h2 {
  margin: 0 0 0.35rem;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text);
}

.settings-page-intro .hint {
  margin: 0;
}

.settings-section-card {
  border-left: 4px solid rgba(71, 85, 105, 0.35);
}

.settings-section-title {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
}

.settings-section-card .card-header-row .settings-section-title {
  margin-bottom: 0;
}

.file-input {
  margin-top: 0.5rem;
  font-size: 0.85rem;
}

.hint {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.hint-block {
  margin-bottom: 1rem;
}

/* Table */
.table-wrap {
  overflow-x: auto;
}

.items-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.items-table th {
  text-align: left;
  padding: 0.65rem 0.5rem;
  font-weight: 600;
  color: var(--text-muted);
  border-bottom: 2px solid var(--border);
  white-space: nowrap;
}

.items-table td {
  padding: 0.5rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.items-table select,
.items-table input {
  width: 100%;
  min-width: 80px;
  padding: 0.45rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.85rem;
}

.items-table .col-urun { min-width: 160px; }
.items-table .col-ebat { min-width: 110px; }
.items-table .col-kagit { min-width: 130px; }
.items-table .col-renk { min-width: 100px; }
.items-table .col-adet { min-width: 70px; }
.items-table .col-fiyat { min-width: 90px; }
.items-table .col-tutar { min-width: 90px; font-weight: 600; }

/* Summary */
.summary-card .summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
}

.summary-card .summary-row.total {
  border-bottom: none;
  border-top: 2px solid var(--text);
  margin-top: 0.5rem;
  padding-top: 0.85rem;
  font-size: 1.1rem;
  font-weight: 700;
}

.summary-input {
  width: 70px;
  padding: 0.35rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  text-align: right;
  font-family: inherit;
}

.action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.25rem;
}

.action-buttons-share {
  margin-top: 1rem;
}

.share-hint {
  margin-top: 0.65rem;
  font-size: 0.8rem;
}

.btn-whatsapp {
  background: #25d366;
  color: #fff;
}

.btn-whatsapp:hover {
  background: #1ebe57;
}

.btn-email {
  background: #475569;
  color: #fff;
}

.btn-email:hover {
  background: #334155;
}

.modal-card-wide {
  max-width: 520px;
}

.share-pdf-info {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #f8fafc;
  margin: 1rem 0;
}

.share-pdf-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 8px;
  background: #fee2e2;
  color: #dc2626;
  font-weight: 800;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.share-text-preview {
  white-space: pre-wrap;
  font-family: inherit;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--text-muted);
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem;
  max-height: 140px;
  overflow: auto;
  margin-bottom: 1rem;
}

.share-modal-actions {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 0.85rem;
}

.share-modal-secondary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.share-modal-note {
  margin-top: 0.75rem;
  font-size: 0.8rem;
}

.backup-card {
  border-left: 4px solid var(--primary);
}

.sync-advanced {
  margin: 0.75rem 0 1rem;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border, #d5dbe5);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.02);
}

.sync-advanced summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--muted, #5b6575);
}

.backup-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 0.75rem;
}

.import-label {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  margin: 0;
}

.backup-note {
  font-size: 0.8rem;
  margin-bottom: 0;
}

/* Buttons */
.btn {
  padding: 0.65rem 1.15rem;
  border: none;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-hover);
}

.btn-accent {
  background: var(--accent);
  color: #fff;
}

.btn-accent:hover {
  background: var(--accent-hover);
}

.btn-secondary {
  background: #e0e7ff;
  color: var(--primary);
}

.btn-secondary:hover {
  background: #c7d2fe;
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.btn-danger {
  background: #fee2e2;
  color: var(--danger);
  border: none;
  padding: 0.35rem 0.6rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.8rem;
}

.baski-header {
  margin-bottom: 0.75rem;
}

.baski-header .hint {
  margin: 0;
}

.baski-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  margin-bottom: 0.5rem;
}

.baski-table th {
  text-align: left;
  padding: 0.5rem 0.35rem;
  font-weight: 600;
  color: var(--text-muted);
  border-bottom: 2px solid var(--border);
  white-space: nowrap;
}

.baski-table td {
  padding: 0.4rem 0.35rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.baski-table select,
.baski-table input {
  width: 100%;
  min-width: 70px;
  padding: 0.4rem 0.45rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.82rem;
}

.baski-table .baski-olcu-input {
  min-width: 110px;
}

.baski-table .baski-kapsam-input {
  min-width: 130px;
}

.malzeme-table .malzeme-name-input {
  min-width: 140px;
}

.malzeme-table .malzeme-note-input {
  min-width: 150px;
}

.baski-table .baski-fiyat-input::placeholder {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.baski-format-price-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 0.65rem;
  margin-top: 0.5rem;
}

.baski-format-price-item label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
  color: var(--text-muted);
}

.baski-format-price-item input {
  width: 100%;
  padding: 0.45rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
}

.baski-large-hint {
  margin-top: 0.65rem;
  margin-bottom: 0;
}

.btn-sm {
  padding: 0.45rem 0.85rem;
  font-size: 0.8rem;
}

.status-bar-top {
  margin-bottom: 0;
  background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%);
  border-left: 4px solid var(--primary);
}

.status-bar-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
}

.status-bar-block {
  min-width: 0;
}

.design-approval-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.design-approval-meta .form-row {
  margin-bottom: 0;
}

.grafik-onay-layout {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(320px, 1.1fr);
  gap: 1.25rem;
  align-items: start;
}

.grafik-onay-editor .status-bar-block {
  margin-top: 1rem;
}

.grafik-onay-editor .status-bar-block:first-of-type {
  margin-top: 0.25rem;
}

.grafik-onay-customer {
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.grafik-onay-item {
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.grafik-onay-item.selected {
  border-color: var(--primary);
  background: #eff6ff;
}

.grafik-onay-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 280px;
}

.grafik-onay-empty[hidden],
.grafik-onay-editor[hidden],
#faturalandirEmpty[hidden],
#faturalandirEditor[hidden],
#grafikOnayEmpty[hidden],
#grafikOnayEditor[hidden] {
  display: none !important;
}

.faturalandir-item {
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.grafik-onay-editor .form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

@media (max-width: 900px) {
  .grafik-onay-layout {
    grid-template-columns: 1fr;
  }
}

.status-bar-top .status-tracker-label {
  margin-bottom: 0.65rem;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.status-buttons-main {
  gap: 0.55rem;
}

.status-buttons-main .status-btn {
  padding: 0.6rem 1.1rem;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.status-tracker {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.status-tracker-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.status-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.status-btn {
  padding: 0.45rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fff;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  color: var(--text-muted);
  transition: all 0.15s;
}

.status-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.status-btn.active {
  font-weight: 600;
  color: #fff;
}

.status-btn[data-status="beklemede"].active {
  background: #f59e0b;
  border-color: #f59e0b;
}

.status-btn[data-status="kabul"].active {
  background: #059669;
  border-color: #059669;
}

.status-btn[data-status="red"].active {
  background: #dc2626;
  border-color: #dc2626;
}

.status-btn[data-status="tasarim"].active {
  background: #2563eb;
  border-color: #2563eb;
}

.status-btn[data-status="baski_hazirlik"].active {
  background: #7c3aed;
  border-color: #7c3aed;
}

.status-btn[data-status="baski_onay_isteme"].active {
  background: #ea580c;
  border-color: #ea580c;
}

.status-btn[data-status="baskiya_gonderildi"].active {
  background: #059669;
  border-color: #059669;
}

.status-btn[data-status="onay_bekliyor"].active {
  background: #f59e0b;
  border-color: #f59e0b;
}

.status-btn[data-status="onay_alindi"].active {
  background: #059669;
  border-color: #059669;
}

.status-btn[data-status="red_revizyon"].active {
  background: #dc2626;
  border-color: #dc2626;
}

.status-btn[data-status="bekliyor"].active {
  background: #d97706;
  border-color: #d97706;
  color: #fff;
}

.status-btn[data-status="kesildi"].active {
  background: #059669;
  border-color: #059669;
  color: #fff;
}

.status-btn[data-status="iptal"].active {
  background: #dc2626;
  border-color: #dc2626;
  color: #fff;
}

.status-btn[data-payment="odenmedi"].active {
  background: #b45309;
  border-color: #b45309;
  color: #fff;
}

.status-btn[data-payment="odendi"].active {
  background: #059669;
  border-color: #059669;
  color: #fff;
}

#tab-faturalandir .status-tracker-emphasis .status-btn.active {
  color: #fff;
}

.invoice-payment-tracker-info {
  margin-top: 0.75rem;
  padding: 0.7rem 0.9rem;
  border-radius: 10px;
  font-size: 0.9rem;
  border: 1px solid transparent;
}

.payment-odenmedi {
  background: #fffbeb;
  color: #b45309;
  border-color: #fde68a;
}

.payment-odendi {
  background: #ecfdf5;
  color: #047857;
  border-color: #a7f3d0;
}

.payment-gecikti {
  background: #fef2f2;
  color: #b91c1c;
  border-color: #fecaca;
}

.status-badge.payment-odenmedi {
  background: #fef3c7;
  color: #b45309;
}

.status-badge.payment-odendi {
  background: #d1fae5;
  color: #047857;
}

.status-badge.payment-gecikti {
  background: #fee2e2;
  color: #b91c1c;
}

.invoice-payment-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 0 0 1.25rem;
}

.invoice-hulasa-card.payment-odenmedi {
  background: #fffbeb;
  border-color: #fde68a;
}

.invoice-hulasa-card.payment-odendi {
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.invoice-hulasa-card.payment-gecikti {
  background: #fef2f2;
  border-color: #fecaca;
}

.status-btn-reedit {
  background: #fee2e2;
  border-color: #fca5a5;
  color: #b91c1c;
  font-weight: 600;
}

.status-btn-reedit:hover {
  background: #fecaca;
  border-color: #f87171;
  color: #991b1b;
}

.status-tracker-emphasis .status-btn-reedit {
  opacity: 1;
  font-size: 0.76rem;
  padding: 0.45rem 0.85rem;
}

.status-tracker-emphasis .status-btn-reedit:hover {
  opacity: 1;
}

/* Durum çubuğu: aktif belirgin, diğerleri soluk */
.status-tracker-emphasis {
  align-items: center;
  gap: 0.35rem;
}

.status-tracker-emphasis .status-btn:not(.active) {
  opacity: 0.62;
  color: #64748b;
  background: #f1f5f9;
  border-color: #e2e8f0;
  font-weight: 500;
  font-size: 0.76rem;
  padding: 0.4rem 0.7rem;
  box-shadow: none;
  transform: none;
}

.status-tracker-emphasis .status-btn.active {
  opacity: 1;
  font-weight: 700;
  font-size: 0.92rem;
  padding: 0.68rem 1.2rem;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.2);
  transform: scale(1.04);
  z-index: 1;
}

.status-tracker-emphasis .status-btn-readonly {
  cursor: default;
  user-select: none;
}

#tab-grafik-onay .status-tracker-emphasis .status-btn:not(.active) {
  cursor: pointer;
}

#tab-grafik-onay .status-tracker-emphasis .status-btn:not(.active):hover {
  opacity: 0.82;
  border-color: #cbd5e1;
  background: #e2e8f0;
  color: #475569;
}

#tab-musteri-hesap .status-tracker-emphasis .status-btn:not(.active):hover {
  opacity: 0.78;
  border-color: #cbd5e1;
  background: #e2e8f0;
  color: #475569;
}

.customer-status-tracker {
  margin: 0.75rem 0 0.25rem;
  padding: 0.85rem 0 0.25rem;
  border-top: 1px solid var(--border);
}

.status-badge {
  display: inline-block;
  margin-left: 0.4rem;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  vertical-align: middle;
}

.status-beklemede {
  background: #fef3c7;
  color: #b45309;
}

.status-kabul {
  background: #d1fae5;
  color: #047857;
}

.status-red {
  background: #fee2e2;
  color: #b91c1c;
}

.surec-tasarim {
  background: #dbeafe;
  color: #1d4ed8;
}

.surec-baski-hazirlik {
  background: #ede9fe;
  color: #6d28d9;
}

.surec-baski-onay {
  background: #ffedd5;
  color: #c2410c;
}

.surec-baskiya-gonderildi {
  background: #d1fae5;
  color: #047857;
}

.visual-bekliyor {
  background: #fef3c7;
  color: #b45309;
}

.visual-onay {
  background: #d1fae5;
  color: #047857;
}

.visual-red {
  background: #fee2e2;
  color: #b91c1c;
}

.nav-layout-editor {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.nav-layout-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  cursor: grab;
  user-select: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.nav-layout-item:active {
  cursor: grabbing;
}

.nav-layout-item.dragging {
  opacity: 0.55;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.12);
}

.nav-layout-item.drag-over {
  border-color: #2563eb;
  background: #eff6ff;
}

.nav-layout-handle {
  color: #94a3b8;
  font-size: 0.95rem;
  letter-spacing: -0.12em;
  line-height: 1;
}

.nav-layout-label {
  flex: 1;
  font-weight: 600;
  color: #0f172a;
}

.nav-layout-label-input {
  flex: 1;
  min-width: 0;
  font: inherit;
  font-weight: 600;
  color: #0f172a;
  border: 1px solid transparent;
  border-radius: 8px;
  background: #f8fafc;
  padding: 0.35rem 0.55rem;
  cursor: text;
  user-select: text;
}

.nav-layout-label-input:hover {
  border-color: #cbd5e1;
}

.nav-layout-label-input:focus {
  outline: none;
  border-color: #2563eb;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.nav-layout-audience {
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748b;
  background: #f1f5f9;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  flex-shrink: 0;
}

.nav-layout-item.is-hidden {
  opacity: 0.72;
  background: #f8fafc;
  border-style: dashed;
}

.nav-layout-item.is-hidden .nav-layout-label,
.nav-layout-item.is-hidden .nav-layout-label-input {
  color: #64748b;
  text-decoration: line-through;
}

.nav-layout-visibility-btn {
  min-width: 4.75rem;
  flex-shrink: 0;
}

.header-nav .nav-btn[hidden],
.header-nav .nav-btn.nav-btn-hidden {
  display: none !important;
}

.invoice-bekliyor {
  background: #fef3c7;
  color: #b45309;
}

.invoice-hazirlaniyor {
  background: #dbeafe;
  color: #1d4ed8;
}

.invoice-kesildi {
  background: #d1fae5;
  color: #047857;
}

.invoice-iptal {
  background: #fee2e2;
  color: #b91c1c;
}

.faturalandir-status-summary {
  margin: 0.75rem 0 1.25rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #f8fafc;
}

.faturalandir-summary-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  margin-bottom: 0.5rem;
}

.faturalandir-summary-grid .label {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 0.2rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.faturalandir-item.selected {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
  background: #f8fbff;
}

.input-with-action {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.input-with-action input {
  flex: 1;
}

.invoice-lines-preview-wrap {
  margin: 1rem 0 0.5rem;
}

.invoice-lines-preview-wrap h4 {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
}

.invoice-lines-preview {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.75rem;
  background: #f8fafc;
  max-height: 220px;
  overflow: auto;
}

.invoice-lines-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.invoice-lines-table th,
.invoice-lines-table td {
  padding: 0.35rem 0.4rem;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
}

.invoice-lines-table th:last-child,
.invoice-lines-table td:last-child {
  text-align: right;
  white-space: nowrap;
}

.invoice-lines-total {
  margin-top: 0.6rem;
  text-align: right;
  font-size: 0.9rem;
}

.invoice-hulasa-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 0.75rem 0 1.25rem;
}

.invoice-hulasa-card {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid transparent;
}

.invoice-hulasa-card .label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  opacity: 0.85;
}

.invoice-hulasa-card strong {
  font-size: 1.35rem;
  line-height: 1.1;
}

.invoice-hulasa-card.invoice-bekliyor {
  background: #fffbeb;
  border-color: #fde68a;
}

.invoice-hulasa-card.invoice-hazirlaniyor {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.invoice-hulasa-card.invoice-kesildi {
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.invoice-hulasa-card.invoice-iptal {
  background: #fef2f2;
  border-color: #fecaca;
}

.rapor-section-title {
  margin: 1.1rem 0 0.55rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
}

.rapor-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.85rem 0 0.35rem;
  padding: 0.35rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #f8fafc;
}

.rapor-subnav-btn {
  border: 1px solid transparent;
  background: transparent;
  color: #475569;
  border-radius: 8px;
  padding: 0.5rem 0.85rem;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.rapor-subnav-btn:hover {
  background: #fff;
  border-color: #cbd5e1;
  color: #0f172a;
}

.rapor-subnav-btn.active {
  background: #fff;
  border-color: #2563eb;
  color: #1d4ed8;
  box-shadow: 0 1px 4px rgba(37, 99, 235, 0.12);
}

.rapor-view {
  margin-top: 0.35rem;
}

.rapor-filters {
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: min(100%, 920px);
}

.rapor-mali-summary,
.rapor-surec-summary {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.rapor-card-net {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.rapor-card-btw {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.rapor-card-urgency {
  background: #fff1f2;
  border-color: #fecdd3;
}

.rapor-card-omzet {
  background: #f5f3ff;
  border-color: #ddd6fe;
}

.rapor-card-taxed {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.rapor-card-margin {
  background: #fff7ed;
  border-color: #fed7aa;
}

.rapor-card-total {
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.rapor-card-delivered {
  background: #ecfeff;
  border-color: #a5f3fc;
}

.rapor-card-process {
  background: #f8fafc;
  border-color: #e2e8f0;
}

.rapor-card-process-ok {
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.rapor-card-process-bad {
  background: #fef2f2;
  border-color: #fecaca;
}

.rapor-charts-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 0.5rem 0 1rem;
}

.rapor-chart-card {
  padding: 1rem 1.1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
}

.rapor-chart-card h4 {
  margin: 0 0 0.85rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: #334155;
}

.rapor-bar-chart {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.rapor-bar-row {
  display: flex;
  flex-direction: column;
  gap: 0.28rem;
}

.rapor-bar-meta {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.8rem;
}

.rapor-bar-label {
  font-weight: 600;
  color: #0f172a;
}

.rapor-bar-value {
  color: #64748b;
  white-space: nowrap;
}

.rapor-bar-track {
  height: 10px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}

.rapor-bar-track-sm {
  height: 7px;
  flex: 1;
  min-width: 60px;
}

.rapor-bar-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb, #f59e0b);
}

.rapor-table-wrap {
  overflow-x: auto;
  margin-bottom: 0.5rem;
}

.rapor-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.rapor-table th,
.rapor-table td {
  padding: 0.65rem 0.75rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: middle;
}

.rapor-table th.num,
.rapor-table td.num {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.rapor-maliyet-table {
  min-width: 980px;
  font-size: 0.85rem;
}

.rapor-maliyet-table .hint {
  margin: 0.15rem 0 0;
  font-size: 0.72rem;
}

.rapor-maliyet-actions {
  white-space: nowrap;
}

.rapor-table th {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #64748b;
  background: #f8fafc;
}

.rapor-table tfoot td {
  background: #f8fafc;
}

.rapor-share {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 140px;
}

.rapor-history-item {
  align-items: flex-start;
}

@media (max-width: 900px) {
  .rapor-charts-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .invoice-hulasa-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.customer-workflow-banner {
  margin: 0.85rem 0 1.1rem;
  padding: 0.9rem 1rem;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  background: linear-gradient(135deg, #eff6ff 0%, #f8fafc 100%);
}

.workflow-steps {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.45rem;
  margin-bottom: 0.75rem;
}

.workflow-step {
  display: inline-block;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: #e2e8f0;
  color: #64748b;
}

.workflow-step.done {
  background: #d1fae5;
  color: #047857;
}

.workflow-step.active {
  background: #dbeafe;
  color: #1d4ed8;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2);
}

.workflow-step-sep {
  color: #94a3b8;
  font-size: 0.8rem;
}

.workflow-status-messages {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.workflow-status-msg {
  font-size: 0.88rem;
  color: #475569;
}

.workflow-status-msg.workflow-status-ok {
  color: #047857;
  font-weight: 600;
}

.workflow-status-msg.workflow-status-warn {
  color: #b91c1c;
  font-weight: 600;
}

.workflow-status-msg.workflow-status-next,
.hint.workflow-status-next {
  color: #1d4ed8;
  font-weight: 600;
}

.history-status-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.6rem;
}

.status-btn-sm {
  padding: 0.3rem 0.55rem;
  font-size: 0.72rem;
}

/* History */
.history-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.history-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f8fafc;
}

.history-item-info h3 {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.4;
}

.history-item-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.history-item-actions {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
}

.empty-state {
  text-align: center;
  color: var(--text-muted);
  padding: 2rem;
}

/* Price list */
.price-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.75rem;
}

.price-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.price-item label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
}

.price-item input {
  padding: 0.5rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: inherit;
}

.price-item-wide label {
  font-weight: 600;
}

.price-section-title {
  margin-bottom: 0;
  padding-top: 0.5rem;
  border-top: none;
}

.price-section-title h3 {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--accent);
}

.price-section-intro {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

.price-section-intro .hint {
  margin: 0.35rem 0 0;
}

.montaj-malzeme-settings,
.baski-format-prices {
  grid-column: 1 / -1;
}

.montaj-malzeme-toggle {
  margin-bottom: 0.35rem;
}

.montaj-malzemeleri-panel {
  margin-top: 0.75rem;
  padding: 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.montaj-malzeme-editor {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-bottom: 0.25rem;
}

.montaj-kategori-block {
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
}

.montaj-kategori-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.55rem;
}

.montaj-kategori-header h4 {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
}

.montaj-kategori-rows {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.montaj-kategori-empty {
  margin: 0;
  font-size: 0.82rem;
}

.montaj-malzeme-row {
  display: grid;
  grid-template-columns: 1fr 100px auto auto;
  gap: 0.5rem;
  align-items: center;
}

.montaj-malzeme-row input[type="text"],
.montaj-malzeme-row input[type="number"] {
  width: 100%;
  padding: 0.45rem 0.6rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
}

.montaj-malzeme-currency {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.montaj-malzeme-default-row {
  margin-top: 0.75rem;
}

.montaj-malzeme-default-row label {
  display: block;
  margin-bottom: 0.35rem;
}

.montaj-malzeme-select-row select {
  width: 100%;
  max-width: 420px;
  padding: 0.5rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
}

.montaj-malzeme-simple-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.montaj-malzeme-selector {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 0.35rem;
}

.montaj-malzeme-selector .montaj-kategori-block {
  margin: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}

.montaj-malzeme-selector .montaj-kategori-header {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin-bottom: 0;
  background: var(--surface-soft);
  border-bottom: 1px solid transparent;
}

.montaj-malzeme-selector .montaj-kategori-block.is-expanded .montaj-kategori-header {
  border-bottom-color: var(--border);
}

.montaj-kategori-select {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 0.6rem 0.65rem 0.75rem;
  border-right: 1px solid var(--border);
  cursor: pointer;
  user-select: none;
}

.montaj-kategori-select input[type="checkbox"] {
  flex-shrink: 0;
  margin: 0;
}

.montaj-kategori-toggle {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.6rem 0.85rem 0.6rem 0.65rem;
  border: none;
  background: transparent;
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  min-width: 0;
}

.montaj-kategori-toggle:hover {
  background: rgba(37, 99, 235, 0.04);
}

.montaj-kategori-title {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  min-width: 0;
}

.montaj-kategori-title h4 {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
}

.montaj-kategori-summary {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.montaj-kategori-summary.has-selection {
  color: var(--primary);
  font-weight: 500;
}

.montaj-kategori-chevron {
  width: 0.45rem;
  height: 0.45rem;
  border-right: 2px solid var(--text-muted);
  border-bottom: 2px solid var(--text-muted);
  transform: rotate(-45deg);
  transition: transform 0.18s ease;
  flex-shrink: 0;
  margin-top: -0.15rem;
}

.montaj-malzeme-selector .montaj-kategori-block.is-expanded .montaj-kategori-chevron {
  transform: rotate(45deg);
  margin-top: 0.15rem;
}

.montaj-malzeme-selector .montaj-kategori-rows {
  flex-direction: column;
  gap: 0.4rem;
  padding: 0.55rem 0.85rem 0.75rem 2.35rem;
  background: #fff;
}

.montaj-malzeme-selector .montaj-kategori-block:not(.is-expanded) .montaj-kategori-rows {
  display: none !important;
}

.montaj-malzeme-selector .montaj-kategori-block.is-expanded .montaj-kategori-rows {
  display: flex;
}

.montaj-malzeme-item {
  font-size: 0.9rem;
}

.price-item-wide {
  grid-column: 1 / -1;
  margin-top: 0.5rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}

.price-item-wide label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

/* Print area */
.print-area {
  display: none;
}

.print-area.pdf-exporting {
  display: block !important;
  position: absolute;
  left: 0;
  top: 0;
  width: 794px;
  max-width: 794px;
  height: auto;
  overflow: visible;
  padding: 0;
  background: #fff;
  z-index: 10000;
  pointer-events: none;
}

@media print {
  body * {
    visibility: hidden;
  }

  .print-area,
  .print-area * {
    visibility: visible;
  }

  .print-area {
    display: block !important;
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    padding: 2rem;
    background: #fff;
  }

  .no-print {
    display: none !important;
  }
}

/* Print document styles (inside printArea) */
.print-doc {
  font-family: var(--font);
  color: #1e293b;
  width: 100%;
  max-width: 794px;
  margin: 0;
  background: #fff;
  padding: 8px 12px;
  box-sizing: border-box;
  font-size: 12px;
  line-height: 1.45;
  display: flex;
  flex-direction: column;
  min-height: 1040px;
}

.print-doc-body {
  flex: 1 1 auto;
}

.print-doc-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  max-width: 220px;
}

.print-doc-slogan {
  margin: 0;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #64748b;
  line-height: 1.35;
  text-transform: uppercase;
}

.pdf-exporting .print-doc,
.pdf-exporting .baski-onay-doc {
  width: 794px !important;
  max-width: 794px !important;
  margin: 0 !important;
  transform: none !important;
}

.print-doc-table tr {
  page-break-inside: avoid;
}

.print-doc-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid #1d4ed8;
}

.print-doc-logo {
  width: 64px;
  height: 64px;
  object-fit: contain;
  background: #fff;
  border-radius: 10px;
  padding: 4px;
  box-sizing: border-box;
}

.print-doc-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1d4ed8;
}

.print-doc-meta {
  text-align: right;
  font-size: 0.85rem;
  color: #64748b;
}

.print-doc-section {
  margin-bottom: 1.5rem;
}

.print-doc-section h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  margin-bottom: 0.5rem;
}

.print-muracaat-item {
  margin-bottom: 0.85rem;
  padding: 0.65rem 0.85rem;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
  font-size: 0.85rem;
}

.print-muracaat-item strong {
  display: block;
  margin-bottom: 0.35rem;
  color: #334155;
}

.print-muracaat-item p {
  margin: 0;
  color: #475569;
  line-height: 1.5;
}

.print-doc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  margin-bottom: 1.5rem;
}

.print-doc-table th,
.print-doc-table td {
  border: 1px solid #e2e8f0;
  padding: 0.5rem 0.65rem;
  text-align: left;
}

.print-doc-table th {
  background: #f1f5f9;
  font-weight: 600;
}

.print-doc-totals {
  margin-left: auto;
  width: 280px;
  font-size: 0.9rem;
}

.print-doc-totals .row {
  display: flex;
  justify-content: space-between;
  padding: 0.35rem 0;
}

.print-doc-totals .row.total {
  font-weight: 700;
  font-size: 1.1rem;
  border-top: 2px solid #1e293b;
  margin-top: 0.5rem;
  padding-top: 0.5rem;
}

.print-doc-notes {
  margin-top: 1.5rem;
  padding: 1rem;
  background: #f8fafc;
  border-radius: 8px;
  font-size: 0.85rem;
}

.print-doc-invoice-terms {
  margin-top: 1.75rem;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
  font-size: 0.8rem;
  line-height: 1.5;
  color: #475569;
  page-break-inside: avoid;
  break-inside: avoid;
}

.print-doc-invoice-terms p {
  margin: 0;
}

.sync-backup-list {
  margin-top: 0.85rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #f8fafc;
}

.sync-backup-ul {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.sync-backup-ul li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.85rem;
  align-items: center;
}

.print-doc-company-footer {
  margin-top: auto;
  padding: 0.45rem 0.75rem 0.55rem;
  background-color: #1e3a8a;
  background: #1e3a8a;
  color: #ffffff;
  border-radius: 6px;
  font-size: 0.68rem;
  line-height: 1.3;
  -webkit-print-color-adjust: exact !important;
  print-color-adjust: exact !important;
  page-break-inside: avoid;
  break-inside: avoid;
  flex-shrink: 0;
}

.print-doc-company-footer-name {
  font-weight: 700;
  font-size: 0.78rem;
  margin: 0 0 0.3rem;
  color: #fff;
  letter-spacing: 0.01em;
}

.print-doc-company-footer-cols {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 0.35rem 1rem;
  align-items: start;
}

.print-doc-company-footer-col {
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
  min-width: 0;
}

.print-doc-company-footer-item {
  display: flex;
  align-items: flex-start;
  gap: 0.35rem;
  color: #f8fafc;
}

.print-doc-company-footer-item svg {
  color: rgba(248, 250, 252, 0.9);
}

.print-doc-company-footer-meta {
  display: grid;
  grid-template-columns: 3.1rem 1fr;
  gap: 0.25rem;
  align-items: baseline;
}

.print-doc-company-footer-meta .label {
  color: rgba(248, 250, 252, 0.72);
  font-weight: 600;
}

.print-doc-company-footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.25rem 1.25rem;
}

.print-doc-company-footer-row {
  display: grid;
  grid-template-columns: 4.75rem 1fr;
  gap: 0.35rem;
  align-items: start;
}

.print-doc-company-footer-row .label {
  color: rgba(248, 250, 252, 0.78);
  font-weight: 600;
}

@media (max-width: 640px) {
  .print-doc-company-footer-cols,
  .print-doc-company-footer-grid {
    grid-template-columns: 1fr;
  }
}

.print-doc-company-details {
  margin-top: 0.55rem;
  font-size: 0.82rem;
  color: #334155;
  line-height: 1.45;
}

.print-doc-company-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.15rem 1rem;
  margin-top: 0.35rem;
}

.print-doc-company-row {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0.35rem;
}

.print-doc-company-row .label {
  color: #64748b;
  font-weight: 600;
}

.baski-onay-panel {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.baski-onay-panel h3 {
  margin-bottom: 0.35rem;
}

.baski-onay-panel h4 {
  margin: 1rem 0 0.65rem;
  font-size: 0.95rem;
}

.baski-onay-upload {
  margin-top: 1rem;
}

.baski-onay-attachment-preview {
  margin-top: 0.75rem;
}

.baski-onay-preview-wrap {
  margin-top: 1.25rem;
}

.baski-onay-preview {
  max-height: 640px;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
  padding: 1rem;
}

.baski-onay-doc {
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--text);
  display: flex;
  flex-direction: column;
  min-height: 1040px;
}

.baski-onay-doc-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.baski-onay-doc .print-doc-company-footer {
  margin-top: auto;
}

.baski-onay-logo {
  width: 64px;
  height: 64px;
  object-fit: contain;
  border-radius: 10px;
  background: #fff;
  padding: 4px;
  box-sizing: border-box;
}

.baski-onay-logo-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1d4ed8;
  color: #fff;
  font-weight: 700;
}

.baski-onay-meta {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.baski-onay-doc-title {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 1rem;
  color: #1e3a8a;
}

.baski-onay-greeting {
  margin-bottom: 0.75rem;
}

.baski-onay-visual {
  margin: 1rem 0;
  padding: 0.75rem;
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 10px;
  text-align: center;
}

.baski-onay-visual-image {
  max-width: 100%;
  max-height: 420px;
  object-fit: contain;
  border-radius: 8px;
}

.baski-onay-visual-frame {
  width: 100%;
  min-height: 420px;
  border: none;
  border-radius: 8px;
  background: #fff;
}

.baski-onay-visual-empty,
.baski-onay-visual-pdf {
  padding: 1rem;
  color: var(--text-muted);
}

.baski-onay-sign {
  margin-top: 1.25rem;
}

.baski-onay-ref {
  margin-top: 1rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.baski-onay-customer-actions {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 2px dashed #cbd5e1;
  text-align: center;
}

.baski-onay-approve-btn {
  min-width: 220px;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.baski-onay-approved-badge {
  display: inline-block;
  padding: 0.65rem 1.25rem;
  border-radius: 999px;
  background: #d1fae5;
  color: #047857;
  font-weight: 700;
}

.baski-onay-actions {
  margin-top: 1rem;
}

.form-error {
  margin-top: 0.5rem;
  color: #b91c1c;
  font-size: 0.85rem;
}

.nav-notif-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.15rem;
  height: 1.15rem;
  margin-left: 0.35rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: #dc2626;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  vertical-align: middle;
}

.approval-notifications-panel {
  margin-bottom: 1rem;
  padding: 1rem;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  background: #eff6ff;
}

.approval-notifications-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.approval-notifications-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.approval-notif-item {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #fff;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, background 0.15s;
}

.approval-notif-item:hover {
  border-color: var(--primary);
  background: #f8fbff;
}

.approval-notif-title {
  font-weight: 600;
  color: var(--text);
}

.approval-notif-time {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.approval-toast {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 1200;
  width: min(360px, calc(100vw - 2rem));
  padding: 1rem;
  border-radius: 12px;
  border: 1px solid #86efac;
  background: #ecfdf5;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.18);
}

.approval-toast strong {
  display: block;
  margin-bottom: 0.35rem;
  color: #047857;
}

.approval-toast p {
  margin: 0 0 0.75rem;
  color: var(--text);
}

.approval-toast-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.baski-onay-staff-notice {
  margin-top: 1rem;
  padding: 0.85rem;
  border-radius: 10px;
  background: #fffbeb;
  border: 1px solid #fde68a;
}

.customer-access-box {
  margin: 1rem 0;
  padding: 1rem;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  background: #f8fbff;
}

.customer-access-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.customer-access-row input {
  flex: 1 1 160px;
  min-width: 140px;
  font-family: ui-monospace, monospace;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.customer-access-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-end;
}

.customer-access-form .form-row {
  flex: 1 1 220px;
  margin-bottom: 0;
}

.customer-order-view {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.customer-order-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.customer-order-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.customer-order-meta p {
  margin: 0.25rem 0;
}

.customer-order-services ul {
  margin: 0.5rem 0 0;
  padding-left: 1.2rem;
}

.customer-order-approval-section {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.customer-section-subtitle {
  margin: 0.75rem 0 0.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
}

.customer-portal-actions {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.customer-portal-teklif-actions {
  padding: 1rem;
  background: var(--surface-alt, rgba(0, 0, 0, 0.03));
  border-radius: var(--radius, 8px);
  border: 1px solid var(--border);
}

.customer-teklif-summary {
  margin-top: 0.5rem;
}

.customer-teklif-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0.75rem 0;
  font-size: 0.95rem;
}

.customer-teklif-table th,
.customer-teklif-table td {
  padding: 0.5rem 0.65rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.customer-teklif-table th:last-child,
.customer-teklif-table td:last-child {
  text-align: right;
  white-space: nowrap;
}

.customer-teklif-totals {
  margin-top: 0.75rem;
  max-width: 320px;
  margin-left: auto;
}

.customer-teklif-totals .row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.35rem 0;
}

.customer-teklif-totals .row.total {
  font-weight: 700;
  font-size: 1.05rem;
  border-top: 2px solid var(--border);
  margin-top: 0.35rem;
  padding-top: 0.65rem;
}

.customer-portal-rejected {
  color: var(--danger, #c0392b);
  margin-top: 1rem;
}

.customer-portal-approved {
  margin-top: 1rem;
  text-align: center;
}

.customer-order-status-note {
  margin-top: 1rem;
}

.customer-order-teklif-hint {
  margin-top: 0.75rem;
  padding: 0.65rem 0.85rem;
  background: var(--surface-alt, rgba(0, 0, 0, 0.03));
  border-radius: var(--radius, 8px);
  border: 1px solid var(--border);
}

.customer-access-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.customer-access-list-item {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
}

.customer-access-list-main {
  flex: 1 1 280px;
  min-width: 0;
}

.customer-access-list-title {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  align-items: baseline;
  margin-bottom: 0.45rem;
}

.customer-access-list-code-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  margin-bottom: 0.55rem;
}

.customer-access-code {
  display: inline-block;
  padding: 0.25rem 0.55rem;
  border-radius: 8px;
  background: #eff6ff;
  color: #1d4ed8;
  font-family: ui-monospace, monospace;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.customer-access-missing {
  color: #b45309;
  font-weight: 600;
  font-size: 0.88rem;
}

.customer-access-created {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.customer-access-list-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.customer-access-list-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: flex-start;
}

.pdf-exporting .baski-onay-doc {
  width: 794px !important;
  max-width: 794px !important;
  padding: 8px 12px;
  box-sizing: border-box;
  font-size: 12px;
}

@media (max-width: 768px) {
  .app {
    padding: 1rem;
  }

  .header-brand {
    padding-right: 0;
    flex-wrap: wrap;
  }

  .header-app-title {
    white-space: normal;
    font-size: 1.35rem;
    letter-spacing: 0.04em;
  }

  .logo-icon,
  .logo-placeholder.logo-icon {
    width: 80px;
    height: 80px;
  }

  .header {
    flex-direction: column;
    align-items: stretch;
  }

  .header-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .header-nav {
    justify-content: stretch;
  }

  .header-staff-panel {
    top: 0.5rem;
    right: 0.5rem;
    left: auto;
    min-width: 70px;
  }

  .nav-btn {
    flex: 1;
    text-align: center;
  }

  .action-buttons .btn {
    flex: 1;
    min-width: 120px;
  }
}

/* Grafik Ajanda / Gantt */
.grafik-ajanda-summary {
  margin-bottom: 1rem;
}

.invoice-hulasa-card.designer-stage-taslak {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.invoice-hulasa-card.designer-stage-revizyon {
  background: #fff7ed;
  border-color: #fed7aa;
}

.invoice-hulasa-card.designer-stage-onaylama {
  background: #f5f3ff;
  border-color: #ddd6fe;
}

.invoice-hulasa-card.designer-stage-teslim {
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.status-badge.designer-stage-taslak { background: #dbeafe; color: #1d4ed8; }
.status-badge.designer-stage-revizyon { background: #ffedd5; color: #c2410c; }
.status-badge.designer-stage-onaylama { background: #ede9fe; color: #6d28d9; }
.status-badge.designer-stage-teslim { background: #d1fae5; color: #047857; }

.grafik-gantt-wrap {
  overflow-x: auto;
}

.grafik-gantt-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 860px;
  font-size: 0.88rem;
}

.grafik-gantt-table th,
.grafik-gantt-table td {
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid var(--border, #e2e8f0);
  text-align: left;
  vertical-align: middle;
}

.grafik-gantt-table th {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #64748b;
  background: #f8fafc;
}

.grafik-gantt-table tbody tr {
  cursor: pointer;
}

.grafik-gantt-table tbody tr:hover {
  background: #f8fafc;
}

.gantt-stage-col,
.gantt-cell {
  text-align: center !important;
  width: 4.5rem;
}

.gantt-cell.done { color: #94a3b8; }
.gantt-cell.active { font-weight: 700; }
.gantt-cell.active.designer-stage-taslak { color: #1d4ed8; }
.gantt-cell.active.designer-stage-revizyon { color: #c2410c; }
.gantt-cell.active.designer-stage-onaylama { color: #6d28d9; }
.gantt-cell.active.designer-stage-teslim { color: #047857; }

.gantt-progress {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 160px;
}

.gantt-progress-track {
  display: flex;
  flex: 1;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: #e2e8f0;
}

.gantt-seg {
  flex: 1;
  background: transparent;
}

.gantt-seg.filled.designer-stage-taslak { background: #3b82f6; }
.gantt-seg.filled.designer-stage-revizyon { background: #f97316; }
.gantt-seg.filled.designer-stage-onaylama { background: #8b5cf6; }
.gantt-seg.filled.designer-stage-teslim { background: #10b981; }

.gantt-pct {
  font-size: 0.75rem;
  color: #64748b;
  min-width: 2.4rem;
  text-align: right;
}

.grafik-ajanda-stage-row {
  margin-top: 0.55rem;
  max-width: 280px;
}

