/* Zenly Clone — landing & content pages
   Design tokens match the app theme: warm yellow + white. */

:root {
    --primary: #FFC312;
    --primary-dark: #C9990E;
    --bg: #FFFAF0;
    --surface: #FFFFFF;
    --text: #1F1B16;
    --muted: #6B6359;
    --border: #EDE6DA;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
    --shadow-strong: 0 16px 48px rgba(0, 0, 0, 0.12);
    --radius: 18px;
    --max-width: 1100px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #161310;
        --surface: #221E18;
        --text: #F4F0E8;
        --muted: #9F968A;
        --border: #332C24;
        --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    }
}

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

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC",
                 "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI",
                 Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
}

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

/* ---- Layout ---------------------------------------------------------- */

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* ---- Header --------------------------------------------------------- */

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: color-mix(in srgb, var(--bg) 88%, transparent);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid var(--border);
}

.site-header .inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 18px;
}

.logo-mark {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 800;
    box-shadow: 0 4px 12px rgba(255, 195, 18, 0.4);
}

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

.nav a {
    color: var(--muted);
    font-size: 14px;
    font-weight: 500;
    transition: color 0.15s;
}

.nav a:hover {
    color: var(--text);
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--primary);
    color: #1F1B16;
    border-radius: 999px;
    font-weight: 600;
    font-size: 14px;
    transition: transform 0.15s, box-shadow 0.15s;
    box-shadow: 0 4px 12px rgba(255, 195, 18, 0.35);
    border: none;
    cursor: pointer;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(255, 195, 18, 0.5);
}

.btn-ghost {
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    box-shadow: none;
}

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

/* ---- Hero ---------------------------------------------------------- */

.hero {
    padding: 80px 0 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(60% 50% at 50% 0%, rgba(255, 195, 18, 0.18) 0%, transparent 100%);
    z-index: -1;
}

.hero h1 {
    font-size: clamp(40px, 6vw, 68px);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.05;
    margin-bottom: 20px;
    background: linear-gradient(180deg, var(--text), color-mix(in srgb, var(--text) 70%, var(--primary)));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero p {
    font-size: clamp(16px, 2vw, 20px);
    color: var(--muted);
    max-width: 640px;
    margin: 0 auto 36px;
}

.hero-cta {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 60px;
}

.hero-mock {
    display: flex;
    justify-content: center;
    margin-top: 20px;
    perspective: 1500px;
}

.phone-frame {
    width: 280px;
    aspect-ratio: 9 / 19;
    border-radius: 38px;
    background: var(--surface);
    border: 8px solid #1F1B16;
    box-shadow: var(--shadow-strong);
    overflow: hidden;
    transform: rotateY(-8deg) rotateX(4deg);
    transition: transform 0.5s;
    position: relative;
}

.phone-frame:hover {
    transform: rotateY(0) rotateX(0);
}

.phone-screen {
    height: 100%;
    background:
        linear-gradient(180deg,
            rgba(255, 195, 18, 0.10) 0%,
            rgba(255, 195, 18, 0.02) 40%,
            transparent 100%),
        repeating-linear-gradient(0deg, var(--border) 0 1px, transparent 1px 60px),
        repeating-linear-gradient(90deg, var(--border) 0 1px, transparent 1px 60px),
        var(--surface);
    position: relative;
    padding: 40px 16px 16px;
}

/* Fake notch */
.phone-screen::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 24px;
    background: #1F1B16;
    border-radius: 16px;
}

.phone-bubble {
    position: absolute;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border: 3px solid var(--surface);
    color: white;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
    animation: pulse 2.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.06); }
}

