/* pinduoduo-to-taiwan landing — structure/style/behaviour separated, responsive. */

/* ==========================================================================
   Scoped design tokens (Pinduoduo-red brand system). All declared inside the
   .pdd-landing scope so this file never leaks variables to the global site.
   ========================================================================== */
.pdd-landing {
    --pdd-red: #e60023;
    --pdd-red-deep: #c92a2a;
    --pdd-orange: #ff6b35;
    --pdd-hero-grad: linear-gradient(135deg, #e60023, #ff4d4d);
    --pdd-cta-grad: linear-gradient(135deg, #e60023, #ff6b35);
    --pdd-tint: #fff5f5;
    --pdd-tip-bg: #f0fff4;
    --pdd-tip-accent: #2a9d8f;
    --pdd-tip-head: #0a4d3c;
    --pdd-zebra: #f8f9fa;
    --pdd-border: #e9ecef;
    --pdd-ink: #1f2937;
    --pdd-ink-soft: #495057;
    --pdd-tldr-accent: #1d4ed8;
    --pdd-radius-sm: 6px;
    --pdd-radius: 8px;
    --pdd-radius-lg: 12px;
    --pdd-shadow-card: 0 2px 8px rgba(0, 0, 0, 0.06);
    --pdd-shadow-hover: 0 10px 24px rgba(230, 0, 35, 0.14);
    --pdd-ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   Hero
   ========================================================================== */
.pdd-landing .page-hero {
    position: relative;
    overflow: hidden;
    background: var(--pdd-hero-grad);
    color: #fff;
    padding: clamp(40px, 7vw, 64px) 0;
}

/* Soft radial highlight for depth — never competes with content. */
.pdd-landing .page-hero::before {
    content: "";
    position: absolute;
    top: -40%;
    right: -10%;
    width: 60%;
    height: 160%;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0) 70%);
    pointer-events: none;
    z-index: 0;
}

.pdd-landing .page-hero > .container {
    position: relative;
    z-index: 1;
}

.pdd-landing .page-hero h1 {
    color: #fff;
    font-size: clamp(1.6rem, 4.5vw, 2.4rem);
    line-height: 1.25;
    font-weight: 800;
    letter-spacing: -0.01em;
    margin: 0 0 6px;
}

.pdd-landing .page-hero h1 i {
    margin-right: 0.4em;
    opacity: 0.92;
}

.pdd-landing .page-hero .lead {
    color: rgba(255, 255, 255, 0.95);
    font-size: clamp(1rem, 2.4vw, 1.15rem);
    line-height: 1.7;
    max-width: 720px;
    margin: 0 auto;
}

.pdd-landing .updated-meta {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.82) !important;
    margin: 8px 0 14px;
    text-align: center;
}

/* ==========================================================================
   AI TL;DR box (replaces original inline white card). Centred as a block,
   left-aligned body text — matches the taobao-tax-calculator sibling.
   ========================================================================== */
.pdd-landing .ai-tldr {
    max-width: 780px;
    margin: 18px auto 0;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.96);
    color: var(--pdd-ink);
    border-radius: var(--pdd-radius-lg);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
    text-align: left;
}

.pdd-landing .ai-tldr__title {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--pdd-tldr-accent);
    margin-bottom: 6px;
}

.pdd-landing .ai-tldr__body {
    margin: 0;
    font-size: 0.98rem;
    line-height: 1.7;
    color: var(--pdd-ink);
}

/* ==========================================================================
   Table of contents
   ========================================================================== */
.pdd-landing .toc {
    background: var(--pdd-tint);
    border: 1px solid rgba(230, 0, 35, 0.08);
    border-radius: var(--pdd-radius);
    padding: 18px 22px;
    margin-bottom: 28px;
}

.pdd-landing .toc h3 {
    font-size: 1.05rem;
    margin-bottom: 10px;
    color: var(--pdd-red-deep);
}

.pdd-landing .toc h3 i {
    margin-right: 0.4em;
    color: var(--pdd-red);
}

.pdd-landing .toc ol {
    margin: 0;
    padding-left: 22px;
}

.pdd-landing .toc li {
    margin: 4px 0;
}

.pdd-landing .toc a {
    color: var(--pdd-red-deep);
    text-decoration: none;
    transition: color 0.18s var(--pdd-ease);
}

.pdd-landing .toc a:hover,
.pdd-landing .toc a:focus-visible {
    color: var(--pdd-red);
    text-decoration: underline;
}

/* ==========================================================================
   Section headings inside the content card
   ========================================================================== */
.pdd-landing .content-card h2 {
    font-size: clamp(1.3rem, 3vw, 1.7rem);
    line-height: 1.35;
    font-weight: 700;
    color: #212529;
    scroll-margin-top: 84px;
}

.pdd-landing .content-card h2 i {
    margin-right: 0.45em;
    color: var(--pdd-red);
}

/* ==========================================================================
   Step boxes
   ========================================================================== */
