@font-face {
  font-family: "Vazirmatn";
  src: url("/fonts/vazirmatn/Vazirmatn-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Vazirmatn";
  src: url("/fonts/vazirmatn/Vazirmatn-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Vazirmatn";
  src: url("/fonts/vazirmatn/Vazirmatn-Bold.woff2") format("woff2");
  font-weight: 700 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg-1: #f6fbff;
  --bg-2: #fff9f3;
  --bg-3: #f8f4ff;
  --panel: rgba(255,255,255,.86);
  --panel-strong: rgba(255,255,255,.96);
  --line: rgba(125, 102, 255, 0.14);
  --text: #22314f;
  --muted: #6c7a96;
  --primary: #6b63ff;
  --primary-2: #39a0ff;
  --peach: #ff9b6a;
  --mint: #19c8a7;
  --pink: #ff62af;
  --success: #1fb86e;
  --shadow: 0 18px 45px rgba(62, 84, 138, 0.12);
  --shadow-soft: 0 10px 25px rgba(62, 84, 138, 0.08);
}

html, body {
  font-family: "Vazirmatn", Tahoma, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top right, rgba(107,99,255,.12), transparent 22%),
    radial-gradient(circle at 10% 20%, rgba(57,160,255,.12), transparent 18%),
    radial-gradient(circle at 82% 80%, rgba(255,155,106,.12), transparent 20%),
    linear-gradient(135deg, var(--bg-1), var(--bg-2) 52%, var(--bg-3));
  color: var(--text);
  min-height: 100%;
}

body { direction: rtl; }
a { color: #3658dd; text-decoration: none; }
a:hover { color: #243cb0; }

.site-shell {
  max-width: 1400px;
  margin: 0 auto;
  padding: 18px;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border: 1px solid rgba(255,255,255,.65);
  background: var(--panel);
  backdrop-filter: blur(24px);
  border-radius: 28px;
  padding: 16px 20px;
  box-shadow: var(--shadow);
  margin-bottom: 22px;
  position: sticky;
  top: 14px;
  z-index: 20;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 14px;
  color: inherit;
}
.brand-link:hover { color: inherit; }
.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-weight: 900;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--pink));
  box-shadow: 0 12px 28px rgba(107,99,255,.25);
}
.brand-title { font-size: 1.7rem; font-weight: 900; line-height: 1.1; }
.brand-subtitle { color: var(--muted); font-size: .95rem; margin-top: 4px; }

.top-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  flex: 1;
}

.top-nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 999px;
  background: rgba(255,255,255,.78);
  border: 1px solid rgba(125,102,255,.10);
  color: var(--text);
  font-weight: 800;
  box-shadow: var(--shadow-soft);
}
.top-nav-link.active,
.top-nav-link:hover {
  background: linear-gradient(135deg, rgba(107,99,255,.18), rgba(57,160,255,.16));
  color: #1f2d4c;
}
.logout-form { margin: 0; }
.logout-button { border: 0; }
.admin-link { background: linear-gradient(135deg, rgba(107,99,255,.14), rgba(255,98,175,.12)); }

.header-status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,.75);
  border: 1px solid rgba(125,102,255,.10);
  font-weight: 700;
}
.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 5px rgba(31,184,110,.12);
}

.site-main { padding-bottom: 28px; }

