/* X账号注册教程 - Styles */
:root {
    --primary: #0f1419;
    --primary-hover: #1a1f26;
    --accent: #1d9bf0;
    --accent-hover: #1a8cd8;
    --text-primary: #333;
    --text-secondary: #737373;
    --bg-white: #fff;
    --bg-dark: #141414;
    --border-light: #e5e5e5;
    --transition-fast: 0.2s ease;
}

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

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    scroll-behavior: smooth;
}

/* 锚点滚动时预留顶部固定导航栏空间 */
[id^="section-"],
[id^="sub-"] {
    scroll-margin-top: 80px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-primary);
    background: var(--bg-dark);
    line-height: 1.5;
    min-height: 100vh;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-img {
    display: block;
    width: 28px;
    height: 28px;
    object-fit: contain;
}

/* Main layout */
.main-wrapper {
    position: relative;
    padding-top: 60px;
    min-height: 100vh;
}

.bg-overlay {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, rgba(20, 20, 20, 0.95) 0%, rgba(80, 40, 40, 0.9) 50%, rgba(20, 30, 50, 0.95) 100%);
    z-index: -1;
}

.bg-overlay::before {
    content: "";
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1920 1080'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%231a0a0a'/%3E%3Cstop offset='0.5' stop-color='%23201520'/%3E%3Cstop offset='1' stop-color='%230a1520'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect fill='url(%23g)' width='1920' height='1080'/%3E%3C/svg%3E") center/cover;
    filter: blur(20px);
    opacity: 0.6;
}

.content-container {
    display: flex;
    max-width: 1100px;
    margin: 0 auto;
    background: var(--bg-white);
    min-height: calc(100vh - 60px);
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.5);
}

/* Sidebar */
.sidebar {
    width: 220px;
    flex-shrink: 0;
    padding: 24px 0;
    border-right: 1px solid var(--border-light);
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 20px 20px;
    border-bottom: 1px solid var(--border-light);
}

.service-icon {
    width: 36px;
    height: 36px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg-white);
    font-weight: 700;
    font-size: 18px;
}

.sidebar-title {
    font-size: 16px;
    font-weight: 600;
}

.sidebar-nav {
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 14px;
    transition: background var(--transition-fast);
}

.nav-item:hover {
    background: #f5f5f5;
}

.nav-item.active {
    background: var(--primary);
    color: var(--bg-white);
}

.nav-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    background: currentColor;
    mask-size: contain;
    mask-position: center;
    mask-repeat: no-repeat;
    -webkit-mask-size: contain;
    -webkit-mask-position: center;
    -webkit-mask-repeat: no-repeat;
}

.nav-item:not(.active) .nav-icon {
    opacity: 0.6;
}

.nav-item.active .nav-icon {
    background: var(--bg-white);
}

.nav-icon-start { mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 8v8M8 12h8'/%3E%3C/svg%3E"); -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 8v8M8 12h8'/%3E%3C/svg%3E"); }
.nav-icon-account { mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Crect x='2' y='4' width='20' height='16' rx='2'/%3E%3Cpath d='M2 10h20'/%3E%3C/svg%3E"); -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Crect x='2' y='4' width='20' height='16' rx='2'/%3E%3Cpath d='M2 10h20'/%3E%3C/svg%3E"); }
.nav-icon-watch { mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 6v6l4 2'/%3E%3C/svg%3E"); -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 6v6l4 2'/%3E%3C/svg%3E"); }
.nav-icon-device { mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Crect x='5' y='2' width='14' height='20' rx='2'/%3E%3Cpath d='M12 18h.01'/%3E%3C/svg%3E"); -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Crect x='5' y='2' width='14' height='20' rx='2'/%3E%3Cpath d='M12 18h.01'/%3E%3C/svg%3E"); }
.nav-icon-security { mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Cpath d='M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z'/%3E%3C/svg%3E"); -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Cpath d='M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z'/%3E%3C/svg%3E"); }
.nav-icon-play { mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Cpolygon points='5 3 19 12 5 21 5 3'/%3E%3C/svg%3E"); -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Cpolygon points='5 3 19 12 5 21 5 3'/%3E%3C/svg%3E"); }
.nav-icon-tv { mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Crect x='2' y='7' width='20' height='15' rx='2'/%3E%3Cpath d='M17 2l-5 5-5-5'/%3E%3C/svg%3E"); -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Crect x='2' y='7' width='20' height='15' rx='2'/%3E%3Cpath d='M17 2l-5 5-5-5'/%3E%3C/svg%3E"); }

