/* ══════════════════════════════════════════════
   DKPhotoSorter — Shared Styles
   ══════════════════════════════════════════════ */

/* ── Custom Properties ───────────────────────── */
:root {
  --bg: #0a0b0d;
  --bg-card: #111318;
  --bg-card-hover: #161922;
  --surface: #1a1d25;
  --border: #2a2d38;
  --text: #e8e9ed;
  --text-secondary: #8b8fa3;
  --accent: #3b82f6;
  --accent-glow: rgba(59, 130, 246, 0.15);
  --accent-green: #22c55e;
  --accent-amber: #f59e0b;
  --accent-rose: #f43f5e;
  --accent-purple: #a78bfa;
  --radius: 12px;
  --radius-lg: 20px;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ── Utility ─────────────────────────────────── */
.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 100px;
  background: var(--accent-glow);
  color: var(--accent);
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.section-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

/* ── Buttons ─────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'DM Sans', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  padding: 16px 36px;
  border-radius: 100px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.3), 0 4px 20px rgba(59, 130, 246, 0.25);
}
.btn-primary:hover {
  background: #4f8ff7;
  transform: translateY(-2px);
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15), 0 8px 30px rgba(59, 130, 246, 0.35);
}

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--text-secondary);
  transform: translateY(-2px);
}

.btn-sm {
  font-size: 0.92rem;
  padding: 10px 24px;
}

/* ── Navbar ──────────────────────────────────── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 16px 0;
  background: rgba(10, 11, 13, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(42, 45, 56, 0.5);
  transition: background 0.3s;
}

nav.nav-scrolled {
  background: rgba(10, 11, 13, 0.95);
}

nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--text);
  text-decoration: none;
}

.nav-logo svg {
  width: 28px;
  height: 28px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }
.nav-links a.nav-active { color: var(--text); }

.nav-cta {
  background: #fff;
  color: #0a0b0d;
  padding: 10px 22px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.88rem;
  transition: all 0.3s;
}
.nav-cta:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-1px);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: 8px;
}

.mobile-menu {
  display: none;
  position: fixed;
  top: 61px;
  left: 0;
  right: 0;
  background: rgba(10, 11, 13, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 24px;
  z-index: 99;
  transform: translateY(-10px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-menu.open {
  display: flex;
  flex-direction: column;
  gap: 4px;
  transform: translateY(0);
  opacity: 1;
}

.mobile-menu a {
  display: block;
  padding: 14px 16px;
  color: var(--text-secondary);
  font-size: 1rem;
  font-weight: 500;
  border-radius: 8px;
  transition: all 0.2s;
}
.mobile-menu a:hover {
  color: var(--text);
  background: var(--surface);
}
.mobile-menu a.nav-active {
  color: var(--text);
}
.mobile-menu .nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
  text-align: center;
}

/* ── Footer ──────────────────────────────────── */
footer {
  padding: 56px 0 40px;
  border-top: 1px solid var(--border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-brand p {
  color: var(--text-secondary);
  font-size: 0.88rem;
  line-height: 1.6;
  max-width: 280px;
}

.footer-col h4 {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
  margin-bottom: 16px;
}

.footer-col ul { list-style: none; }

.footer-col li { margin-bottom: 10px; }

.footer-col a {
  color: var(--text-secondary);
  font-size: 0.88rem;
  transition: color 0.2s;
}
.footer-col a:hover { color: var(--text); }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.82rem;
}

/* ── Section Headers ─────────────────────────── */
.section-header {
  text-align: center;
  margin-bottom: 72px;
}

.section-header h2 {
  font-family: 'Fraunces', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  max-width: 560px;
  margin: 0 auto;
}

/* ── Cards ───────────────────────────────────── */
.card {
  padding: 32px 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all 0.3s;
}

.card:hover {
  border-color: rgba(59, 130, 246, 0.25);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.card-lg {
  border-radius: var(--radius-lg);
  padding: 36px 32px;
}

/* ── Feature Icons ───────────────────────────── */
.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  font-size: 1.3rem;
}

.fi-blue { background: rgba(59, 130, 246, 0.12); color: var(--accent); }
.fi-green { background: rgba(34, 197, 94, 0.12); color: var(--accent-green); }
.fi-amber { background: rgba(245, 158, 11, 0.12); color: var(--accent-amber); }
.fi-rose { background: rgba(244, 63, 94, 0.12); color: var(--accent-rose); }
.fi-purple { background: rgba(167, 139, 250, 0.12); color: var(--accent-purple); }

/* ── App Mockup Frame ────────────────────────── */
.app-mockup {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.app-mockup-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.app-mockup-bar .dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.app-mockup-bar .dot:nth-child(1) { background: var(--accent-rose); }
.app-mockup-bar .dot:nth-child(2) { background: var(--accent-amber); }
.app-mockup-bar .dot:nth-child(3) { background: var(--accent-green); }

.app-mockup-bar .title {
  flex: 1;
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-secondary);
  font-family: 'JetBrains Mono', monospace;
}

.app-mockup-screen {
  aspect-ratio: 16 / 9;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9rem;
}

/* App screenshot styling */
.app-screenshot {
  width: 100%;
  display: block;
  border-radius: var(--radius);
}

.screenshot-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  opacity: 0.4;
}

.screenshot-placeholder svg {
  width: 48px;
  height: 48px;
}

/* ── Folder Tree Demo ────────────────────────── */
.folder-tree {
  padding: 24px 28px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.84rem;
  line-height: 2;
}

.folder-tree .dir { color: var(--accent); }
.folder-tree .file { color: var(--text-secondary); }
.folder-tree .arrow { color: var(--text-secondary); opacity: 0.5; }

/* ── Pricing Cards ───────────────────────────── */
.pricing-card {
  padding: 40px 36px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  position: relative;
}

.pricing-card.featured {
  border-color: var(--accent);
  box-shadow: 0 0 60px rgba(59, 130, 246, 0.1);
}

.pricing-card.featured::before {
  content: 'RECOMMENDED';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  padding: 4px 16px;
  background: var(--accent);
  color: #fff;
  border-radius: 100px;
  font-weight: 500;
}

.pricing-list {
  list-style: none;
  margin-bottom: 28px;
}

.pricing-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
  font-size: 0.92rem;
  color: var(--text-secondary);
}