.hero-section,
.tool-hero,
.app-card,
.promo-panel,
.showcase-tile {
  border: 1px solid rgba(255,255,255,.62);
  background: var(--panel-strong);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.hero-section {
  display: grid;
  grid-template-columns: 1.2fr .95fr;
  gap: 24px;
  border-radius: 34px;
  padding: 34px;
  margin-bottom: 28px;
}
.hero-copy h1,
.tool-hero h1,
.admin-login-card h1 { font-size: clamp(2rem, 3.7vw, 3.15rem); font-weight: 800; margin-bottom: 12px; color: #1f2d4c; line-height: 1.28; letter-spacing: -0.015em; }
.eyebrow { color: var(--primary); font-size: .84rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; margin-bottom: 10px; }
.page-lead { color: var(--muted); line-height: 1.95; font-size: 1rem; }
.page-lead.large { font-size: 1.08rem; max-width: 720px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.compact-actions { margin-top: 0; }

.hero-showcase { display: grid; gap: 16px; }
.showcase-tile {
  border-radius: 24px;
  padding: 22px;
}
.showcase-tile strong { display: block; font-size: 1.1rem; margin-bottom: 8px; }
.showcase-tile span { color: var(--muted); line-height: 1.8; }
.tile-purple { background: linear-gradient(135deg, rgba(107,99,255,.14), rgba(255,255,255,.96)); }
.tile-cyan { background: linear-gradient(135deg, rgba(57,160,255,.14), rgba(255,255,255,.96)); }
.tile-peach { background: linear-gradient(135deg, rgba(255,155,106,.16), rgba(255,255,255,.96)); }

.section-block { margin-bottom: 28px; }
.centered-heading { justify-content: center; text-align: center; }
.section-heading { margin-bottom: 16px; }
.section-heading h2 { font-size: 2rem; font-weight: 900; margin: 0; color: #28385c; }

.tool-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.clean-card,
.step-card {
  border-radius: 28px;
  padding: 24px;
}
.clean-card h3 { font-size: 1.2rem; font-weight: 900; margin-bottom: 10px; }
.clean-card p { color: var(--muted); line-height: 1.9; }
.tool-icon {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  background: rgba(255,255,255,.86);
  box-shadow: var(--shadow-soft);
  font-size: 1.45rem;
}
.soft-purple { color: #5d52eb; }
.soft-cyan { color: #148fd8; }
.soft-peach { color: #da6a29; }
.text-link { font-weight: 900; }

.promo-panel {
  border-radius: 30px;
  padding: 28px 30px;
}
.simple-promo { text-align: center; }
.simple-promo p { color: var(--muted); max-width: 720px; margin: 0 auto; line-height: 1.9; }

.refined-hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  border-radius: 32px;
  padding: 30px 32px;
  margin-bottom: 24px;
}

.app-card { border-radius: 30px; overflow: hidden; }
.elegant-card { background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(248,251,255,.95)); }
.side-note-card { background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(255,246,240,.94)); }
.card-header {
  background: rgba(107,99,255,.05);
  border-bottom: 1px solid rgba(125,102,255,.10);
  padding: 16px 22px;
  font-weight: 900;
  color: #33456f;
}

.form-control,
.form-select {
  min-height: 54px;
  background: rgba(255,255,255,.92);
  border-color: rgba(125,102,255,.12);
  color: var(--text);
  border-radius: 18px;
}
.form-control:focus,
.form-select:focus {
  background: #fff;
  border-color: rgba(107,99,255,.32);
  box-shadow: 0 0 0 .22rem rgba(107,99,255,.10);
}
.form-label { color: #31446d; margin-bottom: 10px; font-weight: 800; }
.form-check-input { width: 1.2rem; height: 1.2rem; }

.btn { border-radius: 18px; font-weight: 900; padding: 12px 18px; }
.btn-primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 12px 24px rgba(107,99,255,.22);
}
.btn-outline-light { border-color: rgba(125,102,255,.14); color: #32466f; background: rgba(255,255,255,.86); }
.btn-soft { background: linear-gradient(135deg, rgba(255,155,106,.18), rgba(255,210,158,.2)); color: #80461d; border: 1px solid rgba(255,155,106,.18); }
.btn-success { background: linear-gradient(135deg, #12b76a, #39d98a); border-color: transparent; }

.btn-hero-primary {
  border-color: transparent;
  background: linear-gradient(135deg, #6f74ff, #8aa8ff);
  color: #fff;
  box-shadow: 0 12px 24px rgba(111,116,255,.18);
}
.btn-hero-primary:hover { color: #fff; }


.result-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  padding: 18px 20px;
  border: 1px solid rgba(31,184,110,.18);
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(31,184,110,.10), rgba(255,255,255,.96));
}
.result-title { font-weight: 900; color: #1f5d41; }
.result-subtitle { color: var(--muted); margin-top: 4px; }

.preview-pane {
  min-height: 540px;
  overflow: auto;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,.86), rgba(248,250,255,.96));
  border: 1px solid rgba(125,102,255,.08);
  padding: 24px 28px;
}
.markdown-body { line-height: 1.95; color: #33476d; }
.markdown-body h1,
.markdown-body h2,
.markdown-body h3 { margin-top: 1.2rem; margin-bottom: .8rem; color: #233155; }
.markdown-body pre,
.markdown-preview-cell {
  background: linear-gradient(180deg, #f7f9ff, #eef3ff);
  color: #20345a;
  border: 1px solid rgba(125,102,255,.1);
  border-radius: 18px;
  padding: 14px;
  overflow: auto;
}

.live-two-pane,
.live-equal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  align-items: stretch;
}

.split-editor {
  width: 100%;
  min-height: 620px;
  padding: 22px 24px;
  border: 0;
  outline: 0;
  resize: vertical;
  overflow: auto;
  background: linear-gradient(180deg, #fcfdff, #f4f7ff);
  color: #21365c;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: .96rem;
  line-height: 1.9;
  direction: ltr;
  text-align: left;
  unicode-bidi: plaintext;
  box-sizing: border-box;
}
.live-preview-pane { min-height: 620px; }
.file-preview-box {
  max-height: 420px;
  min-height: 320px;
  overflow: auto;
  padding: 22px 24px;
}

.upload-dropzone {
  position: relative;
  border: 2px dashed rgba(107,99,255,.18);
  border-radius: 28px;
  min-height: 250px;
  background: linear-gradient(180deg, rgba(251,252,255,.98), rgba(244,248,255,.95));
  overflow: hidden;
}
.upload-dropzone.dragging {
  border-color: rgba(107,99,255,.42);
  background: linear-gradient(180deg, rgba(241,245,255,.98), rgba(236,244,255,.98));
}
.file-input-overlay {
  position: absolute;
  inset: 0;
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}
.dropzone-body {
  min-height: 246px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 28px;
  text-align: center;
}
.dropzone-icon { font-size: 2rem; }
.dropzone-title { font-size: 1.35rem; font-weight: 900; color: #24335a; }
.dropzone-subtitle, .selected-file-name, .image-meta-note { color: var(--muted); }
.upload-trigger { pointer-events: none; }

.image-preview.large-preview {
  max-width: min(100%, 420px);
  max-height: 240px;
  border-radius: 20px;
  border: 1px solid rgba(125,102,255,.10);
  box-shadow: var(--shadow-soft);
  object-fit: contain;
  background: #fff;
}

.format-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.compact-format-selector {
  gap: 12px;
}
.format-pill {
  min-width: 118px;
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(125,102,255,.14);
  background: rgba(255,255,255,.88);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  box-shadow: var(--shadow-soft);
}
.format-pill.active {
  border-color: rgba(107,99,255,.34);
  background: linear-gradient(135deg, rgba(107,99,255,.12), rgba(57,160,255,.10));
}
.format-pill-title { font-weight: 900; font-size: 1rem; }
.format-pill-subtitle { color: var(--muted); font-size: .78rem; }

.size-mode-group {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.compact-size-mode-group { gap: 12px; }
.size-mode-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 20px;
  border: 1px solid rgba(125,102,255,.12);
  background: rgba(255,255,255,.88);
}
.compact-size-mode-card { padding: 12px 14px; }
.size-mode-card.active {
  border-color: rgba(107,99,255,.3);
  background: linear-gradient(135deg, rgba(107,99,255,.10), rgba(57,160,255,.08));
}
.size-mode-card input { margin-top: 3px; }
.size-mode-card span { display: grid; gap: 4px; }
.size-mode-card small { color: var(--muted); }
.custom-size-disabled { opacity: .56; }

.quality-slider-wrap {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 10px 16px;
  border-radius: 18px;
  background: rgba(255,255,255,.9);
  border: 1px solid rgba(125,102,255,.12);
}
.compact-quality-slider-wrap { padding: 12px 18px; }
.quality-slider {
  width: 100%;
  accent-color: var(--primary);
}
.quality-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 64px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(107,99,255,.12);
  color: #31446d;
  font-weight: 900;
}
.quality-ticks {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: .82rem;
  margin-top: 8px;
  padding: 0 18px;
}

.result-image-frame {
  width: 100%;
  padding: 14px;
  border-radius: 22px;
  background: rgba(255,255,255,.76);
  border: 1px solid rgba(125,102,255,.12);
}
.result-image-preview {
  display: block;
  max-width: 100%;
  max-height: 420px;
  margin: 0 auto;
  object-fit: contain;
  border-radius: 16px;
}

.feature-list {
  margin: 0;
  padding-right: 1rem;
  color: #42557e;
  line-height: 2;
}

@media (max-width: 1100px) {
  .hero-section,
  .live-two-pane,
  .live-equal-grid,
  .size-mode-group,
  .tool-grid {
    grid-template-columns: 1fr;
  }

  .refined-hero,
  .site-header {
    flex-direction: column;
    align-items: stretch;
  }
}

.result-download-btn { white-space: nowrap; min-width: 132px; text-align: center; }

.markdown-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0 1.4rem;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid rgba(125,102,255,.14);
  background: rgba(255,255,255,.92);
}
.markdown-body thead {
  background: linear-gradient(135deg, rgba(107,99,255,.12), rgba(57,160,255,.08));
}
.markdown-body th,
.markdown-body td {
  padding: .82rem 1rem;
  border: 1px solid rgba(125,102,255,.10);
  text-align: right;
  vertical-align: top;
}
.markdown-body tbody tr:nth-child(even) {
  background: rgba(248,250,255,.82);
}
.markdown-body ul, .markdown-body ol { padding-right: 1.4rem; }
.contained-preview-box {
  border: 1px solid rgba(125,102,255,.10);
  border-radius: 22px;
  max-height: 430px;
  min-height: 330px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.48);
}
.image-format-selector {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  gap: 10px;
}
.image-format-selector .format-pill {
  min-width: 0;
  padding: 10px 12px;
  border-radius: 16px;
}
.image-format-selector .format-pill-title { font-size: .96rem; }
.image-format-selector .format-pill-subtitle { font-size: .72rem; line-height: 1.55; }
.dimension-inline-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.dimension-inline-item {
  min-width: 0;
}
.image-quality-bar {
  direction: ltr;
}
.image-quality-bar .quality-edge {
  font-weight: 700;
  color: var(--muted);
}
.image-quality-ticks {
  direction: ltr;
}
.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 18px 8px 8px;
  color: var(--muted);
  font-size: .92rem;
}
@media (max-width: 1100px) {
  .dimension-inline-row { grid-template-columns: 1fr; }
  .site-footer { justify-content: center; text-align: center; }
}

.btn-home-primary {
  border-color: transparent;
  background: linear-gradient(135deg, #7e76ff, #8e92ff);
  color: #fff;
  box-shadow: 0 12px 24px rgba(111,116,255,.16);
}
.btn-home-primary:hover { color: #fff; }

.accent-card {
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(252,252,255,.96));
}
.accent-card-purple { background: linear-gradient(180deg, rgba(245,243,255,.95), rgba(255,255,255,.98)); }
.accent-card-cyan { background: linear-gradient(180deg, rgba(240,248,255,.95), rgba(255,255,255,.98)); }
.accent-card-peach { background: linear-gradient(180deg, rgba(255,246,239,.95), rgba(255,255,255,.98)); }

.soft-header {
  background: linear-gradient(135deg, rgba(107,99,255,.06), rgba(57,160,255,.04));
}

.markdown-compact-dropzone {
  min-height: 170px;
}
.markdown-compact-dropzone .dropzone-body,
.image-compact-dropzone .dropzone-body {
  min-height: 166px;
}
.compact-dropzone-body { padding: 22px 20px; }
.small-title { font-size: 1.18rem; }
.compact-upload-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, .75fr);
  gap: 18px;
  align-items: start;
}
.compact-drop-card,
.compact-side-card {
  min-width: 0;
}
.compact-side-card {
  border: 1px solid rgba(125,102,255,.12);
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(255,248,242,.94));
}
.compact-action-row {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 12px;
}
.markdown-file-preview-box {
  max-height: 420px;
  min-height: 260px;
}
.empty-note {
  color: var(--muted);
  display: grid;
  place-items: center;
  min-height: 180px;
  text-align: center;
}

.image-settings-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: start;
}
.inset-selector {
  padding: 2px 4px;
}
.compact-pill {
  min-width: 0;
  padding: 10px 12px;
}
.image-format-selector {
  grid-template-columns: repeat(auto-fit, minmax(84px, 1fr));
  gap: 10px;
}
.image-format-selector .format-pill {
  align-items: center;
  text-align: center;
  padding: 10px 8px;
}
.image-format-selector .format-pill-title {
  font-size: .92rem;
}
.image-format-selector .format-pill-subtitle {
  font-size: .69rem;
  line-height: 1.45;
}
.dimension-inline-row {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.quality-shell {
  margin-top: 2px;
}
.supported-format-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.supported-format-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(107,99,255,.08);
  border: 1px solid rgba(125,102,255,.12);
  color: #32466f;
  font-weight: 800;
}
.side-note-text {
  color: var(--muted);
  line-height: 1.85;
}
.mini-side-card {
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(246,250,255,.95));
}
.image-result-card {
  width: 100%;
}
.image-result-card .result-image-frame {
  width: 100%;
}
.image-note-card { position: sticky; top: 110px; }

.markdown-body .mermaid {
  direction: ltr;
  text-align: center;
  background: linear-gradient(180deg, #f8faff, #eef3ff);
  border: 1px solid rgba(125,102,255,.12);
  border-radius: 18px;
  padding: 16px;
  overflow: auto;
  margin: 1rem 0 1.4rem;
}
.markdown-body img {
  max-width: 100%;
  height: auto;
  border-radius: 16px;
}

@media (max-width: 1100px) {
  .compact-upload-grid,
  .image-settings-grid {
    grid-template-columns: 1fr;
  }
  .image-note-card {
    position: static;
  }
}


/* v14.1 refinements */
.accent-grid .accent-card-purple {
  background: linear-gradient(135deg, rgba(245,242,255,.98), rgba(255,255,255,.98));
  border-color: rgba(137,116,255,.14);
}
.accent-grid .accent-card-cyan {
  background: linear-gradient(135deg, rgba(239,248,255,.98), rgba(255,255,255,.98));
  border-color: rgba(81,163,226,.16);
}
.accent-grid .accent-card-peach {
  background: linear-gradient(135deg, rgba(255,247,240,.98), rgba(255,255,255,.98));
  border-color: rgba(234,158,110,.16);
}
.business-promo {
  background: linear-gradient(135deg, rgba(248,246,255,.98), rgba(255,252,248,.98));
  border-color: rgba(125,102,255,.10);
}
.markdown-body pre,
.markdown-body code,
.markdown-body pre code,
.code-editor {
  direction: ltr;
  text-align: left;
  unicode-bidi: plaintext;
}
.markdown-body pre code {
  display: block;
  white-space: pre;
}
.markdown-body :not(pre) > code {
  display: inline-block;
  padding: .15rem .45rem;
  border-radius: 10px;
  background: rgba(107,99,255,.08);
  border: 1px solid rgba(125,102,255,.10);
}
.markdown-body img {
  display: block;
  max-width: min(100%, 720px);
  margin: 1rem auto 1.25rem;
}
.live-preview-pane .markdown-body,
.file-preview-box .markdown-body {
  overflow-wrap: anywhere;
}
.image-settings-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr);
  gap: 20px;
  margin-top: 18px;
}
.image-settings-main,
.image-settings-side {
  min-width: 0;
}
.image-format-selector {
  grid-template-columns: repeat(auto-fit, minmax(88px, 1fr));
  gap: 8px;
}
.image-format-selector .format-pill {
  padding: 9px 10px;
  min-height: 74px;
}
.size-mode-group {
  gap: 12px;
}
.size-mode-card {
  min-height: 84px;
}
.dimension-inline-row {
  align-items: end;
}
.dimension-inline-item .form-control {
  min-height: 48px;
}
.quality-shell {
  margin-top: 8px;
}
.image-result-card {
  position: sticky;
  top: 98px;
}
.result-image-frame {
  max-height: 460px;
  overflow: auto;
}
.result-image-preview {
  width: auto;
}
.compact-markdown-card .upload-dropzone {
  min-height: 150px;
}
.compact-markdown-card .dropzone-body {
  min-height: 146px;
  padding: 18px 20px;
}
.compact-markdown-action-row {
  justify-content: space-between;
  align-items: center;
}
.compact-action-side-note {
  color: var(--muted);
  font-size: .94rem;
}
.supported-format-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.supported-format-badge {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(107,99,255,.08);
  border: 1px solid rgba(125,102,255,.12);
  color: #33456f;
  font-weight: 700;
}
.side-note-text {
  color: var(--muted);
  line-height: 1.8;
}
@media (max-width: 1100px) {
  .image-settings-grid,
  .compact-upload-grid {
    grid-template-columns: 1fr;
  }
  .image-result-card {
    position: static;
  }
}


/* v14.2 polish */
.refined-hero {
  padding: 22px 28px;
  border-radius: 28px;
}
.refined-hero .page-lead {
  line-height: 1.75;
}
.hero-section {
  padding: 30px;
}
.accent-grid {
  gap: 20px;
}
.accent-grid .accent-card {
  background: linear-gradient(135deg, rgba(255,255,255,.97), rgba(249,251,255,.96));
  box-shadow: 0 14px 30px rgba(62, 84, 138, 0.08);
}
.accent-grid .accent-card-purple {
  background: linear-gradient(135deg, rgba(245, 239, 255, .98), rgba(255, 252, 248, .98));
}
.accent-grid .accent-card-cyan {
  background: linear-gradient(135deg, rgba(238, 249, 255, .98), rgba(246, 250, 255, .98));
}
.accent-grid .accent-card-peach {
  background: linear-gradient(135deg, rgba(255, 246, 238, .98), rgba(255, 251, 246, .98));
}
.markdown-body pre,
.markdown-body pre code,
.markdown-body code[class*="language-"],
.markdown-body code[class^="language-"] {
  direction: ltr !important;
  text-align: left !important;
  unicode-bidi: isolate !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace !important;
}
.markdown-body pre code {
  display: block;
  white-space: pre;
}
.markdown-body :not(pre) > code {
  direction: ltr;
  text-align: left;
  unicode-bidi: isolate;
  display: inline-block;
}
.markdown-body .mermaid,
.markdown-body .mermaid svg,
.markdown-body .mermaid foreignObject,
.markdown-body .mermaid div {
  direction: ltr !important;
  unicode-bidi: isolate !important;
}
.markdown-body .mermaid svg {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}
.markdown-body .mermaid text,
.markdown-body .mermaid tspan {
  direction: ltr !important;
  unicode-bidi: isolate !important;
}
.compact-markdown-card .compact-upload-grid {
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr);
}
.markdown-compact-dropzone {
  min-height: 132px;
}
.markdown-compact-dropzone .dropzone-body {
  min-height: 128px;
  padding: 18px 20px;
}
.markdown-compact-dropzone .dropzone-title {
  font-size: 1.15rem;
}
.compact-markdown-side-body {
  display: grid;
  gap: 16px;
}
.compact-markdown-side-body .feature-list {
  margin-bottom: 0;
}
.compact-side-actions {
  display: flex;
  justify-content: flex-end;
}
.compact-action-side-note {
  color: var(--muted);
  font-size: .93rem;
}
.image-settings-main,
.image-settings-side {
  min-width: 0;
}
.image-settings-main .image-format-selector,
.image-settings-main .size-mode-group,
.image-settings-main .dimension-inline-row,
.image-settings-main .quality-shell,
.image-settings-main .quality-ticks,
.image-settings-main .compact-action-row {
  max-width: 860px;
  margin-inline: auto;
}
.image-settings-main .image-format-selector {
  grid-template-columns: repeat(auto-fit, minmax(96px, 120px));
  justify-content: center;
  gap: 12px;
}
.image-settings-main .format-pill {
  min-height: 76px;
  padding: 8px 10px;
  border-radius: 16px;
}
.image-settings-main .format-pill-subtitle {
  font-size: .66rem;
}
.image-settings-main .size-mode-group {
  gap: 12px;
}
.image-settings-main .size-mode-card {
  min-height: 76px;
}
.image-settings-main .dimension-inline-row {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: end;
}
.image-settings-main .dimension-inline-item .form-control {
  min-height: 48px;
}
.image-settings-main .quality-shell {
  padding: 10px 14px;
}
.image-settings-main .compact-action-row {
  justify-content: flex-end;
}
.image-settings-grid {
  align-items: stretch;
}
.result-card.image-result-card {
  scroll-margin-top: 110px;
}
@media (max-width: 1100px) {
  .refined-hero,
  .hero-section {
    padding: 22px;
  }
  .compact-markdown-card .compact-upload-grid,
  .image-settings-grid,
  .image-settings-main .dimension-inline-row,
  .image-settings-main .size-mode-group {
    grid-template-columns: 1fr;
  }
}


.admin-login-wrap {
  min-height: calc(100vh - 180px);
  display: grid;
  place-items: center;
  padding: 32px 16px;
}
.admin-login-card {
  width: min(100%, 520px);
  border-radius: 32px;
  padding: 32px;
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(247,250,255,.96));
  border: 1px solid rgba(125,102,255,.14);
  box-shadow: 0 24px 60px rgba(62,84,138,.14);
}
.admin-form .form-control {
  min-height: 52px;
  border-radius: 16px;
  border: 1px solid rgba(125,102,255,.14);
  background: rgba(255,255,255,.96);
  box-shadow: none;
}
.admin-form .form-control:focus {
  border-color: rgba(107,99,255,.42);
  box-shadow: 0 0 0 4px rgba(107,99,255,.10);
}
.admin-login-alert {
  margin: 14px 0 18px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255,98,175,.08);
  color: #9b245f;
  border: 1px solid rgba(255,98,175,.18);
  font-weight: 700;
}


