:root {
  --bg: #0b0f17;
  --surface: #121826;
  --surface-2: #182133;
  --surface-3: #1f2a40;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #f1f5f9;
  --text-muted: #94a3b8;
  --accent: #e11d48;
  --accent-hover: #f43f5e;
  --gold: #f7c948;
  --success: #22c55e;
  --radius: 12px;
  --radius-sm: 8px;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 13.5px;
  -webkit-font-smoothing: antialiased;
}

/* Üst Bar */
.topbar {
  height: 64px;
  padding: 0 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 30;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-badge {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #d91e2a, #991b1b);
  color: #fff;
  font-family: 'Montserrat', sans-serif;
  font-weight: 900;
  font-size: 16px;
  display: grid;
  place-items: center;
  letter-spacing: -0.5px;
  box-shadow: 0 4px 14px rgba(217, 30, 42, 0.35);
  flex-shrink: 0;
}

.brand-badge.has-logo {
  width: auto;
  min-width: 40px;
  max-width: 160px;
  height: 40px;
  padding: 4px 10px;
  background: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.brand-badge.has-logo img {
  max-height: 30px;
  max-width: 140px;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

.brand-text h1 {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.2px;
  white-space: nowrap;
}

.brand-text h1 span {
  font-weight: 600;
  color: var(--gold);
  margin-left: 6px;
  font-size: 13px;
}

.brand-text p {
  margin: 2px 0 0;
  font-size: 11.5px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  margin-left: auto;
}

.hidden {
  display: none !important;
}

/* Üst Fotoğraf / Video Stüdyo Sekme Seçicisi */
.studio-mode-tabs {
  display: flex;
  align-items: center;
  gap: 5px;
  background: #0b101b;
  border: 1px solid var(--border-strong);
  border-radius: 11px;
  padding: 4px;
  flex-shrink: 0;
}

.mode-tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-muted);
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.16s ease;
  white-space: nowrap;
}

.mode-tab:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.mode-tab.active[data-studio-mode="photo"] {
  background: linear-gradient(135deg, #e11d48, #be123c);
  color: #fff;
  box-shadow: 0 3px 12px rgba(225, 29, 72, 0.35);
}

.mode-tab.active[data-studio-mode="video"] {
  background: linear-gradient(135deg, #9333ea, #7e22ce);
  color: #fff;
  box-shadow: 0 3px 12px rgba(147, 51, 234, 0.38);
}

.mode-tab.active[data-studio-mode="admin"],
.mode-tab.active[data-studio-mode="mynews"] {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  box-shadow: 0 3px 12px rgba(37, 99, 235, 0.38);
}

.user-session-bar {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 9px;
  padding: 3px 6px 3px 9px;
}

.user-pill {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text);
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.format-select-group {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 5px 10px;
  font-size: 12px;
  color: var(--text-muted);
}

.format-select-group select {
  background: transparent;
  border: none;
  color: var(--text);
  font-weight: 600;
  font-size: 12px;
  outline: none;
  cursor: pointer;
}

.format-select-group select option {
  background: var(--surface);
  color: var(--text);
}

/* Butonlar */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: 8px 13px;
  font-size: 12.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, #e11d48, #be123c);
  color: #fff;
  box-shadow: 0 3px 12px rgba(225, 29, 72, 0.35);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #f43f5e, #e11d48);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--surface-2);
  color: var(--text);
  border-color: var(--border-strong);
}

.btn-secondary:hover {
  background: var(--surface-3);
}

.btn-success {
  background: linear-gradient(135deg, #16a34a, #15803d);
  color: #fff;
  box-shadow: 0 3px 10px rgba(22, 163, 74, 0.3);
}

.btn-success:hover {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  transform: translateY(-1px);
}

.btn-sm {
  padding: 6px 11px;
  font-size: 12px;
}

.btn-xs {
  padding: 5px 9px;
  font-size: 11.5px;
}

.btn-link {
  background: none;
  border: none;
  color: #60a5fa;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  padding: 2px 4px;
}

.btn-link:hover {
  text-decoration: underline;
}

.btn-link.danger {
  color: #f87171;
}

/* Ana İki Sütunlu Düzen */
.workspace {
  display: grid;
  grid-template-columns: 400px 1fr;
  height: calc(100vh - 64px);
  overflow: hidden;
}

/* Sol Panel */
.sidebar {
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sidebar-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 10px 12px;
  background: #0e1420;
  border-bottom: 1px solid var(--border);
}

.tab-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-muted);
  padding: 8px 6px;
  border-radius: 8px;
  font-size: 11.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s ease;
}

.tab-btn:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.tab-btn.active {
  background: var(--surface-2);
  color: #fff;
  border-color: var(--border-strong);
}

.tab-panel {
  display: none;
  flex: 1;
  overflow-y: auto;
  padding: 12px;
  gap: 12px;
  flex-direction: column;
}

.tab-panel.active {
  display: flex;
}

.tab-panel::-webkit-scrollbar {
  width: 6px;
}

.tab-panel::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.14);
  border-radius: 10px;
}

/* Kartlar */
.panel-card {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 13px;
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.card-head h2 {
  margin: 0;
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #cbd5e1;
}

/* Dropzone */
.dropzone {
  border: 1.5px dashed rgba(148, 163, 184, 0.35);
  border-radius: 10px;
  padding: 16px 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.02);
  transition: all 0.15s ease;
}

.dropzone:hover, .dropzone.dragover {
  border-color: var(--accent);
  background: rgba(225, 29, 72, 0.08);
}

.dropzone-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  display: grid;
  place-items: center;
  color: #93c5fd;
  flex-shrink: 0;
}

.dropzone-video {
  border-color: rgba(168, 85, 247, 0.38);
}

.dropzone-video:hover, .dropzone-video.dragover {
  border-color: #a855f7;
  background: rgba(168, 85, 247, 0.1);
}

.dropzone-icon-video {
  color: #c084fc;
}

.video-meta {
  color: #d8b4fe;
  background: rgba(168, 85, 247, 0.1);
  border-color: rgba(168, 85, 247, 0.25);
}

.folder-save-status {
  margin-top: 9px;
  font-size: 11px;
  color: #86efac;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.22);
  border-radius: 6px;
  padding: 6px 8px;
  word-break: break-word;
}

