/* DragonCard — official landing page styles */

:root {
    --primary: #0f766e;
    --primary-light: #14b8a6;
    --primary-dark: #115e59;
    --primary-soft: #ccfbf1;
    --ink: #1d1d1d;
    --ink-2: #475569;
    --ink-3: #64748b;
    --line: #e6e6e6;
    --surface: #ffffff;
    --bg: #f4f7f5;
    --amber: #d97706;
    --unknown: #f43f5e;
    --action-bg: #f1f5f9;

    /* tokens used by vendored card templates */
    --card-bg: #ffffff;
    --card-font-scale: 1;
    --card-font-weight: 600;
    --scale-basic: 1;
    --scale-def: 1;
    --scale-example: 1;
    --action-btn-bg: #f1f5f9;
    --primary-ring: rgba(15, 118, 110, 0.3);
    --unknown-soft: #ffe4e6;
    --unknown-ring: rgba(244, 63, 94, 0.3);
    --amber-soft: #fef3c7;
    --amber-ring: rgba(217, 119, 6, 0.3);
    --def-bg: #e6f0e8;
    --ex-bg: #fdf8e8;
    --slate-soft: #f1f5f9;
    --success: #16a34a;
    --done-bg: #f0fdf4;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: var(--bg);
    color: var(--ink);
    line-height: 1.6;
}

.demo-shell {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 20px 48px;
}

/* ===== Header ===== */
.demo-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 18px 0;
}
.demo-logo {
    font-size: 18px; font-weight: 800; color: var(--primary);
    display: flex; align-items: center; gap: 8px;
}
.demo-lang-btn {
    border: 1px solid var(--line); background: var(--surface);
    border-radius: 8px; padding: 6px 14px; cursor: pointer;
    font-size: 13px; font-weight: 600; color: var(--ink-2);
    transition: all 0.15s;
}
.demo-lang-btn:hover { border-color: var(--primary); color: var(--primary); }
.demo-header-right { display: flex; align-items: center; gap: 10px; }
.demo-store-btn {
    display: inline-flex; align-items: center; gap: 7px;
    background: var(--primary); color: #fff;
    border-radius: 90px; padding: 9px 20px;
    font-size: 13px; font-weight: 700; text-decoration: none;
    box-shadow: 0 4px 14px rgba(15,118,110,0.30);
    transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}
.demo-store-btn:hover {
    transform: translateY(-2px);
    background: var(--primary-dark);
    box-shadow: 0 6px 20px rgba(15,118,110,0.40);
}
.demo-store-btn i { font-size: 14px; }

/* GitHub entry in the header (top-right) */
.header-github {
    display: inline-flex; align-items: center; gap: 7px;
    color: var(--ink-2); font-size: 13px; font-weight: 700; text-decoration: none;
    border: 1px solid var(--line); background: var(--surface);
    border-radius: 90px; padding: 7px 16px;
    transition: all 0.15s;
}
.header-github:hover { border-color: var(--primary); color: var(--primary); }

/* ===== Section titles ===== */
.section-title {
    font-size: 26px; font-weight: 800; text-align: center;
    margin: 8px 0 6px;
}
.section-sub {
    text-align: center; font-size: 13px; color: var(--ink-3);
    margin-bottom: 26px;
}