/* --- v31.2 landing/header refresh additions --- */
/* v31.2 landing + header refresh */
.site-header-refined {
  grid-template-columns: auto 1fr auto;
  display: grid;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  border-radius: 30px;
}

.header-center-panel {
  min-width: 0;
  padding: 8px 10px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255,255,255,.94), rgba(249,251,255,.92));
  border: 1px solid rgba(125,102,255,.10);
}

.brand-group-refined {
  justify-self: end;
}

.brand-group-refined .brand-link {
  gap: 12px;
}

.brand-copy {
  text-align: right;
}

.brand-group-refined .brand-title {
  font-size: 1.45rem;
  line-height: 1.05;
}

.brand-group-refined .brand-subtitle {
  font-size: .88rem;
  margin-top: 5px;
}

.compact-status {
  min-height: 46px;
  padding: 0 14px;
  box-shadow: none;
}

.top-nav {
  gap: 10px;
}

.top-nav-link {
  min-height: 46px;
  padding: 0 16px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(248,250,255,.94));
  box-shadow: none;
}

.hero-section-v15 {
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, .85fr);
  padding: 28px;
  gap: 22px;
  align-items: stretch;
}

.hero-copy-v15 {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-copy-v15 h1 {
  margin-bottom: 14px;
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  line-height: 1.18;
}

.hero-actions-v15 {
  margin-top: 20px;
}

.hero-benefits-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.hero-benefit-pill {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(107,99,255,.08);
  border: 1px solid rgba(125,102,255,.10);
  color: #31446d;
  font-weight: 800;
  font-size: .92rem;
}

.hero-visual-card {
  display: flex;
  align-items: stretch;
}

.hero-visual-window {
  width: 100%;
  padding: 16px;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(248,250,255,.98), rgba(255,255,255,.98));
  border: 1px solid rgba(125,102,255,.12);
  box-shadow: 0 20px 45px rgba(53, 72, 122, .08);
}