.folder-save-status code {
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10.5px;
  color: #bbf7d0;
}

.folder-btn-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.dropzone-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.dropzone-text strong {
  font-size: 13px;
  color: #fff;
}

.dropzone-text span {
  font-size: 11.5px;
  color: var(--text-muted);
}

.photo-meta {
  margin-top: 8px;
  font-size: 11.5px;
  color: #93c5fd;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 6px;
  padding: 5px 8px;
}

.hint-text {
  margin: 8px 0 0;
  font-size: 11.5px;
  line-height: 1.45;
  color: var(--text-muted);
}

/* Formlar */
.form-row.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.field {
  margin-bottom: 10px;
}

.field:last-child {
  margin-bottom: 0;
}

.field label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11.5px;
  font-weight: 600;
  color: #cbd5e1;
  margin-bottom: 5px;
}

.label-tip {
  font-weight: 500;
  font-size: 10.5px;
  color: var(--gold);
}

input[type="text"],
select,
textarea {
  width: 100%;
  background: #0d1320;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--text);
  padding: 8px 10px;
  font-family: inherit;
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s ease;
}

textarea {
  resize: vertical;
  line-height: 1.45;
}

input[type="text"]:focus,
select:focus,
textarea:focus {
  border-color: #60a5fa;
}

/* Görünürlük Satırları */
.visibility-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.vis-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #0e1523;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.vis-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 700;
  color: #e2e8f0;
}

.vis-label em {
  font-style: normal;
  font-size: 10.5px;
  font-weight: 500;
  color: var(--text-muted);
}

