@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

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

html {
    scroll-behavior: smooth;
    overflow-x: clip;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #F3F4F6;
    color: #1F2937;
    line-height: 1.6;
    overflow-x: clip;
    max-width: 100%;
}

.container {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    min-height: 100vh;
    max-width: 100%;
}

.sidebar {
    background: #0F1115;
    padding: 32px 24px;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.logo {
    margin-bottom: 40px;
}

.logo img {
    width: 180px;
    height: auto;
}

.nav-section {
    margin-bottom: 32px;
}

.nav-title {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    color: #6B7280;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-title-icon {
    width: 10px;
    height: 10px;
}

.nav-item {
    padding: 10px 16px;
    margin-bottom: 4px;
    color: #9CA3AF;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    border-radius: 12px;
    transition: all 0.2s ease;
    font-size: 14px;
}

.nav-item i {
    width: 8px;
    height: 8px;
}

.nav-item:hover {
    background: rgba(127, 86, 217, 0.1);
    color: #7F56D9;
    transform: translateX(4px);
}

.nav-item.active {
    background: linear-gradient(135deg, #7F56D9 0%, #6C42E6 100%);
    color: #FFFFFF;
}

.main-content {
    padding: 32px 20px;
    max-width: 1200px;
    min-width: 0;
}

@media (min-width: 769px) {
    .main-content {
        padding: 40px 48px;
    }
}

@media (min-width: 1024px) {
    .main-content {
        padding: 48px 64px;
    }
}

.visual-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    padding: 48px 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(127, 86, 217, 0.02) 0%, rgba(108, 66, 230, 0.04) 100%);
}

.visual-container {
    width: 100%;
}

.visual-container img {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 40px rgba(127, 86, 217, 0.3));
}

.hero {
    background: linear-gradient(135deg, #7F56D9 0%, #6C42E6 100%);
    border-radius: 16px;
    padding: 48px;
    margin-bottom: 48px;
    color: #FFFFFF;
    box-shadow: 0 20px 40px rgba(127, 86, 217, 0.2);
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.15);
    padding: 8px 16px;
    border-radius: 24px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 20px;
    backdrop-filter: blur(10px);
}

.hero-badge i {
    width: 16px;
    height: 16px;
}

.hero h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 16px;
}

.hero p {
    font-size: 18px;
    opacity: 0.9;
    max-width: none;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.section {
    background: #FFFFFF;
    border-radius: 16px;
    padding: 40px;
    margin-bottom: 32px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

.section h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 24px;
    color: #0F1115;
    display: flex;
    align-items: center;
    gap: 12px;
}

.section-icon {
    width: 28px;
    height: 28px;
    color: #7F56D9;
}

.section h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 16px;
    margin-top: 32px;
    color: #374151;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section h3 i {
    width: 20px;
    height: 20px;
    color: #7F56D9;
}

.section p {
    color: #6B7280;
    margin-bottom: 16px;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.code-block {
    background: #0F1115;
    border-radius: 12px;
    padding: 24px;
    margin: 24px 0;
    overflow-x: auto;
    max-width: 100%;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.code-block pre {
    color: #E5E7EB;
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 14px;
    line-height: 1.6;
}

.code-block code {
    color: #10B981;
}

.badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    margin-right: 8px;
}

.badge.get {
    background: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

.badge.post {
    background: rgba(127, 86, 217, 0.1);
    color: #7F56D9;
}

.badge.delete {
    background: rgba(239, 68, 68, 0.1);
    color: #EF4444;
}

.endpoint {
    display: flex;
    align-items: center;
    background: #F9FAFB;
    border-radius: 12px;
    padding: 16px 20px;
    margin: 16px 0;
    border-left: 4px solid #7F56D9;
}

.endpoint code {
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 14px;
    color: #0F1115;
    margin-left: 12px;
}

.params-table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
}

.params-table th {
    text-align: left;
    padding: 12px 16px;
    background: #F9FAFB;
    font-weight: 600;
    font-size: 14px;
    color: #374151;
    border-bottom: 2px solid #E5E7EB;
}

.params-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #E5E7EB;
    color: #6B7280;
    font-size: 14px;
}

.params-table tr:hover {
    background: #F9FAFB;
}

