:root {
    color-scheme: light;
    --bg: #f8f4ec;
    --surface: #fffaf1;
    --surface-strong: #ffffff;
    --ink: #262019;
    --muted: #73685b;
    --line: rgba(38, 32, 25, 0.12);
    --accent: #b85635;
    --accent-dark: #7a341f;
    --accent-soft: #f2d5c8;
    --green: #5f7d52;
    --shadow: 0 24px 70px rgba(91, 58, 36, 0.14);
    font-family:
        "PingFang SC",
        "Microsoft YaHei",
        "Noto Sans SC",
        system-ui,
        sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background:
        radial-gradient(circle at 10% 12%, rgba(242, 213, 200, 0.52), transparent 28rem),
        linear-gradient(180deg, #fffaf1 0%, var(--bg) 38%, #f2eadf 100%);
    color: var(--ink);
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding: 1rem clamp(1rem, 4vw, 4rem);
    background: rgba(255, 250, 241, 0.84);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
}

.brand,
.nav-links,
.hero-actions,
.hero-metrics,
.ingredient-strip,
.footer-links {
    display: flex;
    align-items: center;
}

.brand {
    gap: 0.7rem;
    font-weight: 800;
    letter-spacing: 0;
}

.brand img {
    width: 2.8rem;
    height: 2.8rem;
    object-fit: cover;
    border-radius: 0.7rem;
    box-shadow: 0 8px 20px rgba(91, 58, 36, 0.12);
}

.nav-links {
    gap: clamp(0.8rem, 2vw, 1.6rem);
    color: var(--muted);
    font-size: 0.95rem;
}

.nav-links a {
    padding: 0.55rem 0;
    border-bottom: 2px solid transparent;
    transition: color 0.24s ease, border-color 0.24s ease;
}

.nav-links a:hover {
    color: var(--accent-dark);
    border-color: var(--accent);
}

.hero-section {
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(22rem, 0.88fr);
    gap: clamp(2rem, 7vw, 7rem);
    align-items: center;
    max-width: 1280px;
    min-height: calc(100dvh - 4.5rem);
    margin: 0 auto;
    padding: clamp(2.2rem, 6vw, 7rem) clamp(1rem, 4vw, 3rem);
}

.eyebrow {
    margin: 0 0 1rem;
    color: var(--accent-dark);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    max-width: 13ch;
    margin-bottom: 1.4rem;
    font-size: clamp(3.2rem, 8vw, 7.7rem);
    line-height: 0.94;
    letter-spacing: 0;
}

.hero-description {
    max-width: 40rem;
    color: var(--muted);
    font-size: 1.1rem;
    line-height: 1.9;
}

.hero-actions {
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: 2rem;
}

.primary-button,
.secondary-button,
.download-card {
    transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.primary-button,
.secondary-button {
    min-height: 3rem;
    padding: 0.88rem 1.2rem;
    border-radius: 999px;
    font-weight: 800;
}

.primary-button {
    background: var(--ink);
    color: #fffaf1;
}

.secondary-button {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.5);
    color: var(--ink);
}

.primary-button:hover,
.secondary-button:hover,
.download-card:hover {
    transform: translateY(-2px);
}

.primary-button:active,
.secondary-button:active,
.download-card:active {
    transform: translateY(1px);
}

.hero-metrics {
    flex-wrap: wrap;
    gap: 1rem;
    margin: 2.8rem 0 0;
}

.hero-metrics div {
    min-width: 8rem;
    padding-top: 0.85rem;
    border-top: 1px solid var(--line);
}

.hero-metrics dt {
    font-size: 1.6rem;
    font-weight: 900;
}

.hero-metrics dd {
    margin: 0.25rem 0 0;
    color: var(--muted);
}

.phone-showcase {
    position: relative;
    min-height: 40rem;
}

.phone-frame {
    width: min(100%, 23rem);
    margin-left: auto;
    padding: 1rem;
    border: 1px solid rgba(38, 32, 25, 0.18);
    border-radius: 2.4rem;
    background: #211b16;
    box-shadow: var(--shadow);
    transform: rotate(2deg);
}

.phone-status {
    display: flex;
    justify-content: space-between;
    padding: 0.3rem 1rem 0.85rem;
}

.phone-status span {
    display: block;
    width: 3rem;
    height: 0.34rem;
    border-radius: 999px;
    background: rgba(255, 250, 241, 0.22);
}

.app-preview {
    min-height: 33rem;
    padding: 1.35rem;
    overflow: hidden;
    border-radius: 1.7rem;
    background:
        linear-gradient(155deg, rgba(248, 244, 236, 0.92), rgba(255, 255, 255, 0.92)),
        var(--surface);
}

.cat-hero {
    display: block;
    width: 9.8rem;
    height: 9.8rem;
    object-fit: contain;
    margin: 0 auto 1rem;
    animation: float-cat 4.5s ease-in-out infinite;
}

.preview-label {
    margin-bottom: 0.35rem;
    color: var(--green);
    font-weight: 900;
}

.app-preview h2 {
    margin-bottom: 0.55rem;
    font-size: 2rem;
    line-height: 1.1;
}

.app-preview p {
    color: var(--muted);
}

.ingredient-strip {
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1.5rem 0;
}

.ingredient-strip span {
    padding: 0.48rem 0.65rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--accent-dark);
    font-weight: 800;
}

