/* 跳转链接生成器 - 全局样式 */
* { box-sizing: border-box; margin: 0; padding: 0; }

html { min-height: 100%; }
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background:
        linear-gradient(rgba(10, 30, 20, 0.45), rgba(10, 30, 20, 0.6)),
        url('bg.jpg') center top / cover no-repeat fixed;
    min-height: 100vh;
    color: #333;
    padding: 20px 0;
}

.container {
    max-width: 760px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Header */
.header {
    text-align: center;
    color: #fff;
    margin-bottom: 28px;
    position: relative;
}
.header h1 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
    text-shadow: 0 2px 10px rgba(0,0,0,.55), 0 0 20px rgba(0,0,0,.25);
}
.header p {
    font-size: 14px;
    opacity: .95;
    text-shadow: 0 1px 4px rgba(0,0,0,.45);
}
.nav-link {
    position: absolute;
    top: 0;
    right: 0;
    color: #fff;
    text-decoration: none;
    font-size: 13px;
    background: rgba(255,255,255,.18);
    padding: 6px 14px;
    border-radius: 20px;
    transition: background .2s;
}
.nav-link:hover { background: rgba(255,255,255,.32); }

/* Tabs */
.tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 6px;
    border-radius: 12px;
    box-shadow: 0 6px 24px rgba(0,0,0,.14);
}
.tab-btn {
    flex: 1;
    padding: 12px;
    border: none;
    background: transparent;
    color: #666;
    font-size: 15px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all .2s;
}
.tab-btn.active {
    background: #4f46e5;
    color: #fff;
    box-shadow: 0 2px 8px rgba(79,70,229,.35);
}

/* Panel */
.tab-panel {
    background: rgba(255,255,255,0.94);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 24px;
    border-radius: 14px;
    box-shadow: 0 6px 24px rgba(0,0,0,.14);
    display: none;
}
.tab-panel.active { display: block; }

.form-group { margin-bottom: 16px; }
.form-group label {
    display: block;
    font-size: 13px;
    color: #555;
    margin-bottom: 6px;
    font-weight: 600;
}
.form-group input,
.form-group select {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}
.form-group input:focus,
.form-group select:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79,70,229,.12);
}

/* Buttons */
.btn-primary {
    width: 100%;
    padding: 13px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform .15s, box-shadow .2s;
}
.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(79,70,229,.35);
}
.btn-primary:active { transform: translateY(0); }

.btn-copy {
    padding: 10px 16px;
    background: #4f46e5;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 13px;
    white-space: nowrap;
    transition: background .2s;
}
.btn-copy:hover { background: #4338ca; }

.btn-test {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 24px;
    background: #fff;
    color: #4f46e5;
    text-decoration: none;
    border: 2px solid #4f46e5;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: all .2s;
}
.btn-test:hover { background: #4f46e5; color: #fff; }

/* Upload */
.upload-area {
    border: 2px dashed #cbd5e1;
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: border-color .2s, background .2s;
    margin-bottom: 16px;
}
.upload-area:hover, .upload-area.drag {
    border-color: #4f46e5;
    background: #f5f3ff;
}
.upload-icon {
    font-size: 36px;
    color: #4f46e5;
    margin-bottom: 8px;
}
.upload-hint p { font-size: 14px; color: #666; margin: 2px 0; }
.upload-sub { font-size: 12px !important; color: #999 !important; }

.qr-result {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    padding: 14px;
}
.qr-result-title { font-size: 13px; color: #166534; font-weight: 600; margin-bottom: 6px; }
.qr-result-content {
    font-size: 14px;
    color: #064e3b;
    word-break: break-all;
    background: #fff;
    padding: 8px 10px;
    border-radius: 6px;
    margin-bottom: 8px;
}

/* Result card */
.result-card {
    background: rgba(255,255,255,0.94);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 24px;
    border-radius: 14px;
    margin-top: 20px;
    box-shadow: 0 6px 24px rgba(0,0,0,.14);
    border-left: 4px solid #22c55e;
}
.result-card h3 {
    color: #15803d;
    margin-bottom: 16px;
    font-size: 18px;
}
.result-row { margin-bottom: 16px; }
.result-label {
    display: block;
    font-size: 12px;
    color: #888;
    font-weight: 600;
    margin-bottom: 6px;
}
.result-link-wrap { display: flex; gap: 8px; }
.result-link-wrap input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 13px;
    background: #f9fafb;
    color: #333;
}
.result-tip { font-size: 12px; color: #888; margin-top: 6px; }
.result-note {
    font-size: 13px;
    color: #d97706;
    background: #fef3c7;
    padding: 8px 10px;
    border-radius: 6px;
}
.result-actions { margin-top: 8px; }

/* History */
.history {
    background: rgba(255,255,255,0.94);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 20px;
    border-radius: 14px;
    margin-top: 20px;
    box-shadow: 0 6px 24px rgba(0,0,0,.14);
}
.history h3 { color: #333; margin-bottom: 14px; font-size: 16px; }
.history-item {
    padding: 12px;
    border-bottom: 1px solid #f3f4f6;
}
.history-item:last-child { border-bottom: none; }
.hi-head {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}
.hi-type {
    background: #ede9fe;
    color: #5b21b6;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}
.hi-name { font-size: 13px; color: #333; font-weight: 600; }
.hi-time { font-size: 11px; color: #999; margin-left: auto; }
.hi-views { font-size: 11px; color: #4f46e5; }
.hi-account { font-size: 12px; color: #666; margin-bottom: 4px; }
.hi-link a { color: #4f46e5; font-size: 12px; text-decoration: none; word-break: break-all; }
.empty { text-align: center; color: #aaa; padding: 20px; font-size: 13px; line-height: 1.8; }
.btn-copy-inline,
.btn-del-inline {
    display: inline-block;
    padding: 4px 10px;
    font-size: 12px;
    border-radius: 8px;
    text-decoration: none;
    cursor: pointer;
    transition: all .15s;
    user-select: none;
    font-weight: 600;
}
.btn-copy-inline {
    background: #eef2ff;
    color: #4338ca;
    border: 1px solid #c7d2fe;
}
.btn-copy-inline:hover { background: #e0e7ff; }
.btn-del-inline {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}
.btn-del-inline:hover { background: #fee2e2; }

/* Footer */
.footer {
    text-align: center;
    color: rgba(255,255,255,.85);
    font-size: 12px;
    margin-top: 28px;
    text-shadow: 0 1px 4px rgba(0,0,0,.4);
}

@media (max-width: 640px) {
    .container { padding: 0 12px; }
    .header h1 { font-size: 22px; }
    .nav-link { position: static; display: inline-block; margin-top: 8px; }
    .result-link-wrap { flex-direction: column; }
    .btn-copy { width: 100%; }
}
