/* AiteRich Download Center - Matching old /技术支持/ style */

.adc-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 96px 20px 40px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Microsoft YaHei", sans-serif;
}

/* ── Banner (blue wave gradient) ── */
.adc-banner {
    background: linear-gradient(180deg, #a8d4f5 0%, #d4ecfc 40%, #e8f4fd 70%, #f0f8ff 100%);
    color: #1a5dad;
    text-align: center;
    min-height: 195px;
    padding: 60px 20px 80px;
    margin: 0 -20px 0;
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
}
.adc-banner::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 60'%3E%3Cpath d='M0 30 Q150 0 300 30 T600 30 T900 30 T1200 30 V60 H0Z' fill='%23ffffff'/%3E%3Cpath d='M0 40 Q200 15 400 35 T800 35 T1200 40 V60 H0Z' fill='%23ffffff' opacity='0.5'/%3E%3C/svg%3E") no-repeat bottom center;
    background-size: cover;
}
.adc-banner h2 {
    font-size: 42px;
    font-weight: 700;
    margin: 0;
    color: #1a5dad;
    position: relative;
    z-index: 1;
}

/* ── Search box ── */
.adc-search-wrap {
    max-width: 500px;
    margin: 24px auto 0;
    display: flex;
    position: relative;
    z-index: 1;
}
.adc-search-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-right: none;
    border-radius: 4px 0 0 4px;
    font-size: 15px;
    outline: none;
    color: #333;
    background: #fff;
}
.adc-search-input::placeholder {
    color: #aaa;
}
.adc-search-btn {
    padding: 0 20px;
    background: #1a6cb5;
    color: #fff;
    border: 1px solid #1a6cb5;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.adc-search-btn svg {
    width: 20px;
    height: 20px;
    fill: #fff;
}

/* ── Notice bar ── */
.adc-notice {
    background: #fffbeb;
    border: 1px solid #e5e7eb;
    border-left: 4px solid #f59e0b;
    padding: 14px 20px;
    margin: 24px 0;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}
.adc-notice-title {
    font-weight: 700;
    color: #92400e;
    margin-right: 8px;
}
.adc-notice-text {
    color: #78350f;
    font-size: 14px;
    flex: 1;
}
.adc-notice-close {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #9ca3af;
    padding: 0 4px;
    line-height: 1;
    margin-left: auto;
    flex-shrink: 0;
}

/* ── Tabs (pill-style matching screenshot) ── */
.adc-tabs {
    display: flex;
    margin: 24px 0;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
}
.adc-tab {
    flex: 1;
    padding: 14px 16px;
    font-size: 15px;
    font-weight: 600;
    color: #374151;
    background: #fff;
    border: none;
    border-right: 1px solid #e5e7eb;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
}
.adc-tab:last-child {
    border-right: none;
}
.adc-tab:hover {
    background: #f3f4f6;
}
.adc-tab.active {
    background: #1a5dad;
    color: #fff;
}
.adc-tab-icon {
    display: inline-flex;
    width: 20px;
    height: 20px;
}
.adc-tab-icon svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* ── File list (two-column, simple rows like screenshot) ── */
.adc-panel {
    display: none;
}
.adc-panel.active {
    display: block;
}

.adc-files {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}

.adc-file {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 12px;
    border-bottom: 1px solid #f3f4f6;
    text-decoration: none;
    color: #374151;
    cursor: pointer;
    transition: color 0.15s, background 0.15s;
}
.adc-file:hover {
    color: #1a5dad;
    background: #f8fafc;
}

.adc-file-icon {
    flex-shrink: 0;
    color: #1a5dad;
    display: flex;
    align-items: center;
}
.adc-file-icon svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.adc-file-name {
    font-size: 14px;
    line-height: 1.5;
}

/* No-file placeholder (items without PDF) */
.adc-file.adc-file--nolink {
    opacity: 0.55;
    cursor: default;
}
.adc-file--nolink .adc-file-icon {
    color: #9ca3af;
}

/* ── Separator between left/right columns (visual) ── */
.adc-file:nth-child(odd) {
    border-right: 1px solid #f3f4f6;
}

/* ── Empty state ── */
.adc-empty {
    text-align: center;
    color: #9ca3af;
    padding: 40px 0;
    font-size: 15px;
    grid-column: 1 / -1;
}

