@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400&display=swap');

:root {
  --primary: #006cff;
  --primary-hover: #0056cc;
  --primary-light: #e6f0ff;
  --accent-purple: #6c3cf0;
  
  --bg-page: #f8fafc;
  --bg-card: #ffffff;
  --border-color: #e2e8f0;
  --border-focus: #94a3b8;
  
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-subtle: #94a3b8;

  /* Rozet renk paletleri */
  --badge-emerald-text: #2e8b46;
  --badge-emerald-bg: #ecfdf5;
  --badge-sky-text: #008af5;
  --badge-sky-bg: #e0f2fe;
  --badge-orange-text: #ea8d2a;
  --badge-orange-bg: #fff7ed;
  --badge-rose-text: #d54c37;
  --badge-rose-bg: #fff1f2;
  --badge-violet-text: #6c3cf0;
  --badge-violet-bg: #f5f3ff;
  --badge-zinc-text: #52525b;
  --badge-zinc-bg: #f4f4f5;

  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.08), 0 2px 4px -2px rgb(0 0 0 / 0.06);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.08), 0 4px 6px -4px rgb(0 0 0 / 0.04);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.08), 0 8px 10px -6px rgb(0 0 0 / 0.04);
  --shadow-glow: 0 10px 25px -5px rgba(0, 108, 255, 0.4);

  --font-sans: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, monospace;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
}

html, body, button, input, select, textarea, optgroup {
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  background-color: var(--bg-page);
  color: var(--text-main);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
}

/* Evrensel Gizleme Yardımcısı */
.hidden {
  display: none !important;
}

/* ==========================================================================
   Dot Pattern Arka Plan (Background & Dropfiles örneğinden)
   ========================================================================== */
.dot-pattern-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.6;
  color: #94a3b8;
}

.dot-svg {
  width: 100%;
  height: 100%;
}

.app-container {
  position: relative;
  z-index: 1;
  max-width: 1240px;
  width: 100%;
  margin: 0 auto;
  padding: 32px 24px 60px;
  box-sizing: border-box;
}

@media (max-width: 980px) {
  .app-container {
    padding: 24px 16px 48px;
  }
}

@media (max-width: 640px) {
  .app-container {
    padding: 16px 12px 36px;
  }
}

/* ==========================================================================
   Header & Rozetler
   ========================================================================== */
.app-header {
  text-align: center;
  margin-bottom: 28px;
  width: 100%;
}

.header-badges {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 9999px;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: all 0.2s ease;
}

.badge-icon {
  width: 14px;
  height: 14px;
}

.badge-emerald {
  background-color: var(--badge-emerald-bg);
  color: var(--badge-emerald-text);
  border: 1px solid rgba(46, 139, 70, 0.2);
}

.badge-sky {
  background-color: var(--badge-sky-bg);
  color: var(--badge-sky-text);
  border: 1px solid rgba(0, 138, 245, 0.2);
}

.badge-indigo {
  background-color: #eef2ff;
  color: #4f46e5;
  border: 1px solid rgba(79, 70, 229, 0.2);
}

.main-title {
  font-size: clamp(1.4rem, 4vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #090d16;
  margin-bottom: 10px;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #006cff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  padding: 0 8px;
}

.subtitle {
  font-size: clamp(0.85rem, 2vw, 1.0625rem);
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto 24px;
  line-height: 1.55;
  padding: 0 12px;
}

/* ==========================================================================
   Button dosyasındaki 3 Adımlı Progress Indicator
   ========================================================================== */
.step-indicator-wrapper {
  display: flex;
  justify-content: center;
  margin-top: 10px;
  width: 100%;
}

.step-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  padding: 12px 28px;
  border-radius: 9999px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  max-width: 100%;
  box-sizing: border-box;
}

@media (max-width: 640px) {
  .step-indicator {
    padding: 8px 16px;
    gap: 6px;
  }
}

.step-dots-track {
  display: flex;
  align-items: center;
  gap: 8px;
}

.step-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background-color: #e2e8f0;
  color: #64748b;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8125rem;
  font-weight: 700;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@media (max-width: 640px) {
  .step-dot {
    width: 24px;
    height: 24px;
    font-size: 0.75rem;
  }
}

.step-dot.active {
  background-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 0 0 4px rgba(0, 108, 255, 0.18);
  transform: scale(1.08);
}

.step-dot.completed {
  background-color: #10b981;
  color: #ffffff;
}

.step-line {
  width: 50px;
  height: 3px;
  background-color: #e2e8f0;
  border-radius: 2px;
  transition: background-color 0.3s ease;
}

@media (max-width: 640px) {
  .step-line {
    width: 26px;
  }
}

.step-line.active {
  background-color: #10b981;
}

.step-labels {
  display: flex;
  justify-content: space-between;
  width: 270px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-subtle);
}

@media (max-width: 640px) {
  .step-labels {
    width: 100%;
    max-width: 240px;
    font-size: 0.6875rem;
  }
}

.step-label.active {
  color: var(--primary);
  font-weight: 700;
}

/* ==========================================================================
   Ana Kart & Bölümler
   ========================================================================== */