.hero-window-topbar {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.hero-window-topbar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(107,99,255,.18);
}

.hero-window-body {
  display: grid;
  gap: 14px;
}

.hero-window-label {
  color: var(--primary);
  font-weight: 900;
  font-size: .84rem;
  letter-spacing: .04em;
}

.hero-window-title {
  font-size: 1.25rem;
  font-weight: 900;
  color: #24345b;
  line-height: 1.5;
}

.hero-window-input {
  min-height: 120px;
  border-radius: 24px;
  border: 1px dashed rgba(125,102,255,.18);
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(247,250,255,.96));
  display: grid;
  place-items: center;
  text-align: center;
  padding: 18px;
}

.hero-window-input-title {
  font-weight: 900;
  color: #24345b;
  margin-bottom: 6px;
}

.hero-window-input-subtitle,
.hero-window-note,
.section-muted {
  color: var(--muted);
  line-height: 1.8;
}

.hero-window-formats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-window-formats span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 16px;
  background: rgba(255,255,255,.94);
  border: 1px solid rgba(125,102,255,.10);
  color: #33456f;
  font-weight: 800;
}

.section-block-tight {
  margin-top: 22px;
  margin-bottom: 24px;
}

.landing-heading-v15 {
  margin-bottom: 18px;
}

.section-muted {
  max-width: 620px;
  margin: 10px auto 0;
}

.landing-tools-grid-v15 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.landing-tool-card-v15 {
  min-height: 240px;
}

.landing-tool-card-v15 h3 {
  margin-bottom: 12px;
}

.landing-promo-v15 {
  padding: 26px 30px;
}

.form-control,
.form-select,
.ac-input {
  min-height: 50px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(250,251,255,.96));
  border: 1px solid rgba(125,102,255,.14);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.88);
}

.form-control:focus,
.form-select:focus,
.ac-input:focus {
  border-color: rgba(107,99,255,.30);
  box-shadow: 0 0 0 .22rem rgba(107,99,255,.08);
}

.upload-dropzone {
  border-radius: 24px;
}

.card-header {
  padding: 14px 20px;
}

@media (max-width: 1100px) {
  .site-header-refined,
  .hero-section-v15,
  .landing-tools-grid-v15 {
    grid-template-columns: 1fr;
  }

  .site-header-refined {
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }

  .brand-group-refined,
  .compact-status {
    justify-self: stretch;
  }

  .hero-visual-card {
    order: -1;
  }
}



