/* Bubixo PDF Watermark — palet diger Bubixo araclariyla ayni. */
:root {
  --page: #050914;
  --surface: rgba(8, 15, 30, 0.92);
  --surface-soft: rgba(11, 24, 48, 0.72);
  --text: #f4ead4;
  --muted: rgba(244, 234, 212, 0.6);
  --muted-strong: rgba(244, 234, 212, 0.76);
  --gold: #d6b75c;
  --gold-bright: #e8c96a;
  --cyan: #67e8f9;
  --danger: #fca5a5;
  --success: #6ee7b7;
  --warn: #fcd34d;
  --border: rgba(201, 168, 76, 0.18);
  --border-strong: rgba(201, 168, 76, 0.32);
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.38);
  --radius-lg: 26px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--page); }

body {
  margin: 0;
  background:
    radial-gradient(1100px 620px at 12% -10%, rgba(214, 183, 92, 0.10), transparent 60%),
    radial-gradient(900px 560px at 95% 0%, rgba(103, 232, 249, 0.08), transparent 62%),
    var(--page);
  color: var(--text);
  font-family: Inter, "Segoe UI", system-ui, -apple-system, sans-serif;
  line-height: 1.55;
  min-height: 100vh;
}

/* ------------------------------------------------------------- ust bar */
.site-header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 18px clamp(16px, 4vw, 48px);
  border-bottom: 1px solid var(--border);
}
.brand {
  font-weight: 800; font-size: 20px; letter-spacing: 0.04em;
  color: var(--gold-bright); text-decoration: none;
}
.lang-link {
  display: inline-flex; align-items: center; padding: 8px 15px;
  border: 1px solid var(--border); border-radius: 999px;
  color: var(--muted-strong); font-size: 13px; font-weight: 600;
  text-decoration: none; transition: 0.15s ease;
}
.lang-link:hover { border-color: var(--border-strong); color: var(--gold-bright); }

/* --------------------------------------------------------------- govde */
.shell { max-width: 1240px; margin: 0 auto; padding: clamp(24px, 5vw, 56px) clamp(16px, 4vw, 48px) 72px; }

.intro { margin-bottom: 28px; max-width: 62ch; }
.intro h1 {
  margin: 0 0 10px; font-size: clamp(28px, 4.4vw, 42px); line-height: 1.15;
  font-weight: 800; letter-spacing: -0.015em;
}
.tagline { margin: 0 0 12px; color: var(--muted-strong); font-size: 17px; }
.privacy {
  margin: 0; display: inline-block; padding: 7px 14px;
  border: 1px solid rgba(110, 231, 183, 0.28); border-radius: 999px;
  background: rgba(110, 231, 183, 0.07);
  color: var(--success); font-size: 13px; font-weight: 600;
}

.layout {
  display: grid; gap: 24px;
  grid-template-columns: minmax(300px, 400px) minmax(0, 1fr);
  align-items: start;
}
@media (max-width: 940px) { .layout { grid-template-columns: 1fr; } }

.panel {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow);
  padding: clamp(18px, 3vw, 26px);
}

/* ------------------------------------------------------------ birakma */
.dropzone {
  border: 1.5px dashed var(--border-strong); border-radius: var(--radius-md);
  background: var(--surface-soft); padding: 26px 18px; text-align: center;
  cursor: pointer; transition: 0.15s ease; outline: none;
}
.dropzone:hover, .dropzone:focus-visible, .dropzone.dragging {
  border-color: var(--gold); background: rgba(214, 183, 92, 0.07);
}
.dropzone__idle { display: grid; gap: 6px; justify-items: center; }
.dropzone__idle svg {
  width: 34px; height: 34px; fill: none; stroke: var(--gold);
  stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}
.dropzone__idle strong { font-size: 16px; }
.dropzone__idle span { color: var(--muted); font-size: 13px; }
.dropzone__file { display: none; gap: 4px; justify-items: center; }
.dropzone__file strong { word-break: break-all; font-size: 15px; }
.dropzone__file span { color: var(--muted); font-size: 13px; }
.dropzone__change { color: var(--cyan) !important; font-weight: 600; }
.dropzone.has-file .dropzone__idle { display: none; }
.dropzone.has-file .dropzone__file { display: grid; }

/* ------------------------------------------------------------- alanlar */
#controls { display: grid; gap: 16px; margin-top: 22px; }