.main-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 24px;
  box-shadow: var(--shadow-xl);
  padding: 28px;
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

@media (max-width: 980px) {
  .main-card {
    padding: 20px;
    border-radius: 20px;
  }
}

@media (max-width: 640px) {
  .main-card {
    padding: 14px 12px;
    border-radius: 16px;
  }
}

.flow-step {
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.flow-step.hidden {
  display: none !important;
}

/* ==========================================================================
   Dropzone (Dropfiles örneği)
   ========================================================================== */
.dropzone-card {
  border: 2px dashed #cbd5e1;
  border-radius: 20px;
  padding: 64px 32px;
  text-align: center;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
}

.dropzone-card:hover, .dropzone-card.dragover {
  border-color: var(--primary);
  background: #f0f7ff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.dropzone-icon-box {
  width: 72px;
  height: 72px;
  margin: 0 auto 20px;
  background: var(--primary-light);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  box-shadow: 0 4px 12px rgba(0, 108, 255, 0.15);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dropzone-card:hover .dropzone-icon-box {
  transform: scale(1.1) translateY(-3px);
}

.cloud-icon {
  width: 36px;
  height: 36px;
}

.dropzone-title {
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.dropzone-desc {
  font-size: 0.9375rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.highlight-link {
  color: var(--primary);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Format Etiketleri (files dosyasından esinlenildi) */
.format-chips {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 8px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #475569;
}

.chip svg {
  width: 14px;
  height: 14px;
}

.chip-pdf {
  background: #fef2f2;
  border-color: #fecaca;
  color: #dc2626;
}

.upload-meta-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 0.8125rem;
  color: var(--text-muted);
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}

.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.meta-icon {
  width: 16px;
  height: 16px;
}

.text-emerald { color: #10b981; }
.text-sky { color: #0284c7; }
.text-indigo { color: var(--primary); }

/* ==========================================================================
   İlerleme Çubuğu (Dosya seçilince yukarıdan aşağı kayarak açılan animasyon)
   ========================================================================== */
.upload-progress-card {
  margin-top: 24px;
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 18px;
  padding: 22px 24px;
  box-shadow: 0 10px 30px rgba(0, 108, 255, 0.08);
  overflow: hidden;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.upload-progress-card.hidden {
  display: none !important;
}

.upload-progress-card.slide-down-active {
  animation: progressCardSlideDown 0.45s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes progressCardSlideDown {
  0% {
    opacity: 0;
    transform: translateY(-24px) scale(0.97);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.progress-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.file-summary {
  display: flex;
  align-items: center;
  gap: 12px;
}

.file-summary-icon {
  width: 28px;
  height: 28px;
  color: var(--primary);
}

.file-name {
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--text-main);
}

.file-size {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.progress-bar-bg {
  width: 100%;
  height: 8px;
  background-color: #f1f5f9;
  border-radius: 9999px;
  overflow: hidden;
  margin-bottom: 8px;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #006cff 0%, #10b981 100%);
  border-radius: 9999px;
  transition: width 0.3s ease;
}

.progress-status-msg {
  font-size: 0.8125rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ==========================================================================
   ADIM 2: Önizleme & Akıllı Izgara Çalışma Alanı
   ========================================================================== */
.detection-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  background: #f8fafc;
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 16px 20px;
  margin-bottom: 24px;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 860px) {
  .detection-banner {
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    gap: 12px;
  }
  #btn-change-file {
    width: 100%;
    justify-content: center;
  }
}

.detection-info {
  min-width: 0;
  flex: 1 1 auto;
}

.badge-status-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

/* Kullanıcının badges dosyasındaki tam stiller */
.badge-status {
  height: auto;
  min-height: 34px;
  padding: 6px 14px;
  display: inline-flex;
  align-items: center;
  border-radius: 12px;
  font-size: 0.8125rem;
  font-weight: 600;
  box-sizing: border-box;
}

@media (max-width: 480px) {
  .badge-status {
    font-size: 0.75rem;
    padding: 4px 10px;
  }
}

.bg-orange {
  background-color: var(--badge-orange-bg);
  color: var(--badge-orange-text);
  border: 1px solid rgba(234, 141, 42, 0.2);
}

.bg-emerald {
  background-color: var(--badge-emerald-bg);
  color: var(--badge-emerald-text);
  border: 1px solid rgba(46, 139, 70, 0.2);
}

.bg-sky {
  background-color: var(--badge-sky-bg);
  color: var(--badge-sky-text);
  border: 1px solid rgba(0, 138, 245, 0.2);
}

.bg-violet {
  background-color: #ede9fe;
  color: #6d28d9;
  border: 1px solid rgba(109, 40, 217, 0.2);
}

.badge-status.hidden {
  display: none !important;
}

.smart-note {
  font-size: 0.8125rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 24px;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

@media (max-width: 1120px) {
  .workspace-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }
}

/* Sol Taraf: Canlı Önizleme Tuvali */
.preview-canvas-col {
  display: flex;
  flex-direction: column;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

.canvas-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  flex-wrap: wrap;
  width: 100%;
  box-sizing: border-box;
}

.canvas-title-group {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  flex-wrap: wrap;
  min-width: 0;
}

.canvas-zoom-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.zoom-label {
  display: inline-flex;
  align-items: center;
  font-size: 0.75rem;
  font-weight: 600;
  background: #f1f5f9;
  padding: 4px 10px;
  border-radius: 6px;
  color: #64748b;
  white-space: nowrap;
}

/* ==========================================================================
   Çok Sayfalı PDF Sayfa Gezgini
   ========================================================================== */
.pdf-page-selector {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid #e0e7ff;
  padding: 3px 10px;
  border-radius: 9999px;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.08);
}

.pdf-page-selector.hidden {
  display: none !important;
}

.page-sel-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #4f46e5;
}

.page-nav-controls {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.page-nav-btn {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  color: #334155;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  outline: none;
}

.page-nav-btn:hover:not(:disabled) {
  background: #4f46e5;
  color: #ffffff;
  border-color: #4f46e5;
}

.page-nav-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.page-indicator {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #0f172a;
  padding: 0 4px;
  min-width: 75px;
  text-align: center;
}

.bg-violet {
  background-color: var(--badge-violet-bg);
  color: var(--badge-violet-text);
  border: 1px solid rgba(108, 60, 240, 0.2);
}

.canvas-stage {
  background: #0f172a;
  border-radius: 16px;
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 440px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
  .canvas-stage {
    min-height: 300px;
    padding: 14px;
    border-radius: 12px;
  }
}

@media (max-width: 480px) {
  .canvas-stage {
    min-height: 220px;
    padding: 8px;
  }
}

.grid-overlay-container {
  position: relative;
  display: inline-block;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
  line-height: 0;
  border: 1px solid rgba(255, 255, 255, 0.15);
  max-width: 100%;
  box-sizing: border-box;
}

#main-preview-canvas {
  display: block;
  max-width: 100%;
  max-height: 520px;
  height: auto !important;
  object-fit: contain;
  background-color: #ffffff;
}

/* Kesim Çizgileri Katmanı */
.grid-lines-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  display: grid;
}

.grid-tile {
  position: relative;
  border: 1.5px dashed rgba(239, 68, 68, 0.9); /* Kırmızı kesik çizgi */
  box-sizing: border-box;
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  padding: 6px 8px;
  pointer-events: auto;
  transition: background-color 0.15s ease;
}

.grid-tile:hover {
  background-color: rgba(0, 108, 255, 0.15);
}

.tile-badge {
  background: rgba(15, 23, 42, 0.88);
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(6px);
  line-height: 1.2;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  letter-spacing: 0.02em;
}

/* ==========================================================================
   8 mm UHU / Yapıştırma Kılavuzu & Navigasyon Tasarımı
   ========================================================================== */
.glue-guide-card {
  border-left: 3px solid #f59e0b;
}

.glue-switch .switch-input:checked + .switch-slider {
  background-color: #f59e0b;
}

.glue-strip {
  position: absolute;
  pointer-events: none;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-sizing: border-box;
  user-select: none;
}

.glue-strip-right {
  top: 0;
  right: 0;
  bottom: 0;
  width: 26px;
  background: repeating-linear-gradient(
    -45deg,
    rgba(254, 240, 138, 0.45),
    rgba(254, 240, 138, 0.45) 8px,
    rgba(251, 191, 36, 0.3) 8px,
    rgba(251, 191, 36, 0.3) 16px
  );
  border-left: 2px dashed #d97706;
}

.glue-strip-bottom {
  bottom: 0;
  left: 0;
  right: 0;
  height: 24px;
  background: repeating-linear-gradient(
    -45deg,
    rgba(254, 240, 138, 0.45),
    rgba(254, 240, 138, 0.45) 8px,
    rgba(251, 191, 36, 0.3) 8px,
    rgba(251, 191, 36, 0.3) 16px
  );
  border-top: 2px dashed #d97706;
}

.glue-strip-inner {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.94);
  color: #78350f;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid #f59e0b;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  white-space: nowrap;
}

.glue-strip-right .glue-strip-inner {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  transform: rotate(180deg);
  padding: 6px 2px;
}

.glue-strip-icon {
  font-size: 0.75rem;
  line-height: 1;
}

.glue-strip-arrow {
  color: #b45309;
  font-weight: 800;
}

/* ==========================================================================
   Sarı Kılavuz Alanı: Baskı & Kusursuz Çıktı İpuçları
   ========================================================================== */
.print-tips-card {
  margin-top: 14px;
  padding: 16px 18px;
  background: #fffbeb; /* Sıcak yumuşak amber sarısı */
  border: 1.5px solid #fde68a;
  border-radius: 14px;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.08);
  width: 100%;
  box-sizing: border-box;
}

.tips-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px dashed #fcd34d;
  flex-wrap: wrap;
  gap: 8px;
}

.tips-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tips-icon-badge {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: #fef3c7;
  border: 1px solid #fde68a;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #b45309;
  flex-shrink: 0;
}

.tips-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #92400e;
  margin: 0;
}

.tips-tag {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  background: #fef3c7;
  color: #b45309;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid #fde68a;
  white-space: nowrap;
}

.tips-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px 14px;
}

@media (max-width: 768px) {
  .tips-grid {
    grid-template-columns: 1fr;
  }
}

.tip-box {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid #fef08a;
  border-radius: 10px;
  padding: 10px 12px;
}

.tip-icon-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8125rem;
  font-weight: 700;
  color: #78350f;
  margin-bottom: 4px;
}