.grid-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    gap: 24px;
    margin: 32px 0;
    max-width: 100%;
}

.card {
    background: #FFFFFF;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.card-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, rgba(127, 86, 217, 0.1) 0%, rgba(108, 66, 230, 0.1) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.card-icon i {
    width: 20px;
    height: 20px;
    color: #7F56D9;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(127, 86, 217, 0.15);
    border-color: #7F56D9;
}

.card h4 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #0F1115;
}

.card p {
    font-size: 14px;
    color: #6B7280;
}

.step-card {
    background: #FFFFFF;
    border-radius: 16px;
    padding: 0;
    margin: 20px 0;
    display: grid;
    grid-template-columns: auto 1fr;
    overflow: hidden;
    border: 1px solid #E5E7EB;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.step-card:hover {
    border-color: rgba(127, 86, 217, 0.35);
    box-shadow: 0 8px 24px rgba(127, 86, 217, 0.12);
    transform: translateY(-2px);
}

.step-number {
    width: 80px;
    background: linear-gradient(135deg, #7F56D9 0%, #6C42E6 100%);
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 32px;
    flex-shrink: 0;
    position: relative;
}

.step-number::after {
    content: '';
    position: absolute;
    right: -20px;
    width: 40px;
    height: 100%;
    background: linear-gradient(135deg, #7F56D9 0%, #6C42E6 100%);
    clip-path: polygon(0 0, 100% 0, 50% 100%, 0 100%);
    opacity: 0.15;
}

.step-content {
    padding: 28px 32px;
    flex: 1;
}

.step-content h4 {
    font-size: 18px;
    font-weight: 600;
    color: #0F1115;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.step-content p {
    color: #6B7280;
    font-size: 14px;
    margin-bottom: 14px;
    line-height: 1.6;
}

.step-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #FFFFFF;
    background: linear-gradient(135deg, #7F56D9 0%, #6C42E6 100%);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    padding: 10px 18px;
    border-radius: 10px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(127, 86, 217, 0.25);
}

.step-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(127, 86, 217, 0.35);
}

.step-link i {
    width: 14px;
    height: 14px;
}

.key-types {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    gap: 20px;
    margin-top: 20px;
    max-width: 100%;
}

.key-card {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 24px;
    border: 2px solid #E5E7EB;
    transition: all 0.3s ease;
}

.key-card:hover {
    border-color: #7F56D9;
    box-shadow: 0 8px 24px rgba(127, 86, 217, 0.12);
}

.key-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 12px;
}

.key-badge i {
    width: 16px;
    height: 16px;
}

.key-badge.public {
    background: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

.key-badge.secret {
    background: rgba(127, 86, 217, 0.1);
    color: #7F56D9;
}

.key-format {
    display: block;
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 16px;
    color: #0F1115;
    background: #F9FAFB;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 12px;
}

.key-card p {
    color: #6B7280;
    font-size: 14px;
    margin: 0;
}

.required-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    background: rgba(239, 68, 68, 0.1);
    color: #EF4444;
}

.optional-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    background: rgba(107, 114, 128, 0.1);
    color: #6B7280;
}

.info-card {
    background: linear-gradient(135deg, rgba(127, 86, 217, 0.05) 0%, rgba(108, 66, 230, 0.08) 100%);
    border-radius: 12px;
    padding: 20px 24px;
    margin: 24px 0;
    border-left: 4px solid #7F56D9;
}

.info-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.info-card-header i {
    width: 20px;
    height: 20px;
    color: #7F56D9;
}

.info-card-header h4 {
    font-size: 16px;
    font-weight: 600;
    color: #0F1115;
    margin: 0;
}

.info-card-header code {
    font-size: 13px;
    color: #7F56D9;
    background: rgba(127, 86, 217, 0.1);
    padding: 4px 8px;
    border-radius: 6px;
}

.info-card p {
    color: #374151;
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
}

.code-tabs {
    margin: 24px 0;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid #E5E7EB;
    max-width: 100%;
}

.code-tabs-nav {
    display: flex;
    background: #F9FAFB;
    border-bottom: 2px solid #E5E7EB;
    overflow-x: auto;
}