.vis-checks {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.chk {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px !important;
  font-weight: 500 !important;
  color: #cbd5e1 !important;
  cursor: pointer;
  margin-bottom: 0 !important;
}

.chk input[type="checkbox"] {
  accent-color: var(--accent);
  width: 14px;
  height: 14px;
  cursor: pointer;
}

/* Şablon Seçici */
.template-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.tpl-option {
  background: #0e1523;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  transition: all 0.15s ease;
}

.tpl-option:hover {
  border-color: rgba(255, 255, 255, 0.25);
}

.tpl-option.active {
  border-color: var(--accent);
  background: rgba(225, 29, 72, 0.12);
}

.tpl-thumb {
  width: 100%;
  height: 54px;
  border-radius: 6px;
  position: relative;
  overflow: hidden;
}

.tpl-thumb-cinematic {
  background: linear-gradient(180deg, #334155 0%, #0f172a 75%, #020617 100%);
  border-bottom: 3px solid #d91e2a;
}

.tpl-thumb-editorial {
  background: linear-gradient(180deg, #475569 0%, #475569 52%, #d91e2a 52%, #d91e2a 57%, #0b1320 57%, #0b1320 100%);
}

.tpl-thumb-breaking {
  background: linear-gradient(180deg, #b91c1c 0%, #b91c1c 28%, #1e293b 28%, #090d16 100%);
  border: 2px solid #dc2626;
}

.tpl-thumb-custom {
  background: repeating-conic-gradient(#1e293b 0% 25%, #0f172a 0% 50%) 50% / 14px 14px;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: var(--gold);
  letter-spacing: 1px;
  border: 1px dashed rgba(247, 201, 72, 0.45);
}

/* Logo ve Filigran Yükleme Kutusu & Switch */
.asset-upload-box {
  display: flex;
  align-items: center;
  gap: 11px;
  background: #0e1523;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 9px;
  margin-bottom: 12px;
}

.asset-preview-thumb {
  width: 68px;
  height: 46px;
  border-radius: 7px;
  background: repeating-conic-gradient(#1e293b 0% 25%, #0f172a 0% 50%) 50% / 12px 12px;
  border: 1px solid var(--border-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
  padding: 4px;
}

.asset-preview-thumb span {
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.asset-preview-thumb img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

.asset-upload-meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.quick-watermark-bar {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

.toggle-switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: #0e1523;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 8px 10px;
  cursor: pointer;
}

.toggle-label {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.toggle-label strong {
  font-size: 12px;
  color: #f1f5f9;
}

.toggle-label em {
  font-style: normal;
  font-size: 10.5px;
  color: var(--text-muted);
}

.switch {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 22px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.switch-slider {
  position: absolute;
  inset: 0;
  background: #334155;
  border-radius: 99px;
  transition: 0.18s ease;
}

.switch-slider::before {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  left: 3px;
  top: 3px;
  border-radius: 50%;
  background: #fff;
  transition: 0.18s ease;
}

.switch input:checked + .switch-slider {
  background: var(--accent);
}

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

.logo-upload-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}

.logo-bg-options {
  margin-top: 9px;
  background: #0e1523;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 9px 10px;
  display: flex;
  flex-direction: column;
  gap: 9px;
  transition: opacity 0.15s ease;
}

.logo-bg-options.disabled {
  opacity: 0.45;
}

.logo-bg-color-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.logo-bg-picker {
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo-bg-picker label {
  font-size: 11.5px;
  font-weight: 600;
  color: #cbd5e1;
}

.logo-bg-picker input[type="color"] {
  width: 34px;
  height: 24px;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
  padding: 1px;
}

.swatch-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.color-swatch {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 1.5px solid rgba(255, 255, 255, 0.28);
  cursor: pointer;
  padding: 0;
  transition: transform 0.12s ease, border-color 0.12s ease;
}

.color-swatch:hover {
  transform: scale(1.1);
  border-color: #fff;
}

.status-pill {
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--text-muted);
  white-space: nowrap;
}

.status-pill.ok {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
}

.color-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}

.color-field {
  background: #0e1523;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.color-field label {
  font-size: 10.5px;
  color: var(--text-muted);
  font-weight: 600;
}

.color-field input[type="color"] {
  width: 100%;
  height: 26px;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
}

.slider-field {
  margin-bottom: 11px;
}

.slider-head {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  color: #cbd5e1;
  font-weight: 600;
  margin-bottom: 4px;
}

.slider-head span {
  color: var(--gold);
}

input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
  cursor: pointer;
}

/* Özel PNG Şablon Listesi */
.custom-overlay-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
}

.overlay-item {
  background: #0e1523;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.overlay-item strong {
  display: block;
  font-size: 12px;
}

.overlay-item span {
  font-size: 10.5px;
  color: var(--text-muted);
}

.overlay-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-icon-del {
  background: rgba(248, 113, 113, 0.12);
  border: 1px solid rgba(248, 113, 113, 0.25);
  color: #f87171;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 11px;
  display: grid;
  place-items: center;
}

.btn-icon-del:hover {
  background: rgba(248, 113, 113, 0.25);
}

.divider {
  height: 1px;
  background: var(--border);
  margin: 12px 0;
}

/* Sağ Önizleme Sahnesi */
.preview-stage {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 12%, rgba(225, 29, 72, 0.08), transparent 40%),
    radial-gradient(circle at 82% 88%, rgba(59, 130, 246, 0.08), transparent 40%),
    #090d15;
}

.stage-toolbar {
  padding: 10px 18px;
  border-bottom: 1px solid var(--border);
  background: rgba(18, 24, 38, 0.72);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.view-switcher {
  display: flex;
  gap: 4px;
  background: #0d1320;
  padding: 3px;
  border-radius: 9px;
  border: 1px solid var(--border);
}

.view-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: 6px 11px;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s ease;
}

.view-btn:hover {
  color: #fff;
}

.view-btn.active {
  background: var(--surface-3);
  color: #fff;
}

.stage-tip {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.dot-live {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
}

/* Önizleme Izgarası — Tam Çerçeve & Ekran Boyutuna Göre Orantılı Ölçekleme */
.preview-grid {
  flex: 1;
  overflow: auto;
  padding: 16px 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: flex-start;
  align-content: flex-start;
  justify-content: center;
}

/* Fotoğraf 3'lü Görünüm: Her kart kendi tuval oranına tam oturur, siyah boşluk kalmaz */
.preview-grid.view-all-photos {
  flex-wrap: nowrap;
}

.preview-grid.view-all-photos .preview-card[data-format="web"] {
  flex: 1 1 300px;
  min-width: 260px;
  max-width: min(100%, calc((100vh - 260px) * 1000 / 565 + 24px));
}

.preview-grid.view-all-photos .preview-card[data-format="post"] {
  flex: 0 1 auto;
  width: clamp(230px, calc((100vh - 260px) * 4 / 5 + 24px), 410px);
  max-width: 100%;
}

.preview-grid.view-all-photos .preview-card[data-format="story"] {
  flex: 0 1 auto;
  width: clamp(205px, calc((100vh - 260px) * 9 / 16 + 24px), 340px);
  max-width: 100%;
}

/* Video 2'li Görünüm: Hem 1920x1080 yatay hem 1080x1920 dikey tek ekrana tam çerçeve sığar */
.preview-grid.view-all-videos {
  flex-wrap: nowrap;
}

.preview-grid.view-all-videos .preview-card[data-format="videoWide"] {
  flex: 1 1 380px;
  min-width: 320px;
  max-width: min(100%, calc((100vh - 305px) * 16 / 9 + 24px));
}

.preview-grid.view-all-videos .preview-card[data-format="video"] {
  flex: 0 0 auto;
  width: clamp(235px, calc((100vh - 345px) * 9 / 16 + 24px), 390px);
  max-width: 100%;
}

/* Tekli Görünüm: Seçilen format ekrana göre tam çerçeve büyür/küçülür */
.preview-grid.view-single {
  flex-wrap: nowrap;
  justify-content: center;
}

.preview-grid.view-single .preview-card.hidden-card {
  display: none;
}

.preview-grid.view-single .preview-card[data-format="web"] {
  width: min(100%, calc((100vh - 255px) * 1000 / 565 + 24px));
}

.preview-grid.view-single .preview-card[data-format="post"] {
  width: clamp(260px, calc((100vh - 255px) * 4 / 5 + 24px), 560px);
  max-width: 100%;
}

.preview-grid.view-single .preview-card[data-format="story"] {
  width: clamp(240px, calc((100vh - 255px) * 9 / 16 + 24px), 440px);
  max-width: 100%;
}

.preview-grid.view-single .preview-card[data-format="videoWide"] {
  width: min(100%, calc((100vh - 295px) * 16 / 9 + 24px));
}

.preview-grid.view-single .preview-card[data-format="video"] {
  width: clamp(250px, calc((100vh - 335px) * 9 / 16 + 24px), 460px);
  max-width: 100%;
}

.video-stage-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.shared-video-bar {
  margin: 12px 18px 0;
  background: var(--surface);
  border: 1px solid rgba(168, 85, 247, 0.35);
  border-radius: 12px;
  padding: 8px 14px;
  display: flex;
  align-items: center;
  gap: 11px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.shared-video-bar input[type="range"] {
  flex: 1;
}

.recording-badge-inline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(244, 63, 94, 0.16);
  border: 1px solid rgba(244, 63, 94, 0.55);
  border-radius: 8px;
  padding: 4px 10px;
  font-size: 11.5px;
  font-weight: 700;
  color: #fff;
}

.preview-card-video {
  border-color: rgba(168, 85, 247, 0.28);
}

.dim-badge-video {
  color: #e9d5ff;
  background: rgba(168, 85, 247, 0.16);
  border-color: rgba(168, 85, 247, 0.35);
}

.btn-render-video {
  background: linear-gradient(135deg, #9333ea, #7e22ce);
  border-color: rgba(192, 132, 252, 0.45);
}

.btn-render-video:hover {
  background: linear-gradient(135deg, #a855f7, #9333ea);
  border-color: #c084fc;
}

.recording-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  background: rgba(15, 23, 42, 0.92);
  border: 1px solid rgba(244, 63, 94, 0.6);
  border-radius: 9px;
  padding: 7px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  font-weight: 700;
  color: #fff;
  z-index: 5;
}

.recording-badge.hidden {
  display: none;
}

.rec-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #f43f5e;
  box-shadow: 0 0 8px #f43f5e;
  animation: pulseRec 1s infinite;
}

@keyframes pulseRec {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.btn-rec-cancel {
  margin-left: auto;
  background: rgba(248, 113, 113, 0.2);
  border: 1px solid rgba(248, 113, 113, 0.4);
  color: #fecaca;
  border-radius: 6px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}

.video-player-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  background: #0e1523;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 5px 8px;
}

.btn-video-ctl {
  background: var(--surface-3);
  border: 1px solid var(--border-strong);
  color: #fff;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  cursor: pointer;
  font-size: 11px;
  flex-shrink: 0;
}

.btn-video-ctl:hover {
  background: #9333ea;
}

.video-time {
  font-size: 10.5px;
  font-variant-numeric: tabular-nums;
  color: var(--text-muted);
  white-space: nowrap;
}

.video-layout-row {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11px;
  color: var(--text-muted);
}

.video-layout-row label {
  white-space: nowrap;
  font-weight: 600;
}

.video-layout-row select {
  padding: 4px 7px;
  font-size: 11.5px;
}

.preview-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

.preview-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.preview-title {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.preview-title h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
}

.dim-badge {
  font-size: 11px;
  font-weight: 700;
  color: var(--gold);
  background: rgba(247, 201, 72, 0.12);
  border: 1px solid rgba(247, 201, 72, 0.25);
  padding: 2px 7px;
  border-radius: 99px;
}

.btn-download-one {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  padding: 5px 11px;
  font-size: 11.5px;
  border-color: var(--border-strong);
}

.btn-download-one:hover {
  background: var(--accent);
  border-color: var(--accent);
}

/* Tuval Çerçevesi — Siyah Boşluksuz Tam Çerçeve */
.canvas-frame {
  width: 100%;
  background: transparent;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.canvas-frame canvas {
  display: block;
  width: 100%;
  height: auto;
  cursor: grab;
  user-select: none;
  touch-action: none;
}

.canvas-frame canvas:active {
  cursor: grabbing;
}

.preview-card-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.mini-slider {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: var(--text-muted);
}

.mini-slider input[type="range"] {
  flex: 1;
}

.btn-mini-reset {
  background: transparent;
  border: 1px solid var(--border-strong);
  color: #cbd5e1;
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 11px;
  cursor: pointer;
}

.btn-mini-reset:hover {
  background: var(--surface-3);
  color: #fff;
}

/* Toast Bildirimi */
.toast {
  position: fixed;
  bottom: 22px;
  right: 22px;
  background: #10b981;
  color: #052e16;
  font-weight: 700;
  font-size: 13px;
  padding: 10px 16px;
  border-radius: 10px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: all 0.22s ease;
  z-index: 400;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* Küçük Ekranlar */
@media (max-width: 1360px) {
  .brand-text p {
    display: none;
  }
}

@media (max-width: 1180px) {
  .workspace {
    grid-template-columns: 360px 1fr;
  }
  .preview-grid.view-all-photos,
  .preview-grid.view-all-videos {
    flex-wrap: wrap;
  }
}

@media (max-width: 860px) {
  .workspace {
    grid-template-columns: 1fr;
    height: auto;
    overflow: visible;
  }
  .topbar {
    flex-wrap: wrap;
    height: auto;
    padding: 12px 16px;
  }
  .brand-badge.has-logo {
    max-width: 124px;
    padding: 3px 8px;
  }
  .brand-badge.has-logo img {
    max-width: 108px;
    max-height: 26px;
  }
  .preview-grid.view-all-photos,
  .preview-grid.view-all-videos {
    flex-wrap: wrap;
  }
  .preview-grid .preview-card {
    width: 100% !important;
    max-width: 100% !important;
  }
}

/* ============================================================================
 * AÇIK TEMA (LIGHT MODE) — TEMİZ, FERAH YAYIN STÜDYOSU GÖRÜNÜMÜ
 * ============================================================================ */
body[data-theme="light"] {
  --bg: #f1f5f9;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --surface-3: #e2e8f0;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --text: #0f172a;
  --text-muted: #64748b;
  --gold: #b45309;
}

body[data-theme="light"] .topbar {
  background: #ffffff;
  box-shadow: 0 1px 6px rgba(15, 23, 42, 0.06);
}

body[data-theme="light"] .brand-text h1 span {
  color: #dc2626;
}

body[data-theme="light"] .brand-badge.has-logo {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.08);
}

body[data-theme="light"] .studio-mode-tabs {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

body[data-theme="light"] .mode-tab {
  color: #475569;
}

body[data-theme="light"] .mode-tab:hover {
  color: #0f172a;
  background: rgba(15, 23, 42, 0.05);
}

body[data-theme="light"] .sidebar {
  background: #ffffff;
  border-right-color: #e2e8f0;
}

body[data-theme="light"] .sidebar-tabs {
  background: #f1f5f9;
  border-bottom-color: #e2e8f0;
}

body[data-theme="light"] .tab-btn {
  color: #475569;
}

body[data-theme="light"] .tab-btn:hover {
  color: #0f172a;
  background: rgba(15, 23, 42, 0.04);
}

body[data-theme="light"] .tab-btn.active {
  background: #ffffff;
  color: #0f172a;
  border-color: #cbd5e1;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

body[data-theme="light"] .panel-card {
  background: #f8fafc;
  border-color: #e2e8f0;
}

body[data-theme="light"] .card-head h2 {
  color: #334155;
}

body[data-theme="light"] .field label,
body[data-theme="light"] .slider-head,
body[data-theme="light"] .chk,
body[data-theme="light"] .logo-bg-picker label {
  color: #334155 !important;
}

body[data-theme="light"] .label-tip,
body[data-theme="light"] .slider-head span {
  color: #b45309;
}

body[data-theme="light"] input[type="text"],
body[data-theme="light"] select,
body[data-theme="light"] textarea {
  background: #ffffff;
  color: #0f172a;
  border-color: #cbd5e1;
}

body[data-theme="light"] .format-select-group {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: #475569;
}

body[data-theme="light"] .format-select-group select {
  background: transparent;
  color: #0f172a;
}

body[data-theme="light"] .format-select-group select option {
  background: #ffffff;
  color: #0f172a;
}

body[data-theme="light"] .dropzone {
  background: #ffffff;
  border-color: #94a3b8;
}

body[data-theme="light"] .dropzone:hover,
body[data-theme="light"] .dropzone.dragover {
  background: #fff1f2;
  border-color: var(--accent);
}

body[data-theme="light"] .dropzone-video:hover,
body[data-theme="light"] .dropzone-video.dragover {
  background: #faf5ff;
  border-color: #9333ea;
}

body[data-theme="light"] .dropzone-icon {
  background: #eff6ff;
  color: #2563eb;
}

body[data-theme="light"] .dropzone-icon-video {
  background: #f3e8ff;
  color: #7e22ce;
}

body[data-theme="light"] .dropzone-text strong {
  color: #0f172a;
}

body[data-theme="light"] .photo-meta {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1d4ed8;
}

body[data-theme="light"] .video-meta {
  background: #faf5ff;
  border-color: #e9d5ff;
  color: #7e22ce;
}

body[data-theme="light"] .folder-save-status {
  background: #f0fdf4;
  border-color: #bbf7d0;
  color: #15803d;
}

body[data-theme="light"] .folder-save-status code {
  color: #166534;
}

body[data-theme="light"] .vis-row,
body[data-theme="light"] .tpl-option,
body[data-theme="light"] .asset-upload-box,
body[data-theme="light"] .toggle-switch-row,
body[data-theme="light"] .logo-bg-options,
body[data-theme="light"] .color-field,
body[data-theme="light"] .overlay-item {
  background: #ffffff;
  border-color: #e2e8f0;
}

body[data-theme="light"] .vis-label,
body[data-theme="light"] .toggle-label strong,
body[data-theme="light"] .tpl-option {
  color: #0f172a;
}

body[data-theme="light"] .tpl-option.active {
  background: #fff1f2;
  border-color: var(--accent);
}

body[data-theme="light"] .asset-preview-thumb {
  background: repeating-conic-gradient(#e2e8f0 0% 25%, #f8fafc 0% 50%) 50% / 12px 12px;
  border-color: #cbd5e1;
}

body[data-theme="light"] .status-pill {
  background: #e2e8f0;
  color: #475569;
}

body[data-theme="light"] .status-pill.ok {
  background: #dcfce7;
  color: #15803d;
}

body[data-theme="light"] .switch-slider {
  background: #cbd5e1;
}

body[data-theme="light"] .color-swatch {
  border-color: #94a3b8;
}

body[data-theme="light"] .btn-secondary {
  background: #ffffff;
  color: #0f172a;
  border-color: #cbd5e1;
}

body[data-theme="light"] .btn-secondary:hover {
  background: #f1f5f9;
}

body[data-theme="light"] .btn-link {
  color: #2563eb;
}

body[data-theme="light"] .btn-link.danger {
  color: #dc2626;
}

body[data-theme="light"] .preview-stage {
  background:
    radial-gradient(circle at 18% 12%, rgba(225, 29, 72, 0.05), transparent 42%),
    radial-gradient(circle at 82% 88%, rgba(59, 130, 246, 0.06), transparent 42%),
    #e9eef5;
}

body[data-theme="light"] .stage-toolbar {
  background: rgba(255, 255, 255, 0.9);
  border-bottom-color: #dbe3ee;
}

body[data-theme="light"] .view-switcher {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

body[data-theme="light"] .view-btn {
  color: #475569;
}

body[data-theme="light"] .view-btn:hover {
  color: #0f172a;
}

body[data-theme="light"] .view-btn.active {
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.1);
}

body[data-theme="light"] .preview-card {
  background: #ffffff;
  border-color: #dbe3ee;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

body[data-theme="light"] .preview-title h3 {
  color: #0f172a;
}

body[data-theme="light"] .dim-badge {
  color: #b45309;
  background: #fef3c7;
  border-color: #fde68a;
}

body[data-theme="light"] .dim-badge-video {
  color: #7e22ce;
  background: #f3e8ff;
  border-color: #d8b4fe;
}

body[data-theme="light"] .btn-download-one {
  background: #f1f5f9;
  color: #0f172a;
  border-color: #cbd5e1;
}

body[data-theme="light"] .btn-download-one:hover {
  background: var(--accent);
  color: #ffffff;
  border-color: var(--accent);
}

body[data-theme="light"] .btn-render-video {
  background: linear-gradient(135deg, #9333ea, #7e22ce);
  color: #ffffff;
  border-color: #7e22ce;
}

body[data-theme="light"] .btn-mini-reset {
  color: #334155;
  border-color: #cbd5e1;
}

body[data-theme="light"] .btn-mini-reset:hover {
  background: #f1f5f9;
  color: #0f172a;
}

body[data-theme="light"] .shared-video-bar {
  background: #ffffff;
  border-color: #d8b4fe;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.07);
}

body[data-theme="light"] .btn-video-ctl {
  background: #f1f5f9;
  color: #0f172a;
  border-color: #cbd5e1;
}

body[data-theme="light"] .btn-video-ctl:hover {
  background: #9333ea;
  color: #ffffff;
}

body[data-theme="light"] .recording-badge-inline {
  background: #fff1f2;
  color: #be123c;
}

body[data-theme="light"] .btn-rec-cancel {
  color: #be123c;
}

body[data-theme="light"] .tab-panel::-webkit-scrollbar-thumb {
  background: #cbd5e1;
}

/* ============================================================================
 * YÖNETİM PANELİ, ALT KULLANICILAR, ÜRETİM KAYITLARI VE MODALLAR
 * ============================================================================ */
.admin-stage {
  height: calc(100vh - 64px);
  overflow-y: auto;
  padding: 20px 24px 40px;
  background: var(--bg);
}

.admin-container {
  max-width: 1440px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(170px, 1fr));
  gap: 14px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.14);
}

.stat-label {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.stat-value {
  font-family: 'Montserrat', sans-serif;
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
}

.stat-value-sm {
  font-size: 16px;
  line-height: 1.3;
}

.admin-subtabs {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
}

.admin-subtab {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  color: var(--text-muted);
  padding: 9px 16px;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s ease;
}

.admin-subtab:hover {
  color: var(--text);
}

.admin-subtab.active {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  border-color: #2563eb;
}

.admin-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.14);
}

.admin-filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.filter-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 145px;
}

.filter-item.filter-search {
  flex: 1;
  min-width: 200px;
}

.filter-item label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.filter-item input[type="date"],
.filter-item input[type="text"],
.filter-item select {
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 7px 9px;
  font-size: 12.5px;
  font-family: inherit;
}

.filter-actions {
  display: flex;
  gap: 8px;
}

.admin-users-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.admin-users-head h3 {
  margin: 0;
  font-size: 15px;
}

.admin-users-head p {
  margin: 3px 0 0;
  font-size: 12px;
  color: var(--text-muted);
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.admin-table th {
  text-align: left;
  padding: 10px 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-strong);
  white-space: nowrap;
}

.admin-table td {
  padding: 10px 10px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.admin-table tbody tr:hover {
  background: rgba(59, 130, 246, 0.05);
}

.empty-cell {
  text-align: center;
  padding: 28px 12px !important;
  color: var(--text-muted);
}

.log-thumb-btn {
  width: 68px;
  height: 44px;
  border-radius: 7px;
  border: 1px solid var(--border-strong);
  background: var(--surface-2);
  overflow: hidden;
  padding: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
}

.log-thumb-btn img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.badge-admin { background: rgba(37, 99, 235, 0.16); color: #3b82f6; }
.badge-subuser { background: rgba(148, 163, 184, 0.16); color: var(--text-muted); }
.badge-active { background: rgba(34, 197, 94, 0.16); color: #16a34a; }
.badge-passive { background: rgba(239, 68, 68, 0.16); color: #dc2626; }
.badge-photo { background: rgba(225, 29, 72, 0.14); color: #e11d48; }
.badge-video { background: rgba(147, 51, 234, 0.16); color: #9333ea; }
.badge-folder { background: rgba(22, 163, 74, 0.16); color: #16a34a; }
.badge-brand { background: rgba(245, 158, 11, 0.16); color: #d97706; }

.perm-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-width: 360px;
}

.perm-chip {
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  color: var(--text);
}

.row-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}

/* Modallar & Giriş Ekranı */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(5px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-box {
  width: 100%;
  max-width: 440px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  max-height: 92vh;
  overflow-y: auto;
}

.user-modal-box {
  max-width: 600px;
}

.preview-modal-box {
  max-width: 780px;
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.modal-head h3 {
  margin: 0;
  font-size: 16px;
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.login-brand h2 {
  margin: 0;
  font-size: 16px;
}

.login-brand p {
  margin: 3px 0 0;
  font-size: 12px;
  color: var(--text-muted);
}

.modal-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.modal-form input[type="password"],
.modal-form input[type="text"],
.modal-form select {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--text);
  padding: 8px 10px;
  font-size: 13px;
  font-family: inherit;
}

.form-error {
  background: rgba(239, 68, 68, 0.14);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #ef4444;
  font-size: 12px;
  font-weight: 600;
  border-radius: 8px;
  padding: 8px 10px;
}

.default-pw-hint {
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 8px;
  padding: 9px 11px;
  font-size: 12px;
  line-height: 1.45;
}

.btn-full {
  width: 100%;
  padding: 10px;
  font-size: 13.5px;
}

.perm-section {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 11px;
}

.perm-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 9px;
  flex-wrap: wrap;
}

.perm-title {
  font-size: 12px;
  font-weight: 700;
}

.perm-presets {
  display: flex;
  gap: 5px;
}

.btn-preset {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  color: var(--text);
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}

.btn-preset:hover {
  border-color: #2563eb;
  color: #2563eb;
}

.perm-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 6px;
}

.lp-media-box {
  background: #0b1120;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: 62vh;
}

.lp-media-box img,
.lp-media-box video {
  max-width: 100%;
  max-height: 62vh;
  display: block;
}

.lp-meta {
  margin-top: 12px;
  font-size: 12.5px;
  line-height: 1.5;
}

.lp-meta p {
  margin: 4px 0;
}

@media (max-width: 900px) {
  .admin-stats-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* ============================================================================
 * OTURUM KONTROLÜ & BAĞIMSIZ GİRİŞ SAYFASI (/login.html)
 * ============================================================================ */
body:not([data-auth="authenticated"]):not(.login-page-body) .topbar,
body:not([data-auth="authenticated"]):not(.login-page-body) .workspace,
body:not([data-auth="authenticated"]):not(.login-page-body) .admin-stage {
  display: none !important;
}

.login-page-body {
  margin: 0;
  min-height: 100vh;
}

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  position: relative;
  background:
    radial-gradient(circle at 20% 20%, rgba(225, 29, 72, 0.14), transparent 45%),
    radial-gradient(circle at 80% 80%, rgba(37, 99, 235, 0.14), transparent 45%),
    var(--bg);
}

body[data-theme="light"] .login-page {
  background:
    radial-gradient(circle at 20% 20%, rgba(225, 29, 72, 0.08), transparent 45%),
    radial-gradient(circle at 80% 80%, rgba(37, 99, 235, 0.09), transparent 45%),
    #e9eef5;
}

.login-theme-corner {
  position: fixed;
  top: 18px;
  right: 20px;
}

.login-page-card {
  max-width: 430px;
  width: 100%;
  padding: 26px;
}

/* ============================================================================
 * İLK KURULUM SİHİRBAZI (/setup.html), SADE SOL PANEL & 4 SEKMELİ YÖNETİM
 * ============================================================================ */
.setup-page {
  min-height: 100vh;
  padding: 26px 20px 44px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  background:
    radial-gradient(circle at 15% 15%, rgba(225, 29, 72, 0.12), transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(37, 99, 235, 0.14), transparent 45%),
    var(--bg);
}

body[data-theme="light"] .setup-page {
  background:
    radial-gradient(circle at 15% 15%, rgba(225, 29, 72, 0.06), transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(37, 99, 235, 0.08), transparent 45%),
    #e9eef5;
}

.setup-card {
  width: 100%;
  max-width: 1220px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.16);
}

.setup-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 18px;
}

.setup-header h1 {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  font-size: 20px;
  font-weight: 800;
}

.setup-header p {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--text-muted);
}

.setup-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(260px, 1fr));
  gap: 16px;
}

.setup-section {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 15px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.setup-sec-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 4px;
}

.setup-sec-title span {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  display: grid;
  place-items: center;
}

.setup-footer {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.sidebar-header {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}

.sidebar-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.sidebar-header h2 {
  margin: 0;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.2px;
}

.sidebar-header span {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  color: var(--text-muted);
}

.workspace-mode-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 10px 14px 0;
  padding: 4px;
  background: #0b101b;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  flex-shrink: 0;
}

.workspace-mode-switch .mode-tab {
  justify-content: center;
  padding: 7px 10px;
}

body[data-theme="light"] .workspace-mode-switch {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.admin-top-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.admin-top-header h2 {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  font-size: 19px;
}

.admin-top-header p {
  margin: 3px 0 0;
  font-size: 12.5px;
  color: var(--text-muted);
}

.admin-top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.admin-subtabs {
  flex-wrap: wrap;
}

.subuser-guide-banner {
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.25);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.subuser-guide-banner strong {
  display: block;
  font-size: 13.5px;
  margin-bottom: 3px;
}

.subuser-guide-banner p {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.45;
}

.subuser-guide-banner code {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  padding: 1px 6px;
  font-weight: 700;
  color: var(--text);
}

.subuser-guide-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.admin-template-layout {
  display: grid;
  grid-template-columns: 1fr 390px;
  gap: 16px;
  align-items: start;
}

.admin-template-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(250px, 1fr));
  gap: 12px;
}

.admin-template-preview {
  position: sticky;
  top: 12px;
}

.admin-template-preview .canvas-frame canvas {
  max-height: 68vh;
  width: auto !important;
  max-width: 100%;
  cursor: default;
}

@media (max-width: 1120px) {
  .setup-grid {
    grid-template-columns: 1fr;
  }
  .admin-template-layout {
    grid-template-columns: 1fr;
  }
  .admin-template-controls {
    grid-template-columns: 1fr;
  }
  .admin-template-preview {
    position: static;
  }
}

/* ============================================================================
 * Aktif Haber Düzenleme Şeridi, ✨ Oluştur Popup ve Önceki Haberler Listesi
 * ============================================================================ */
.active-news-banner {
  margin: 10px 12px 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.35);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.edit-banner-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.edit-banner-actions {
  display: flex;
  gap: 5px;
}

.edit-banner-dates {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 11px;
  color: var(--text-muted);
}

.create-modal-box {
  max-width: 820px;
}

.my-news-modal-box {
  max-width: 860px;
}

.ce-meta-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  padding: 9px 12px;
  border-radius: 9px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  font-size: 12px;
  margin-bottom: 14px;
}

.ce-section {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 12px;
}

.ce-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.ce-section-head h4 {
  margin: 0;
  font-size: 13.5px;
  font-weight: 800;
}

.ce-bulk-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.ce-photo-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.ce-thumb-card {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.ce-thumb-img-wrap {
  height: 170px;
  background: #0b1120;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
}

.ce-thumb-img-wrap img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 4px;
}

.ce-thumb-foot {
  padding: 8px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  font-weight: 700;
}

.ce-thumb-foot em {
  font-style: normal;
  font-weight: 500;
  color: var(--text-muted);
  font-size: 11px;
}

.ce-video-box {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.ce-video-empty {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12px;
  color: var(--text-muted);
}

.ce-video-progress {
  font-size: 12px;
  font-weight: 700;
  color: #2563eb;
}

.my-news-toolbar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.my-news-toolbar input[type="text"] {
  flex: 1;
  min-width: 200px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--text);
  padding: 8px 10px;
  font-size: 13px;
}

.my-news-toolbar select {
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--text);
  padding: 8px 10px;
  font-size: 13px;
}

.my-news-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 62vh;
  overflow-y: auto;
}

.news-item-row {
  display: grid;
  grid-template-columns: 116px 1fr auto;
  gap: 12px;
  align-items: center;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px;
}

.news-item-thumb {
  width: 116px;
  height: 68px;
  border-radius: 7px;
  background: #0b1120;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  font-size: 11px;
}

.news-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-item-info h4 {
  margin: 0 0 4px;
  font-size: 13.5px;
  line-height: 1.3;
}

.news-item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  font-size: 11.5px;
  color: var(--text-muted);
}

.news-item-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.ts-badge {
  display: inline-block;
  font-size: 11.5px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.ts-muted {
  color: var(--text-muted);
  font-size: 11.5px;
}

@media (max-width: 720px) {
  .ce-photo-grid {
    grid-template-columns: 1fr;
  }
  .news-item-row {
    grid-template-columns: 1fr;
  }
}

.badge-danger {
  background: rgba(239, 68, 68, 0.16);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

.row-user-deleted {
  background: rgba(239, 68, 68, 0.05);
}

.storage-stats-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  padding: 10px 14px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 12px;
  margin-bottom: 12px;
}

.storage-stats-strip code {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  padding: 1px 6px;
}

.storage-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 1fr));
  gap: 12px;
}

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

.chip-btn {
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.chip-btn:hover {
  border-color: #2563eb;
  color: #2563eb;
}

@media (max-width: 860px) {
  .storage-settings-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================================
 * Özel Silme & Onay Popup Modalı
 * ============================================================================ */
.confirm-modal-backdrop {
  z-index: 300;
}

.confirm-modal-box {
  max-width: 450px;
  padding: 20px 22px;
  border-radius: 16px;
  animation: confirmPopIn 0.16s ease-out;
}

@keyframes confirmPopIn {
  from { opacity: 0; transform: scale(0.95) translateY(6px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.confirm-modal-top {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.confirm-icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(239, 68, 68, 0.14);
  border: 1px solid rgba(239, 68, 68, 0.35);
  color: #ef4444;
  font-size: 20px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.confirm-modal-texts {
  flex: 1;
  min-width: 0;
}

.confirm-modal-texts h3 {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 800;
}

.confirm-modal-texts p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-muted);
}

.confirm-item-pill {
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 4px 9px;
  margin-bottom: 8px;
  border-radius: 7px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
}

.confirm-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.btn-danger-solid {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #ffffff;
  border: none;
  font-weight: 700;
}

.btn-danger-solid:hover {
  filter: brightness(1.06);
}

.inactive-retention-bar {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.inactive-retention-bar strong {
  display: block;
  font-size: 13px;
  margin-bottom: 3px;
}

.inactive-retention-bar p {
  margin: 0;
  font-size: 11.5px;
  color: var(--text-muted);
  max-width: 560px;
}

.inactive-retention-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.inactive-retention-controls input[type="number"] {
  width: 78px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 7px;
  color: var(--text);
  padding: 5px 8px;
  font-size: 12.5px;
  font-weight: 700;
}

.btn-warn-xs {
  background: rgba(245, 158, 11, 0.16);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.4);
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
}

.btn-warn-xs:hover {
  background: rgba(245, 158, 11, 0.28);
}

.row-user-passive {
  opacity: 0.85;
  background: rgba(148, 163, 184, 0.06);
}

/* ============================================================================
 * META DEVELOPER API (INSTAGRAM & FACEBOOK) STİLLERİ
 * ============================================================================ */
.badge-meta {
  background: rgba(168, 85, 247, 0.16);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.35);
}

.meta-status-strip {
  align-items: center;
}

.meta-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(290px, 1fr));
  gap: 14px;
}

.meta-secret-row {
  display: flex;
  gap: 6px;
  align-items: center;
}

.meta-secret-row input {
  flex: 1;
}

.meta-discover-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 6px;
}

.meta-discovered-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
  padding: 10px;
  border-radius: 10px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
}

.meta-discover-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  flex-wrap: wrap;
}

