/* FixMyPhotos — fixmyphotos.app
   Brand: purple→coral gradient (#A12DB4 → #FF6857) on deep purple, from the app theme. */

:root {
  --bg: #120a1e;
  --bg-2: #1b1030;
  --surface: rgba(255, 255, 255, 0.05);
  --surface-border: rgba(255, 255, 255, 0.10);
  --text: #f3eefc;
  --text-dim: #b9aed0;
  --grad-a: #a12db4;
  --grad-b: #ff6857;
  --grad: linear-gradient(100deg, var(--grad-a), var(--grad-b));
  --radius: 20px;
  --container: 1120px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.container.narrow { max-width: 760px; }
.center { text-align: center; }

.grad {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.grad-animated {
  background: linear-gradient(100deg, var(--grad-a), var(--grad-b), #ffb86b, var(--grad-a));
  background-size: 300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradShift 6s linear infinite;
}
@keyframes gradShift {
  to { background-position: 300% 0; }
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(18, 10, 30, 0.75);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--surface-border);
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: none;
}
.brand img { border-radius: 9px; }

.nav-links {
  display: flex;
  gap: 24px;
  margin-left: auto;
}
.nav-links a {
  text-decoration: none;
  color: var(--text-dim);
  font-size: 0.95rem;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

.btn-primary {
  background: var(--grad);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 10px 22px;
  border-radius: 30px;
  transition: transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 4px 18px rgba(161, 45, 180, 0.35);
  white-space: nowrap;
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 24px rgba(255, 104, 87, 0.4); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 84px 0 96px;
  background: var(--bg-2);
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 120px;
  background: linear-gradient(transparent, var(--bg));
  pointer-events: none;
  z-index: 2;
}

/* Drifting gradient blobs */
.blob {
  position: absolute;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
  pointer-events: none;
  will-change: transform;
}
.blob-a {
  background: radial-gradient(circle, rgba(161, 45, 180, 0.55), transparent 65%);
  top: -220px;
  left: -120px;
  animation: drift 16s ease-in-out infinite alternate;
}
.blob-b {
  background: radial-gradient(circle, rgba(255, 104, 87, 0.35), transparent 65%);
  top: -80px;
  right: -180px;
  animation: drift 20s ease-in-out infinite alternate-reverse;
}
@keyframes drift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(90px, 60px) scale(1.15); }
}

/* Twinkling sparkles */
.sparkles span {
  position: absolute;
  color: #ffd9f4;
  font-size: 14px;
  opacity: 0;
  animation: twinkle 3.2s ease-in-out infinite;
  pointer-events: none;
}
@keyframes twinkle {
  0%, 100% { opacity: 0; transform: scale(0.6); }
  50% { opacity: 0.9; transform: scale(1.2); }
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
  position: relative;
  z-index: 3;
}

.eyebrow {
  color: var(--grad-b);
  font-weight: 600;
  letter-spacing: 0.04em;
  font-size: 0.9rem;
  margin-bottom: 14px;
}

h1 {
  font-size: clamp(2.3rem, 5vw, 3.6rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-weight: 800;
  margin-bottom: 18px;
}

.lead {
  color: var(--text-dim);
  font-size: 1.15rem;
  max-width: 34em;
  margin-bottom: 30px;
}

/* Ratings / proof bar */
.proof-bar {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 34px;
  margin-top: 26px;
}
.proof-bar li { display: flex; flex-direction: column; line-height: 1.3; }
.proof-bar strong { font-size: 1.25rem; font-weight: 800; }
.proof-bar span { color: var(--text-dim); font-size: 0.8rem; }

/* Store badges */
.store-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.store-badges.center { justify-content: center; }

.store-badge {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  color: #14101c;
  text-decoration: none;
  border-radius: 14px;
  padding: 10px 20px;
  transition: transform 0.15s, box-shadow 0.15s;
}
.store-badge:hover { transform: translateY(-2px); box-shadow: 0 8px 26px rgba(0, 0, 0, 0.45); }
.store-badge svg { width: 26px; height: 26px; flex: none; }
.store-badge span { display: flex; flex-direction: column; line-height: 1.2; font-weight: 700; font-size: 1.05rem; }
.store-badge small { font-size: 0.62rem; font-weight: 600; letter-spacing: 0.06em; color: #6b6478; }

/* Demo tabs */
.demo-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.demo-tab {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text-dim);
  padding: 8px 18px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  transition: color 0.2s, border-color 0.2s, background 0.2s, transform 0.15s;
}
.demo-tab:hover { color: var(--text); transform: translateY(-1px); }
.demo-tab.active {
  background: var(--grad);
  border-color: transparent;
  color: #fff;
}

/* ---------- Compare slider ---------- */
.compare {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 3 / 2;
  user-select: none;
  -webkit-user-select: none;
  touch-action: pan-y;
  background: var(--surface);
  isolation: isolate;
}
.compare.switching img { opacity: 0; }
.compare img { transition: opacity 0.25s ease; }

.compare-hero {
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.55), 0 0 0 1px var(--surface-border);
}

.compare img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.compare-before {
  clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0);
  z-index: 2;
}