/* ===== Module 1: Hero ===== */
.demo-hero {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    border-radius: 20px;
    padding: 48px 40px;
    color: #fff;
    text-align: center;
    margin-bottom: 40px;
}
.hero-badge {
    display: inline-block;
    background: rgba(255,255,255,0.15);
    border-radius: 90px; padding: 5px 16px;
    font-size: 12px; font-weight: 700; letter-spacing: 0.5px;
    margin-bottom: 16px;
}
.hero-badge i { margin-right: 6px; }
.hero-title {
    font-size: 44px; font-weight: 800; margin-bottom: 12px;
    letter-spacing: 2px;
}
.hero-sub {
    font-size: 15px; opacity: 0.94; max-width: 620px; margin: 0 auto 28px;
}
.hero-points {
    display: flex; gap: 20px; justify-content: center; flex-wrap: wrap;
}
.hero-point {
    background: rgba(255,255,255,0.10);
    border-radius: 14px; padding: 16px 22px;
    min-width: 170px;
    display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.hero-point i { font-size: 22px; color: var(--primary-soft); }
.hero-point span { font-weight: 700; font-size: 16px; }
.hero-point small { font-size: 11px; opacity: 0.8; }

/* ===== Module 2: Philosophy ===== */
.demo-philosophy {
    background: var(--surface);
    border: 1px solid var(--line); border-radius: 16px;
    padding: 28px 30px; margin-bottom: 40px;
    box-shadow: 0 6px 20px rgba(15,118,110,0.06);
}
.philo-block {
    margin: 18px 0;
    border-left: 3px solid var(--primary-soft);
    padding: 2px 0 2px 18px;
}
.philo-head {
    display: flex; align-items: center; gap: 10px;
    font-size: 15px; font-weight: 800; color: var(--primary-dark);
    margin-bottom: 8px;
}
.philo-head i { color: var(--primary); width: 18px; text-align: center; }
.philo-block p {
    font-size: 14px; color: var(--ink-2); line-height: 1.7;
    margin-bottom: 6px;
}
.philo-compare { text-align: center; margin-top: 22px; }
.philo-compare-btn {
    display: inline-flex; align-items: center; gap: 8px;
    border: 1px solid var(--line); background: var(--surface);
    color: var(--ink-2); border-radius: 90px; padding: 10px 22px;
    font-size: 13px; font-weight: 700; cursor: pointer;
    transition: all 0.15s;
}
.philo-compare-btn:hover { border-color: var(--primary); color: var(--primary); }

/* ===== Comparison modal ===== */
.modal-backdrop {
    position: fixed; inset: 0; z-index: 100;
    background: rgba(15, 23, 42, 0.55);
    display: none; justify-content: center; align-items: flex-start;
    padding: 40px 20px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.modal-backdrop.open { display: flex; }
.modal-box {
    background: var(--surface);
    border-radius: 18px; max-width: 760px; width: 100%;
    max-height: none; min-height: 0; flex-shrink: 1;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    padding: 22px 24px;
}
.modal-head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 16px;
}
.modal-title { font-size: 18px; font-weight: 800; color: var(--primary-dark); }
.modal-close {
    width: 36px; height: 36px; border-radius: 90px;
    border: 1px solid var(--line); background: var(--action-bg);
    color: var(--ink-2); cursor: pointer; font-size: 15px;
    transition: all 0.15s;
}
.modal-close:hover { border-color: var(--primary); color: var(--primary); }
.modal-body { overflow-x: auto; }
.compare-table-inner { width: 100%; border-collapse: collapse; font-size: 13px; }
.compare-table-inner th, .compare-table-inner td {
    text-align: left; padding: 10px 14px;
    border: 1px solid var(--line); vertical-align: top; line-height: 1.6;
}
.compare-table-inner thead th {
    background: var(--primary-soft); color: var(--primary-dark);
    font-weight: 700; font-size: 13px;
}
.compare-table-inner tbody th {
    background: var(--action-bg); color: var(--ink);
    font-weight: 600; white-space: nowrap;
}

/* ===== Module 3: Card samples ===== */
.demo-samples { margin-bottom: 40px; }
.sample-tabs {
    display: flex; justify-content: center; gap: 10px; flex-wrap: wrap;
    margin-bottom: 22px;
}
.sample-tab {
    display: inline-flex; align-items: center; gap: 8px;
    border: 1px solid var(--line); background: var(--surface);
    color: var(--ink-2); border-radius: 90px; padding: 8px 18px;
    font-size: 13px; font-weight: 700; cursor: pointer;
    transition: all 0.15s;
}
.sample-tab i { font-size: 13px; color: var(--primary); }
.sample-tab:hover { border-color: var(--primary-light); color: var(--primary); }
.sample-tab.active {
    border-color: var(--primary); background: var(--primary-soft); color: var(--primary-dark);
}
.sample-category { margin-bottom: 36px; }
.sample-cat-head {
    display: flex; align-items: center; gap: 14px;
    margin-bottom: 16px;
}
.sample-cat-head > i {
    font-size: 20px; color: var(--primary);
    width: 42px; height: 42px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    background: var(--primary-soft); border-radius: 12px;
}
.sample-cat-titles h3 { font-size: 18px; font-weight: 800; }
.sample-cat-titles p { font-size: 12px; color: var(--ink-3); }
.sample-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
}
.sample-cell {
    background: var(--surface);
    border: 1px solid var(--line); border-radius: 16px;
    padding: 16px 16px 8px;
    box-shadow: 0 4px 16px rgba(15,118,110,0.05);
    transition: transform 0.2s, box-shadow 0.2s;
    min-width: 0;
}
.sample-cell:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(15,118,110,0.12); }
.sample-mount { min-width: 0; }