.tip-box p {
  font-size: 0.75rem;
  color: #854d0e;
  line-height: 1.4;
  margin: 0;
}

.tip-box p em {
  font-weight: 600;
  font-style: normal;
  text-decoration: underline;
}

.border-overlap {
  background: #10b981;
}

/* ==========================================================================
   Sağ Taraf: Kontroller
   ========================================================================== */
.controls-col {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

.control-box {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 18px 20px;
  box-shadow: var(--shadow-sm);
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 640px) {
  .control-box {
    padding: 14px 16px;
    border-radius: 14px;
  }
}

/* ==========================================================================
   Hedef Okul Panosu Ölçüsü (Akıllı Pano Uydurucu)
   ========================================================================== */
.school-board-box {
  border-color: #e0e7ff;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcfe 100%);
  transition: all 0.25s ease;
}

.school-board-box.active-board {
  border-color: #818cf8;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.12);
}

/* iOS/Modern style Switch */
.toggle-switch-wrapper {
  display: flex;
  align-items: center;
}

.switch-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}

.switch-caption {
  font-size: 0.8125rem;
  font-weight: 500;
  color: #64748b;
  transition: color 0.2s ease;
}

.switch-label:hover .switch-caption {
  color: #1e293b;
}

.switch-input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.switch-slider {
  position: relative;
  display: inline-block;
  width: 38px;
  height: 22px;
  background-color: #cbd5e1;
  border-radius: 9999px;
  transition: background-color 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.switch-slider::before {
  content: "";
  position: absolute;
  height: 18px;
  width: 18px;
  left: 2px;
  bottom: 2px;
  background-color: #ffffff;
  border-radius: 50%;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.switch-input:checked + .switch-slider {
  background-color: #4f46e5;
}

.switch-input:checked + .switch-slider::before {
  transform: translateX(16px);
}

.board-inputs-container {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed #e2e8f0;
  animation: fadeInDown 0.25s ease;
}

.board-inputs-container.hidden {
  display: none !important;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.board-inputs-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}

@media (max-width: 480px) {
  .board-inputs-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}

.board-input-cell {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.board-input-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #475569;
}

.input-with-unit {
  position: relative;
  display: flex;
  align-items: center;
}

.input-with-unit input {
  width: 100%;
  height: 38px;
  padding: 0 38px 0 12px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  color: #0f172a;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-with-unit input:focus {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.unit-text {
  position: absolute;
  right: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #94a3b8;
  pointer-events: none;
}

.board-presets-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.board-presets-title {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
}

.board-preset-chips {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.board-chip {
  padding: 5px 10px;
  border-radius: 6px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  font-size: 0.75rem;
  font-weight: 500;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s ease;
}

.board-chip:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.board-chip.active {
  background: #4f46e5;
  color: #ffffff;
  border-color: #4f46e5;
  font-weight: 600;
}

.board-fit-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 0.8125rem;
  line-height: 1.4;
  margin-top: 4px;
}

.board-fit-badge.fit-success {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}

.board-fit-badge.fit-warning {
  background: #fffbeb;
  border: 1px solid #fef3c7;
  color: #92400e;
}

.board-fit-badge.fit-info {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
}

.control-box-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.control-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-main);
  letter-spacing: -0.01em;
}