.group { border: 0; padding: 0; margin: 0; }
.group legend {
  padding: 0 0 8px; font-size: 12px; font-weight: 700;
  letter-spacing: 0.09em; text-transform: uppercase; color: var(--muted);
}
.segmented {
  display: grid; grid-auto-flow: column; gap: 6px;
  padding: 4px; border: 1px solid var(--border); border-radius: 999px;
  background: var(--surface-soft);
}
.segmented label {
  position: relative; display: flex; align-items: center; justify-content: center;
  padding: 9px 12px; border-radius: 999px; cursor: pointer;
  font-size: 14px; font-weight: 600; color: var(--muted-strong);
  transition: 0.15s ease;
}
.segmented input { position: absolute; opacity: 0; pointer-events: none; }
.segmented input:checked + span { color: #0b1220; }
.segmented label:has(input:checked) { background: var(--gold); }
.segmented label:focus-within { outline: 2px solid var(--cyan); outline-offset: 2px; }

.field { display: grid; gap: 7px; font-size: 14px; font-weight: 600; }
.field > span { color: var(--muted-strong); }
.field input[type="text"], .field select, .field input[type="file"] {
  width: 100%; padding: 11px 13px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--surface-soft);
  color: var(--text); font: inherit; font-weight: 500;
}
.field input[type="text"]:focus, .field select:focus {
  outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(214, 183, 92, 0.16);
}
.field--range { grid-template-columns: 1fr auto; align-items: center; }
.field--range > span { grid-column: 1 / -1; }
.field--range input[type="range"] { width: 100%; accent-color: var(--gold); }
.field--range output {
  min-width: 52px; text-align: right; color: var(--gold-bright);
  font-variant-numeric: tabular-nums; font-size: 13px;
}
.field--color { grid-template-columns: 1fr auto; align-items: center; }
.field--color input[type="color"] {
  width: 54px; height: 34px; padding: 2px; cursor: pointer;
  border: 1px solid var(--border); border-radius: 8px; background: var(--surface-soft);
}
.check { display: flex; align-items: center; gap: 9px; font-size: 14px; color: var(--muted-strong); cursor: pointer; }
.check input { width: 17px; height: 17px; accent-color: var(--gold); }

#textPanel, #imagePanel { display: grid; gap: 14px; }
.image-meta { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); }
.image-meta img {
  width: 46px; height: 46px; object-fit: contain;
  border: 1px solid var(--border); border-radius: 8px; background: rgba(255, 255, 255, 0.06);
}

.apply {
  margin-top: 4px; padding: 14px 18px; border: 0; border-radius: 999px;
  background: linear-gradient(135deg, var(--gold), var(--gold-bright));
  color: #0b1220; font: inherit; font-size: 15px; font-weight: 800;
  cursor: pointer; transition: 0.15s ease;
}
.apply:hover:not(:disabled) { filter: brightness(1.07); }
.apply:disabled { opacity: 0.45; cursor: not-allowed; }

.message {
  margin: 0; padding: 11px 14px; border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 600; border: 1px solid transparent;
}
.message--error { color: var(--danger); border-color: rgba(252, 165, 165, 0.3); background: rgba(252, 165, 165, 0.08); }
.message--warn { color: var(--warn); border-color: rgba(252, 211, 77, 0.3); background: rgba(252, 211, 77, 0.08); }
.message--ok { color: var(--success); border-color: rgba(110, 231, 183, 0.3); background: rgba(110, 231, 183, 0.08); }

/* ----------------------------------------------------------- onizleme */
.preview-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.preview-head h2 { margin: 0; font-size: 17px; font-weight: 700; }
.pager { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted-strong); }
.pager button {
  width: 32px; height: 32px; border-radius: 50%; cursor: pointer;
  border: 1px solid var(--border); background: var(--surface-soft);
  color: var(--text); font-size: 18px; line-height: 1; transition: 0.15s ease;
}
.pager button:hover:not(:disabled) { border-color: var(--gold); color: var(--gold-bright); }
.pager button:disabled { opacity: 0.35; cursor: not-allowed; }

.preview-wrap {
  display: flex; align-items: center; justify-content: center;
  min-height: 340px; padding: 18px; border-radius: var(--radius-md);
  background: repeating-conic-gradient(rgba(255,255,255,0.03) 0% 25%, transparent 0% 50%) 50% / 22px 22px;
  border: 1px solid var(--border); overflow: auto;
}
.preview-empty { margin: 0; color: var(--muted); font-size: 14px; text-align: center; }
.preview-stage { position: relative; line-height: 0; box-shadow: 0 12px 40px rgba(0,0,0,0.5); }
.preview-stage canvas { display: block; max-width: 100%; }
#markCanvas { position: absolute; inset: 0; pointer-events: none; }
.preview-note { margin: 12px 0 0; font-size: 13px; color: var(--muted); text-align: center; min-height: 20px; }

/* Sayfa secimi alani */
#pageSpecRow { gap: 6px; }
.hint { color: var(--muted); font-size: 12.5px; font-weight: 500; line-height: 1.4; min-height: 17px; }