.code-tab-btn {
    padding: 14px 24px;
    background: transparent;
    border: none;
    font-size: 14px;
    font-weight: 500;
    color: #6B7280;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 3px solid transparent;
    white-space: nowrap;
}

.code-tab-btn i {
    width: 16px;
    height: 16px;
    font-size: 16px;
}

.code-tab-btn svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.code-tab-btn:hover {
    background: rgba(127, 86, 217, 0.05);
    color: #7F56D9;
}

.code-tab-btn.active {
    color: #7F56D9;
    background: #FFFFFF;
    border-bottom-color: #7F56D9;
}

.code-tab-content {
    display: none;
}

.code-tab-content.active {
    display: block;
}

.code-tab-content .code-block {
    margin: 0;
    border-radius: 0;
}

.flow-cards {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin: 24px 0;
}

.flow-card {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 24px;
    border: 2px solid #E5E7EB;
}

.flow-header {
    margin-bottom: 16px;
}

.flow-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 12px;
}

.flow-badge.true {
    background: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

.flow-badge.false {
    background: rgba(239, 68, 68, 0.1);
    color: #EF4444;
}

.flow-header h4 {
    font-size: 18px;
    font-weight: 600;
    color: #0F1115;
    margin-bottom: 8px;
}

.flow-card p {
    color: #6B7280;
    font-size: 14px;
    margin-bottom: 16px;
}

.error-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 24px 0;
}

.error-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: #FFFFFF;
    border-radius: 10px;
    border-left: 4px solid #EF4444;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.error-item code {
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 13px;
    color: #EF4444;
    font-weight: 600;
}

.error-item span {
    color: #6B7280;
    font-size: 14px;
}

.status-timeline {
    margin: 32px 0;
}

.status-section {
    margin-bottom: 40px;
}

.status-section:last-child {
    margin-bottom: 0;
}

.status-section-title {
    font-size: 14px;
    font-weight: 600;
    color: #6B7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
    padding-left: 4px;
}

.status-flow-horizontal {
    display: flex;
    align-items: stretch;
    gap: 0;
    margin-bottom: 16px;
}

.status-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    flex-shrink: 0;
}

.status-arrow i {
    width: 24px;
    height: 24px;
    color: #9CA3AF;
}

.status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    gap: 16px;
    max-width: 100%;
}

.status-card {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 24px;
    flex: 1;
    min-width: 180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border: 2px solid;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.status-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    opacity: 0.6;
}

.status-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.status-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.status-icon i {
    width: 28px;
    height: 28px;
}

.status-name {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: 0.5px;
}

.status-desc {
    font-size: 13px;
    color: #6B7280;
    line-height: 1.4;
}

.status-card.pending {
    border-color: #FDB022;
    background: linear-gradient(135deg, rgba(253, 176, 34, 0.02) 0%, rgba(251, 191, 36, 0.05) 100%);
}