/* 3D sample toggle */
.dc-3d-bar { display: flex; justify-content: flex-end; padding: 10px 2px 6px; }
.dc-3d-btn {
    display: inline-flex; align-items: center; gap: 8px;
    border: 1px solid var(--line); background: var(--action-bg);
    color: var(--ink-2); border-radius: 90px; padding: 7px 16px;
    font-size: 12px; font-weight: 700; cursor: pointer;
    transition: all 0.15s;
}
.dc-3d-btn:hover { border-color: var(--primary); color: var(--primary); }
.dc-3d-view {
    height: 320px; border-radius: 12px; overflow: hidden;
    background: linear-gradient(135deg, #f0fdfa, #e0f2f1);
    border: 1px solid var(--primary-soft);
}
.sc-3d-err {
    display: flex; align-items: center; justify-content: center;
    height: 100%; color: var(--ink-3); font-size: 13px;
}
.samples-error { text-align: center; color: var(--ink-3); padding: 40px 0; }

/* ===== Module 4: Free / paid clarification ===== */
.demo-clarify { margin-bottom: 40px; }
.clarify-box {
    background: var(--surface);
    border: 1px solid var(--line); border-radius: 18px;
    padding: 30px;
    box-shadow: 0 8px 26px rgba(15,118,110,0.08);
    border-top: 4px solid var(--primary);
}
.clarify-badge {
    display: inline-block;
    background: var(--primary-soft); color: var(--primary-dark);
    border-radius: 90px; padding: 6px 18px;
    font-size: 13px; font-weight: 800; margin-bottom: 22px;
}
.clarify-badge i { margin-right: 6px; }
.clarify-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.clarify-item {
    border-radius: 14px; padding: 20px 22px;
    border: 1px solid var(--line);
}
.clarify-item h3 {
    font-size: 16px; font-weight: 800; margin-bottom: 10px;
    display: flex; align-items: center; gap: 8px;
}
.clarify-free { background: var(--primary-soft); border-color: var(--primary-soft); }
.clarify-free h3 { color: var(--primary-dark); }
.clarify-paid { background: #fdf8e8; border-color: #f5e8c8; }
.clarify-paid h3 { color: #92400e; }
.clarify-item p {
    font-size: 13px; color: var(--ink-2); line-height: 1.7; margin-bottom: 6px;
}

/* ===== Store hero ===== */
.store-hero {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    border-radius: 20px;
    padding: 48px 40px;
    color: #fff;
    text-align: center;
    margin-bottom: 32px;
}
.hero-actions { margin-top: 28px; display: flex; justify-content: center; gap: 12px; }
.hero-btn {
    display: inline-flex; align-items: center; gap: 8px;
    background: #fff; color: var(--primary-dark);
    border-radius: 90px; padding: 11px 26px;
    font-size: 14px; font-weight: 700; text-decoration: none;
    box-shadow: 0 4px 14px rgba(0,0,0,0.12);
    transition: transform 0.15s, box-shadow 0.15s;
}
.hero-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,0.18); }

/* ===== Deck store grid ===== */
.demo-store { margin-top: 8px; }
.store-grid {
    display: grid; grid-template-columns: repeat(3, 1fr);
    gap: 20px; max-width: 1000px; margin: 0 auto;
}
.store-empty { text-align: center; padding: 60px 20px; color: var(--ink-3); grid-column: 1 / -1; }
.store-card {
    background: var(--surface);
    border: 1px solid var(--line); border-radius: 16px;
    overflow: hidden;
    display: flex; flex-direction: column;
    box-shadow: 0 4px 16px rgba(15,118,110,0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}
.store-card:hover { transform: translateY(-4px); box-shadow: 0 10px 28px rgba(15,118,110,0.12); }
.store-preview {
    width: 100%; height: 150px; object-fit: cover;
    background: #eef2ef;
}
.store-preview-empty {
    display: flex; align-items: center; justify-content: center;
    color: #a8b3ad; font-size: 30px;
}
.store-info { padding: 14px 16px 6px; flex: 1; }
.store-name-row { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.store-lang {
    font-size: 10px; font-weight: 700; letter-spacing: 1px;
    background: var(--primary-soft); color: var(--primary-dark);
    border-radius: 4px; padding: 2px 6px;
}
.store-name { font-size: 15px; font-weight: 700; }
.store-desc {
    font-size: 12px; color: var(--ink-3); line-height: 1.6;
    margin-bottom: 8px;
}
.store-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.store-tag {
    font-size: 10px; color: var(--ink-2);
    background: var(--action-bg); border-radius: 90px; padding: 2px 8px;
}
.store-foot {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 16px; border-top: 1px solid var(--line);
}
.store-price { font-size: 14px; font-weight: 700; color: var(--primary-dark); }
.store-btn {
    display: inline-flex; align-items: center; gap: 6px;
    background: var(--primary); color: #fff;
    border-radius: 90px; padding: 7px 16px;
    font-size: 12px; font-weight: 600; text-decoration: none;
    transition: background 0.15s;
}
.store-btn:hover { background: var(--primary-dark); }

/* ===== Module 5: CTA ===== */
.demo-cta {
    text-align: center; padding: 20px 0 8px;
}
.cta-btn {
    display: inline-flex; align-items: center; gap: 10px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff; border-radius: 90px; padding: 16px 40px;
    font-size: 17px; font-weight: 800; text-decoration: none;
    box-shadow: 0 8px 24px rgba(15,118,110,0.35);
    transition: transform 0.15s, box-shadow 0.15s;
}
.cta-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(15,118,110,0.45); }
.cta-note { margin-top: 12px; font-size: 12px; color: var(--ink-3); }

/* ===== Footer ===== */
.demo-footer {
    text-align: center; padding: 40px 0 0;
    font-size: 12px; color: var(--ink-3);
}
.footer-links {
    display: flex; align-items: center; justify-content: center; gap: 16px;
    flex-wrap: wrap; margin-bottom: 12px;
}
.footer-links a {
    color: var(--ink-2); text-decoration: none; font-weight: 600;
    display: inline-flex; align-items: center; gap: 6px;
}
.footer-links a:hover { color: var(--primary); }

/* ===== Legal pages (terms / privacy) ===== */
.legal-card {
    background: var(--surface);
    border: 1px solid var(--line); border-radius: 16px;
    padding: 34px 38px; margin: 8px 0 16px;
    box-shadow: 0 6px 20px rgba(15,118,110,0.06);
    max-width: 760px; margin-left: auto; margin-right: auto;
}
.legal-card h1 { font-size: 26px; font-weight: 800; margin-bottom: 4px; }
.legal-date { font-size: 12px; color: var(--ink-3); margin-bottom: 22px; }
.legal-card h2 {
    font-size: 15px; font-weight: 800; color: var(--primary-dark);
    margin: 20px 0 8px;
}
.legal-card p {
    font-size: 13px; color: var(--ink-2); line-height: 1.8; margin-bottom: 6px;
}
.legal-card a { color: var(--primary); }
.footer-trust {
    display: flex; align-items: center; justify-content: center; gap: 12px;
    flex-wrap: wrap; margin-bottom: 12px;
}
.footer-github {
    display: inline-flex; align-items: center; gap: 7px;
    color: var(--primary); font-weight: 700; text-decoration: none;
    border: 1px solid var(--line); background: var(--surface);
    border-radius: 90px; padding: 6px 16px;
}
.footer-github:hover { border-color: var(--primary); }
.trust-chip {
    display: inline-flex; align-items: center; gap: 6px;
    background: var(--action-bg); color: var(--ink-2);
    border-radius: 90px; padding: 6px 14px; font-weight: 600;
}
.footer-note { font-size: 12px; }

/* ===== Responsive ===== */
@media (max-width: 800px) {
    .hero-title { font-size: 30px; }
    .hero-points { gap: 12px; }
    .clarify-row { grid-template-columns: 1fr; }
    .sample-grid { grid-template-columns: 1fr; }
    .store-grid { grid-template-columns: 1fr; }
    .demo-hero { padding: 36px 24px; }
    .store-hero { padding: 36px 24px; }
}
