/* NASJ STUDIO — Modern Dark Premium */
:root {
  --bg: #090909;
  --card: #111111;
  --card-2: #151515;
  --line: #252525;
  --line-2: #303030;
  --text: #e5e5e5;
  --muted: #8f8f8f;
  --dim: #5f5f5f;
  --silver-1: #f4f4f4;
  --silver-2: #b9b9b9;
  --silver-3: #7c7c7c;
  --silver-grad: linear-gradient(135deg, #f6f6f6 0%, #b4b4b4 42%, #e6e6e6 68%, #8a8a8a 100%);
  --ok: #9fbfa6;
  --bad: #d39a92;
  --radius: 18px;
  --radius-sm: 12px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --font: 'Inter', 'IBM Plex Sans Arabic', system-ui, -apple-system, 'Segoe UI', Tahoma, sans-serif;
  --font-ar: 'IBM Plex Sans Arabic', 'Inter', system-ui, 'Segoe UI', Tahoma, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0; min-height: 100vh; background: var(--bg); color: var(--text);
  font-family: var(--font); font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
html[lang="ar"] body { font-family: var(--font-ar); }
img, svg, canvas { display: block; max-width: 100%; }
button, input { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }
::selection { background: #3a3a3a; color: #fff; }
:focus-visible { outline: 2px solid #cfcfcf; outline-offset: 3px; border-radius: 6px; }

.container { width: min(1120px, 100% - 40px); margin-inline: auto; }
.muted { color: var(--muted); }

/* Background ---------------------------------------------------------- */
.bg { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.bg-grid {
  position: absolute; inset: -1px;
  background-image:
    linear-gradient(to right, rgba(255,255,255,.028) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,.028) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 75%);
}
.bg-glow {
  position: absolute; width: 900px; height: 600px; left: 50%; top: -340px; transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(220,220,220,.09), transparent 70%);
  filter: blur(10px);
}

/* Glass --------------------------------------------------------------- */
.glass {
  background: linear-gradient(180deg, rgba(22,22,22,.78), rgba(17,17,17,.72));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
  box-shadow: 0 1px 0 rgba(255,255,255,.04) inset, 0 24px 60px -30px rgba(0,0,0,.8);
}

/* Header -------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 20;
  transition: background .4s var(--ease), border-color .4s var(--ease), backdrop-filter .4s;
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(9,9,9,.72); border-bottom-color: var(--line);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 12px; direction: ltr; }
.brand-mark { width: 34px; height: 34px; transition: transform .8s var(--ease); }
.brand:hover .brand-mark { transform: rotate(60deg); }
.brand-word {
  font-family: 'Inter', sans-serif; font-weight: 600; letter-spacing: .22em; font-size: 15px;
  background: var(--silver-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  direction: ltr;
}
.brand-word span { font-weight: 300; margin-inline-start: .45em; }
.brand-word.small { font-size: 12px; }
.header-actions { display: flex; align-items: center; gap: 10px; }
.lang-btn {
  height: 38px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line);
  background: rgba(255,255,255,.02); cursor: pointer; font-size: 14px; color: var(--text);
  transition: border-color .25s, background .25s;
}
.lang-btn:hover { border-color: #3d3d3d; background: rgba(255,255,255,.05); }

/* Buttons ------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 44px; padding: 0 20px; border-radius: 12px; border: 1px solid transparent;
  font-size: 15px; font-weight: 500; cursor: pointer; white-space: nowrap; user-select: none;
  transition: transform .2s var(--ease), background .25s, border-color .25s, color .25s, box-shadow .3s, opacity .2s;
}
.btn svg { width: 19px; height: 19px; }
.btn:active { transform: translateY(1px) scale(.99); }
.btn-lg { height: 54px; padding: 0 28px; font-size: 16px; border-radius: 14px; }
.btn-primary {
  position: relative; overflow: hidden; color: #0b0b0b; font-weight: 600;
  background: linear-gradient(180deg, #f2f2f2, #c4c4c4);
  box-shadow: 0 1px 0 rgba(255,255,255,.6) inset, 0 10px 30px -12px rgba(220,220,220,.35);
}
.btn-primary::after {
  content: ''; position: absolute; inset: 0; transform: translateX(-120%);
  background: linear-gradient(100deg, transparent 30%, rgba(255,255,255,.65) 50%, transparent 70%);
  transition: transform .9s var(--ease);
}
.btn-primary:hover::after { transform: translateX(120%); }
.btn-primary:hover { box-shadow: 0 1px 0 rgba(255,255,255,.6) inset, 0 14px 36px -12px rgba(230,230,230,.45); }
.btn-primary[disabled] { opacity: .5; pointer-events: none; }
.btn-ghost { border-color: var(--line-2); background: rgba(255,255,255,.03); color: var(--text); }
.btn-ghost:hover { border-color: #474747; background: rgba(255,255,255,.06); }
.btn-quiet { background: transparent; color: var(--muted); padding: 0 12px; height: 38px; }
.btn-quiet:hover { color: var(--text); background: rgba(255,255,255,.04); }
.icon-btn {
  width: 36px; height: 36px; flex: none; display: grid; place-items: center; border-radius: 10px;
  border: 1px solid var(--line); background: rgba(255,255,255,.02); cursor: pointer; color: var(--silver-2);
  transition: border-color .2s, color .2s, background .2s;
}
.icon-btn:hover { border-color: #3f3f3f; color: #fff; background: rgba(255,255,255,.05); }
.icon-btn svg { width: 18px; height: 18px; }

/* Hero ---------------------------------------------------------------- */
.hero { text-align: center; padding: 72px 0 40px; }
.eyebrow {
  display: inline-block; margin: 0 0 22px; padding: 6px 14px; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(255,255,255,.02);
  font-family: 'Inter', sans-serif; font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--silver-2);
  direction: ltr;
}
.hero h1 {
  margin: 0 auto; max-width: 860px; font-weight: 600; letter-spacing: -.02em;
  font-size: clamp(32px, 5.4vw, 60px); line-height: 1.12;
  background: linear-gradient(180deg, #fafafa 20%, #a9a9a9 120%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
html[lang="ar"] .hero h1 { letter-spacing: 0; line-height: 1.3; }
.lead { margin: 22px auto 0; max-width: 640px; color: var(--muted); font-size: clamp(15px, 1.8vw, 18px); }
.badges { list-style: none; padding: 0; margin: 30px 0 0; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.badges li {
  padding: 7px 14px; border-radius: 999px; font-size: 13px; color: #cfcfcf;
  border: 1px solid var(--line); background: rgba(17,17,17,.6);
}

/* Reveal animation */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.hero .reveal:nth-child(2) { transition-delay: .06s; }
.hero .reveal:nth-child(3) { transition-delay: .12s; }
.hero .reveal:nth-child(4) { transition-delay: .18s; }

/* Tool card ----------------------------------------------------------- */
.tool { padding: 18px 0 40px; }
.tool-card { position: relative; padding: 26px; min-height: 420px; }
.tool-skeleton { display: grid; place-items: center; }
.stepper {
  list-style: none; margin: 0 0 24px; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px;
}
.stepper li {
  position: relative; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px;
  color: var(--dim); font-size: 14px; border: 1px solid transparent; transition: color .4s, border-color .4s, background .4s;
}
.stepper .num {
  width: 24px; height: 24px; flex: none; border-radius: 50%; display: grid; place-items: center;
  font-size: 12px; font-family: 'Inter', sans-serif; border: 1px solid var(--line-2); transition: all .4s var(--ease);
}
.stepper li.done { color: var(--muted); }
.stepper li.done .num { background: #2a2a2a; border-color: #3a3a3a; color: #ddd; }
.stepper li.active { color: var(--text); border-color: var(--line); background: rgba(255,255,255,.03); }
.stepper li.active .num { background: var(--silver-grad); border-color: transparent; color: #111; }

.panel.enter { animation: panelIn .55s var(--ease) both; }
@keyframes panelIn { from { opacity: 0; transform: translateY(10px) scale(.995); } to { opacity: 1; transform: none; } }

/* Upload */
.dropzone {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  min-height: 330px; padding: 40px 20px; text-align: center; cursor: pointer;
  border: 1.5px dashed #333; border-radius: var(--radius); background:
    radial-gradient(ellipse at 50% 0%, rgba(255,255,255,.035), transparent 60%), rgba(12,12,12,.5);
  transition: border-color .3s, background .3s, transform .3s var(--ease);
}
.dropzone:hover, .dropzone.is-over { border-color: #6a6a6a; background-color: rgba(20,20,20,.6); }
.dropzone.is-over { transform: scale(1.005); }
.dz-icon {
  width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; margin-bottom: 8px;
  border: 1px solid var(--line-2); background: linear-gradient(180deg, #1b1b1b, #121212); color: var(--silver-1);
  transition: transform .5s var(--ease);
}
.dropzone:hover .dz-icon, .dropzone.is-over .dz-icon { transform: translateY(-4px); }
.dz-icon svg { width: 28px; height: 28px; }
.dz-title { font-size: 19px; font-weight: 500; }
.dz-or { color: var(--dim); font-size: 13px; }
.dz-formats { color: var(--muted); font-size: 13px; letter-spacing: .08em; direction: ltr; margin-top: 6px; }
.dz-private { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px rgba(159,191,166,.12); }
.loading { min-height: 330px; display: flex; align-items: center; justify-content: center; gap: 14px; color: var(--muted); }
.spinner {
  width: 22px; height: 22px; border-radius: 50%; border: 2px solid #2a2a2a; border-top-color: #d8d8d8;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Editor */
.edit-grid { display: grid; grid-template-columns: minmax(240px, 300px) 1fr; gap: 28px; align-items: start; }
.col-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.col-head h3 { margin: 0; font-size: 15px; font-weight: 500; color: var(--silver-2); letter-spacing: .02em; }
.chip {
  font-size: 12px; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted);
  font-family: 'Inter', sans-serif; direction: ltr; unicode-bidi: isolate;
}
.crop-frame {
  position: relative; width: 100%; aspect-ratio: 160 / 220; border-radius: 14px; overflow: hidden;
  background: #000; border: 1px solid var(--line-2);
  box-shadow: 0 0 0 6px rgba(255,255,255,.02), 0 30px 60px -30px rgba(0,0,0,.9);
}
.crop-canvas { width: 100%; height: 100%; cursor: grab; touch-action: none; }
.crop-canvas.is-dragging { cursor: grabbing; }
.crop-guides { position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .3s; }
.crop-frame:has(.is-dragging) .crop-guides, .crop-frame:hover .crop-guides { opacity: 1; }
.crop-guides i { position: absolute; background: rgba(255,255,255,.18); }
.crop-guides i:nth-child(1) { left: 33.33%; top: 0; bottom: 0; width: 1px; }
.crop-guides i:nth-child(2) { left: 66.66%; top: 0; bottom: 0; width: 1px; }
.crop-guides i:nth-child(3) { top: 33.33%; left: 0; right: 0; height: 1px; }
.crop-guides i:nth-child(4) { top: 66.66%; left: 0; right: 0; height: 1px; }
.zoom-row { display: flex; align-items: center; gap: 10px; margin-top: 14px; direction: ltr; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin-top: 12px; padding: 4px; border: 1px solid var(--line); border-radius: 12px; background: rgba(0,0,0,.25); }
.seg-btn { height: 34px; border: 0; border-radius: 9px; background: transparent; color: var(--muted); font-size: 13px; cursor: pointer; transition: background .2s, color .2s; }
.seg-btn:hover { background: rgba(255,255,255,.06); color: var(--text); }
.hint { margin: 10px 0 0; font-size: 13px; color: var(--dim); }
.note { margin: 10px 0 0; font-size: 13px; color: #c9b98f; }

/* Range */
input[type="range"] { -webkit-appearance: none; appearance: none; flex: 1; height: 28px; background: transparent; cursor: pointer; }
input[type="range"]::-webkit-slider-runnable-track { height: 3px; border-radius: 3px; background: #2c2c2c; }
input[type="range"]::-moz-range-track { height: 3px; border-radius: 3px; background: #2c2c2c; }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 18px; height: 18px; margin-top: -7.5px; border-radius: 50%;
  background: var(--silver-grad); border: 0; box-shadow: 0 0 0 4px rgba(255,255,255,.07);
}
input[type="range"]::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: #d6d6d6; border: 0; }

.side-col { min-width: 0; display: flex; flex-direction: column; }
.file-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; margin-bottom: 22px;
  border: 1px solid var(--line); border-radius: 14px; background: rgba(0,0,0,.25);
}
.file-meta { min-width: 0; display: flex; flex-direction: column; }
.file-name { font-weight: 500; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; direction: ltr; text-align: start; unicode-bidi: plaintext; }
.file-info { font-size: 12px; color: var(--muted); direction: ltr; text-align: start; unicode-bidi: plaintext; }

/* Timeline */
.tl { position: relative; user-select: none; -webkit-user-select: none; }
.tl-track {
  position: relative; height: 64px; border-radius: 12px; overflow: visible; background: #0d0d0d;
  border: 1px solid var(--line); touch-action: none; cursor: pointer;
}
.tl-thumbs { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 11px; opacity: .9; }
.tl-shade { position: absolute; top: 0; bottom: 0; background: rgba(9,9,9,.72); pointer-events: none; }
.tl-shade-a { left: 0; border-radius: 11px 0 0 11px; }
.tl-shade-b { right: 0; border-radius: 0 11px 11px 0; }
.tl-sel {
  position: absolute; top: -3px; bottom: -3px; border: 2px solid #dcdcdc; border-radius: 10px;
  box-shadow: 0 0 0 1px rgba(0,0,0,.6), 0 8px 26px -8px rgba(255,255,255,.18);
  cursor: grab; touch-action: none;
}
.is-dragging .tl-sel { cursor: grabbing; }
.tl-handle {
  position: absolute; top: -2px; bottom: -2px; width: 16px; padding: 0; border: 0; cursor: ew-resize; touch-action: none;
  background: linear-gradient(180deg, #f0f0f0, #bdbdbd);
  display: grid; place-items: center;
}
.tl-handle span { width: 2px; height: 18px; border-radius: 2px; background: rgba(0,0,0,.45); }
.tl-handle-a { left: -9px; border-radius: 9px 4px 4px 9px; }
.tl-handle-b { right: -9px; border-radius: 4px 9px 9px 4px; }
.tl-handle::before { content: ''; position: absolute; inset: -10px -12px; } /* bigger touch target */
.tl-playhead {
  position: absolute; top: -8px; bottom: -8px; width: 2px; margin-left: -1px; background: #fff; pointer-events: none;
  box-shadow: 0 0 8px rgba(255,255,255,.6); border-radius: 2px;
}
.tl-playhead::before { content: ''; position: absolute; top: -3px; left: -4px; width: 10px; height: 6px; border-radius: 3px; background: #fff; }

.trim-row { display: flex; align-items: center; gap: 16px; margin-top: 18px; }
.play-btn {
  width: 48px; height: 48px; flex: none; border-radius: 50%; border: 1px solid var(--line-2); cursor: pointer;
  background: linear-gradient(180deg, #1c1c1c, #121212); color: var(--silver-1); display: grid; place-items: center;
  transition: transform .2s var(--ease), border-color .2s;
}
.play-btn:hover { border-color: #4a4a4a; transform: scale(1.04); }
.play-btn svg { width: 20px; height: 20px; }
.trim-vals { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.trim-vals span { display: flex; flex-direction: column; padding: 8px 12px; border-radius: 12px; border: 1px solid var(--line); background: rgba(0,0,0,.2); }
.trim-vals em { font-style: normal; font-size: 11px; color: var(--dim); }
.trim-vals b { font-weight: 500; font-size: 15px; font-family: 'Inter', sans-serif; font-variant-numeric: tabular-nums; direction: ltr; text-align: start; unicode-bidi: plaintext; }

.convert-box { margin-top: auto; padding-top: 26px; display: flex; flex-direction: column; align-items: stretch; gap: 10px; }
.auto-note { margin: 0; text-align: center; font-size: 13px; color: var(--dim); }

/* Progress */
.progress-wrap { max-width: 560px; margin: 0 auto; padding: 70px 0; display: flex; flex-direction: column; gap: 18px; }
.pg-phases { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.pg-phases span { font-size: 13px; color: var(--dim); padding-top: 10px; border-top: 2px solid #222; transition: color .4s, border-color .4s; }
.pg-phases span.active { color: var(--text); border-color: #d6d6d6; }
.pg-phases span.done { color: var(--muted); border-color: #555; }
.pg-bar { height: 6px; border-radius: 6px; background: #1b1b1b; overflow: hidden; }
.pg-bar i {
  display: block; height: 100%; transform-origin: left; transform: scaleX(0); transition: transform .25s linear;
  background: linear-gradient(90deg, #8a8a8a, #f2f2f2, #9a9a9a); background-size: 200% 100%;
  animation: sheen 2.4s linear infinite;
}
html[dir="rtl"] .pg-bar i { transform-origin: right; }
@keyframes sheen { to { background-position: -200% 0; } }
.pg-row { display: flex; justify-content: space-between; color: var(--muted); font-size: 14px; }
.pg-pct { color: var(--text); font-family: 'Inter', sans-serif; font-variant-numeric: tabular-nums; }
.act-cancel { align-self: center; margin-top: 10px; }

/* Result */
.result-grid { display: grid; grid-template-columns: auto 1fr; gap: 36px; align-items: start; }
.previews { display: flex; gap: 22px; align-items: flex-end; }
.pv { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.pv-box {
  padding: 10px; border-radius: 16px; border: 1px solid var(--line);
  background: repeating-conic-gradient(#141414 0% 25%, #101010 0% 50%) 0 0 / 16px 16px;
}
.pv img { border-radius: 6px; image-rendering: auto; }
.pv-actual img { width: 160px; height: 220px; }
.pv-zoom img { width: 320px; height: 440px; image-rendering: pixelated; }
.pv figcaption { font-size: 12px; color: var(--dim); }
.result-title { margin: 0 0 18px; font-size: 26px; font-weight: 600; background: var(--silver-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; margin: 0; }
.stats div { padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); background: rgba(0,0,0,.22); }
.stats dt { font-size: 12px; color: var(--dim); }
.stats dd { margin: 2px 0 0; font-size: 16px; font-weight: 500; font-variant-numeric: tabular-nums; }
.stats dd small { display: block; font-size: 12px; color: var(--muted); font-weight: 400; direction: ltr; text-align: start; unicode-bidi: plaintext; }
.checks { margin-top: 20px; }
.checks h4 { margin: 0 0 10px; font-size: 13px; font-weight: 500; color: var(--muted); }
.check-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px 16px; }
.check-list li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: #cfcfcf; opacity: 0; animation: panelIn .5s var(--ease) forwards; }
.check-list li:nth-child(2) { animation-delay: .05s; } .check-list li:nth-child(3) { animation-delay: .1s; }
.check-list li:nth-child(4) { animation-delay: .15s; } .check-list li:nth-child(5) { animation-delay: .2s; }
.check-list li:nth-child(6) { animation-delay: .25s; } .check-list li:nth-child(7) { animation-delay: .3s; }
.check-list svg { width: 18px; height: 18px; flex: none; padding: 2px; border-radius: 50%; }
.check-list li.ok svg { color: var(--ok); background: rgba(159,191,166,.1); }
.check-list li.bad svg { color: var(--bad); background: rgba(211,154,146,.1); }
.result-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }

/* Toast & modal */
.toast {
  position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 5;
  width: min(560px, calc(100% - 32px)); display: flex; align-items: flex-start; gap: 12px; padding: 14px 14px 14px 18px;
  border-radius: 14px; border: 1px solid #3a2f2d; background: rgba(28,22,21,.96); color: #ead6d2; font-size: 14px;
  box-shadow: 0 20px 50px -20px rgba(0,0,0,.9);
}
.toast.show { animation: panelIn .45s var(--ease); }
.toast-msg { flex: 1; }
.toast-x { width: 28px; height: 28px; flex: none; border: 0; background: transparent; color: inherit; cursor: pointer; border-radius: 8px; display: grid; place-items: center; }
.toast-x svg { width: 16px; height: 16px; }
.modal {
  width: min(480px, calc(100% - 32px)); padding: 0; border: 1px solid var(--line-2); border-radius: var(--radius);
  background: #121212; color: var(--text); box-shadow: 0 40px 100px -30px #000;
}
.modal::backdrop { background: rgba(0,0,0,.6); backdrop-filter: blur(4px); }
.modal[open] { animation: panelIn .4s var(--ease); }
.modal-body { padding: 26px; }
.modal h3 { margin: 0 0 10px; font-size: 18px; font-weight: 600; }
.modal p { margin: 0; color: var(--muted); font-size: 15px; }
.modal-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }

/* Sections ------------------------------------------------------------ */
.section-title {
  text-align: center; margin: 0 0 30px; font-size: clamp(22px, 3vw, 32px); font-weight: 600; letter-spacing: -.01em;
  background: linear-gradient(180deg, #f5f5f5, #9d9d9d); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.features { padding: 60px 0 30px; }
.feature-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.feature { padding: 24px; transition: transform .5s var(--ease), border-color .4s; }
.feature:hover { transform: translateY(-4px); border-color: #333; }
.feature svg { width: 26px; height: 26px; color: var(--silver-1); margin-bottom: 18px; }
.feature h3 { margin: 0 0 8px; font-size: 16px; font-weight: 600; }
.feature p { margin: 0; color: var(--muted); font-size: 14px; }
.feature-grid .feature:nth-child(2) { transition-delay: .05s; }
.feature-grid .feature:nth-child(3) { transition-delay: .1s; }
.feature-grid .feature:nth-child(4) { transition-delay: .15s; }

.faq { padding: 50px 0 70px; }
.faq-list { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 10px; }
.faq details { padding: 0; border-radius: 14px; }
.faq summary {
  list-style: none; cursor: pointer; padding: 18px 22px; font-weight: 500; display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 20px; color: var(--muted); transition: transform .3s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0; padding: 0 22px 20px; color: var(--muted); font-size: 15px; }

.site-footer { border-top: 1px solid var(--line); padding: 28px 0; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; font-size: 13px; }
.noscript { text-align: center; color: var(--muted); }

/* Responsive ---------------------------------------------------------- */
@media (max-width: 960px) {
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .result-grid { grid-template-columns: 1fr; }
  .previews { justify-content: center; }
}
@media (max-width: 760px) {
  .container { width: min(1120px, 100% - 24px); }
  .header-cta { display: none; }
  .hero { padding: 44px 0 26px; }
  .tool-card { padding: 16px; border-radius: 16px; }
  .stepper { gap: 4px; margin-bottom: 18px; }
  .stepper li { flex-direction: column; gap: 6px; padding: 8px 4px; font-size: 12px; text-align: center; }
  .edit-grid { grid-template-columns: 1fr; gap: 22px; }
  .crop-col { max-width: 300px; width: 100%; margin-inline: auto; }
  .dropzone { min-height: 260px; }
  .trim-vals { gap: 6px; }
  .trim-vals span { padding: 6px 8px; }
  .trim-vals b { font-size: 13px; }
  .pv-zoom img { width: 200px; height: 275px; image-rendering: auto; }
  .previews { gap: 12px; }
  .result-actions .btn { flex: 1; }
  .result-actions .btn-primary { flex-basis: 100%; }
  .progress-wrap { padding: 40px 0; }
}
@media (max-width: 420px) {
  .pv-actual { display: none; }
  .pv-zoom img { width: 240px; height: 330px; }
  .feature-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}