.status-card.pending::before {
    background: linear-gradient(90deg, #FDB022 0%, #FBBF24 100%);
}

.status-card.pending .status-icon {
    background: rgba(253, 176, 34, 0.1);
    color: #F59E0B;
}

.status-card.pending .status-name {
    color: #F59E0B;
}

.status-card.processing {
    border-color: #3B82F6;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.02) 0%, rgba(59, 130, 246, 0.05) 100%);
}

.status-card.processing::before {
    background: linear-gradient(90deg, #3B82F6 0%, #60A5FA 100%);
}

.status-card.processing .status-icon {
    background: rgba(59, 130, 246, 0.1);
    color: #3B82F6;
}

.status-card.processing .status-name {
    color: #3B82F6;
}

.status-card.paid {
    border-color: #10B981;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.02) 0%, rgba(16, 185, 129, 0.05) 100%);
}

.status-card.paid::before {
    background: linear-gradient(90deg, #10B981 0%, #34D399 100%);
}

.status-card.paid .status-icon {
    background: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

.status-card.paid .status-name {
    color: #10B981;
}

.status-card.failed {
    border-color: #EF4444;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.02) 0%, rgba(239, 68, 68, 0.05) 100%);
}

.status-card.failed::before {
    background: linear-gradient(90deg, #EF4444 0%, #F87171 100%);
}

.status-card.failed .status-icon {
    background: rgba(239, 68, 68, 0.1);
    color: #EF4444;
}

.status-card.failed .status-name {
    color: #EF4444;
}

.status-card.expired {
    border-color: #6B7280;
    background: linear-gradient(135deg, rgba(107, 114, 128, 0.02) 0%, rgba(107, 114, 128, 0.05) 100%);
}

.status-card.expired::before {
    background: linear-gradient(90deg, #6B7280 0%, #9CA3AF 100%);
}

.status-card.expired .status-icon {
    background: rgba(107, 114, 128, 0.1);
    color: #6B7280;
}

.status-card.expired .status-name {
    color: #6B7280;
}

.status-card.refund {
    border-color: #A855F7;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.02) 0%, rgba(168, 85, 247, 0.05) 100%);
}

.status-card.refund::before {
    background: linear-gradient(90deg, #A855F7 0%, #C084FC 100%);
}

.status-card.refund .status-icon {
    background: rgba(168, 85, 247, 0.1);
    color: #A855F7;
}

.status-card.refund .status-name {
    color: #A855F7;
}

.status-card.chargeback {
    border-color: #DC2626;
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.02) 0%, rgba(239, 68, 68, 0.05) 100%);
}

.status-card.chargeback::before {
    background: linear-gradient(90deg, #DC2626 0%, #EF4444 100%);
}

.status-card.chargeback .status-icon {
    background: rgba(220, 38, 38, 0.1);
    color: #DC2626;
}

.status-card.chargeback .status-name {
    color: #DC2626;
}

@media (max-width: 768px) {
    html {
        scroll-padding-top: 64px;
    }

    .container {
        display: block;
        width: 100%;
        max-width: 100%;
        overflow-x: clip;
    }

    .mobile-header {
        display: flex;
        align-items: center;
        gap: 12px;
        position: sticky;
        top: 0;
        z-index: 90;
        width: 100%;
        max-width: 100%;
        padding: 12px 16px;
        background: #0F1115;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    }

    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        border: 1px solid rgba(255, 255, 255, 0.12);
        border-radius: 10px;
        background: rgba(255, 255, 255, 0.06);
        color: #FFFFFF;
        cursor: pointer;
        flex-shrink: 0;
        transition: background 0.2s ease;
    }

    .mobile-menu-btn:hover {
        background: rgba(127, 86, 217, 0.25);
    }

    .mobile-menu-btn i {
        width: 20px;
        height: 20px;
    }

    .mobile-header-logo {
        display: flex;
        align-items: center;
        min-width: 0;
    }

    .mobile-header-logo img {
        height: 28px;
        width: auto;
        max-width: 140px;
        object-fit: contain;
    }

    .sidebar-backdrop {
        position: fixed;
        inset: 0;
        z-index: 110;
        background: rgba(15, 17, 21, 0.55);
        backdrop-filter: blur(4px);
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.25s ease, visibility 0.25s ease;
    }

    .sidebar-backdrop.visible {
        opacity: 1;
        visibility: visible;
    }

    body.menu-open {
        overflow: hidden;
    }

    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        z-index: 120;
        width: min(300px, 88vw);
        height: 100vh;
        height: 100dvh;
        padding: 20px 16px 24px;
        transform: translateX(-105%);
        transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.28s ease;
        box-shadow: 8px 0 32px rgba(0, 0, 0, 0.35);
        visibility: hidden;
        pointer-events: none;
    }

    .sidebar.open {
        transform: translateX(0);
        visibility: visible;
        pointer-events: auto;
    }

    .sidebar-close-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        top: 16px;
        right: 16px;
        width: 36px;
        height: 36px;
        border: 1px solid rgba(255, 255, 255, 0.12);
        border-radius: 10px;
        background: rgba(255, 255, 255, 0.06);
        color: #9CA3AF;
        cursor: pointer;
    }

    .sidebar-close-btn:hover {
        color: #FFFFFF;
        background: rgba(255, 255, 255, 0.12);
    }

    .sidebar-close-btn i {
        width: 18px;
        height: 18px;
    }

    .sidebar .logo {
        margin-bottom: 28px;
        padding-right: 44px;
    }

    .sidebar .logo img {
        width: 150px;
    }

    .nav-item:hover {
        transform: none;
    }

    .visual-sidebar {
        display: none;
    }

    .main-content {
        padding: 20px 16px 32px;
        max-width: 100%;
        width: 100%;
        min-width: 0;
        overflow-x: clip;
    }

    .hero {
        padding: 28px 20px;
        margin-bottom: 24px;
        border-radius: 14px;
        max-width: 100%;
        overflow: hidden;
    }

    .hero-badge {
        font-size: 12px;
        padding: 6px 12px;
        margin-bottom: 14px;
    }

    .hero h1 {
        font-size: 28px;
        line-height: 1.15;
        margin-bottom: 12px;
        overflow-wrap: anywhere;
    }

    .hero p {
        font-size: 15px;
        line-height: 1.65;
    }

    .section {
        padding: 24px 18px;
        margin-bottom: 20px;
        border-radius: 14px;
        max-width: 100%;
        overflow: hidden;
    }

    .section h2 {
        font-size: 22px;
        flex-wrap: wrap;
        gap: 8px;
        margin-bottom: 16px;
    }

    .section h3 {
        font-size: 17px;
        margin-top: 24px;
        flex-wrap: wrap;
    }

    .section-icon {
        width: 24px;
        height: 24px;
    }

    .grid-cards {
        grid-template-columns: 1fr;
        gap: 16px;
        margin: 20px 0;
    }

    .card {
        padding: 20px;
        max-width: 100%;
        min-width: 0;
    }

    .step-card {
        display: flex;
        flex-direction: column;
        max-width: 100%;
        min-width: 0;
    }

    .step-number {
        width: 40px;
        height: 40px;
        margin: 18px 18px 0;
        border-radius: 12px;
        font-size: 18px;
        align-self: flex-start;
    }

    .step-number::after {
        display: none;
    }

    .step-content {
        padding: 14px 18px 20px;
    }

    .step-link {
        width: 100%;
        justify-content: center;
        word-break: break-all;
        text-align: center;
    }

    .key-types {
        grid-template-columns: 1fr;
    }

    .endpoint {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding: 14px 16px;
    }

    .endpoint code {
        margin-left: 0;
        word-break: break-all;
        font-size: 13px;
    }

    .table-scroll {
        margin: 16px 0;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-radius: 12px;
        border: 1px solid #E5E7EB;
        max-width: 100%;
    }

    .params-table {
        margin: 0;
        min-width: 520px;
        font-size: 13px;
    }

    .params-table th,
    .params-table td {
        padding: 10px 12px;
    }

    .code-block {
        padding: 16px;
        margin: 16px 0;
        border-radius: 10px;
    }

    .code-block pre {
        font-size: 12px;
        line-height: 1.55;
        white-space: pre-wrap;
        word-break: break-word;
    }

    .code-tab-btn {
        padding: 12px 16px;
        font-size: 13px;
    }

    .status-flow-horizontal {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .status-arrow {
        width: auto;
        height: 28px;
        transform: rotate(90deg);
    }

    .status-card {
        min-width: 0;
        width: 100%;
    }

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

    .error-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 14px 16px;
    }

    .error-item span {
        font-size: 13px;
    }

    .info-card {
        padding: 16px 18px;
    }

    .info-card-header {
        flex-wrap: wrap;
    }

    .flow-card {
        padding: 18px;
    }
}

@media (max-width: 480px) {
    .mobile-header {
        padding: 10px 12px;
    }

    .main-content {
        padding: 16px 12px 28px;
    }

    .hero {
        padding: 22px 16px;
    }

    .hero h1 {
        font-size: 24px;
    }

    .hero p {
        font-size: 14px;
    }

    .section {
        padding: 20px 14px;
    }

    .section h2 {
        font-size: 20px;
    }

    .params-table {
        min-width: 480px;
    }

    .code-block pre {
        font-size: 11px;
    }
}

/* Desktop-only: hide mobile chrome */
.mobile-header,
.sidebar-backdrop,
.sidebar-close-btn {
    display: none;
}

@media (max-width: 768px) {
    .mobile-header {
        display: flex;
    }

    .sidebar-backdrop {
        display: block;
    }

    .sidebar-close-btn {
        display: flex;
    }
}