.recipe-lines {
    display: grid;
    gap: 0.8rem;
    margin-top: 2rem;
}

.recipe-lines span {
    display: block;
    height: 3.6rem;
    border-radius: 1rem;
    background: linear-gradient(90deg, rgba(184, 86, 53, 0.12), rgba(95, 125, 82, 0.1));
}

.recipe-lines span:nth-child(2) {
    width: 83%;
}

.recipe-lines span:nth-child(3) {
    width: 68%;
}

.preview-note {
    position: absolute;
    right: min(55%, 16rem);
    bottom: 3rem;
    width: 13.5rem;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.58);
    border-radius: 0.5rem;
    background: rgba(255, 250, 241, 0.82);
    box-shadow: 0 18px 45px rgba(91, 58, 36, 0.12);
    backdrop-filter: blur(14px);
}

.preview-note strong,
.preview-note span {
    display: block;
}

.preview-note span {
    margin-top: 0.4rem;
    color: var(--muted);
    line-height: 1.55;
}

.section-block,
.legal-section {
    max-width: 1180px;
    margin: 0 auto;
    padding: clamp(4rem, 8vw, 7rem) clamp(1rem, 4vw, 3rem);
    scroll-margin-top: 5.5rem;
}

.section-heading {
    display: grid;
    grid-template-columns: minmax(11rem, 0.42fr) minmax(0, 1fr);
    gap: clamp(1rem, 6vw, 5rem);
    align-items: start;
    margin-bottom: 2rem;
}

.section-heading h2,
.download-section h2,
.legal-section h2 {
    max-width: 16ch;
    margin-bottom: 1rem;
    font-size: clamp(2rem, 4.2vw, 4rem);
    line-height: 1.05;
    letter-spacing: 0;
}

.section-heading.compact h2 {
    max-width: none;
}

.feature-grid {
    display: grid;
    grid-template-columns: 1.25fr 0.85fr 0.9fr;
    gap: 1rem;
}

.feature-card {
    min-height: 16rem;
    padding: 1.4rem;
    border: 1px solid var(--line);
    border-radius: 0.5rem;
    background: rgba(255, 255, 255, 0.58);
}

.feature-card.large {
    grid-row: span 2;
    min-height: 32rem;
    background: #fffaf1;
}

.feature-card.wide {
    grid-column: span 2;
}

.feature-card img {
    width: 3.4rem;
    height: 3.4rem;
    object-fit: contain;
    margin-bottom: 1.3rem;
}

.feature-card h3 {
    margin-bottom: 0.7rem;
    font-size: 1.35rem;
}

.feature-card p,
.download-section p,
.legal-content p {
    color: var(--muted);
    line-height: 1.85;
}

.download-notes {
    display: grid;
    gap: 0.55rem;
    margin: 1.35rem 0 0;
    padding: 0;
    color: var(--muted);
    line-height: 1.7;
    list-style: none;
}

.download-notes li {
    position: relative;
    padding-left: 1.1rem;
}

.download-notes li::before {
    position: absolute;
    top: 0.72em;
    left: 0;
    width: 0.38rem;
    height: 0.38rem;
    border-radius: 999px;
    background: var(--accent);
    content: "";
}

.download-section {
    display: grid;
    grid-template-columns: minmax(0, 0.85fr) minmax(22rem, 1.15fr);
    gap: clamp(2rem, 6vw, 5rem);
    align-items: start;
}

.download-panel {
    display: grid;
    gap: 0.85rem;
}

.download-card {
    display: grid;
    grid-template-columns: 7rem minmax(0, 1fr);
    gap: 0.7rem 1rem;
    align-items: center;
    min-height: 6.2rem;
    padding: 1rem 1.15rem;
    border: 1px solid var(--line);
    border-radius: 0.5rem;
    background: rgba(255, 255, 255, 0.66);
}