.control-icon {
  width: 17px;
  height: 17px;
  color: var(--primary);
}

.dim-badge {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #0284c7;
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  padding: 3px 10px;
  border-radius: 9999px;
  letter-spacing: -0.01em;
}

/* ==========================================================================
   Segmented Control & Toolbar Stilleri (Poppins)
   ========================================================================== */
.unit-badge {
  font-size: 0.75rem;
  font-weight: 500;
  color: #0284c7;
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  padding: 3px 8px;
  border-radius: 6px;
}

/* 1. Segmented Control (ToggleGroup) */
.segmented-control {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 4px;
  display: flex;
  gap: 6px;
  margin-top: 8px;
  width: 100%;
  box-sizing: border-box;
}

.segmented-btn {
  flex: 1;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 9px;
  border: 1px solid transparent;
  background: transparent;
  color: #64748b;
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  outline: none;
  box-sizing: border-box;
}

@media (max-width: 480px) {
  .segmented-btn {
    padding: 8px 6px;
    gap: 6px;
  }
}

.segmented-btn:hover {
  color: #0f172a;
  background: rgba(255, 255, 255, 0.7);
}

.segmented-btn.active {
  background: #ffffff;
  color: var(--primary);
  border-color: #cbd5e1;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
}

.segmented-icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Sayfa Minyatürü */
.sheet-mini {
  border: 1.5px solid #64748b;
  border-radius: 2px;
  background: #ffffff;
  transition: all 0.15s ease;
}

