/* ============================================================
   Koloritoo — Brand tokens
   ============================================================ */
:root {
  --color-primary: #a855f7;
  --color-secondary: #ec4899;
  --color-bg: #fcf0f5;
  --color-surface: #ffffff;
  --color-text: #1a1a1a;
  --color-text-muted: #666666;
  --color-border: #e0e0e0;
  --gradient: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  --radius-sm: 12px;
  --radius-md: 24px;
  --radius-lg: 32px;
  --shadow: 0 4px 24px rgba(168, 85, 247, 0.12);
  --shadow-lg: 0 8px 48px rgba(168, 85, 247, 0.2);
}

/* ============================================================
   Reset & base
   ============================================================ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--color-primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ============================================================
   Layout helpers
   ============================================================ */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 80px 0;
}

/* ============================================================
   Navigation
   ============================================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(252, 240, 245, 0.85);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 16px;
}

.nav-logo {
  font-size: 1.25rem;
  font-weight: 700;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text-muted);
}

.nav-links a:hover {
  color: var(--color-primary);
  text-decoration: none;
}

.lang-switcher {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
}

.lang-switcher .lang-sep {
  color: var(--color-border);
}

.lang-switcher a {
  color: var(--color-text-muted);
  text-decoration: none;
}

.lang-switcher a:hover {
  color: var(--color-primary);
  text-decoration: none;
}

.lang-switcher .lang-active {
  color: var(--color-primary);
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
  border: none;
  text-decoration: none;
}

.btn:hover {
  transform: translateY(-2px);
  text-decoration: none;
}

.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: var(--shadow);
}

.btn-primary:hover {
  box-shadow: var(--shadow-lg);
}

.btn-outline {
  background: var(--color-surface);
  color: var(--color-text);
  border: 2px solid var(--color-border);
}

.btn-outline:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.btn-store {
  background: var(--color-text);
  color: #fff;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
}

.btn-store:hover {
  opacity: 0.85;
}

.btn-store svg {
  flex-shrink: 0;
}

.store-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ============================================================
   Hero
   ============================================================ */
.hero {
  padding: 100px 0 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: -50%;
  background: radial-gradient(ellipse 80% 60% at 50% 40%, rgba(168, 85, 247, 0.12), transparent 70%);
  pointer-events: none;
}

.hero-badge {
  display: inline-block;
  background: rgba(168, 85, 247, 0.1);
  color: var(--color-primary);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 6px 16px;
  border-radius: 100px;
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 20px;
}

.hero h1 .gradient-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 1.2rem;
  color: var(--color-text-muted);
  max-width: 520px;
  margin: 0 auto 40px;
}

.hero .store-buttons {
  justify-content: center;
}

.hero .screenshots {
  background: transparent;
  padding: 16px 0 0;
}

/* ============================================================
   Before / After
   ============================================================ */
.before-after {
  background: var(--color-surface);
}

.before-after h2 {
  text-align: center;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 12px;
}

.before-after .subtitle {
  text-align: center;
  color: var(--color-text-muted);
  margin-bottom: 56px;
  font-size: 1.1rem;
}

/* Before / After slider */
.ba-slider {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  cursor: default;
  -webkit-user-select: none;
  user-select: none;
  aspect-ratio: 3/2;
}

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

.ba-img--before {
  z-index: 1;
  clip-path: inset(0 50% 0 0);
}


/* Handle */
.ba-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 44px;
  cursor: col-resize;
  z-index: 10;
}

.ba-handle-bar {
  flex: 1;
  width: 2px;
  background: #fff;
  opacity: 0.85;
}

.ba-handle-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--color-primary);
}

.ba-handle:focus-visible .ba-handle-circle {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

/* Screenshots carousel */
.screenshots {
  background: var(--color-surface);
  padding: 16px 0 44px;
}

.screenshots-carousel {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 8px 0px;
}

.screenshots-track {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  gap: 16px;
  overflow-x: auto;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  scrollbar-width: none;
  padding-top: 38px;
  padding-bottom: 56px;
  margin-bottom: -56px;
}

.screenshots-track::-webkit-scrollbar {
  display: none;
}

.screenshot-item {
  flex: 0 0 calc((100% - 3 * 16px) / 4);
  scroll-snap-align: start;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  background: var(--color-bg);
}

.screenshot-item img {
  width: 100%;
  display: block;
  object-fit: cover;
}

.screenshot-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* Prev / Next buttons */
.sc-btn[hidden] {
  display: none;
}

.sc-btn {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: var(--color-surface);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
  color: var(--color-text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, opacity 0.15s ease, transform 0.15s ease;
  z-index: 2;
}

.sc-btn:hover {
  background: var(--color-primary);
  color: #fff;
  transform: scale(1.08);
}

.sc-btn:disabled {
  opacity: 0.3;
  pointer-events: none;
}

.sc-btn--prev {
  order: -1;
}

/* Dots */
.sc-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 24px;
}

.sc-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--color-border);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s ease, transform 0.2s ease;
}

.sc-dot.is-active {
  background: var(--color-primary);
  transform: scale(1.3);
}

/* ============================================================
   Features
   ============================================================ */
.features {
  background: var(--color-bg);
}

.features h2 {
  text-align: center;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 12px;
}

.features .subtitle {
  text-align: center;
  color: var(--color-text-muted);
  margin-bottom: 56px;
  font-size: 1.1rem;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

@media (max-width: 1023px) {
  .screenshot-item {
    flex: 0 0 calc((100% - 1 * 16px) / 2);
  }
}

@media (max-width: 599px) {
  .screenshots {
    padding: 40px 0 32px;
  }

  .screenshot-item {
    flex: 0 0 100%;
  }
}

.feature-card {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.feature-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-sm);
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 20px;
}