/* ── Cooperation tab ── */
.adc-cooperation {
    text-align: center;
    padding: 48px 20px;
    color: #6b7280;
}
.adc-cooperation p {
    margin: 0 0 20px;
    font-size: 15px;
}
.adc-cooperation a {
    display: inline-block;
    padding: 10px 32px;
    background: #1a5dad;
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
}
.adc-cooperation a:hover {
    background: #15498e;
    color: #fff;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .adc-wrap {
        padding-top: 252px;
    }
    .adc-banner {
        min-height: 150px;
        padding: 40px 16px 60px;
    }
    .adc-banner h2 {
        font-size: 28px;
    }
    .adc-files {
        grid-template-columns: 1fr;
    }
    .adc-file:nth-child(odd) {
        border-right: none;
    }
    .adc-tabs {
        flex-wrap: wrap;
    }
    .adc-tab {
        flex: 1 1 45%;
        font-size: 13px;
        padding: 10px 8px;
    }
    .adc-tab:nth-child(2) {
        border-right: none;
    }
    .adc-tab:nth-child(1),
    .adc-tab:nth-child(2) {
        border-bottom: 1px solid #e5e7eb;
    }
}

/* V3.0 staging UI notes: explicit contrast polish for final UAT. */
.adc-file { background: #ffffff; color: #111827; }
.adc-file:hover, .adc-file:focus-visible { background: #eef6ff; color: #0b4f91; }
.adc-file-name { color: inherit; }
.adc-file.adc-file--nolink { color: #4b5563; opacity: 1; }
.adc-file--nolink .adc-file-icon { color: #6b7280; }
.adc-tab.active { background: #0b4f91; color: #ffffff; }

/* V6.2 staging: inline download login dialog for saved browser credentials. */
.aiterich-download-login-modal[hidden] {
    display: none;
}

.aiterich-download-login-modal-open {
    overflow: hidden;
}

.aiterich-download-login-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.aiterich-download-login-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.48);
}

.aiterich-download-login-modal__dialog {
    position: relative;
    width: min(100%, 420px);
    max-height: calc(100vh - 48px);
    overflow: auto;
    background: #ffffff;
    border: 1px solid #dbe7f2;
    border-radius: 8px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
    padding: 28px;
}

.aiterich-download-login-modal__close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 6px;
    background: #f1f5f9;
    color: #475569;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.aiterich-download-login-modal__close:hover,
.aiterich-download-login-modal__close:focus-visible {
    background: #e2e8f0;
    color: #0f172a;
}

.aiterich-download-login-modal__head {
    padding-right: 28px;
}

.aiterich-download-login-modal__kicker {
    margin: 0 0 8px;
    color: #0b4f91;
    font-size: 12px;
    font-weight: 700;
}

.aiterich-download-login-modal__head h2 {
    margin: 0;
    color: #0f172a;
    font-size: 22px;
    line-height: 1.35;
    font-weight: 700;
}

.aiterich-download-login-modal__file {
    margin: 8px 0 0;
    color: #64748b;
    font-size: 13px;
    line-height: 1.6;
}

.aiterich-download-login-modal__form {
    margin-top: 22px;
}

.aiterich-download-login-modal__field {
    margin-bottom: 16px;
}

.aiterich-download-login-modal__field label {
    display: block;
    margin-bottom: 6px;
    color: #334155;
    font-size: 14px;
    font-weight: 600;
}

.aiterich-download-login-modal__field input {
    width: 100%;
    height: 46px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #ffffff;
    color: #0f172a;
    font-size: 15px;
    line-height: 1.4;
    padding: 10px 12px;
    box-shadow: none;
}

.aiterich-download-login-modal__field input:focus {
    border-color: #0b4f91;
    outline: 2px solid rgba(11, 79, 145, 0.16);
    outline-offset: 0;
}

.aiterich-download-login-modal__error {
    margin: 0 0 14px;
    padding: 10px 12px;
    border: 1px solid #fecaca;
    border-radius: 6px;
    background: #fff1f2;
    color: #b91c1c;
    font-size: 13px;
    line-height: 1.5;
}

.aiterich-download-login-modal__submit {
    width: 100%;
    min-height: 46px;
    border: 0;
    border-radius: 6px;
    background: #0b4f91;
    color: #ffffff;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
}

.aiterich-download-login-modal__submit:hover,
.aiterich-download-login-modal__submit:focus-visible {
    background: #083f74;
}

.aiterich-download-login-modal__submit:disabled {
    cursor: wait;
    opacity: 0.72;
}

.aiterich-download-login-modal__link {
    display: block;
    margin-top: 14px;
    color: #0b4f91;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
}

.aiterich-download-login-modal__link:hover,
.aiterich-download-login-modal__link:focus-visible {
    color: #083f74;
    text-decoration: underline;
}

@media (max-width: 480px) {
    .aiterich-download-login-modal {
        align-items: flex-end;
        padding: 12px;
    }

    .aiterich-download-login-modal__dialog {
        width: 100%;
        padding: 24px 18px 20px;
    }
}