.portrait-mini {
  width: 15px;
  height: 22px;
}

.landscape-mini {
  width: 22px;
  height: 15px;
}

.segmented-btn.active .sheet-mini {
  border-color: var(--primary);
  background: #eff6ff;
}

.segmented-label-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.3;
  min-width: 0;
}

.segmented-title {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: inherit;
  white-space: nowrap;
}

@media (max-width: 480px) {
  .segmented-title {
    font-size: 0.78125rem;
  }
}

.segmented-metric {
  font-size: 0.75rem;
  font-weight: 500;
  color: #94a3b8;
  white-space: nowrap;
}

@media (max-width: 480px) {
  .segmented-metric {
    font-size: 0.6875rem;
  }
}

.segmented-btn.active .segmented-metric {
  color: #0284c7;
}

/* 2. Toolbar Butonları (quick-grid-presets) */
.quick-grid-presets {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 12px;
  margin-top: 8px;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 500px) {
  .quick-grid-presets {
    grid-template-columns: repeat(2, 1fr);
  }
}

.preset-btn {
  height: 46px;
  padding: 4px 6px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  outline: none;
  min-width: 0;
  box-sizing: border-box;
}

.preset-btn:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
}

.preset-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  box-shadow: 0 3px 8px rgba(0, 108, 255, 0.3);
}

.preset-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.2;
}

.preset-sub {
  font-size: 0.6875rem;
  font-weight: 500;
  color: #94a3b8;
  line-height: 1;
}

.preset-btn.active .preset-title {
  color: #ffffff;
}

.preset-btn.active .preset-sub {
  color: rgba(255, 255, 255, 0.88);
}

/* Stepper Toolbar */
.stepper-toolbar {
  display: flex;
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid #f1f5f9;
  flex-wrap: wrap;
}

@media (max-width: 440px) {
  .stepper-toolbar {
    flex-direction: column;
  }
}

.stepper-cell {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 6px 10px;
}

.stepper-tag {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #475569;
}

.stepper-group {
  display: inline-flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 2px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.stepper-group .step-btn {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: #334155;
  font-weight: 600;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: all 0.12s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stepper-group .step-btn:hover {
  background: #f1f5f9;
  color: var(--primary);
}

.stepper-group input {
  width: 32px;
  height: 26px;
  border: none;
  background: transparent;
  text-align: center;
  font-size: 0.875rem;
  font-weight: 700;
  color: #0f172a;
  outline: none;
}

/* 3. Sığdırma Modu Segmented Bar */
.fit-segmented {
  margin-top: 8px;
}

.fit-btn {
  font-size: 0.875rem;
  font-weight: 600;
  padding: 10px 16px;
  gap: 8px;
}

.control-hint {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.8125rem;
  color: #475569;
  margin-top: 10px;
  line-height: 1.5;
  padding: 9px 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}

/* ==========================================================================
   Aksiyon Kartı (Button dosyasındaki stil ve parlama)
   ========================================================================== */
.action-card {
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 20px;
  box-shadow: var(--shadow-md);
}

/* ==========================================================================
   Tam Hat / Sağa Sola Yaslı Full-Width Aksiyon Kartı (Kırmızı Hat Alanı)
   ========================================================================== */
.action-card.full-width-action-card {
  grid-column: 1 / -1;
  width: 100%;
  box-sizing: border-box;
  margin-top: 6px;
  padding: 20px 24px;
  border: 1.5px solid #e2e8f0;
  border-radius: 18px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
}

.action-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  flex-wrap: wrap;
  gap: 10px;
}

.action-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

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

.action-badge-sub {
  font-size: 0.8125rem;
  font-weight: 500;
  color: #64748b;
}

.action-buttons-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  align-items: stretch;
  justify-content: space-between;
  margin-bottom: 0;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 768px) {
  .action-card.full-width-action-card {
    padding: 16px;
    border-radius: 14px;
  }
  .action-buttons-group {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

/* Aksiyon Butonları */
.action-btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 16px 24px;
  width: 100%;
  border-radius: 16px !important;
  box-sizing: border-box;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, background 0.2s ease;
}

/* 1. Doğrudan Kenarlıksız Yazdır Butonu (Mavi Glow) */
#btn-direct-print, .print-motion-btn {
  background: linear-gradient(135deg, #006cff 0%, #0056cc 100%);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 16px rgba(0, 108, 255, 0.35);
}

#btn-direct-print:hover, .print-motion-btn:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #0056cc 0%, #0044aa 100%);
  box-shadow: 0 8px 24px rgba(0, 108, 255, 0.45);
}

/* 2. Bölünmüş PDF İndir Butonu (Sayfadaki Zümrüt / Emerald Yeşil Renk & Glow Efektli) */
#btn-download-pdf, .btn-emerald-action, .pdf-motion-btn {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.38) !important;
}

#btn-download-pdf:hover, .btn-emerald-action:hover, .pdf-motion-btn:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.48) !important;
}

#btn-download-pdf:active, .btn-emerald-action:active, .pdf-motion-btn:active {
  transform: translateY(0);
}

