/* ══════════════════════════════════════════════
   Memo++ — Shared Styles
   ══════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --primary: #6366F1;
    --primary-dark: #4F46E5;
    --primary-light: #818CF8;
    --bg-dark: #0F172A;
    --bg-hero: #1B3A5C;
    --bg-section: #F8FAFC;
    --text: #1E293B;
    --text-light: #64748B;
    --text-white: #F1F5F9;
    --accent-green: #22C55E;
    --accent-orange: #F97316;
    --accent-blue: #3B82F6;
    --accent-rose: #EC4899;
    --radius: 16px;
    --shadow: 0 4px 24px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 40px rgba(0,0,0,0.12);
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    background: white;
}

/* ── Lucide icon sizing ── */
.hero-chip i[data-lucide] { width: 16px; height: 16px; stroke-width: 2; }
.feature-icon i[data-lucide] { width: 24px; height: 24px; stroke-width: 1.8; }
.phone-card-icon i[data-lucide] { width: 16px; height: 16px; stroke-width: 2; }
.vocal-bubble i[data-lucide],
.vocal-response i[data-lucide] { width: 16px; height: 16px; stroke-width: 2; display: inline; vertical-align: -2px; }
.vocal-check i[data-lucide] { width: 14px; height: 14px; stroke-width: 2.5; }
.rgpd-card-icon i[data-lucide] { width: 22px; height: 22px; stroke-width: 1.8; }
.support-icon i[data-lucide] { width: 28px; height: 28px; stroke-width: 1.8; }
.btn-donate i[data-lucide] { width: 18px; height: 18px; stroke-width: 2; display: inline; vertical-align: -3px; }
.nav-mobile-btn i[data-lucide] { width: 24px; height: 24px; stroke-width: 2; }
.toc-icon i[data-lucide] { width: 18px; height: 18px; stroke-width: 2; }
.section-icon i[data-lucide] { width: 24px; height: 24px; stroke-width: 1.8; }
.tip-box i[data-lucide],
.warn-box i[data-lucide] { width: 16px; height: 16px; stroke-width: 2; display: inline; vertical-align: -3px; }
.toc-card > h2 > i[data-lucide] { width: 20px; height: 20px; stroke-width: 2; display: inline; vertical-align: -3px; }
.vocal-example i[data-lucide] { width: 16px; height: 16px; stroke-width: 2; flex-shrink: 0; margin-top: 3px; color: var(--primary); }

/* ── NAV ── */
nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    background: rgba(15, 23, 42, 0.88);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255,255,255,0.08);
    transition: background 0.3s;
}
.nav-inner {
    max-width: 900px; margin: 0 auto;
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 24px;
}
.nav-inner.nav-wide { max-width: 1200px; }
.nav-logo {
    display: flex; align-items: center; gap: 10px;
    text-decoration: none; color: white; font-weight: 700; font-size: 1.25rem;
}
.nav-logo img { border-radius: 8px; }
.nav-links { display: flex; gap: 28px; list-style: none; }
.nav-links a {
    color: var(--text-white); text-decoration: none; font-size: 0.9rem;
    font-weight: 500; opacity: 0.8; transition: opacity 0.2s;
}
.nav-links a:hover { opacity: 1; }
.nav-links a.active {
    opacity: 1;
    border-bottom: 2px solid var(--primary-light);
    padding-bottom: 2px;
}
.nav-right { display: flex; align-items: center; gap: 12px; }
.nav-cta {
    background: var(--primary); color: white; border: none; padding: 8px 20px;
    border-radius: 8px; font-weight: 600; font-size: 0.9rem; cursor: pointer;
    text-decoration: none; transition: background 0.2s;
}
.nav-cta:hover { background: var(--primary-dark); }
.nav-lang {
    color: var(--text-white); opacity: 0.6; text-decoration: none;
    font-size: 0.8rem; font-weight: 600; letter-spacing: 0.05em;
    padding: 4px 10px; border: 1px solid rgba(255,255,255,0.2);
    border-radius: 6px; transition: all 0.2s;
}
.nav-lang:hover { opacity: 1; border-color: rgba(255,255,255,0.4); }
.nav-mobile-btn {
    display: none; background: none; border: none; color: white;
    font-size: 1.5rem; cursor: pointer;
}