.pricing-list li svg {
  width: 18px;
  height: 18px;
  color: var(--accent-green);
  flex-shrink: 0;
  margin-top: 2px;
}

/* ── Privacy Diagram ─────────────────────────── */
.privacy-diagram-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.privacy-diagram-item:last-child { border-bottom: none; }

.privacy-diagram-item .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.privacy-diagram-item .label {
  flex: 1;
  font-size: 0.92rem;
}

.privacy-diagram-item .status {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 6px;
  white-space: nowrap;
}

.stays-local { color: var(--accent-green); background: rgba(34, 197, 94, 0.1); }
.sent-encrypted, .sent-https { color: var(--accent-amber); background: rgba(245, 158, 11, 0.1); }

/* ── Format Pills ────────────────────────────── */
.format-pill {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.82rem;
  font-weight: 500;
  padding: 10px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 100px;
  color: var(--text-secondary);
  transition: all 0.2s;
}
.format-pill:hover {
  border-color: var(--accent);
  color: var(--text);
}
.format-pill.highlight-pill {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

/* ── FAQ Accordion ───────────────────────────── */
.faq-item {
  border-bottom: 1px solid var(--border);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  font-size: 1.05rem;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
  color: var(--text);
  transition: color 0.2s;
}
.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: '+';
  font-size: 1.4rem;
  font-weight: 300;
  color: var(--text-secondary);
  transition: transform 0.3s;
}

.faq-item[open] summary::after {
  content: '\2212';
  transform: rotate(180deg);
}

.faq-item summary:hover { color: var(--accent); }

.faq-item .faq-answer {
  padding: 0 0 20px;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
}

.faq-item .faq-answer a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.faq-item .faq-answer a:hover { color: #4f8ff7; }

/* ── Prose (Content Pages) ───────────────────── */
.prose {
  max-width: 720px;
  margin: 0 auto;
  font-size: 1.02rem;
  line-height: 1.8;
  color: var(--text-secondary);
}

.prose h2 {
  font-family: 'Fraunces', serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  margin: 48px 0 16px;
  letter-spacing: -0.01em;
}

.prose h3 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text);
  margin: 32px 0 12px;
}

.prose p {
  margin-bottom: 16px;
}

.prose ul, .prose ol {
  margin: 12px 0 20px 24px;
}

.prose li {
  margin-bottom: 8px;
}

.prose a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.prose a:hover { color: #4f8ff7; }

.prose strong { color: var(--text); }

.prose .callout {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin: 24px 0;
}

.prose .callout-warning {
  border-left: 3px solid var(--accent-amber);
}

.prose .callout-important {
  border-left: 3px solid var(--accent-rose);
  background: rgba(244, 63, 94, 0.05);
}

.prose .callout-green {
  border-left: 3px solid var(--accent-green);
  background: rgba(34, 197, 94, 0.05);
}

/* ── Page Headers (Inner Pages) ──────────────── */
.page-hero {
  padding: 140px 0 60px;
  text-align: center;
}

.page-hero h1 {
  font-family: 'Fraunces', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.page-hero p {
  color: var(--text-secondary);
  font-size: 1.05rem;
}

.page-hero .breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.page-hero .breadcrumb a {
  color: var(--accent);
  text-decoration: none;
}
.page-hero .breadcrumb a:hover { text-decoration: underline; }

/* ── Animations ──────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes typeIn {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes pulse {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

/* ── Scroll Reveal ───────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children */
.reveal-stagger > .reveal:nth-child(1) { transition-delay: 0.05s; }
.reveal-stagger > .reveal:nth-child(2) { transition-delay: 0.10s; }
.reveal-stagger > .reveal:nth-child(3) { transition-delay: 0.15s; }
.reveal-stagger > .reveal:nth-child(4) { transition-delay: 0.20s; }
.reveal-stagger > .reveal:nth-child(5) { transition-delay: 0.25s; }
.reveal-stagger > .reveal:nth-child(6) { transition-delay: 0.30s; }
.reveal-stagger > .reveal:nth-child(7) { transition-delay: 0.35s; }
.reveal-stagger > .reveal:nth-child(8) { transition-delay: 0.40s; }
.reveal-stagger > .reveal:nth-child(9) { transition-delay: 0.45s; }

/* ── Responsive ──────────────────────────────── */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .mobile-menu-btn { display: block; }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}

@media (max-width: 600px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
}