/* v32 landing */
.section-muted{ color: var(--muted); line-height: 1.9; max-width: 760px; margin: .5rem auto 0; }
.ltr-fragment{ direction:ltr; unicode-bidi:embed; display:inline-block; }
.landing-hero-v32{
  grid-template-columns: minmax(0,1.08fr) minmax(360px,.92fr);
  align-items:center;
}
.hero-copy-v32 .page-lead{ max-width: 780px; }
.hero-stat-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: .9rem;
  margin-top: 1.1rem;
}
.hero-stat-card{
  border-radius: 24px;
  padding: 1rem 1.1rem;
  background: rgba(255,255,255,.78);
  border: 1px solid rgba(107,99,255,.10);
  box-shadow: var(--shadow-soft);
}
.hero-stat-card strong{
  display:block;
  font-size:1.35rem;
  color:#24365d;
  margin-bottom:.25rem;
}
.hero-stat-card span{ color:var(--muted); line-height:1.8; font-size:.95rem; }
.hero-illustration-shell{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height: 100%;
}
.landing-hero-illustration,
.landing-full-illustration{
  width:100%;
  display:block;
  border-radius:28px;
}
.landing-link-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
  gap:1rem;
}
.landing-link-card{
  display:block;
  border-radius:24px;
  padding:1.15rem 1.15rem;
  background: rgba(255,255,255,.84);
  border:1px solid rgba(107,99,255,.10);
  box-shadow: var(--shadow-soft);
  color: inherit;
  transition: transform .16s ease, box-shadow .16s ease;
}
.landing-link-card:hover{
  transform: translateY(-3px);
  box-shadow: 0 20px 36px rgba(30,41,59,.09);
  color: inherit;
}
.landing-link-title{ font-weight:900; font-size:1.03rem; margin-bottom:.4rem; color:#24365d; }
.landing-link-subtitle{ color:var(--muted); line-height:1.8; font-size:.93rem; }
.landing-illustration-panel{
  border-radius:30px;
  overflow:hidden;
  background: rgba(255,255,255,.84);
  border:1px solid rgba(107,99,255,.10);
  box-shadow: var(--shadow);
  padding: .75rem;
}
.landing-capability-grid{ grid-template-columns: repeat(3, minmax(0,1fr)); }
.landing-two-col{
  display:grid;
  grid-template-columns: minmax(0,1fr) minmax(0,1fr);
  gap:1.2rem;
  align-items:stretch;
}
.format-badge-cloud{
  display:flex; flex-wrap:wrap; gap:.6rem;
}
.mini-check-list{
  display:grid; gap:.55rem; color:#33476d;
}
.faq-mini-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: .8rem;
  margin-top: 1rem;
}
.faq-mini-item{
  background: rgba(255,255,255,.78);
  border: 1px solid rgba(107,99,255,.10);
  border-radius: 20px;
  padding: .95rem 1rem;
}
.faq-mini-item strong{ display:block; margin-bottom:.35rem; color:#24365d; }
.faq-mini-item span{ color:var(--muted); line-height:1.8; font-size:.92rem; }
.faq-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0,1fr));
  gap:1rem;
}
.faq-card{
  border-radius:24px;
  padding:1.15rem 1.2rem;
  background: rgba(255,255,255,.86);
  border:1px solid rgba(107,99,255,.10);
  box-shadow: var(--shadow-soft);
}
.faq-card h3{
  font-size:1.02rem;
  line-height:1.8;
  margin-bottom:.5rem;
  color:#24365d;
}
.faq-card p{ color:var(--muted); line-height:1.9; margin-bottom:0; }

@media (max-width: 1100px){
  .landing-hero-v32,
  .landing-two-col{ grid-template-columns: 1fr; }
}
@media (max-width: 900px){
  .hero-stat-grid,
  .faq-mini-grid,
  .faq-grid,
  .landing-capability-grid{ grid-template-columns: 1fr; }
}


/* v34 landing and SEO polish */
.landing-hero-v34 {
  grid-template-columns: 1.05fr .95fr;
  align-items: stretch;
}
.hero-copy-v34 {
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.hero-side-stack {
  display: grid;
  gap: 18px;
  align-content: start;
}
.hero-upload-card {
  border-radius: 30px;
  padding: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(244,248,255,.95));
  border: 1px solid rgba(125,102,255,.10);
  box-shadow: var(--shadow);
}
.hero-upload-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
  margin-bottom: 16px;
}
.hero-upload-title { font-size: 1.12rem; font-weight: 900; color: #243457; }
.hero-upload-subtitle { color: var(--muted); line-height: 1.9; font-size: .95rem; }
.hero-upload-badge {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(107,99,255,.10);
  color: var(--primary);
  font-size: .82rem;
  font-weight: 900;
  white-space: nowrap;
}
.hero-route-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.hero-quick-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
.hero-quick-link {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  text-align: center;
  border-radius: 18px;
  padding: 0 14px;
  background: rgba(255,255,255,.88);
  border: 1px solid rgba(125,102,255,.10);
  color: #29406b;
  font-weight: 800;
  box-shadow: var(--shadow-soft);
}
.hero-quick-link:hover { transform: translateY(-1px); }
.hero-upload-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}
.hero-illustration-shell-v34 {
  padding: 18px;
  border-radius: 30px;
  background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(250,244,255,.92));
}
.hero-stat-grid-v34 { margin-top: 22px; }
.hero-benefits-row-v34 { margin-top: 16px; }
.landing-link-grid-v34 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.landing-link-card-v34 {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 176px;
}
.landing-link-cta {
  margin-top: auto;
  color: var(--primary);
  font-weight: 900;
}
.landing-two-col-balanced { align-items: stretch; }
.mini-feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.v34-capability-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.site-footer-v34 {
  margin-top: 30px;
  border: 1px solid rgba(255,255,255,.65);
  background: var(--panel);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
  border-radius: 28px;
  padding: 22px 24px;
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 18px;
}
.footer-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--muted);
}
.footer-col strong {
  color: #22314f;
  font-size: 1rem;
}
.footer-col a { color: #3658dd; }
.footer-meta { justify-content: end; }
@media (max-width: 1200px) {
  .landing-link-grid-v34 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .site-footer-v34 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 992px) {
  .landing-hero-v34,
  .landing-two-col,
  .reverse-mobile {
    grid-template-columns: 1fr;
  }
  .hero-route-grid,
  .hero-quick-grid,
  .mini-feature-grid,
  .v34-capability-grid,
  .landing-link-grid-v34,
  .site-footer-v34 {
    grid-template-columns: 1fr;
  }
  .hero-upload-head {
    flex-direction: column;
  }
}


/* v35 production landing */
.brand-logo-image{
  width:52px;
  height:52px;
  border-radius:18px;
  box-shadow: 0 12px 28px rgba(107,99,255,.18);
  background:#fff;
  padding:4px;
}

.landing-hero-production{
  align-items:center;
}

.hero-benefits-row-v35{
  margin-top: 18px;
}

.format-chip-grid{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
}
.format-chip{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:92px;
  min-height:48px;
  padding:0 18px;
  border-radius:999px;
  background:linear-gradient(135deg, rgba(107,99,255,.12), rgba(57,160,255,.10));
  border:1px solid rgba(107,99,255,.18);
  color:var(--text);
  font-weight:800;
}

.knowledge-grid,
.blog-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap:18px;
}

.knowledge-card,
.blog-card,
.article-shell{
  overflow:hidden;
  border-radius:28px;
}

.knowledge-card h3,
.blog-card-title{
  font-size:1.2rem;
  font-weight:800;
  color:#22314f;
  margin-bottom:10px;
  line-height:1.7;
}

.blog-card-image,
.article-hero-image{
  width:100%;
  display:block;
  object-fit:cover;
  background:#f8fbff;
}

.blog-card-image{ height:220px; }
.article-hero-image{ max-height:420px; }

.blog-hero,
.format-hero{
  margin-bottom: 24px;
}

.article-shell .card-body{
  max-width:980px;
  margin:0 auto;
}

.article-paragraph{
  color: var(--text);
  line-height: 2.1;
  font-size: 1.03rem;
  margin-bottom: 1rem;
}

.article-subtitle{
  font-size:1.35rem;
  font-weight:800;
  color:#22314f;
  margin: 1.8rem 0 1rem;
}

.article-list{
  margin:0;
  padding-right:1.2rem;
}
.article-list li{
  margin-bottom:.7rem;
  line-height:1.95;
  color:var(--text);
}

.format-guide-grid{
  grid-template-columns: repeat(2, minmax(0,1fr));
}

.site-footer-v35{
  display:grid;
  grid-template-columns:repeat(4, minmax(0,1fr));
  gap:20px;
  margin-top: 28px;
  padding: 28px;
  border-radius: 28px;
  border: 1px solid rgba(255,255,255,.62);
  background: var(--panel);
  box-shadow: var(--shadow);
}
.site-footer-v35 .footer-col{
  display:flex;
  flex-direction:column;
  gap:8px;
}
.site-footer-v35 strong{
  font-size:1.02rem;
  color:#22314f;
}
.site-footer-v35 span,
.site-footer-v35 a{
  color: var(--muted);
  line-height: 1.9;
}

