@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@500;600;700;800&display=swap');

* { box-sizing: border-box; }

:root {
  color-scheme: light;
  --bg: #f7faf8;
  --bg-soft: #eef5f1;
  --panel: rgba(255, 255, 255, 0.9);
  --panel-solid: #ffffff;
  --panel-light: #f3f8f5;
  --line: rgba(18, 72, 53, 0.11);
  --line-strong: rgba(18, 72, 53, 0.18);
  --text: #10211b;
  --muted: #6f837b;
  --muted-strong: #4f675e;
  --accent: #059669;
  --accent-strong: #10b981;
  --accent-ink: #ffffff;
  --warning: #a86108;
  --shadow: 0 24px 70px rgba(31, 67, 53, 0.12);
  --radius-lg: 24px;
  --radius-md: 16px;
}

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 50% -10%, rgba(67, 181, 139, 0.14), transparent 34rem),
    linear-gradient(180deg, #fbfdfc 0%, #f5faf7 48%, #f1f7f4 100%);
  color: var(--text);
  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; }
button { border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
::selection { background: var(--accent); color: var(--accent-ink); }

.shell { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }
.page-glow { position: fixed; z-index: -1; border-radius: 999px; filter: blur(100px); pointer-events: none; opacity: .22; }
.page-glow-one { width: 380px; height: 380px; top: 8%; left: -220px; background: #94e2c5; }
.page-glow-two { width: 460px; height: 460px; top: 36%; right: -300px; background: #b4ded0; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(18, 72, 53, 0.08);
  background: rgba(250, 253, 251, 0.82);
  backdrop-filter: blur(22px) saturate(130%);
}

.header-inner { min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand-mark { width: 40px; height: 40px; display: grid; place-items: center; flex: 0 0 auto; border: 1px solid rgba(5, 150, 105, .18); border-radius: 12px; background: linear-gradient(145deg, rgba(16, 185, 129, .12), rgba(16, 185, 129, .035)); color: var(--accent); box-shadow: inset 0 1px rgba(255,255,255,.7); }
.brand-mark svg { width: 23px; height: 23px; }
.brand strong { display: block; font-family: "Manrope", sans-serif; font-size: 15px; font-weight: 700; letter-spacing: -.02em; }
.brand small { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; }
.privacy-pill { display: inline-flex; align-items: center; gap: 9px; min-height: 36px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted-strong); background: rgba(255,255,255,.72); font-size: 12px; font-weight: 600; }
.privacy-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-strong); box-shadow: 0 0 0 5px rgba(52, 211, 153, .1); }

.hero { padding: 94px 0 50px; text-align: center; }
.eyebrow, .section-kicker { color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }
.eyebrow { display: inline-flex; align-items: center; gap: 9px; }
.eyebrow span { width: 22px; height: 1px; background: var(--accent); }
.hero h1 { max-width: 900px; margin: 23px auto 24px; font-family: "Manrope", sans-serif; font-size: clamp(42px, 6.2vw, 76px); line-height: 1.04; letter-spacing: -.055em; }
.hero h1 em { color: var(--accent); font-style: normal; }
.hero-copy { max-width: 690px; margin: 0 auto; color: var(--muted-strong); font-size: clamp(16px, 2vw, 19px); line-height: 1.7; }
.trust-row { display: flex; justify-content: center; flex-wrap: wrap; gap: 22px 32px; margin-top: 34px; color: var(--muted); font-size: 13px; font-weight: 500; }
.trust-row div { display: flex; align-items: center; gap: 8px; }
.check { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; background: rgba(110, 231, 183, .1); color: var(--accent); font-size: 11px; }