.pdd-landing .step-box {
    background: var(--pdd-tint);
    border-left: 4px solid var(--pdd-red);
    padding: 18px 22px;
    margin: 18px 0;
    border-radius: var(--pdd-radius);
    scroll-margin-top: 84px;
    transition: transform 0.2s var(--pdd-ease), box-shadow 0.2s var(--pdd-ease);
}

.pdd-landing .step-box:hover {
    transform: translateY(-2px);
    box-shadow: var(--pdd-shadow-hover);
}

.pdd-landing .step-box h4 {
    display: flex;
    align-items: center;
    font-size: 1.1rem;
    line-height: 1.4;
    margin-bottom: 8px;
}

.pdd-landing .step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    background: var(--pdd-red);
    color: #fff;
    width: 32px;
    height: 32px;
    line-height: 1;
    text-align: center;
    border-radius: 50%;
    font-weight: bold;
    margin-right: 10px;
}

/* ==========================================================================
   Comparison table + horizontal scroll wrapper (replaces inline overflow)
   ========================================================================== */
.pdd-landing .table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 18px 0;
    border-radius: var(--pdd-radius);
}

.pdd-landing .compare-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    font-size: 0.95rem;
}

.pdd-landing .compare-table th {
    background: var(--pdd-red);
    color: #fff;
    padding: 12px 14px;
    text-align: left;
    white-space: nowrap;
}

.pdd-landing .compare-table td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--pdd-border);
    vertical-align: top;
}

.pdd-landing .compare-table tr:nth-child(even) {
    background: var(--pdd-zebra);
}

.pdd-landing .compare-table .pdd {
    color: var(--pdd-red);
    font-weight: bold;
}

.pdd-landing .compare-table .tb {
    color: var(--pdd-orange);
    font-weight: bold;
}

/* ==========================================================================
   Pitfall callouts
   ========================================================================== */
.pdd-landing .pitfall {
    background: var(--pdd-tint);
    border-left: 4px solid var(--pdd-red-deep);
    padding: 14px 18px;
    margin: 14px 0;
    border-radius: var(--pdd-radius-sm);
    transition: transform 0.2s var(--pdd-ease), box-shadow 0.2s var(--pdd-ease);
}

.pdd-landing .pitfall:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(201, 42, 42, 0.12);
}

.pdd-landing .pitfall h4 {
    color: var(--pdd-red-deep);
    margin-bottom: 8px;
    font-size: 1.05rem;
}

/* ==========================================================================
   Tip callouts
   ========================================================================== */
.pdd-landing .tip {
    background: var(--pdd-tip-bg);
    border-left: 4px solid var(--pdd-tip-accent);
    padding: 14px 18px;
    margin: 14px 0;
    border-radius: var(--pdd-radius-sm);
    transition: transform 0.2s var(--pdd-ease), box-shadow 0.2s var(--pdd-ease);
}

.pdd-landing .tip:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(42, 157, 143, 0.14);
}

.pdd-landing .tip h4 {
    color: var(--pdd-tip-head);
    margin-bottom: 8px;
    font-size: 1.05rem;
}

/* ==========================================================================
   Why-us grid
   ========================================================================== */
.pdd-landing .why-us-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin: 20px 0;
}

.pdd-landing .why-us-grid .item {
    text-align: center;
    padding: 22px 18px;
    background: #fff;
    border: 1px solid var(--pdd-border);
    border-radius: var(--pdd-radius-lg);
    box-shadow: var(--pdd-shadow-card);
    transition: transform 0.2s var(--pdd-ease), box-shadow 0.2s var(--pdd-ease);
}

.pdd-landing .why-us-grid .item:hover {
    transform: translateY(-4px);
    box-shadow: var(--pdd-shadow-hover);
}

.pdd-landing .why-us-grid .item i {
    display: block;
    font-size: 2rem;
    color: var(--pdd-red);
    margin-bottom: 10px;
}

.pdd-landing .why-us-grid .item h4 {
    font-size: 1.05rem;
    margin-bottom: 6px;
    color: #212529;
}

/* ==========================================================================
   CTA section
   ========================================================================== */
.pdd-landing .cta-section {
    background: var(--pdd-cta-grad);
    color: #fff;
    padding: clamp(36px, 6vw, 50px) 0;
    text-align: center;
    border-radius: var(--pdd-radius-lg);
    margin: 40px 0 0;
}

.pdd-landing .cta-section h2 {
    color: #fff;
    font-size: clamp(1.4rem, 3.4vw, 1.9rem);
    margin-bottom: 6px;
}

.pdd-landing .cta-section h2 i {
    margin-right: 0.4em;
}

.pdd-landing .cta-section p {
    color: rgba(255, 255, 255, 0.95);
    font-size: clamp(1rem, 2.2vw, 1.1rem);
    line-height: 1.7;
    max-width: 640px;
    margin: 0 auto;
}