/* ── FOOTER ── */
footer {
    background: var(--bg-dark); padding: 48px 24px 32px;
    border-top: 1px solid rgba(255,255,255,0.06);
}
.footer-inner {
    max-width: 1200px; margin: 0 auto;
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 24px;
}
.footer-brand {
    display: flex; align-items: center; gap: 10px;
    color: white; font-weight: 700; font-size: 1.1rem;
}
.footer-brand img { border-radius: 8px; }
.footer-links { display: flex; gap: 24px; list-style: none; }
.footer-links a {
    color: var(--text-white); opacity: 0.6; text-decoration: none;
    font-size: 0.9rem; transition: opacity 0.2s;
}
.footer-links a:hover { opacity: 1; }
.footer-copy { color: var(--text-white); opacity: 0.4; font-size: 0.8rem; }
.footer-copy a { color: var(--primary-light); text-decoration: none; }

.simple-footer {
    background: var(--bg-dark); padding: 32px 24px; text-align: center;
}
.simple-footer p {
    color: var(--text-white); opacity: 0.6; font-size: 0.85rem;
}
.simple-footer a {
    color: var(--primary-light); text-decoration: none;
}
.simple-footer a:hover { text-decoration: underline; }

/* ── TOAST ── */
.toast {
    position: fixed; bottom: 32px; left: 50%; transform: translateX(-50%) translateY(80px);
    background: var(--bg-dark); color: white; padding: 14px 28px;
    border-radius: 12px; font-size: 0.95rem; font-weight: 500;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3); z-index: 200;
    opacity: 0; transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none; border: 1px solid rgba(255,255,255,0.1);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── ANIMATIONS ── */