#btn-download-pdf .btn-motion-slot, .btn-emerald-action .btn-motion-slot {
  background: rgba(255, 255, 255, 0.2) !important;
}

#btn-download-pdf .btn-icon, .btn-emerald-action .btn-icon {
  color: #ffffff !important;
}

#btn-download-pdf .btn-title, .btn-emerald-action .btn-title {
  color: #ffffff !important;
}

#btn-download-pdf .btn-sub, .btn-emerald-action .btn-sub {
  color: rgba(255, 255, 255, 0.92) !important;
}

.action-btn .btn-title {
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.action-btn .btn-sub {
  font-size: 0.8125rem;
  font-weight: 500;
  opacity: 0.88;
}

/* Mikro Motion Graphic Yuvası */
.btn-motion-slot {
  position: relative;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.16);
}

.btn-motion-slot .btn-icon {
  position: relative;
  z-index: 2;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.action-btn:hover .btn-motion-slot .btn-icon {
  transform: scale(1.12);
}

/* Mikro A4 Kağıt / Sayfa Efekti */
.motion-sheet {
  position: absolute;
  width: 14px;
  height: 16px;
  border-radius: 2px;
  z-index: 1;
  pointer-events: none;
  opacity: 0;
  transform: translateY(-10px) scale(0.85);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.sheet-printer {
  background: #ffffff;
  border: 1px solid rgba(0, 108, 255, 0.4);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.sheet-pdf {
  background: #ffffff;
  border: 1.5px solid #10b981;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

/* Hover durumunda minik kağıt ucu görünümü */
.print-motion-btn:hover .sheet-printer {
  opacity: 0.9;
  transform: translateY(-8px) scale(0.92);
}

.pdf-motion-btn:hover .sheet-pdf {
  opacity: 0.9;
  transform: translateY(-8px) scale(0.92);
}

.pdf-motion-btn:hover .sheet-pdf {
  opacity: 0.9;
  transform: translateY(-8px) scale(0.92);
}

/* 1. YAZDIR Butonuna Basıldığında Kağıdın Yazıcıya Akış Animasyonu */
.print-motion-btn.printing-active {
  transform: scale(0.97);
}

.print-motion-btn.printing-active .sheet-printer {
  opacity: 1;
  animation: paperFeedIntoPrinter 1.25s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes paperFeedIntoPrinter {
  0% {
    opacity: 0;
    transform: translateY(-16px) scale(0.85);
  }
  25% {
    opacity: 1;
    transform: translateY(-6px) scale(1);
  }
  65% {
    opacity: 0.95;
    transform: translateY(2px) scale(0.95);
  }
  85% {
    opacity: 0.5;
    transform: translateY(10px) scale(0.8);
  }
  100% {
    opacity: 0;
    transform: translateY(18px) scale(0.6);
  }
}

/* 2. PDF İNDİR Butonuna Basıldığında Sayfanın İndirme Tepsisine Süzülüş Animasyonu */
.pdf-motion-btn.downloading-active {
  transform: scale(0.97);
}

.pdf-motion-btn.downloading-active .sheet-pdf {
  opacity: 1;
  animation: pdfSlideAndDownload 1.25s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes pdfSlideAndDownload {
  0% {
    opacity: 0;
    transform: translateY(-14px) scale(0.8) rotate(0deg);
  }
  25% {
    opacity: 1;
    transform: translateY(0px) scale(1) rotate(-4deg);
  }
  60% {
    opacity: 1;
    transform: translateY(6px) scale(1.08) rotate(3deg);
  }
  85% {
    opacity: 0.6;
    transform: translateY(14px) scale(0.9) rotate(-1deg);
  }
  100% {
    opacity: 0;
    transform: translateY(22px) scale(0.6) rotate(0deg);
  }
}

/* Buton dosyasındaki rounded-full ve modern flex butonlar */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 9999px;
  border: none;
  cursor: pointer;
  font-family: var(--font-sans);
  font-weight: 600;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-decoration: none;
}

.btn-sm {
  padding: 6px 14px;
  font-size: 0.8125rem;
}

.btn-lg {
  padding: 14px 24px;
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
}

.btn-glow {
  box-shadow: 0 4px 14px rgba(0, 108, 255, 0.35);
}

.btn-secondary {
  background-color: #ffffff;
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background-color: #f8fafc;
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

.btn-subtle {
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #e2e8f0;
}

.btn-subtle:hover {
  background: #e2e8f0;
}

.btn-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.btn-text-block {
  text-align: left;
}

.btn-title {
  display: block;
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.2;
}

.btn-sub {
  display: block;
  font-size: 0.6875rem;
  opacity: 0.85;
  font-weight: 500;
}

.cleanup-notice {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.75rem;
  color: #64748b;
  line-height: 1.4;
  background: #f1f5f9;
  padding: 10px 12px;
  border-radius: 8px;
}

.cleanup-icon {
  width: 14px;
  height: 14px;
  color: #94a3b8;
  margin-top: 2px;
  flex-shrink: 0;
}

/* ==========================================================================
   Modal (İşlem Yapılıyor)
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(6px);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop.hidden {
  display: none;
}

.modal-card {
  background: #ffffff;
  border-radius: 20px;
  padding: 36px 32px;
  max-width: 440px;
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--border-color);
}

.modal-spinner {
  position: relative;
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
}

.spinner-ring {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 4px solid #e2e8f0;
  border-top-color: var(--primary);
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.modal-center-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 22px;
  height: 22px;
  color: var(--primary);
}

.modal-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
}

.modal-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.modal-progress-track {
  width: 100%;
  height: 6px;
  background: #f1f5f9;
  border-radius: 9999px;
  overflow: hidden;
}

.modal-progress-bar {
  height: 100%;
  background: var(--primary);
  border-radius: 9999px;
  transition: width 0.3s ease;
}

/* ==========================================================================
   ePDR Dijital Rehberlik Servisi — Footer Marka & Ücretsiz Vurgu Kartı
   ========================================================================== */
.epdr-footer-card {
  margin-top: 36px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 16px 22px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: all 0.25s ease;
}

.epdr-footer-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.epdr-footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.epdr-brand-section {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.epdr-footer-logo {
  height: 42px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
  display: block;
}

.epdr-divider {
  width: 1px;
  height: 42px;
  background-color: #e2e8f0;
  flex-shrink: 0;
}

.epdr-message-section {
  flex: 1;
  min-width: 260px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.epdr-badges-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.epdr-badge-free {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 10px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
}

.epdr-badge-quality {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 10px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
}

.epdr-desc-text {
  font-size: 0.8125rem;
  color: #64748b;
  line-height: 1.45;
  margin: 0;
}

.epdr-meta-section {
  flex-shrink: 0;
}

.epdr-tag-pill {
  font-size: 0.75rem;
  font-weight: 500;
  color: #475569;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  padding: 6px 12px;
  border-radius: 8px;
  display: inline-block;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .epdr-divider {
    display: none;
  }
  .epdr-footer-content {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}

/* ==========================================================================
   SIFIR KENARLIKLI BASKI ÇIKTISI (PRINT STYLES - ZERO MARGIN ENGINE)
   ========================================================================== */
.print-container {
  display: none;
}

@page {
  size: A4 portrait;
  margin: 0mm !important; /* Tarayıcı grip margin'ini sıfırlar */
}

@media print {
  /* Ekrandaki her şeyi gizle */
  body * {
    visibility: hidden;
  }
  
  html, body {
    margin: 0 !important;
    padding: 0 !important;
    background: #ffffff !important;
    width: 210mm !important;
    height: auto !important;
  }

  /* Yalnızca baskı şablonunu göster */
  .print-container, .print-container * {
    visibility: visible;
  }

  .print-container {
    display: block !important;
    position: absolute;
    left: 0 !important;
    top: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    width: 210mm !important;
  }

  .print-page {
    width: 210mm !important;
    height: 297mm !important;
    page-break-after: always !important;
    break-after: page !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    position: relative !important;
    box-sizing: border-box !important;
  }

  .print-page.landscape {
    width: 297mm !important;
    height: 210mm !important;
  }

  .print-slice-img {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: fill !important;
    margin: 0 !important;
    padding: 0 !important;
    display: block !important;
  }
}

/* ==========================================================================
   Özel Akıcı Cursor Efekti (Smooth Magnetic Dot & Ring)
   ========================================================================== */
.cursor-dot {
  position: fixed;
  top: 0;
  left: 0;
  width: 8px;
  height: 8px;
  background-color: var(--primary);
  border-radius: 50%;
  pointer-events: none;
  z-index: 99999;
  transform: translate(-50%, -50%);
  transition: opacity 0.2s ease, transform 0.1s ease, background-color 0.2s ease;
  will-change: transform;
}

.cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  width: 32px;
  height: 32px;
  border: 1.5px solid rgba(0, 108, 255, 0.45);
  background: rgba(0, 108, 255, 0.04);
  border-radius: 50%;
  pointer-events: none;
  z-index: 99998;
  transform: translate(-50%, -50%);
  transition: width 0.22s cubic-bezier(0.34, 1.56, 0.64, 1), 
              height 0.22s cubic-bezier(0.34, 1.56, 0.64, 1), 
              border-color 0.2s ease, 
              background-color 0.2s ease, 
              opacity 0.2s ease;
  will-change: transform, width, height;
}

/* Hover Durumu (Buton, Kart, Sekme üzerine gelince) */
.cursor-dot.cursor-hover {
  transform: translate(-50%, -50%) scale(1.5);
  background-color: var(--primary-hover);
}

.cursor-ring.cursor-hover {
  width: 48px;
  height: 48px;
  border-color: rgba(0, 108, 255, 0.85);
  background: rgba(0, 108, 255, 0.12);
  box-shadow: 0 0 16px rgba(0, 108, 255, 0.25);
  backdrop-filter: blur(1px);
}

/* Tıklama Durumu */
.cursor-dot.cursor-click {
  transform: translate(-50%, -50%) scale(0.7);
}

.cursor-ring.cursor-click {
  transform: translate(-50%, -50%) scale(0.85);
  border-color: var(--primary);
  background: rgba(0, 108, 255, 0.22);
}

/* Sayfa Dışına Çıkınca */
.cursor-hidden {
  opacity: 0 !important;
}

/* Dokunmatik Ekranlarda ve Baskıda Devre Dışı Bırak */
@media (pointer: coarse) {
  .cursor-dot, .cursor-ring {
    display: none !important;
  }
}

@media print {
  .cursor-dot, .cursor-ring {
    display: none !important;
  }
}

/* ==========================================================================
   Akıllı Yazıcı Modu & Kenar Telafisi
   ========================================================================== */
.printer-mode-box {
  border-color: #e0e7ff;
  background: linear-gradient(180deg, #ffffff 0%, #fcfdff 100%);
}

.help-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
  padding: 3px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #4f46e5;
  cursor: pointer;
  transition: all 0.2s ease;
}

.help-link-btn:hover {
  background: #eef2ff;
  border-color: #c7d2fe;
  color: #3730a3;
  transform: translateY(-1px);
}

.printer-segmented {
  margin-top: 10px;
  margin-bottom: 10px;
}

.printer-segmented .segmented-btn.active {
  border-color: #10b981;
  background: #f0fdf4;
  color: #065f46;
}

.printer-segmented .segmented-btn.active .segmented-metric {
  color: #059669;
}

.print-iso-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  margin-top: 10px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 10px;
  font-size: 0.75rem;
  color: #475569;
  line-height: 1.35;
}

/* ==========================================================================
   Baskı Rehberi Modalı (Print Guide Modal)
   ========================================================================== */
.print-guide-card {
  max-width: 580px;
  width: 95%;
  padding: 24px;
  text-align: left;
}

.print-guide-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid #e2e8f0;
}

.guide-header-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.guide-icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #eef2ff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.guide-modal-heading {
  font-size: 1.0625rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
  line-height: 1.25;
}

.guide-modal-subheading {
  font-size: 0.8125rem;
  color: #64748b;
  margin: 2px 0 0;
}

.btn-icon-close {
  background: #f1f5f9;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-icon-close:hover {
  background: #fee2e2;
  color: #ef4444;
}

.guide-steps-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 20px;
}

.guide-step-row {
  display: flex;
  gap: 14px;
  padding: 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
}

.guide-step-row.highlight-step {
  background: #f0fdf4;
  border-color: #bbf7d0;
}

.guide-step-badge {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #4f46e5;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.step-badge-emerald {
  background: #10b981;
}

.guide-step-body {
  flex: 1;
}

.guide-step-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 4px;
}

.guide-step-desc {
  font-size: 0.8125rem;
  color: #475569;
  line-height: 1.45;
  margin: 0 0 8px;
}

.guide-tag-ok {
  display: inline-block;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid #bae6fd;
}

.guide-tag-tip {
  display: inline-block;
  background: #ecfdf5;
  color: #047857;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid #a7f3d0;
}

.print-guide-footer {
  display: flex;
  justify-content: flex-end;
}

/* ==========================================================================
   Hata & Görüş Bildirimi Butonu & Modalı (ePDR Destek)
   ========================================================================== */
.btn-report-feedback {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #4338ca;
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  padding: 8px 14px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 3px rgba(67, 56, 202, 0.08);
}

.btn-report-feedback:hover {
  background: #4f46e5;
  color: #ffffff;
  border-color: #4f46e5;
  transform: translateY(-1.5px);
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.28);
}

.feedback-modal-card {
  background: #ffffff;
  border-radius: 20px;
  padding: 28px 28px 24px;
  max-width: 520px;
  width: 95%;
  text-align: left;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.22);
  border: 1px solid #e2e8f0;
  position: relative;
  animation: modalFadeIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.feedback-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid #f1f5f9;
}

.feedback-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.feedback-icon-box {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.feedback-title {
  font-size: 1.125rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
  line-height: 1.25;
}

.feedback-subtitle {
  font-size: 0.8125rem;
  color: #64748b;
  margin: 3px 0 0;
}

.feedback-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

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

.form-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #334155;
  display: flex;
  align-items: center;
  gap: 4px;
}

.form-label-optional {
  font-size: 0.75rem;
  font-weight: 400;
  color: #94a3b8;
}

.form-label-required {
  color: #ef4444;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  font-size: 0.875rem;
  font-family: var(--font-sans);
  color: #0f172a;
  outline: none;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  background: #ffffff;
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.form-textarea {
  resize: vertical;
  min-height: 85px;
  line-height: 1.5;
}

.feedback-system-info {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  font-size: 0.75rem;
  color: #64748b;
}

.feedback-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 6px;
}

.feedback-success-state {
  text-align: center;
  padding: 24px 16px;
}

.success-icon-circle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #ecfdf5;
  border: 2px solid #a7f3d0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.success-title {
  font-size: 1.125rem;
  font-weight: 700;
  color: #065f46;
  margin: 0 0 8px;
}

.success-desc {
  font-size: 0.875rem;
  color: #475569;
  line-height: 1.5;
  margin: 0;
}