.pdd-landing .btn-cta {
    display: inline-block;
    background: #fff;
    color: var(--pdd-red);
    padding: 14px 36px;
    font-size: 1.15rem;
    font-weight: bold;
    border-radius: 50px;
    margin-top: 16px;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
    transition: transform 0.2s var(--pdd-ease), box-shadow 0.2s var(--pdd-ease), background 0.2s var(--pdd-ease);
}

.pdd-landing .btn-cta:hover {
    background: #fff;
    color: var(--pdd-red);
    transform: translateY(-2px);
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.22);
}

/* ==========================================================================
   FAQ
   ========================================================================== */
.pdd-landing .faq-q {
    background: var(--pdd-tint);
    padding: 14px 18px;
    border-radius: var(--pdd-radius);
    margin: 14px 0 6px;
    font-weight: bold;
    color: var(--pdd-red-deep);
}

.pdd-landing .faq-a {
    padding: 0 18px;
    color: var(--pdd-ink-soft);
    line-height: 1.8;
}

.pdd-landing .faq-a a {
    color: var(--pdd-red);
    text-decoration: none;
}

.pdd-landing .faq-a a:hover,
.pdd-landing .faq-a a:focus-visible {
    text-decoration: underline;
}

/* ==========================================================================
   Related links
   ========================================================================== */
.pdd-landing .related-links {
    background: var(--pdd-zebra);
    border-radius: var(--pdd-radius-lg);
    padding: 18px 22px;
    margin-top: 28px;
}

.pdd-landing .related-links h4 {
    color: var(--pdd-red-deep);
    margin-bottom: 10px;
}

.pdd-landing .related-links h4 i {
    margin-right: 0.4em;
    color: var(--pdd-red);
}

.pdd-landing .related-links ul {
    padding-left: 20px;
    margin: 0;
}

.pdd-landing .related-links li {
    margin: 6px 0;
}

.pdd-landing .related-links a {
    color: var(--pdd-red-deep);
    text-decoration: none;
    transition: color 0.18s var(--pdd-ease);
}

.pdd-landing .related-links a:hover,
.pdd-landing .related-links a:focus-visible {
    color: var(--pdd-red);
    text-decoration: underline;
}

/* ==========================================================================
   Accessibility — visible keyboard focus ring across interactive elements
   ========================================================================== */
.pdd-landing a:focus-visible,
.pdd-landing .btn-cta:focus-visible {
    outline: 3px solid rgba(230, 0, 35, 0.55);
    outline-offset: 2px;
    border-radius: 3px;
}

/* CTA button needs a light ring against the red gradient backdrop. */
.pdd-landing .btn-cta:focus-visible {
    outline-color: rgba(255, 255, 255, 0.9);
}

/* ==========================================================================
   Responsive ladder
   ========================================================================== */
@media (max-width: 768px) {
    .pdd-landing .toc,
    .pdd-landing .related-links {
        padding: 16px 18px;
    }

    .pdd-landing .step-box {
        padding: 16px 18px;
    }

    .pdd-landing .why-us-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
        gap: 14px;
    }
}

@media (max-width: 640px) {
    .pdd-landing .page-hero {
        padding: 38px 0;
    }

    .pdd-landing .page-hero h1 {
        line-height: 1.35;
    }

    .pdd-landing .page-hero .lead {
        line-height: 1.65;
    }

    .pdd-landing .ai-tldr {
        padding: 14px 16px;
    }

    .pdd-landing .compare-table {
        font-size: 0.88rem;
    }

    .pdd-landing .compare-table th,
    .pdd-landing .compare-table td {
        padding: 9px 11px;
    }

    .pdd-landing .why-us-grid {
        grid-template-columns: 1fr;
    }

    .pdd-landing .cta-section {
        margin: 32px 0 0;
    }
}

@media (max-width: 480px) {
    .pdd-landing .page-hero {
        padding: 30px 0;
    }

    .pdd-landing .toc,
    .pdd-landing .related-links {
        padding: 14px 16px;
    }

    .pdd-landing .step-box {
        padding: 14px 16px;
    }

    .pdd-landing .step-box h4 {
        font-size: 1.02rem;
    }

    .pdd-landing .step-num {
        width: 28px;
        height: 28px;
        margin-right: 8px;
    }

    .pdd-landing .btn-cta {
        padding: 12px 28px;
        font-size: 1.05rem;
    }

    .pdd-landing .compare-table {
        font-size: 0.84rem;
    }
}

/* ==========================================================================
   Reduced motion — disable all transform/transition movement
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    .pdd-landing .step-box,
    .pdd-landing .pitfall,
    .pdd-landing .tip,
    .pdd-landing .why-us-grid .item,
    .pdd-landing .btn-cta,
    .pdd-landing .toc a,
    .pdd-landing .related-links a {
        transition: none;
    }

    .pdd-landing .step-box:hover,
    .pdd-landing .pitfall:hover,
    .pdd-landing .tip:hover,
    .pdd-landing .why-us-grid .item:hover,
    .pdd-landing .btn-cta:hover {
        transform: none;
    }
}