.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.feature-card p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

/* ============================================================
   How it works
   ============================================================ */
.how-it-works {
  background: var(--color-surface);
}

.how-it-works h2 {
  text-align: center;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 12px;
}

.how-it-works .subtitle {
  text-align: center;
  color: var(--color-text-muted);
  margin-bottom: 56px;
  font-size: 1.1rem;
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0;
  position: relative;
}

.steps::before {
  content: '';
  position: absolute;
  top: 40px;
  left: 16.67%;
  right: 16.67%;
  height: 2px;
  background: var(--gradient);
  opacity: 0.25;
}

.step {
  text-align: center;
  padding: 0 24px;
  position: relative;
}

.step-number {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
  font-size: 1.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  box-shadow: var(--shadow);
  position: relative;
  z-index: 1;
}

.step h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.step p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  line-height: 1.65;
}

/* ============================================================
   Download CTA
   ============================================================ */
.download-cta {
  background: var(--gradient);
  text-align: center;
  color: #fff;
  padding: 80px 0;
}

.download-cta h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 12px;
}

.download-cta p {
  font-size: 1.1rem;
  opacity: 0.85;
  margin-bottom: 40px;
}

.download-cta .store-buttons {
  justify-content: center;
}

.download-cta .btn-store {
  background: rgba(255, 255, 255, 0.15);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
}

.download-cta .btn-store:hover {
  background: rgba(255, 255, 255, 0.25);
  opacity: 1;
}

/* ============================================================
   Footer
   ============================================================ */
.footer {
  background: var(--color-text);
  color: rgba(255, 255, 255, 0.65);
  padding: 48px 0;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
}

.footer-logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
}

.footer-links {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  justify-content: center;
  list-style: none;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: #fff;
  text-decoration: none;
}

.footer-copy {
  font-size: 0.8rem;
}

/* ============================================================
   Legal pages
   ============================================================ */
.legal-page {
  padding: 80px 0;
  max-width: 760px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

.legal-page h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 8px;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.legal-page .last-updated {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: 48px;
}

.legal-page h2 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 40px 0 12px;
  color: var(--color-text);
}

.legal-page h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 24px 0 8px;
}

.legal-page p {
  color: var(--color-text-muted);
  margin-bottom: 12px;
  line-height: 1.75;
}

.legal-page ul,
.legal-page ol {
  padding-left: 24px;
  margin-bottom: 16px;
}

.legal-page li {
  color: var(--color-text-muted);
  margin-bottom: 6px;
  line-height: 1.7;
}

.legal-page a {
  color: var(--color-primary);
}

.legal-page table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 24px;
  font-size: 0.9rem;
}

.legal-page th {
  text-align: left;
  padding: 10px 14px;
  background: rgba(168, 85, 247, 0.08);
  font-weight: 600;
  color: var(--color-text);
  border-bottom: 2px solid var(--color-border);
}

.legal-page td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text-muted);
  vertical-align: top;
}

.legal-page tr:last-child td {
  border-bottom: none;
}

.legal-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text-muted);
  margin-bottom: 40px;
}

.legal-back:hover {
  color: var(--color-primary);
  text-decoration: none;
}

/* ============================================================
   FAQ pages
   ============================================================ */
.faq-page {
  max-width: 760px;
}

.faq-intro {
  margin-bottom: 12px;
}

.faq-list {
  display: grid;
  gap: 14px;
  padding: 15px 0 0 0;
}

.faq-item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  overflow: hidden;
}

.faq-item h2 {
  margin: 0;
}

.faq-question {
  width: 100%;
  border: none;
  background: transparent;
  color: var(--color-text);
  text-align: left;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  padding: 18px 52px 18px 18px;
  line-height: 1.35;
  cursor: pointer;
  position: relative;
  transition: background-color 0.2s ease;
}

.faq-question:hover {
  background: rgba(168, 85, 247, 0.05);
}

.faq-question::after {
  content: '+';
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-primary);
  font-size: 1.4rem;
  line-height: 1;
  transition: transform 0.15s ease;
}

.faq-question[aria-expanded='true']::after {
  content: '-';
}

.faq-question:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: -3px;
}

.faq-answer {
  border-top: 1px solid var(--color-border);
  padding: 12px 18px 18px;
}

.faq-answer p {
  color: var(--color-text-muted);
  line-height: 1.75;
  margin-bottom: 0;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 700px) {
  .nav-links {
    display: none;
  }

  .steps {
    grid-template-columns: 1fr;
    gap: 32px;
    padding-left: 20px;
  }

  /* repurpose the horizontal desktop line as a vertical timeline line */
  .steps::before {
    display: block;
    top: 40px;
    bottom: 40px;
    left: 60px;
    /* padding-left(20) + half circle(40) */
    right: auto;
    width: 2px;
    height: auto;
  }

  /* each step: circle on the left, title+description on the right */
  .step {
    display: grid;
    grid-template-columns: 80px 1fr;
    grid-template-rows: auto auto;
    column-gap: 20px;
    text-align: left;
    padding: 0;
  }

  .step-number {
    grid-row: 1 / 3;
    margin: 0;
    align-self: start;
  }

  section {
    padding: 60px 0;
  }

  .faq-question {
    font-size: 1.1rem;
    padding: 16px 46px 16px 16px;
  }

  .faq-answer {
    padding: 12px 16px 16px;
  }
}