.sub-nav {
    padding: 16px 20px 0;
}

.sub-nav-label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.sub-nav a {
    display: block;
    padding: 6px 0;
    color: #0066cc;
    text-decoration: none;
    font-size: 13px;
}

.sub-nav a:hover {
    text-decoration: underline;
}

/* Main content */
.main-content {
    flex: 1;
    padding: 32px 48px 60px;
    overflow-y: auto;
}

.hero h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
}

.hero-subtitle {
    color: var(--text-secondary);
    font-size: 16px;
    margin-bottom: 20px;
}

/* Hero 下方推广横幅（谷歌账号 CTA） */
.hero-promo-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 20px 28px;
    background: #1a1a1a;
    border-radius: 16px;
    margin-bottom: 32px;
}

.hero-promo-cta__left {
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
}

.hero-promo-cta__icon {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #2a2a2a;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-promo-cta__google {
    display: block;
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.hero-promo-cta__text {
    min-width: 0;
}

.hero-promo-cta__title {
    margin: 0 0 6px;
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    line-height: 1.35;
}

.hero-promo-cta__sub {
    margin: 0;
    font-size: 14px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.92);
    line-height: 1.4;
}

.hero-promo-cta__btn {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    border-radius: 10px;
    background: #ffb400;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    transition: background 0.2s ease, transform 0.15s ease;
}

.hero-promo-cta__btn:hover {
    background: #e6a200;
    color: #fff;
}

.hero-promo-cta__btn:active {
    transform: scale(0.98);
}

@media (max-width: 520px) {
    .hero-promo-cta {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        padding: 18px 20px;
    }

    .hero-promo-cta__left {
        flex-direction: column;
        text-align: center;
    }

    .hero-promo-cta__btn {
        width: 100%;
    }
}

.hero-featured {
    display: flex;
    align-items: stretch;
    background: var(--primary);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 40px;
}

.hero-featured-left {
    flex: 1;
    padding: 32px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.featured-icon {
    width: 64px;
    height: 64px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg-white);
    font-weight: 700;
    font-size: 28px;
    margin-bottom: 16px;
}

.hero-featured-left p {
    color: var(--bg-white);
    font-size: 18px;
    font-weight: 600;
}

.hero-featured-right {
    width: 200px;
    display: flex;
    align-items: flex-end;
    padding: 20px;
}

.phone-mockup {
    width: 120px;
    height: 200px;
    background: #1a1a1a;
    border-radius: 16px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* 内容区块 */
.content-section {
    margin-bottom: 32px;
}

.content-section h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 16px;
}

#section-share > h2 {
    margin-bottom: 8px;
}

.share-update-time {
    margin: 0 0 16px;
    font-size: 14px;
    font-weight: 700;
    color: var(--text-secondary);
    line-height: 1.5;
    text-align: center;
}

.content-section h3 {
    font-size: 19px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 24px 0 12px;
    padding-left: 14px;
    border-left: 4px solid var(--accent);
}

.content-section h3:first-of-type {
    margin-top: 0;
}

.article-item {
    margin-bottom: 20px;
}

.article-item h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 8px;
}

.article-item p {
    margin: 0;
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.article-item p + p {
    margin-top: 10px;
}

/* 美区 Apple ID 分享卡片（账号 / 密码 + 复制） */
.apple-id-cards {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin: 20px 0 24px;
}

.apple-id-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding: 16px;
    border: 1px solid #eee;
}