@media (max-width: 1100px){
  .knowledge-grid,
  .blog-grid,
  .site-footer-v35{
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 820px){
  .knowledge-grid,
  .blog-grid,
  .site-footer-v35,
  .format-guide-grid{
    grid-template-columns: 1fr;
  }

  .brand-logo-image{
    width:44px;
    height:44px;
    border-radius:14px;
  }
}


/* v36.1 navigation + UX polish */
.grouped-nav{
  gap:12px;
  flex-wrap:nowrap;
}
.nav-dropdown{
  position:relative;
}
.nav-toggle{
  min-width:128px;
}
.nav-dropdown-menu{
  position:absolute;
  top:calc(100% + 10px);
  right:0;
  min-width:240px;
  padding:10px;
  border-radius:22px;
  background:rgba(255,255,255,.98);
  border:1px solid rgba(125,102,255,.14);
  box-shadow:0 18px 40px rgba(62,84,138,.12);
  display:none;
  z-index:40;
}
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu{
  display:grid;
  gap:8px;
}
.nav-dropdown-item{
  display:block;
  padding:10px 12px;
  border-radius:14px;
  color:var(--text);
  font-weight:700;
  line-height:1.8;
}
.nav-dropdown-item:hover{
  background:linear-gradient(135deg, rgba(107,99,255,.10), rgba(57,160,255,.08));
  color:#1f2d4c;
}
.nav-auth{
  display:flex;
  align-items:center;
  gap:10px;
  margin-inline-start:auto;
}
.login-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:42px;
  padding:0 14px;
  border-radius:999px;
  background:rgba(31,184,110,.10);
  color:#117a49;
  border:1px solid rgba(31,184,110,.16);
  font-weight:800;
}
.auth-logout-button{
  background:linear-gradient(135deg, rgba(255,98,175,.12), rgba(255,155,106,.10));
}
.related-links{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  align-items:center;
}
.related-link{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:8px 16px;
  border-radius:999px;
  background:#f2f5ff;
  border:1px solid #dbe2ff;
  color:#2d3f67;
  font-weight:800;
  line-height:1.4;
}
.related-link:hover{
  background:linear-gradient(135deg, rgba(107,99,255,.14), rgba(57,160,255,.10));
  color:#1d2c49;
}
.related-format-chips{
  margin-top:10px;
}
.related-format-chip{
  min-width:82px;
}
@media (max-width: 1280px){
  .grouped-nav{
    flex-wrap:wrap;
  }
  .nav-auth{
    margin-inline-start:0;
  }
}
@media (max-width: 920px){
  .grouped-nav{
    display:grid;
    grid-template-columns:1fr 1fr;
    width:100%;
  }
  .nav-dropdown-menu{
    position:static;
    display:grid;
    margin-top:8px;
    min-width:unset;
  }
  .nav-auth{
    grid-column:1 / -1;
  }
}


/* v36.2 nav bridge + admin auth fix */
.nav-dropdown-menu{
  top: calc(100% + 2px) !important;
}
.nav-dropdown::before{
  content:"";
  position:absolute;
  top:100%;
  right:0;
  width:100%;
  height:16px;
}
.nav-dropdown-menu:hover,
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu{
  display:grid;
}
@media (max-width: 920px){
  .nav-dropdown::before{
    display:none;
  }
}


/* v37 details-based nav and secure links */
.top-nav-details{
  gap:12px;
  flex-wrap:wrap;
}
.nav-details{
  position:relative;
}
.nav-details > summary{
  list-style:none;
  cursor:pointer;
}
.nav-details > summary::-webkit-details-marker{
  display:none;
}
.nav-details[open] > summary{
  background: linear-gradient(135deg, rgba(107,99,255,.18), rgba(57,160,255,.16));
  color:#1f2d4c;
}
.nav-details-menu{
  position:absolute;
  top:calc(100% + 8px);
  right:0;
  min-width:250px;
  display:grid;
  gap:8px;
  padding:10px;
  border-radius:22px;
  background:rgba(255,255,255,.98);
  border:1px solid rgba(125,102,255,.14);
  box-shadow:0 18px 40px rgba(62,84,138,.12);
  z-index:45;
}
.nav-details-item{
  display:block;
  padding:10px 12px;
  border-radius:14px;
  color:var(--text);
  font-weight:700;
  line-height:1.8;
}
.nav-details-item:hover{
  background:linear-gradient(135deg, rgba(107,99,255,.10), rgba(57,160,255,.08));
  color:#1f2d4c;
}
@media (max-width: 920px){
  .nav-details{
    width:100%;
  }
  .nav-details-menu{
    position:static;
    min-width:unset;
    margin-top:8px;
  }
}


/* v41 production hardening */
.result-card .result-subtitle{
  color: var(--muted);
  line-height: 1.9;
  font-weight: 700;
}


/* v42 tool layout v2 */
.tool-v2-grid{
  display:grid;
  grid-template-columns:minmax(240px,.58fr) minmax(0,1.42fr);
  gap:1rem;
  align-items:start;
}
.tool-v2-side .mini-side-card{
  position:sticky;
  top:1rem;
}
.tool-v2-main{
  display:flex;
  flex-direction:column;
  gap:1rem;
}
.tool-v2-upload-block,
.tool-v2-settings-wrap,
.tool-v2-result-card,
.tool-v2-progress-panel{
  background:#fbfcff;
  border:1px solid rgba(60,90,140,.08);
  border-radius:20px;
  padding:1rem;
}
.tool-v2-section-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:1rem;
  margin-bottom:.9rem;
}
.tool-v2-title{
  font-size:1.1rem;
  font-weight:800;
  color:#243b63;
}
.tool-v2-subtitle{
  color:#6b7a92;
  font-size:.95rem;
}
.tool-v2-tip{
  font-size:.92rem;
  line-height:1.9;
  color:#607089;
  background:#f7f9ff;
  border:1px dashed rgba(79,109,245,.18);
  border-radius:14px;
  padding:.8rem .9rem;
}
.tool-v2-dropzone{
  min-height:260px;
  border:2px dashed #d7dff5;
  border-radius:22px;
  background:linear-gradient(180deg,#fbfdff,#f5f8ff);
  position:relative;
  overflow:hidden;
}
.tool-v2-dropzone.dragover,
.tool-v2-dropzone.dragging{
  border-color:#5b72ff;
  background:linear-gradient(180deg,#f4f7ff,#edf3ff);
  box-shadow:0 0 0 6px rgba(91,114,255,.08);
}
.tool-v2-dropzone-inner{
  min-height:260px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  gap:.6rem;
  padding:1.5rem;
}
.tool-v2-dropzone-icon{
  width:72px;
  height:72px;
  border-radius:20px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#eef2ff;
  font-size:2rem;
}
.tool-v2-dropzone-title{
  font-size:1.25rem;
  font-weight:900;
  color:#233760;
}
.tool-v2-dropzone-subtitle{
  color:#687891;
}
.tool-v2-upload-btn{
  padding:.8rem 1.2rem;
  border-radius:14px;
  font-weight:800;
}
.tool-v2-accept-note{
  direction:ltr;
  color:#7a879d;
  font-weight:700;
  font-size:.92rem;
}
.tool-v2-preview-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:1rem;
}
.tool-v2-preview-card{
  background:#fff;
  border:1px solid rgba(60,90,140,.09);
  border-radius:20px;
  padding:1rem;
  display:flex;
  flex-direction:column;
  gap:.85rem;
}
.tool-v2-preview-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:.75rem;
}
.tool-v2-meta-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:34px;
  padding:0 .85rem;
  border-radius:999px;
  background:#eff3ff;
  color:#3857a1;
  font-weight:800;
}
.tool-v2-preview-body{
  min-height:280px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(180deg,#fbfcff,#f7f9fe);
  border:1px dashed #d7dff5;
  border-radius:18px;
  overflow:hidden;
  padding:1rem;
}
.tool-v2-preview-image{
  display:block;
  max-width:100%;
  max-height:248px;
  object-fit:contain;
  border-radius:16px;
  box-shadow:0 12px 34px rgba(36,59,99,.10);
}
.tool-v2-preview-placeholder{
  color:#7a879d;
  text-align:center;
  line-height:1.9;
  font-weight:700;
}
.tool-v2-preview-meta{
  display:flex;
  flex-direction:column;
  gap:.35rem;
}
.tool-v2-file-name{
  font-weight:800;
  color:#233760;
  word-break:break-word;
}
.tool-v2-file-stats{
  display:flex;
  flex-wrap:wrap;
  gap:.75rem;
  color:#677892;
  font-size:.93rem;
}
.tool-v2-settings-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:1rem;
}
.tool-v2-setting-card{
  background:#fff;
  border:1px solid rgba(60,90,140,.09);
  border-radius:18px;
  padding:1rem;
}
.tool-v2-wide-card{
  grid-column:1 / -1;
}
.tool-v2-setting-title{
  font-weight:800;
  color:#22385d;
  margin-bottom:.75rem;
}
.tool-v2-progress-panel{
  padding:1rem 1.1rem;
}
.tool-v2-progress-label{
  font-weight:800;
  color:#2f4675;
  margin-bottom:.65rem;
}
.tool-v2-progress-bar{
  height:10px;
  border-radius:999px;
  overflow:hidden;
  background:#e6ebf7;
}
.tool-v2-progress-value{
  width:62%;
  height:100%;
  border-radius:999px;
  background:linear-gradient(90deg,#5b72ff,#74a9ff);
  animation:toolv2pulse 1.2s ease-in-out infinite alternate;
}
@keyframes toolv2pulse{
  from{ width:38%; }
  to{ width:82%; }
}
.tool-v2-action-row{
  display:flex;
  justify-content:flex-end;
}
.tool-v2-primary-btn{
  min-width:240px;
  border-radius:16px;
  font-weight:900;
}
.tool-v2-result-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  flex-wrap:wrap;
  margin-bottom:1rem;
}
.tool-v2-download-btn{
  min-height:54px;
  min-width:220px;
  border-radius:16px;
  font-weight:900;
}
.tool-v2-result-stats{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:.9rem;
}
.tool-v2-result-stat{
  background:#fff;
  border:1px solid rgba(60,90,140,.09);
  border-radius:16px;
  padding:.9rem 1rem;
  display:flex;
  flex-direction:column;
  gap:.35rem;
}
.tool-v2-result-stat span{
  color:#687892;
  font-size:.92rem;
}
.tool-v2-result-stat strong{
  color:#233760;
  font-size:1rem;
}
@media (max-width: 980px){
  .tool-v2-grid{
    grid-template-columns:1fr;
  }
  .tool-v2-side .mini-side-card{
    position:static;
  }
  .tool-v2-preview-grid,
  .tool-v2-settings-grid,
  .tool-v2-result-stats{
    grid-template-columns:1fr;
  }
  .tool-v2-action-row{
    justify-content:stretch;
  }
  .tool-v2-primary-btn,
  .tool-v2-download-btn{
    width:100%;
  }
}