.phone-bubble:nth-child(1) { top: 80px; left: 28%; animation-delay: 0s; }
.phone-bubble:nth-child(2) { top: 120px; right: 22%; background: linear-gradient(135deg, #EE5A6F, #C73855); animation-delay: 0.5s; }
.phone-bubble:nth-child(3) { top: 200px; left: 38%; background: linear-gradient(135deg, #6C5CE7, #483FA8); animation-delay: 1s; }
.phone-bubble:nth-child(4) { top: 260px; right: 30%; background: linear-gradient(135deg, #00B894, #007F66); animation-delay: 1.5s; }

.phone-sheet {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--surface);
    border-top: 1px solid var(--border);
    border-radius: 24px 24px 0 0;
    padding: 16px;
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.08);
}

.phone-sheet .handle {
    width: 32px;
    height: 4px;
    background: var(--border);
    border-radius: 2px;
    margin: 0 auto 12px;
}

.phone-sheet .row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 12px;
}

.phone-sheet .row .avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    flex-shrink: 0;
}

.phone-sheet .row .name {
    font-weight: 600;
    color: var(--text);
}

.phone-sheet .row .meta {
    color: var(--muted);
    font-size: 10px;
}

/* ---- Features ----------------------------------------------------- */

section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
}

.section-title p {
    color: var(--muted);
    font-size: 16px;
}

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

.feature {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    transition: transform 0.2s, box-shadow 0.2s;
}

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

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: color-mix(in srgb, var(--primary) 25%, transparent);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    font-size: 24px;
}

.feature h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
}

.feature p {
    color: var(--muted);
    font-size: 14px;
}

/* ---- Download ----------------------------------------------------- */

.download {
    background: var(--surface);
    border-radius: 32px;
    padding: clamp(40px, 6vw, 80px);
    text-align: center;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.download h2 {
    font-size: clamp(24px, 4vw, 36px);
    font-weight: 800;
    margin-bottom: 12px;
}

.download p {
    color: var(--muted);
    margin-bottom: 32px;
}

.store-badges {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.store-badge {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 12px 22px;
    background: #1F1B16;
    color: white;
    border-radius: 12px;
    transition: transform 0.15s, opacity 0.15s;
}

.store-badge:hover { transform: translateY(-2px); }
.store-badge.disabled { opacity: 0.4; cursor: not-allowed; }
.store-badge.disabled:hover { transform: none; }

.store-badge-icon {
    font-size: 26px;
}

.store-badge-text {
    text-align: left;
    line-height: 1.2;
}

.store-badge-text small {
    display: block;
    font-size: 10px;
    opacity: 0.7;
    margin-bottom: 2px;
}

.store-badge-text strong {
    font-size: 16px;
    font-weight: 700;
}

/* ---- Footer ------------------------------------------------------- */

.site-footer {
    padding: 40px 0 60px;
    text-align: center;
    color: var(--muted);
    font-size: 13px;
    border-top: 1px solid var(--border);
    margin-top: 40px;
}

.site-footer .links {
    display: flex;
    gap: 24px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.site-footer a:hover {
    color: var(--text);
}

/* ---- Content pages (privacy / terms / support) ------------------- */

.content {
    padding: 60px 0;
}

.content article {
    max-width: 760px;
    margin: 0 auto;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: clamp(32px, 5vw, 64px);
    box-shadow: var(--shadow);
}

.content h1 {
    font-size: clamp(28px, 4vw, 38px);
    font-weight: 800;
    margin-bottom: 8px;
    letter-spacing: -0.02em;
}

.content .updated {
    color: var(--muted);
    font-size: 13px;
    margin-bottom: 32px;
}

.content h2 {
    font-size: 22px;
    font-weight: 700;
    margin: 32px 0 12px;
}

.content h3 {
    font-size: 16px;
    font-weight: 600;
    margin: 20px 0 8px;
}

.content p, .content li {
    font-size: 15px;
    color: var(--text);
    margin-bottom: 12px;
}

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

.content code {
    background: var(--bg);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: -apple-system, "SF Mono", Menlo, monospace;
    font-size: 13px;
}

/* ---- Mobile ------------------------------------------------------ */

@media (max-width: 720px) {
    .nav {
        display: none;
    }
    .hero {
        padding: 56px 0 40px;
    }
    section {
        padding: 56px 0;
    }
    .download {
        padding: 32px 24px;
    }
}