.tool-shell { padding-bottom: 88px; }
.tool-card { position: relative; overflow: hidden; border: 1px solid var(--line-strong); border-radius: var(--radius-lg); background: linear-gradient(150deg, rgba(255,255,255,.98), rgba(246,251,248,.96)); box-shadow: var(--shadow), inset 0 1px rgba(255,255,255,.9); }
.tool-card::before { content: ""; position: absolute; width: 320px; height: 320px; left: 50%; top: -250px; transform: translateX(-50%); border-radius: 50%; background: rgba(16, 185, 129, .12); filter: blur(55px); pointer-events: none; }
.upload-zone { position: relative; min-height: 330px; display: flex; flex-direction: column; align-items: center; justify-content: center; margin: 14px; padding: 48px 24px; outline: none; border: 1px dashed rgba(5, 150, 105, .27); border-radius: 17px; background: rgba(239, 248, 243, .72); text-align: center; transition: border-color .2s, background .2s, transform .2s; }
.upload-zone:hover, .upload-zone:focus-visible, .upload-zone.border-primary { border-color: rgba(5, 150, 105, .62); background: rgba(226, 246, 237, .86); }
.upload-zone:focus-visible { box-shadow: 0 0 0 3px rgba(110, 231, 183, .15); }
.upload-icon { width: 64px; height: 64px; display: grid; place-items: center; margin-bottom: 22px; border: 1px solid rgba(5, 150, 105, .2); border-radius: 18px; color: var(--accent); background: linear-gradient(145deg, rgba(16, 185, 129, .14), rgba(16, 185, 129, .035)); box-shadow: 0 14px 35px rgba(39, 93, 72, .12); transition: transform .2s; }
.upload-zone:hover .upload-icon { transform: translateY(-3px); }
.upload-icon svg { width: 30px; height: 30px; }
.upload-zone h2 { margin: 0; font-family: "Manrope", sans-serif; font-size: clamp(22px, 3vw, 30px); letter-spacing: -.035em; }
.upload-zone p { margin: 10px 0 22px; color: var(--muted); font-size: 14px; }
.format-row { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px; }
.format-row span { padding: 5px 9px; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); background: rgba(255,255,255,.75); font-size: 10px; font-weight: 700; letter-spacing: .06em; }