/* v43 compact layout with right control panel */
.tool-v3-grid{display:grid;grid-template-columns:minmax(0,1.45fr) minmax(320px,.75fr);gap:1rem;align-items:start}
.tool-v3-main,.tool-v3-side{min-width:0}
.tool-v3-sticky{position:sticky;top:1rem;display:flex;flex-direction:column;gap:1rem}
.tool-v3-upload-block,.tool-v3-settings-wrap,.tool-v3-result-card,.tool-v3-progress-panel{background:#fbfcff;border:1px solid rgba(60,90,140,.08);border-radius:20px;padding:1rem}
.tool-v3-section-head{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;margin-bottom:.85rem}
.tool-v3-section-head.compact{margin-bottom:.65rem}
.tool-v3-title{font-size:1.05rem;font-weight:800;color:#243b63}
.tool-v3-subtitle{color:#6b7a92;font-size:.92rem}
.tool-v3-dropzone{min-height:170px;border:2px dashed #d7dff5;border-radius:22px;background:linear-gradient(180deg,#fbfdff,#f5f8ff);position:relative;overflow:hidden;transition:all .18s ease}
.tool-v3-dropzone.has-file{min-height:128px}
.tool-v3-dropzone.dragover,.tool-v3-dropzone.dragging{border-color:#5b72ff;background:linear-gradient(180deg,#f4f7ff,#edf3ff);box-shadow:0 0 0 6px rgba(91,114,255,.08)}
.tool-v3-dropzone-inner{min-height:170px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;gap:.45rem;padding:1rem 1.25rem}
.tool-v3-dropzone.has-file .tool-v3-dropzone-inner{min-height:128px;gap:.3rem}
.tool-v3-dropzone-icon{width:54px;height:54px;border-radius:16px;display:flex;align-items:center;justify-content:center;background:#eef2ff;font-size:1.5rem}
.tool-v3-dropzone-title{font-size:1.08rem;font-weight:900;color:#233760}
.tool-v3-dropzone-subtitle{color:#687891;font-size:.92rem}
.tool-v3-upload-btn{padding:.7rem 1.1rem;border-radius:14px;font-weight:800}
.tool-v3-accept-note{direction:ltr;color:#7a879d;font-weight:700;font-size:.88rem}
.tool-v3-selected-file{color:#243b63;font-weight:800;word-break:break-word;font-size:.92rem}
.tool-v3-preview-grid{display:grid;grid-template-columns:1fr 1fr;gap:1rem;margin-top:1rem}
.tool-v3-preview-card{background:#fff;border:1px solid rgba(60,90,140,.09);border-radius:20px;padding:1rem;display:flex;flex-direction:column;gap:.8rem}
.tool-v3-preview-head{display:flex;align-items:center;justify-content:space-between;gap:.75rem}
.tool-v3-meta-pill{display:inline-flex;align-items:center;justify-content:center;min-height:32px;padding:0 .75rem;border-radius:999px;background:#eff3ff;color:#3857a1;font-weight:800;font-size:.86rem}
.tool-v3-preview-body{min-height:240px;display:flex;align-items:center;justify-content:center;background:linear-gradient(180deg,#fbfcff,#f7f9fe);border:1px dashed #d7dff5;border-radius:18px;overflow:hidden;padding:1rem}
.tool-v3-preview-image{display:block;max-width:100%;max-height:205px;object-fit:contain;border-radius:16px;box-shadow:0 12px 34px rgba(36,59,99,.10)}
.tool-v3-preview-placeholder{color:#7a879d;text-align:center;line-height:1.9;font-weight:700}
.tool-v3-preview-meta{display:flex;flex-direction:column;gap:.35rem}
.tool-v3-file-name{font-weight:800;color:#233760;word-break:break-word}
.tool-v3-file-stats{display:flex;flex-wrap:wrap;gap:.75rem;color:#677892;font-size:.9rem}
.tool-v3-settings-stack{display:flex;flex-direction:column;gap:.9rem}
.tool-v3-setting-card{background:#fff;border:1px solid rgba(60,90,140,.09);border-radius:18px;padding:1rem}
.tool-v3-setting-title{font-weight:800;color:#22385d;margin-bottom:.75rem}
.tool-v3-primary-btn{width:100%;min-height:54px;border-radius:16px;font-weight:900}
.tool-v3-progress-panel{padding:.9rem 1rem}
.tool-v3-progress-label{font-weight:800;color:#2f4675;margin-bottom:.55rem}
.tool-v3-progress-bar{height:10px;border-radius:999px;overflow:hidden;background:#e6ebf7}
.tool-v3-progress-value{width:62%;height:100%;border-radius:999px;background:linear-gradient(90deg,#5b72ff,#74a9ff);animation:toolv3pulse 1.2s ease-in-out infinite alternate}
@keyframes toolv3pulse{from{width:34%}to{width:82%}}
.tool-v3-result-top{display:flex;align-items:center;justify-content:space-between;gap:1rem;flex-wrap:wrap;margin-bottom:1rem}
.tool-v3-download-btn{min-height:54px;min-width:220px;border-radius:16px;font-weight:900}
.tool-v3-result-stats{display:grid;grid-template-columns:repeat(3,1fr);gap:.9rem}
.tool-v3-result-stat{background:#fff;border:1px solid rgba(60,90,140,.09);border-radius:16px;padding:.9rem 1rem;display:flex;flex-direction:column;gap:.35rem}
.tool-v3-result-stat span{color:#687892;font-size:.92rem}
.tool-v3-result-stat strong{color:#233760;font-size:1rem}
@media (max-width:1100px){.tool-v3-grid{grid-template-columns:1fr}.tool-v3-sticky{position:static}}
@media (max-width:820px){.tool-v3-preview-grid,.tool-v3-result-stats{grid-template-columns:1fr}.tool-v3-download-btn{width:100%}}


/* v43.1 micro polish for right settings panel */
.tool-v3-setting-card{
  padding:.85rem;
}
.tool-v3-setting-card small,
.tool-v3-setting-card .size-mode-card small{
  font-size:.82rem;
  line-height:1.4;
}
.tool-v3-setting-card .locked-output-label{
  font-size:.85rem;
}
.tool-v3-setting-card .format-pill-subtitle{
  font-size:.80rem;
}
.tool-v3-setting-title{
  margin-bottom:.55rem;
}
.size-mode-card.compact-size-mode-card{
  padding:.7rem .75rem;
}
.dimension-inline-row.mt-3{
  margin-top:.75rem !important;
}
.tool-v3-settings-stack{
  gap:.75rem;
}
.quality-slider-wrap.compact-quality-slider-wrap{
  padding:.6rem .7rem;
}
.tool-v3-primary-btn{
  min-height:50px;
}


/* v45.1 reconstructed from v44 */
.nav-details-admin summary{
  min-width:110px;
  text-align:center;
}
.nav-logout-form{
  margin:0;
}
.nav-logout-item{
  width:100%;
  text-align:right;
  background:transparent;
  border:0;
}
.top-nav-details .nav-details{
  z-index:20;
}
.top-nav-details .nav-details[open]{
  z-index:40;
}
.top-nav-details .nav-details-menu{
  min-width:260px;
}
.markdown-locale-fa{
  direction:rtl;
  text-align:right;
}
.markdown-locale-fa ul,
.markdown-locale-fa ol{
  padding-right:1.5rem;
  padding-left:0;
}
.markdown-locale-fa ol{
  list-style-type: persian;
}


/* v50 image-converter menu and landing polish */
.nav-image-converter-link{
  background: linear-gradient(135deg, rgba(107,99,255,.16), rgba(57,160,255,.14));
}
.nav-details-item-strong{
  font-weight: 900;
  color: #243b63;
  background: linear-gradient(135deg, rgba(107,99,255,.08), rgba(57,160,255,.08));
  border-radius: 12px;
}

.tool-breadcrumbs{
  display:flex;
  align-items:center;
  gap:.5rem;
  margin: .25rem 0 .85rem;
  color: var(--muted);
  font-size: .92rem;
  font-weight: 700;
}
.tool-breadcrumbs a{
  color: #4a64c4;
}
.tool-breadcrumbs a:hover{
  color: #2e49b1;
}

.landing-feature-strip{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:16px;
}
.landing-feature-strip-item{
  display:block;
  border:1px solid rgba(125,102,255,.12);
  background: rgba(255,255,255,.82);
  border-radius:22px;
  padding:18px 20px;
  box-shadow: var(--shadow-soft);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.landing-feature-strip-item strong{
  display:block;
  color:#22314f;
  font-size:1rem;
  margin-bottom:6px;
}
.landing-feature-strip-item span{
  color:var(--muted);
  line-height:1.8;
  font-size:.94rem;
}
.landing-feature-strip-item:hover{
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: rgba(107,99,255,.24);
}

.landing-link-card,
.landing-link-card-v34,
.blog-card,
.related-post-card{
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.landing-link-card:hover,
.landing-link-card-v34:hover,
.blog-card:hover,
.related-post-card:hover{
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.tool-v3-selected-file,
.tool-v3-file-name{
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

@media (max-width: 980px){
  .landing-feature-strip{
    grid-template-columns:1fr;
  }
}


/* v60 unified tool template + seo + progress */
.seo-hero-link-btn{
  min-height: 40px;
  padding-inline: 14px;
  border-radius: 999px;
  font-weight: 800;
}

.tool-v3-fileinfo-grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:.85rem;
  margin: 0 0 1rem;
}
.tool-v3-fileinfo-item{
  background:#fff;
  border:1px solid rgba(60,90,140,.09);
  border-radius:16px;
  padding:.85rem .95rem;
  display:flex;
  flex-direction:column;
  gap:.32rem;
}
.tool-v3-fileinfo-item span{
  color:#6d7b92;
  font-size:.88rem;
}
.tool-v3-fileinfo-item strong{
  color:#22385d;
  font-size:.96rem;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.tool-v3-progress-steps{
  display:flex;
  gap:.55rem;
  flex-wrap:wrap;
  margin-top:.8rem;
}
.tool-v3-progress-steps span{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:34px;
  padding:0 .8rem;
  border-radius:999px;
  background:#eef2fb;
  color:#6c7a96;
  font-size:.84rem;
  font-weight:800;
}
.tool-v3-progress-steps span.active{
  background:linear-gradient(135deg, rgba(107,99,255,.14), rgba(57,160,255,.14));
  color:#243b63;
}

.tool-v3-result-stat-accent{
  background:linear-gradient(135deg, rgba(31,184,110,.08), rgba(107,99,255,.06));
  border-color: rgba(31,184,110,.18);
}

.seo-two-col .app-card,
.landing-two-col .app-card{
  transition: transform .18s ease, box-shadow .18s ease;
}
.seo-two-col .app-card:hover,
.landing-two-col .app-card:hover{
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

@media (max-width: 980px){
  .tool-v3-fileinfo-grid{
    grid-template-columns:1fr 1fr;
  }
}
@media (max-width: 640px){
  .tool-v3-fileinfo-grid{
    grid-template-columns:1fr;
  }
}


/* v61 markdown prominence + tools architecture */
.nav-markdown-link{
  background: linear-gradient(135deg, rgba(255,98,175,.15), rgba(107,99,255,.12));
}
.nav-details-markdown .nav-details-menu{
  min-width: 300px;
}
.landing-markdown-strip{
  grid-template-columns: repeat(3, 1fr);
}
.landing-markdown-item{
  border-color: rgba(255,98,175,.18);
  background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(255,246,252,.96));
}
.tools-grid-featured{
  margin-bottom: 1.25rem;
}
.tools-grid-featured .polished-hub-card{
  border: 1px solid rgba(255,98,175,.14);
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(255,248,252,.95));
}
@media (max-width: 980px){
  .landing-markdown-strip{
    grid-template-columns: 1fr;
  }
}


/* ===== header compact fix for current nav system ===== */

.top-nav.top-nav-compact{
  flex-wrap: nowrap;
  gap: 8px;
  overflow: visible;
  justify-content: center;
  min-width: 0;
  padding-bottom: 2px;
}

.top-nav.top-nav-compact .top-nav-link{
  min-height: 42px;
  padding: 0 14px;
  font-size: .92rem;
  white-space: nowrap;
  flex: 0 0 auto;
}

.top-nav.top-nav-compact .nav-details{
  flex: 0 0 auto;
  position: relative;
}

.top-nav.top-nav-compact .nav-details-menu{
  min-width: 240px;
  z-index: 80;
}

.top-nav.top-nav-compact .nav-details-markdown .nav-details-menu{
  min-width: 280px;
}

.top-nav.top-nav-compact .nav-auth{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.site-header{
  align-items: center;
  overflow: visible;
}

.brand-title{
  font-size: 1.45rem;
}

.brand-subtitle{
  font-size: .82rem;
}

.nav-markdown-link{
  background: linear-gradient(135deg, rgba(255,98,175,.13), rgba(107,99,255,.10));
}

@media (max-width: 1200px){
  .top-nav.top-nav-compact{
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .top-nav.top-nav-compact .top-nav-link{
    min-height: 40px;
    padding: 0 12px;
    font-size: .88rem;
  }
}

@media (max-width: 900px){
  .site-header{
    flex-wrap: wrap;
    gap: 12px;
  }

  .top-nav.top-nav-compact{
    order: 3;
    width: 100%;
  }
}

/* ===== Hero alignment fix ===== */
.refined-hero{
  align-items: flex-start;
}

.refined-hero h1{
  margin-top: 4px;
}


.preview-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

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

.compact-side-actions-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
