/* GEO AI Detection — 弹窗、Loading、样式 */

/* Modal overlay */
.geo-modal-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6);
    z-index: 99999;
    display: flex; align-items: center; justify-content: center;
    padding: 20px;
}

.geo-modal-box {
    background: #fff;
    border-radius: 16px;
    max-width: 480px;
    width: 100%;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: geoSlideUp 0.3s ease;
}

@keyframes geoSlideUp {
    from { transform: translateY(30px); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
}

.geo-modal-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 20px 24px 12px;
    border-bottom: 1px solid #eee;
}

.geo-modal-header h3 {
    font-size: 18px; font-weight: 600; margin: 0; color: #1a1a2e;
}

.geo-modal-close {
    background: none; border: none; font-size: 24px;
    color: #999; cursor: pointer; padding: 0; line-height: 1;
}

.geo-modal-close:hover { color: #333; }

.geo-modal-body { padding: 20px 24px; }

.geo-modal-desc {
    font-size: 14px; color: #666; line-height: 1.6; margin: 0 0 16px;
}

.geo-modal-input {
    width: 100%; padding: 12px 16px;
    border: 2px solid #e0e0e0; border-radius: 10px;
    font-size: 15px; outline: none; transition: border-color 0.2s;
    box-sizing: border-box;
}

.geo-modal-input:focus { border-color: #4f6ef7; }

.geo-quota-info {
    margin-top: 12px; font-size: 13px;
}

.geo-quota-ok { color: #10b981; }
.geo-quota-warn { color: #ef4444; font-weight: 500; }

.geo-modal-error {
    margin-top: 8px; font-size: 13px; color: #ef4444; display: none;
}

.geo-modal-footer {
    padding: 12px 24px 20px;
    display: flex; gap: 12px; justify-content: flex-end;
}

/* Loading */
.geo-loading-overlay { background: rgba(15,18,38,0.85); }

.geo-loading-box {
    text-align: center;
    color: #fff;
    max-width: 420px;
}

.geo-loading-spinner {
    width: 56px; height: 56px;
    border: 4px solid rgba(255,255,255,0.15);
    border-top-color: #6c5ce7;
    border-radius: 50%;
    margin: 0 auto 24px;
    animation: geoSpin 0.8s linear infinite;
}

@keyframes geoSpin { to { transform: rotate(360deg); } }

.geo-loading-box h3 {
    font-size: 20px; font-weight: 600; margin: 0 0 8px;
}

.geo-loading-url {
    font-size: 14px; color: #8b92c7; margin: 0 0 28px;
    word-break: break-all;
}

.geo-loading-steps {
    display: flex; flex-direction: column; gap: 14px;
    margin-bottom: 24px; text-align: left;
    max-width: 280px; margin-left: auto; margin-right: auto;
}

.geo-step {
    display: flex; align-items: center; gap: 12px;
    font-size: 14px; color: #5a5f72;
    transition: all 0.3s;
}

.geo-step.active { color: #fff; }

.geo-step.done { color: #55efc4; }
.geo-step.done .geo-step-num {
    background: #55efc4; color: #0f1226;
}

.geo-step-num {
    width: 28px; height: 28px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 600;
    background: rgba(255,255,255,0.1);
    color: #8b92c7;
    flex-shrink: 0;
    transition: all 0.3s;
}

.geo-step.active .geo-step-num {
    background: #6c5ce7; color: #fff;
    box-shadow: 0 0 0 4px rgba(108,92,231,0.2);
}

.geo-loading-tip {
    font-size: 12px; color: #5a5f72; margin: 0;
}

/* Error modal */
.geo-error-icon {
    width: 48px; height: 48px;
    border-radius: 50%;
    background: #fee;
    color: #ef4444;
    font-size: 24px; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px;
}

.geo-error-text {
    font-size: 15px; color: #333; text-align: center;
    line-height: 1.6; margin: 0;
}

/* AI badge on report page */
.geo-ai-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    color: #6c5ce7;
    background: rgba(108,92,231,0.1);
    margin-top: 8px;
}

/* Responsive */
@media (max-width: 480px) {
    .geo-modal-box { max-width: 100%; }
    .geo-modal-header h3 { font-size: 16px; }
    .geo-loading-box h3 { font-size: 18px; }
}