.compare-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos, 50%);
  width: 3px;
  background: #fff;
  transform: translateX(-50%);
  z-index: 3;
  pointer-events: none;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.5);
}
.compare-handle span {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: #fff;
  color: #14101c;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: -1px;
}

.compare-label {
  position: absolute;
  top: 12px;
  z-index: 3;
  background: rgba(10, 6, 18, 0.65);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  pointer-events: none;
  backdrop-filter: blur(4px);
}
.label-before { left: 12px; }
.label-after { right: 12px; }

.compare-range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: ew-resize;
  z-index: 4;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
}

.demo-hint {
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
  margin-top: 14px;
}

/* ---------- Results marquee ---------- */
.marquee-section { padding: 48px 0 8px; }

.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.marquee-track {
  display: flex;
  gap: 18px;
  width: max-content;
  animation: marquee 48s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee {
  to { transform: translateX(-50%); }
}

.marquee-card {
  position: relative;
  width: 260px;
  flex: none;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--surface-border);
}
.marquee-card > img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.marquee-card .thumb {
  position: absolute;
  left: 10px;
  bottom: 10px;
  width: 74px;
  border-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.85);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  filter: saturate(0.9);
}
.marquee-card .tag {
  position: absolute;
  right: 10px;
  bottom: 10px;
  background: rgba(10, 6, 18, 0.7);
  backdrop-filter: blur(4px);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
}

/* ---------- Sections ---------- */
section { padding: 90px 0; }

.section-title {
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 14px;
}

.section-sub {
  text-align: center;
  color: var(--text-dim);
  margin-bottom: 48px;
}

/* Features */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  margin-top: 40px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius);
  padding: 14px 14px 22px;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.feature-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 104, 87, 0.35);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35);
}
.feature-card .compare { border-radius: 12px; margin-bottom: 16px; }
.feature-card h3 { font-size: 1.1rem; margin: 0 6px 6px; }
.feature-card p { color: var(--text-dim); font-size: 0.92rem; margin: 0 6px; }

/* How it works */
.how {
  background:
    radial-gradient(600px 380px at 50% 0%, rgba(161, 45, 180, 0.14), transparent 70%),
    var(--bg);
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  margin-top: 46px;
}

.step {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius);
  padding: 34px 28px;
  text-align: center;
}
.step-num {
  width: 46px;
  height: 46px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: var(--grad);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.15rem;
  color: #fff;
}
.step h3 { margin-bottom: 8px; font-size: 1.15rem; }
.step p { color: var(--text-dim); font-size: 0.95rem; }

/* FAQ */
.faq details {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 14px;
  padding: 20px 24px;
  margin-bottom: 14px;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 1.05rem;
  list-style: none;
  position: relative;
  padding-right: 32px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.4rem;
  color: var(--grad-b);
  transition: transform 0.2s;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { margin-top: 12px; color: var(--text-dim); }
.faq details a { color: var(--grad-b); }

/* Final CTA */
.cta {
  background:
    radial-gradient(640px 400px at 50% 110%, rgba(255, 104, 87, 0.2), transparent 70%),
    radial-gradient(640px 400px at 50% -30%, rgba(161, 45, 180, 0.22), transparent 70%),
    var(--bg-2);
}
.cta-icon {
  border-radius: 22px;
  margin: 0 auto 26px;
  box-shadow: 0 14px 44px rgba(161, 45, 180, 0.45);
  animation: float 5s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
.cta .section-title { margin-bottom: 34px; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--surface-border);
  padding: 34px 0;
}
.footer-grid {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
}
.footer-brand img { border-radius: 7px; }
.footer-links {
  display: flex;
  gap: 22px;
  margin-left: auto;
  flex-wrap: wrap;
}
.footer-links a {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 0.88rem;
}
.footer-links a:hover { color: var(--text); }
.footer-copy {
  width: 100%;
  color: var(--text-dim);
  font-size: 0.8rem;
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .blob, .sparkles span, .cta-icon, .grad-animated { animation: none !important; }
  .marquee-track { animation: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero { padding: 52px 0 70px; }
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}

@media (max-width: 560px) {
  section { padding: 64px 0; }
  .feature-grid { grid-template-columns: 1fr; }
  .store-badge { flex: 1; justify-content: center; }
  .marquee-card { width: 210px; }
  .proof-bar { gap: 8px 24px; }
}