.fade-up {
    opacity: 0; transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible { opacity: 1; transform: translateY(0); }

/* Staggered children (feature cards, rgpd cards) */
.fade-up-stagger > * {
    opacity: 0; transform: translateY(24px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}
.fade-up-stagger.visible > * { opacity: 1; transform: translateY(0); }
.fade-up-stagger.visible > *:nth-child(1) { transition-delay: 0s; }
.fade-up-stagger.visible > *:nth-child(2) { transition-delay: 0.08s; }
.fade-up-stagger.visible > *:nth-child(3) { transition-delay: 0.16s; }
.fade-up-stagger.visible > *:nth-child(4) { transition-delay: 0.24s; }
.fade-up-stagger.visible > *:nth-child(5) { transition-delay: 0.32s; }
.fade-up-stagger.visible > *:nth-child(6) { transition-delay: 0.4s; }
.fade-up-stagger.visible > *:nth-child(7) { transition-delay: 0.48s; }
.fade-up-stagger.visible > *:nth-child(8) { transition-delay: 0.56s; }
.fade-up-stagger.visible > *:nth-child(9) { transition-delay: 0.64s; }
.fade-up-stagger.visible > *:nth-child(10) { transition-delay: 0.72s; }
.fade-up-stagger.visible > *:nth-child(11) { transition-delay: 0.8s; }
.fade-up-stagger.visible > *:nth-child(12) { transition-delay: 0.88s; }
.fade-up-stagger.visible > *:nth-child(13) { transition-delay: 0.96s; }

/* Slide-in from left / right */
.slide-left {
    opacity: 0; transform: translateX(-40px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.slide-right {
    opacity: 0; transform: translateX(40px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.slide-left.visible, .slide-right.visible { opacity: 1; transform: translateX(0); }

/* Gentle float (for hero visual) */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}
.float { animation: float 4s ease-in-out infinite; }

/* Scale-in (for support icon) */
.scale-in {
    opacity: 0; transform: scale(0.7);
    transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.scale-in.visible { opacity: 1; transform: scale(1); }

/* Shimmer line (decorative) */
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.shimmer {
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.08) 50%, transparent 100%);
    background-size: 200% 100%;
    animation: shimmer 3s ease-in-out infinite;
}

/* Hero chip hover */
.hero-chip {
    transition: all 0.25s ease;
}
.hero-chip:hover {
    background: rgba(255,255,255,0.15);
    transform: translateY(-2px);
}

/* Vocal bubble sequential appear */
.vocal-bubble, .vocal-response {
    opacity: 0; transform: translateY(12px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}
.vocal-demo.visible .vocal-bubble,
.vocal-demo.visible .vocal-response { opacity: 1; transform: translateY(0); }
.vocal-demo.visible .vocal-bubble:nth-of-type(1) { transition-delay: 0.2s; }
.vocal-demo.visible .vocal-response:nth-of-type(1) { transition-delay: 0.5s; }
.vocal-demo.visible .vocal-bubble:nth-of-type(2) { transition-delay: 0.9s; }
.vocal-demo.visible .vocal-response:nth-of-type(2) { transition-delay: 1.2s; }
.vocal-demo.visible .vocal-bubble:nth-of-type(3) { transition-delay: 1.6s; }
.vocal-demo.visible .vocal-response:nth-of-type(3) { transition-delay: 1.9s; }
.vocal-demo.visible .vocal-bubble:nth-of-type(4) { transition-delay: 2.3s; }
.vocal-demo.visible .vocal-response:nth-of-type(4) { transition-delay: 2.6s; }

/* Heart pulse on support icon */
@keyframes heart-pulse {
    0%, 100% { transform: scale(1); }
    15% { transform: scale(1.15); }
    30% { transform: scale(1); }
    45% { transform: scale(1.1); }
    60% { transform: scale(1); }
}
.support-icon.visible { animation: heart-pulse 2.5s ease-in-out infinite 0.5s; }

/* Nav scroll shadow */
nav.scrolled {
    background: rgba(15, 23, 42, 0.95);
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

/* ── SECTION HEADERS ── */
.section-inner { max-width: 1200px; margin: 0 auto; }
.section-header { text-align: center; margin-bottom: 64px; }
.section-label {
    display: inline-block; font-size: 0.85rem; font-weight: 600;
    color: var(--primary); text-transform: uppercase; letter-spacing: 0.1em;
    margin-bottom: 12px;
}
.section-header h2 {
    font-size: 2.4rem; font-weight: 800; line-height: 1.2;
    margin-bottom: 16px;
}
.section-header p {
    font-size: 1.1rem; color: var(--text-light); max-width: 600px; margin: 0 auto;
}

/* ── PAGE HEADER (guide, privacy) ── */
.page-header {
    background: linear-gradient(135deg, var(--bg-dark) 0%, var(--bg-hero) 100%);
    padding: 120px 24px 60px; text-align: center;
}
.page-header h1 {
    font-size: 2.4rem; font-weight: 800; color: white; margin-bottom: 12px;
}
.page-header p {
    font-size: 1.1rem; color: var(--text-white); opacity: 0.8;
    max-width: 600px; margin: 0 auto;
}

/* ── BUTTONS ── */
.btn-primary {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--primary); color: white; padding: 14px 28px;
    border-radius: 12px; font-weight: 600; font-size: 1rem;
    text-decoration: none; transition: all 0.2s; border: none; cursor: pointer;
}
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(99,102,241,0.3); }
.btn-secondary {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(255,255,255,0.1); color: white; padding: 14px 28px;
    border-radius: 12px; font-weight: 600; font-size: 1rem;
    text-decoration: none; border: 1px solid rgba(255,255,255,0.2);
    transition: all 0.2s; cursor: pointer;
}
.btn-secondary:hover { background: rgba(255,255,255,0.15); transform: translateY(-2px); }

/* ── RESPONSIVE BASE ── */
@media (max-width: 968px) {
    .section-header h2 { font-size: 2rem; }
    .footer-inner { flex-direction: column; text-align: center; }
}
@media (max-width: 640px) {
    .page-header { padding: 100px 16px 48px; }
    .page-header h1 { font-size: 1.8rem; }
    .nav-links { display: none; }
    .nav-mobile-btn { display: block; }
    .nav-links.show {
        display: flex !important; flex-direction: column;
        position: absolute; top: 100%; left: 0; right: 0;
        background: rgba(15,23,42,0.95); padding: 16px 24px;
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }
    .footer-inner { flex-direction: column; text-align: center; }
}