.meta-discover-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 12px;
}

.meta-guide-box {
  background: rgba(37, 99, 235, 0.09);
  border: 1px solid rgba(37, 99, 235, 0.28);
  border-radius: 10px;
  padding: 11px 13px;
  font-size: 12px;
  line-height: 1.5;
  margin-top: 8px;
}

.meta-guide-box strong {
  display: block;
  margin-bottom: 4px;
}

.meta-guide-box p {
  margin: 0 0 6px;
  color: var(--text-muted);
}

.meta-guide-box ul {
  margin: 0;
  padding-left: 18px;
  color: var(--text-muted);
}

.meta-guide-box code {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  padding: 1px 5px;
  color: var(--text);
  font-size: 11px;
}

.meta-test-results {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 12px;
  padding: 10px;
  border-radius: 10px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
}

.meta-test-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  padding: 6px 8px;
  border-radius: 7px;
  background: var(--surface);
  border: 1px solid var(--border);
}

.meta-test-row.ok {
  border-color: rgba(34, 197, 94, 0.35);
}

.meta-test-row.fail {
  border-color: rgba(239, 68, 68, 0.4);
}

.ce-meta-account-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.meta-targets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(175px, 1fr));
  gap: 8px;
  margin-bottom: 8px;
}

.meta-target-chip {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 10px;
  border-radius: 9px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.meta-target-chip:hover {
  border-color: #3b82f6;
}

.meta-target-chip.disabled {
  opacity: 0.48;
  cursor: not-allowed;
}

.meta-target-chip small {
  font-weight: 500;
  color: var(--text-muted);
  font-size: 11px;
}

.meta-publish-options {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.ce-meta-actions-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.meta-publish-results {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px;
  border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
}

.meta-pub-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  padding: 6px 8px;
  border-radius: 7px;
  background: var(--surface-2);
  flex-wrap: wrap;
}

body[data-theme="light"] .badge-meta {
  color: #7e22ce;
}

body[data-theme="light"] .meta-guide-box {
  background: #eff6ff;
  border-color: #bfdbfe;
}

body[data-theme="light"] .meta-guide-box p,
body[data-theme="light"] .meta-guide-box ul {
  color: #334155;
}

@media (max-width: 860px) {
  .meta-settings-grid {
    grid-template-columns: 1fr;
  }
  .meta-targets-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ============================================================================
 * Başlık Mini Biçimlendirme Çubuğu & Klavye Kısayolu İpuçları
 * ============================================================================ */
.headline-toolbar {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.btn-fmt-tool {
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 700;
  font-family: inherit;
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
  cursor: pointer;
  line-height: 1.35;
  transition: border-color 0.14s ease, background 0.14s ease, color 0.14s ease;
}

.btn-fmt-tool:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(225, 29, 72, 0.08);
}

.btn-fmt-tool.fmt-highlight {
  border-color: rgba(247, 201, 72, 0.45);
  color: var(--gold);
  background: rgba(247, 201, 72, 0.1);
}

.btn-fmt-tool.fmt-highlight:hover {
  border-color: var(--gold);
  background: rgba(247, 201, 72, 0.2);
}

body[data-theme="light"] .btn-fmt-tool {
  background: #ffffff;
  color: #1e293b;
  border-color: #cbd5e1;
}

body[data-theme="light"] .btn-fmt-tool:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: #fff1f2;
}

body[data-theme="light"] .btn-fmt-tool.fmt-highlight {
  background: #fef3c7;
  color: #92400e;
  border-color: #f59e0b;
}

body[data-theme="light"] .btn-fmt-tool.fmt-highlight:hover {
  background: #fde68a;
}

.headline-char-count {
  margin-left: auto;
  font-size: 10.5px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.shortcut-kbd {
  display: inline-block;
  padding: 1px 5px;
  font-size: 10px;
  font-weight: 700;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  line-height: 1.35;
  color: var(--text);
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 4px;
}


/* ============================================================================
 * WEB SİTESİ XML OTOMASYONU (KURUMSALX) STİLLERİ
 * ============================================================================ */
.badge-web {
  background: rgba(14, 165, 233, 0.16);
  color: #38bdf8;
  border: 1px solid rgba(14, 165, 233, 0.35);
}

body[data-theme="light"] .badge-web {
  color: #0369a1;
  background: #e0f2fe;
  border-color: #7dd3fc;
}

.wf-url-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  flex: 1 1 320px;
}

.wf-url-bar code {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: inline-block;
  vertical-align: middle;
}

.wf-mapping-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11.5px;
  margin-top: 6px;
}

.wf-mapping-table th,
.wf-mapping-table td {
  text-align: left;
  padding: 5px 8px;
  border-bottom: 1px solid var(--border);
}

.wf-mapping-table th {
  font-size: 10.5px;
  text-transform: uppercase;
  color: var(--text-muted);
}

.wf-mapping-table code {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 4px;
  padding: 1px 5px;
  font-size: 11px;
  font-weight: 700;
}