.download-card.primary-download {
    border-color: rgba(184, 86, 53, 0.32);
    background: #fffaf1;
    box-shadow: 0 18px 48px rgba(91, 58, 36, 0.12);
}

.download-card.primary-download .platform {
    background: var(--ink);
    color: #fffaf1;
}

.download-card.disabled-download {
    cursor: not-allowed;
    opacity: 0.68;
}

.download-card.disabled-download:hover {
    transform: none;
}

.download-card strong {
    font-size: 1.15rem;
}

.download-card small {
    grid-column: 2;
    color: var(--muted);
}

.platform {
    grid-row: span 2;
    display: inline-grid;
    place-items: center;
    min-height: 4.2rem;
    border-radius: 0.5rem;
    background: var(--accent-soft);
    color: var(--accent-dark);
    font-weight: 900;
}

.info-list {
    display: grid;
    border-top: 1px solid var(--line);
}

.info-list div {
    display: grid;
    grid-template-columns: minmax(8rem, 0.28fr) minmax(0, 1fr);
    gap: 1rem;
    padding: 1.2rem 0;
    border-bottom: 1px solid var(--line);
}

.info-list span {
    color: var(--muted);
}

.info-list strong {
    line-height: 1.65;
}

.info-list a,
.legal-content a {
    color: var(--accent-dark);
    text-decoration: underline;
    text-underline-offset: 0.25em;
}

.legal-section {
    max-width: 980px;
}

.legal-date {
    color: var(--muted);
}

.legal-content {
    margin-top: 1.5rem;
    padding-top: 1.2rem;
    border-top: 1px solid var(--line);
}

.legal-content h3 {
    margin: 2rem 0 0.6rem;
    font-size: 1.2rem;
}

.sdk-table-wrap {
    width: 100%;
    margin-top: 1rem;
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 0.5rem;
    background: rgba(255, 255, 255, 0.62);
}

.sdk-table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
    color: var(--ink);
    font-size: 0.92rem;
}

.sdk-table th,
.sdk-table td {
    padding: 0.85rem 0.9rem;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
    line-height: 1.7;
}

.sdk-table th {
    background: rgba(236, 222, 198, 0.45);
    font-weight: 900;
}

.sdk-table tr:last-child td {
    border-bottom: 0;
}

.privacy-page {
    background: #f7f2e8;
}

.privacy-page .legal-section {
    max-width: 1040px;
}

.site-footer {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem 2rem;
    padding: 2rem clamp(1rem, 4vw, 4rem);
    border-top: 1px solid var(--line);
    background: #211b16;
    color: #fffaf1;
}

.site-footer div:first-child {
    display: grid;
    gap: 0.35rem;
}

.site-footer span,
.site-footer p,
.site-footer a {
    color: rgba(255, 250, 241, 0.72);
}

.footer-links {
    gap: 1rem;
}

.site-footer p {
    margin: 0;
}

@keyframes float-cat {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-0.45rem);
    }
}

@media (max-width: 920px) {
    .site-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.65rem;
    }

    .nav-links {
        width: 100%;
        overflow-x: auto;
        padding-bottom: 0.2rem;
        white-space: nowrap;
    }

    .hero-section,
    .download-section,
    .section-heading,
    .info-list div,
    .site-footer {
        grid-template-columns: 1fr;
    }

    .hero-section {
        min-height: auto;
    }

    .section-block,
    .legal-section {
        scroll-margin-top: 8.5rem;
    }

    h1 {
        max-width: 11ch;
        font-size: clamp(3rem, 15vw, 5.2rem);
    }

    .phone-showcase {
        min-height: auto;
    }

    .phone-frame {
        margin: 0 auto;
        transform: none;
    }

    .preview-note {
        position: relative;
        right: auto;
        bottom: auto;
        width: min(100%, 23rem);
        margin: 1rem auto 0;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }

    .feature-card.large,
    .feature-card.wide {
        grid-column: auto;
        grid-row: auto;
        min-height: 15rem;
    }

    .footer-links {
        flex-wrap: wrap;
    }
}

@media (max-width: 560px) {
    .site-header {
        padding-inline: 1rem;
    }

    .hero-metrics {
        align-items: stretch;
        flex-direction: column;
    }

    .hero-metrics div {
        width: 100%;
    }

    .download-card {
        grid-template-columns: 1fr;
    }

    .download-card small,
    .platform {
        grid-column: auto;
        grid-row: auto;
    }

    .platform {
        min-height: 3rem;
    }
}
