/* 自定义样式 */
.hover-shadow {
    transition: box-shadow 0.3s ease;
}

.hover-shadow:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.card {
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
}

.breadcrumb {
    background-color: transparent;
    padding: 0;
}

.list-group-item-action:hover {
    background-color: #f8f9fa;
}

#promo-hero {
    position: relative;
}

.promo-hero {
    position: relative;
    border-radius: 18px;
    padding: 28px 28px 20px;
    overflow: hidden;
    color: #fff;
    background: radial-gradient(1200px 400px at 10% -10%, rgba(13, 110, 253, 0.35), transparent),
                linear-gradient(135deg, #0d6efd, #4c8bff 40%, #6f6bff);
    box-shadow: 0 12px 30px rgba(13, 110, 253, 0.25);
    animation: promoFloat 6s ease-in-out infinite;
}

.promo-glow {
    position: absolute;
    inset: -30%;
    background: conic-gradient(from 120deg, rgba(255, 255, 255, 0.2), transparent 35%, rgba(255, 255, 255, 0.15), transparent 70%);
    animation: promoGlow 8s linear infinite;
    pointer-events: none;
}

.promo-content {
    position: relative;
    z-index: 1;
    text-align: center;
}

.promo-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    font-weight: 600;
    letter-spacing: 0.08em;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.3);
    margin-bottom: 10px;
}

.promo-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.promo-subtitle {
    font-size: 1rem;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.9);
}

.promo-stats {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.promo-stat {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 12px 10px;
    backdrop-filter: blur(6px);
}

.promo-stat-value {
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.promo-stat-label {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.85);
}

.dtc-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
    border: 1px solid rgba(15, 23, 42, 0.05);
    overflow: hidden;
}

.dtc-card-header {
    padding: 20px 24px 12px;
    background: linear-gradient(120deg, rgba(13, 110, 253, 0.12), rgba(25, 135, 84, 0.08));
}

.dtc-card-body {
    padding: 18px 24px 24px;
    margin: 0;
}

.dtc-card .input-group .form-control {
    border-radius: 12px 0 0 12px;
}

.dtc-card .input-group .btn {
    border-radius: 0 12px 12px 0;
}

/* Homepage polish */
.home-page {
    --home-border: rgba(15, 23, 42, 0.08);
    --home-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.home-page .card {
    border-radius: 14px;
}

.home-search-card {
    border: 1px solid var(--home-border);
    box-shadow: var(--home-shadow);
}

.home-evdb-card {
    position: relative;
    border: 1px solid var(--home-border);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--home-shadow);
    background:
        radial-gradient(600px 160px at 10% 0%, rgba(13, 110, 253, 0.1), transparent),
        radial-gradient(500px 140px at 100% 100%, rgba(25, 135, 84, 0.08), transparent),
        #fff;
}

.home-evdb-content h3 {
    font-weight: 700;
}

.home-evdb-content p {
    max-width: 560px;
}

.home-evdb-btn {
    border-radius: 12px;
    padding-inline: 1.2rem;
    box-shadow: 0 6px 16px rgba(13, 110, 253, 0.3);
}

.home-brand-card {
    border: 1px solid var(--home-border);
    border-radius: 12px;
}

.home-brand-card .card-title {
    margin-bottom: 0;
    font-weight: 600;
    color: #1f2937;
}

.home-series-card {
    border: 1px solid var(--home-border);
    box-shadow: var(--home-shadow);
}

.home-series-header {
    border-bottom: none;
}

.home-series-header-primary {
    background: linear-gradient(135deg, #0d6efd, #4388ff) !important;
}

.home-series-header-success {
    background: linear-gradient(135deg, #198754, #2eb67d) !important;
}

.home-dtc-list {
    border-radius: 12px;
    border: 1px solid var(--home-border);
    overflow: hidden;
}

.home-dtc-item {
    font-size: 0.93rem;
    border-left: 0;
    border-right: 0;
    border-color: rgba(15, 23, 42, 0.06);
}

.home-dtc-item:hover {
    background: #f8fbff;
    color: #0b5ed7;
}

.home-keyword-card {
    border: 1px solid var(--home-border);
    border-radius: 14px;
    box-shadow: var(--home-shadow);
}

.home-keyword-tag {
    color: #334155;
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    padding: 0.45rem 0.75rem;
}

.home-keyword-tag:hover {
    background: #eaf3ff !important;
    color: #0b5ed7;
    border-color: #b9d7ff !important;
}

@media (max-width: 768px) {
    .promo-hero {
        padding: 22px 18px 16px;
    }

    .promo-title {
        font-size: 1.35rem;
    }

    .home-evdb-card .card-body {
        padding: 1rem;
    }
}

@keyframes promoGlow {
    0% { transform: rotate(0deg); opacity: 0.6; }
    50% { opacity: 0.9; }
    100% { transform: rotate(360deg); opacity: 0.6; }
}

@keyframes promoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

#pdf-viewer {
    background-color: #525252;
}

#pdf-viewer canvas {
    display: block;
    margin: 0 auto;
}

/* EV database (mimic data.carnewschina list layout) */
.evdb-shell {
    background: #fff;
    border: 1px solid #e8eaed;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
}

.evdb-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid #eceff3;
}

.evdb-title {
    font-size: 1.2rem;
    font-weight: 700;
}

.evdb-tabs {
    display: inline-flex;
    gap: 8px;
}

.evdb-tab {
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    padding: 4px 8px;
    border-radius: 999px;
    border: 1px solid #dce1e8;
    color: #4b5563;
    background: #f8fafc;
}

.evdb-tab.active {
    color: #fff;
    background: #111827;
    border-color: #111827;
}

.evdb-metric {
    font-size: .82rem;
    font-weight: 600;
    color: #6b7280;
    background: #f8fafc;
    border: 1px solid #dce1e8;
    border-radius: 999px;
    padding: 4px 10px;
}

.evdb-filter-bar {
    padding: 12px 16px;
    border-bottom: 1px solid #eceff3;
    background: #fafbfc;
}

.evdb-brand-strip {
    display: flex;
    gap: 8px;
    padding: 12px 16px 14px;
    overflow-x: auto;
    border-bottom: 1px solid #eceff3;
}

.evdb-brand-pill {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #374151;
    text-decoration: none;
    border: 1px solid #dce1e8;
    border-radius: 999px;
    padding: 6px 10px;
    background: #fff;
    font-size: .85rem;
}

.evdb-brand-pill:hover {
    border-color: #b8c2cf;
    color: #111827;
}

.evdb-brand-pill.active {
    border-color: #111827;
    background: #111827;
    color: #fff;
}

.evdb-brand-pill img {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.evdb-model-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
}

.evdb-model-card {
    background: #fff;
    border: 1px solid #e8eaed;
    border-radius: 12px;
    transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}

.evdb-model-card:hover {
    border-color: #d2d8e0;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
    transform: translateY(-2px);
}

.evdb-model-link {
    display: block;
    color: inherit;
    text-decoration: none;
    padding: 12px;
}

.evdb-model-image-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 120px;
    margin-bottom: 10px;
}

.evdb-model-image-wrap img {
    max-width: 100%;
    max-height: 110px;
    object-fit: contain;
}

.evdb-model-name {
    font-size: .96rem;
    font-weight: 700;
    line-height: 1.3;
}

.evdb-model-slug {
    color: #6b7280;
    font-size: .75rem;
    word-break: break-all;
}