.apple-id-card__head {
    background: #333;
    color: #fff;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    padding: 10px 12px;
    border-radius: 8px;
    margin-bottom: 14px;
}

.apple-id-card__row {
    display: flex;
    align-items: stretch;
    gap: 10px;
    margin-bottom: 10px;
}

.apple-id-card__row:last-child {
    margin-bottom: 0;
}

.apple-id-card__field {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px 8px;
    background: #f5f5f5;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 14px;
    color: #111;
}

.apple-id-card__label {
    font-weight: 600;
    flex-shrink: 0;
}

.apple-id-card__value {
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
    font-size: 13px;
    word-break: break-all;
}

.apple-id-card__copy {
    flex-shrink: 0;
    align-self: center;
    min-width: 72px;
    padding: 10px 16px;
    border: none;
    border-radius: 8px;
    background: #2ecc71;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.15s ease;
}

.apple-id-card__copy:hover {
    background: #27ae60;
}

.apple-id-card__copy:active {
    transform: scale(0.98);
}

.apple-id-card__copy.is-copied {
    background: #1abc9c;
}

@media (max-width: 520px) {
    .apple-id-card__row {
        flex-direction: column;
    }

    .apple-id-card__copy {
        align-self: stretch;
        width: 100%;
    }
}

/* Actions */
.actions-section {
    display: flex;
    gap: 16px;
    margin: 32px 0;
}

.btn-action {
    padding: 12px 24px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: opacity var(--transition-fast);
}

.btn-action:hover {
    opacity: 0.9;
}

.btn-reactivate {
    background: var(--accent);
    color: var(--bg-white);
}

.btn-cancel {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--text-primary);
}

/* Plans table */
.plans-section {
    margin: 40px 0;
}

.plans-section h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
}

.table-wrapper {
    overflow-x: auto;
}

.plans-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.plans-table th,
.plans-table td {
    padding: 12px 16px;
    border: 1px solid var(--border-light);
    text-align: left;
}

.plans-table th {
    background: #f5f5f5;
    font-weight: 600;
}

.plans-table tbody tr:hover {
    background: #fafafa;
}

/* Contact section */
.contact-section {
    margin-top: 40px;
}

.contact-section h2 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 16px;
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
}

.contact-link {
    display: block;
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
    line-height: 1.5;
}

.contact-link:hover {
    text-decoration: underline;
}

/* Footer */
.footer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 14px;
    padding: 20px 16px 24px;
    background: rgba(0, 0, 0, 0.8);
}

.footer-copyright {
    margin: 0;
    color: #808080;
    font-size: 13px;
}

.footer-friendly {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    max-width: 640px;
    text-align: center;
}

.footer-friendly__label {
    font-size: 13px;
    font-weight: 600;
    color: #a0a0a0;
    letter-spacing: 0.05em;
}

.footer-friendly__links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px 6px;
    font-size: 13px;
}

.footer-friendly__links a {
    color: #b8b8b8;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-friendly__links a:hover {
    color: #e8e8e8;
    text-decoration: underline;
}

.footer-friendly__sep {
    color: #555;
    user-select: none;
    font-size: 12px;
}

/* Responsive */
@media (max-width: 900px) {
    .content-container {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border-light);
        padding: 16px 20px;
    }

    .sidebar-nav {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }

    .nav-item {
        padding: 8px 12px;
    }

    .sub-nav {
        display: none;
    }

    .main-content {
        padding: 24px 24px 40px;
    }

    .hero-featured {
        flex-direction: column;
    }

    .hero-featured-right {
        width: 100%;
        justify-content: center;
        align-items: center;
    }
}

@media (max-width: 600px) {
    .actions-section {
        flex-direction: column;
    }

    .btn-action {
        text-align: center;
    }
}