.quality-panel { display: grid; gap: 18px; margin: 0 0 22px; padding: 18px 0 22px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.quality-heading { display: flex; align-items: center; gap: 12px; }
.quality-heading label { font-family: "Manrope", sans-serif; font-size: 14px; font-weight: 700; }
.quality-heading output { min-width: 48px; padding: 5px 8px; border-radius: 8px; background: rgba(110, 231, 183, .12); color: var(--accent); font-size: 12px; font-weight: 700; text-align: center; }
.quality-copy p { margin: 8px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.range-wrap input { width: 100%; height: 5px; appearance: none; border-radius: 999px; outline: none; background: linear-gradient(to right, var(--accent) 0%, var(--accent) 36.36%, #dbe7e2 36.36%, #dbe7e2 100%); }
.range-wrap input::-webkit-slider-thumb { width: 20px; height: 20px; appearance: none; border: 4px solid #ffffff; border-radius: 50%; background: #059669; box-shadow: 0 0 0 3px rgba(5,150,105,.13), 0 4px 12px rgba(39,93,72,.2); cursor: grab; }
.range-wrap input::-moz-range-thumb { width: 13px; height: 13px; border: 4px solid #ffffff; border-radius: 50%; background: #059669; box-shadow: 0 0 0 3px rgba(5,150,105,.13); cursor: grab; }
.range-labels { display: flex; justify-content: space-between; margin-top: 10px; color: #80948c; font-size: 10px; }
.local-note { display: flex; align-items: center; justify-content: center; gap: 9px; margin: 18px auto 0; color: #71867e; font-size: 12px; }
.local-note svg { width: 15px; height: 15px; color: var(--accent); }

.result-section, .batch-section { padding: 8px 0 100px; }
.result-grid { display: grid; grid-template-columns: minmax(0, 1fr) 315px; gap: 20px; align-items: start; }
.preview-card, .actions-card, .batch-card-shell { border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--panel); box-shadow: 0 20px 60px rgba(35,81,63,.1); backdrop-filter: blur(20px); }
.preview-card { overflow: hidden; }
.card-header { min-height: 87px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.preview-card .card-header { align-items: flex-start; flex-direction: column; justify-content: flex-start; gap: 14px; }
.card-header h2, .actions-card h2, .section-heading h2 { margin: 5px 0 0; font-family: "Manrope", sans-serif; letter-spacing: -.035em; }
.card-header h2 { font-size: 20px; }
.meta-row { width: 100%; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 10px; color: var(--muted); font-size: 10px; line-height: 1.55; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.meta-row > span { min-width: 0; padding: 10px 12px; overflow-wrap: anywhere; border: 1px solid var(--line); border-radius: 10px; background: rgba(241,248,244,.65); }
.meta-row p { display: block; margin: 4px 0 0; }
.comparison-stage { min-height: 480px; display: grid; place-items: center; padding: 22px; background-color: #edf3f0; background-image: linear-gradient(45deg, rgba(39,93,72,.04) 25%, transparent 25%), linear-gradient(-45deg, rgba(39,93,72,.04) 25%, transparent 25%), linear-gradient(45deg, transparent 75%, rgba(39,93,72,.04) 75%), linear-gradient(-45deg, transparent 75%, rgba(39,93,72,.04) 75%); background-size: 20px 20px; background-position: 0 0, 0 10px, 10px -10px, -10px 0; }
.comparison-container { position: relative; width: fit-content; max-width: 100%; user-select: none; }
.comparison-container > img { display: block; width: auto; height: auto; max-width: 100%; max-height: 68vh; object-fit: contain; }
.processed-overlay { position: absolute; z-index: 10; top: 0; left: 0; width: 50%; height: 100%; overflow: hidden; border-right: 1px solid rgba(255,255,255,.88); box-sizing: content-box; }
.processed-overlay img { display: block; height: 100%; max-width: none; object-fit: contain; object-position: left top; }
.slider-handle { position: absolute; z-index: 20; top: 0; bottom: 0; width: 44px; margin-left: -22px; align-items: center; justify-content: center; cursor: col-resize; }
.slider-handle span { width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; gap: 3px; border: 1px solid rgba(255,255,255,.5); border-radius: 50%; color: #0b1a16; background: #f5fbf8; box-shadow: 0 6px 20px rgba(0,0,0,.3); }
.slider-handle b { font-family: Arial, sans-serif; font-size: 19px; font-weight: 400; line-height: 1; }
.image-label { position: absolute; z-index: 30; top: 12px; padding: 5px 9px; border: 1px solid rgba(255,255,255,.15); border-radius: 7px; color: rgba(255,255,255,.88); background: rgba(5,14,12,.65); backdrop-filter: blur(8px); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; pointer-events: none; }
.label-after { left: 12px; }
.label-before { right: 12px; }
.drag-hint { margin: 0; padding: 13px 20px; border-top: 1px solid var(--line); color: #71877f; font-size: 11px; text-align: center; }

.actions-card { position: sticky; top: 98px; padding: 28px; }
.actions-card h2 { margin-top: 8px; font-size: 24px; line-height: 1.2; }
.actions-card > p { margin: 13px 0 24px; color: var(--muted); font-size: 13px; line-height: 1.65; }
.action-stack { display: grid; gap: 10px; }
.button { min-height: 46px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 0 16px; border: 1px solid transparent; border-radius: 11px; font-size: 12px; font-weight: 700; transition: transform .15s, border-color .15s, background .15s, color .15s; }
.button:hover { transform: translateY(-1px); }
.button:active { transform: scale(.985); }
.button svg { width: 17px; height: 17px; }
.button-primary { color: var(--accent-ink); background: linear-gradient(135deg, #059669, #10b981); box-shadow: 0 10px 24px rgba(5,150,105,.18); }
.button-primary:hover { background: linear-gradient(135deg, #047857, #059669); }
.button-secondary { border-color: var(--line-strong); color: var(--text); background: rgba(239,247,243,.88); }
.button-secondary:hover { border-color: rgba(5,150,105,.3); background: rgba(222,244,234,.9); }
.button-ghost { border-color: transparent; color: var(--muted-strong); background: transparent; }
.button-ghost:hover { color: var(--text); background: rgba(18,72,53,.05); }
.status-message { display: none; min-height: 20px; margin-top: 16px; color: var(--warning); font-size: 11px; line-height: 1.5; }
.quality-reminder { display: flex; align-items: flex-start; gap: 8px; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); color: #758b83; font-size: 10px; line-height: 1.5; }
.quality-reminder span { width: 6px; height: 6px; flex: 0 0 auto; margin-top: 4px; border-radius: 50%; background: var(--accent); }
.text-primary { color: var(--accent) !important; }
.text-warning { color: var(--warning) !important; }

.batch-card-shell { overflow: hidden; }
.batch-header-actions { display: flex; align-items: center; gap: 16px; }
.batch-header-actions p { color: var(--muted); font-size: 11px; }
.batch-list { display: grid; gap: 12px; padding: 16px; }
.batch-card { display: grid; grid-template-columns: minmax(300px, 42%) minmax(0, 1fr) auto; gap: 18px; align-items: center; min-height: 158px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: rgba(247,251,249,.9); }
.batch-comparison { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; min-width: 0; }
.batch-pane { position: relative; height: 132px; display: grid; place-items: center; overflow: hidden; border-radius: 10px; background: #eaf1ed; }
.batch-pane-label { position: absolute; z-index: 1; top: 8px; left: 8px; padding: 4px 7px; border-radius: 6px; color: var(--muted-strong); background: rgba(5,14,12,.72); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; }
.batch-image { display: block; max-width: 100%; max-height: 100%; object-fit: contain; }
.batch-main { min-width: 0; text-align: left; }
.batch-title { margin: 0 0 6px; overflow: hidden; color: var(--text); font-family: "Manrope", sans-serif; font-size: 13px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.batch-status { color: var(--muted); font-size: 11px; }
.batch-actions { display: flex; gap: 8px; align-items: center; }
.batch-button { min-height: 38px; padding: 0 12px; border-radius: 9px; font-size: 10px; font-weight: 700; transition: transform .15s, background .15s; }
.batch-button:hover { transform: translateY(-1px); }
.batch-button.primary { color: var(--accent-ink); background: var(--accent); }
.batch-button.secondary { border: 1px solid var(--line-strong); color: var(--text); background: #f2f8f5; }
.batch-button svg { width: 14px; height: 14px; }

.how-it-works { padding: 34px 0 110px; }
.section-heading { max-width: 620px; margin: 0 auto 42px; text-align: center; }
.section-heading h2 { margin-top: 10px; font-size: clamp(28px, 4vw, 42px); }
.section-heading p { margin: 15px auto 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.feature-grid article { min-height: 210px; padding: 28px; border: 1px solid var(--line); border-radius: var(--radius-md); background: linear-gradient(145deg, rgba(255,255,255,.96), rgba(241,248,244,.9)); box-shadow: 0 12px 32px rgba(35,81,63,.055); }
.feature-top { display: flex; align-items: center; justify-content: space-between; }
.feature-number { color: var(--accent); font-family: ui-monospace, monospace; font-size: 11px; }
.feature-icon { width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid rgba(110,231,183,.2); border-radius: 14px; color: var(--accent); background: linear-gradient(145deg, rgba(110,231,183,.12), rgba(110,231,183,.025)); font-family: "Manrope", sans-serif; font-size: 24px; line-height: 1; box-shadow: inset 0 1px rgba(255,255,255,.04); }
.feature-icon-arrow { font-size: 27px; font-weight: 500; }
.feature-grid h3 { margin: 28px 0 10px; font-family: "Manrope", sans-serif; font-size: 20px; }
.feature-grid p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.faq-section { padding: 0 0 100px; }
.faq-list { max-width: 820px; margin: 0 auto; display: grid; gap: 12px; }
.faq-list details { border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.82); box-shadow: 0 10px 28px rgba(35,81,63,.045); }
.faq-list summary { position: relative; padding: 20px 52px 20px 22px; cursor: pointer; list-style: none; font-family: "Manrope", sans-serif; font-size: 15px; font-weight: 700; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; position: absolute; right: 22px; top: 50%; translate: 0 -50%; color: var(--accent); font-size: 24px; font-weight: 500; }
.faq-list details[open] summary::after { content: "−"; }
.faq-list details p { margin: 0; padding: 0 22px 20px; color: var(--muted); font-size: 13px; line-height: 1.7; }
.independence-note { margin: 22px auto 0; color: #7a8e86; font-size: 11px; text-align: center; }

footer { border-top: 1px solid var(--line); background: rgba(237,246,241,.72); }
.footer-inner { min-height: 96px; display: flex; align-items: center; justify-content: space-between; gap: 30px; padding-block: 18px; }
.footer-inner > p { color: #6f857d; font-size: 11px; }
.footer-brand .brand-mark { width: 36px; height: 36px; }

.loading-overlay { position: fixed; z-index: 100; inset: 0; display: grid; place-items: center; align-items: center; justify-content: center; padding: 20px; background: rgba(235,244,239,.82); backdrop-filter: blur(15px); }
.loading-card { width: min(400px, calc(100vw - 40px)); display: flex; flex-direction: column; align-items: center; padding: 38px; border: 1px solid var(--line-strong); border-radius: 22px; background: var(--panel-solid); box-shadow: var(--shadow); text-align: center; }
.loading-card strong { margin-top: 16px; font-family: "Manrope", sans-serif; font-size: 15px; }
.loading-card small { max-width: 310px; margin-top: 8px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.processing-mark { position: relative; width: 48px; height: 48px; display: grid; place-items: center; border: 1px solid rgba(110,231,183,.23); border-radius: 15px; background: rgba(110,231,183,.08); }
.processing-mark::before, .processing-mark::after, .processing-mark span { content: ""; position: absolute; border-radius: 50%; background: var(--accent); }
.processing-mark::before { width: 8px; height: 8px; animation: processing-pulse 1.4s ease-in-out infinite; }
.processing-mark::after { width: 24px; height: 24px; opacity: .14; animation: processing-ring 1.4s ease-out infinite; }
.processing-mark span { width: 38px; height: 38px; opacity: .06; animation: processing-ring 1.4s .35s ease-out infinite; }
.loading-progress { position: relative; width: 100%; height: 5px; margin-top: 24px; overflow: hidden; border-radius: 999px; background: rgba(183,229,213,.1); }
.loading-progress span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #34d399, #9af3d0); transition: width .25s ease; }
.loading-progress.is-indeterminate span { animation: loading-slide 1.25s ease-in-out infinite; }
.loading-reassurance { margin: 12px 0 0; color: #6f857d; font-size: 9px; }
@keyframes processing-pulse { 0%, 100% { transform: scale(.78); opacity: .55; } 50% { transform: scale(1); opacity: 1; } }
@keyframes processing-ring { 0% { transform: scale(.4); opacity: .22; } 100% { transform: scale(1.25); opacity: 0; } }
@keyframes loading-slide { 0% { transform: translateX(-115%); } 55% { transform: translateX(115%); } 100% { transform: translateX(210%); } }

@media (max-width: 900px) {
  .result-grid { grid-template-columns: 1fr; }
  .actions-card { position: static; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-grid article { min-height: 170px; }
  .feature-grid h3 { margin-top: 24px; }
  .batch-card { grid-template-columns: 1fr; }
  .batch-actions { justify-content: flex-end; }
}

@media (max-width: 640px) {
  .shell { width: min(100% - 24px, 1180px); }
  .site-header { position: relative; }
  .header-inner { min-height: 70px; }
  .brand strong { font-size: 13px; }
  .brand small, .privacy-pill { display: none; }
  .hero { padding: 66px 0 38px; }
  .hero h1 { font-size: 42px; }
  .hero-copy { font-size: 15px; }
  .trust-row { align-items: flex-start; flex-direction: column; width: max-content; margin: 28px auto 0; gap: 12px; }
  .tool-shell { padding-bottom: 64px; }
  .upload-zone { min-height: 285px; margin: 9px; padding: 36px 18px; }
  .quality-heading { justify-content: space-between; }
  .local-note { align-items: flex-start; text-align: left; line-height: 1.5; }
  .result-section, .batch-section { padding-bottom: 72px; }
  .card-header { align-items: flex-start; flex-direction: column; }
  .meta-row { justify-content: flex-start; }
  .meta-row { grid-template-columns: 1fr; }
  .comparison-stage { min-height: 330px; padding: 10px; }
  .actions-card { padding: 24px; }
  .batch-header-actions { align-items: flex-start; flex-direction: column; gap: 8px; }
  .batch-comparison { grid-template-columns: 1fr 1fr; }
  .batch-pane { height: 112px; }
  .footer-inner { align-items: flex-start; flex-direction: column; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
