/* 前端搜索页样式 - 轻快简约 */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(180deg, #f7fbff 0%, #eef3f8 48%, #f8fafc 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 860px;
    margin: 0 auto;
    padding: 0 16px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 导航 */
.header { padding: 16px 0; }
.nav-top { display: flex; justify-content: flex-end; gap: 8px; align-items: center; }
.btn-submit, .nav-extra-btn {
    padding: 7px 15px; border-radius: 999px; border: 1px solid #d9e2ef;
    background: rgba(255,255,255,0.86); color: #526071; cursor: pointer; font-size: 13px;
    text-decoration: none; transition: all 0.2s; box-shadow: 0 6px 18px rgba(15,23,42,0.06);
}
.btn-submit:hover, .nav-extra-btn:hover { border-color: #2563eb; color: #2563eb; transform: translateY(-1px); }

/* 主区域 */
.main { flex: 1; text-align: center; padding: 54px 0 28px; }

.site-title {
    font-size: 42px; color: #111827; margin-bottom: 12px; font-weight: 800;
    letter-spacing: 0;
    line-height: 1.1;
}

.banner-texts { margin-bottom: 24px; }
.banner-text { color: #617084; font-size: 14px; margin: 5px 0; }

/* 搜索框 */
.search-box { max-width: 620px; margin: 0 auto; }
.search-input-wrap {
    display: flex; background: rgba(255,255,255,0.96); border-radius: 26px;
    overflow: hidden; box-shadow: 0 18px 45px rgba(37,99,235,0.12), 0 2px 10px rgba(15,23,42,0.06);
    border: 2px solid transparent; transition: border-color 0.2s;
}
.search-input-wrap:focus-within { border-color: #2563eb; }
.search-input-wrap input {
    flex: 1; padding: 15px 20px; border: none; outline: none;
    font-size: 15px; background: transparent;
}
.btn-search {
    padding: 15px 30px; background: #2563eb; color: #fff; border: none;
    cursor: pointer; font-size: 15px; font-weight: 600; transition: background 0.2s;
    border-radius: 0 26px 26px 0;
}
.btn-search:hover { background: #1d4ed8; }

/* 网盘类型选择 - 带图标全名 */
.search-pan-types {
    display: flex; justify-content: center; gap: 6px;
    margin-top: 14px; flex-wrap: wrap;
}
.pan-type-btn {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 7px 14px; border-radius: 18px; cursor: pointer;
    background: #fff; color: #666; font-size: 13px; transition: all 0.2s;
    border: 1px solid #e8e8e8; user-select: none;
}
.pan-type-btn input { display: none; }
.pan-type-btn .pan-svg { vertical-align: middle; flex-shrink: 0; }
.pan-type-btn.active { background: #2563eb; color: #fff; border-color: #2563eb; }
.pan-type-btn.active .pan-count { color: #fff; font-weight: 700; }
.pan-type-btn:hover { border-color: #2563eb; }
.pan-count { font-size: 13px; color: #e74c3c; margin-left: 2px; font-weight: 700; }

/* 搜索结果 - 紧凑框选 */
.results { margin-top: 20px; text-align: left; }
.result-list-box {
    background: rgba(255,255,255,0.98); border-radius: 14px; overflow: hidden;
    box-shadow: 0 12px 28px rgba(15,23,42,0.08);
    border: 1px solid rgba(226,232,240,0.9);
}

.result-item {
    padding: 13px 16px; display: flex; align-items: center; gap: 12px;
    transition: background 0.15s; border-bottom: 1px solid #f0f0f0;
}
.result-item:last-child { border-bottom: none; }
.result-item:hover { background: #f8fbff; }

.result-left { flex: 1; min-width: 0; }
.result-title { font-size: 14px; font-weight: 500; color: #1a1a1a; line-height: 1.5;
    word-break: break-all; white-space: normal; }
.result-source { font-size: 12px; color: #bbb; margin-top: 2px; }

.result-right { flex-shrink: 0; }
.result-link {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 6px 14px; border-radius: 6px; font-size: 13px; text-decoration: none;
    color: #fff; transition: opacity 0.2s; border: none; cursor: pointer; font-weight: 500;
}
.result-link:hover { opacity: 0.85; }
.result-link svg { vertical-align: middle; }
.result-link.pan-baidu { background: #06a7ff; }
.result-link.pan-quark { background: #4e6ef2; }
.result-link.pan-xunlei { background: #0c8cf5; }
.result-link.pan-uc { background: #fa6400; }

/* Loading */
.loading { text-align: center; padding: 40px; color: #999; }
.spinner {
    width: 32px; height: 32px; margin: 0 auto 12px;
    border: 3px solid #eee; border-top-color: #4e6ef2;
    border-radius: 50%; animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.no-result {
    text-align: center; padding: 40px; color: #bbb; font-size: 14px;
}

/* 弹窗 */
.popup-modal, .anti-red-modal, .captcha-modal {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.4); display: flex; align-items: center;
    justify-content: center; z-index: 1000;
}
.popup-content, .anti-red-content, .captcha-content {
    background: #fff; border-radius: 14px; padding: 28px; max-width: 480px;
    width: 90%; max-height: 80vh; overflow-y: auto; position: relative;
    text-align: center;
}
.popup-close {
    position: absolute; top: 10px; right: 15px; border: none; background: none;
    font-size: 22px; cursor: pointer; color: #ccc;
}
.popup-image { max-width: 100%; border-radius: 8px; margin-bottom: 12px; }
.btn-agree, .btn-copy {
    margin-top: 12px; padding: 10px 28px; border: none; border-radius: 8px;
    background: #4e6ef2; color: #fff; cursor: pointer; font-size: 14px;
}
.anti-red-icon { font-size: 42px; color: #faad14; font-weight: bold; margin-bottom: 8px; }
.anti-red-url {
    margin: 12px 0; padding: 10px; background: #f7f8fa; border-radius: 8px;
    word-break: break-all; font-family: monospace; font-size: 13px;
}

/* 验证码 */
.captcha-img-wrap { margin: 12px 0; position: relative; display: inline-block; }
.captcha-img-wrap img { border: 1px solid #eee; border-radius: 4px; }
.captcha-refresh {
    position: absolute; right: -50px; top: 50%; transform: translateY(-50%);
    color: #4e6ef2; cursor: pointer; font-size: 13px;
}
#captcha-input {
    padding: 8px; font-size: 16px; text-align: center; letter-spacing: 6px;
    border: 1px solid #ddd; border-radius: 6px; width: 140px;
}
.btn-captcha {
    display: block; margin: 12px auto 0; padding: 8px 36px;
    border: none; border-radius: 6px; background: #4e6ef2; color: #fff;
    cursor: pointer; font-size: 14px;
}

/* Footer */
.footer {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    text-align: center;
    padding: 18px 16px 24px;
    background: #e8f4cf;
    color: #5f6b57;
    font-size: 14px;
    line-height: 1.8;
}
.footer-inner {
    max-width: 1120px;
    margin: 0 auto;
}
.footer-notice {
    max-width: 1120px;
    margin: 0 auto;
}
.footer-friends,
.footer-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
}
.footer a,
.footer-link {
    color: inherit;
    text-decoration: none;
}
.footer a:hover,
.footer-link:hover {
    color: #2563eb;
}
.footer-label {
    color: inherit;
}

/* 响应式 */
@media (max-width: 768px) {
    .site-title { font-size: 30px; }
    .main { padding: 30px 0 16px; }
    .search-input-wrap input { padding: 12px 16px; font-size: 14px; }
    .btn-search { padding: 12px 20px; font-size: 14px; }
    .pan-type-btn { padding: 5px 10px; font-size: 12px; }
}
@media (max-width: 480px) {
    .site-title { font-size: 24px; }
    .banner-text { font-size: 13px; }
    .result-item { padding: 10px 12px; flex-wrap: wrap; }
    .result-right { width: 100%; text-align: right; }
    .footer { font-size: 13px; padding: 16px 14px 22px; }
    .footer-notice { text-align: center; }
}
