*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    min-height: 100vh;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text",
        "Segoe UI", sans-serif;
    color: #f5f5f7;
    /* Чуть светлее фон */
    background-color: #080a10;
    background-image:
        radial-gradient(circle at 0% 0%, rgba(255, 255, 255, 0.05), transparent 55%),
        radial-gradient(circle at 100% 100%, rgba(255, 255, 255, 0.04), transparent 55%);
    background-attachment: fixed;
}

img {
    max-width: 100%;
    display: block;
}

#root {
    max-width: 1180px;
    margin: 0 auto;
    padding: 32px 18px 44px;
}

.header {
    display: flex;
    justify-content: center;
    margin-bottom: 18px;
}

.logo-block {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    border-radius: 999px;
    background: rgba(22, 22, 28, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.07);
    box-shadow:
        0 18px 40px rgba(0, 0, 0, 0.8),
        0 0 0 0.5px rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(24px) saturate(150%);
    -webkit-backdrop-filter: blur(24px) saturate(150%);
}

.logo {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.logo-text h1 {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: #f5f5f7;
}

.logo-text p {
    margin: 0;
    font-size: 12px;
    color: #a1a1aa;
}

.search-container {
    margin: 18px 0 26px;
    display: flex;
    justify-content: center;
}

.search-wrapper {
    position: relative;
    width: 100%;
    max-width: 660px;
}

.search-input {
    width: 100%;
    padding: 12px 42px 12px 18px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(28, 28, 35, 0.9);
    color: #f5f5f7;
    outline: none;
    font-size: 14px;
    box-shadow:
        0 18px 45px rgba(0, 0, 0, 0.85),
        0 0 0 0.6px rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(22px) saturate(150%);
    -webkit-backdrop-filter: blur(22px) saturate(150%);
    transition:
        border-color 0.18s ease,
        box-shadow 0.18s ease,
        transform 0.06s ease,
        background-color 0.18s ease;
}

.search-input::placeholder {
    color: #777;
}

.search-input:focus {
    border-color: rgba(255, 255, 255, 0.36);
    box-shadow:
        0 22px 55px rgba(0, 0, 0, 0.95),
        0 0 0 1.2px rgba(255, 255, 255, 0.26);
    transform: translateY(-1px);
    background: rgba(32, 32, 40, 0.96);
}

.search-clear {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: none;
    color: #999;
    cursor: pointer;
    font-size: 18px;
    padding: 0;
}

.search-clear:hover {
    color: #fff;
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin: 6px 0 0;
    padding: 6px;
    list-style: none;
    border-radius: 14px;
    background: rgba(20, 20, 26, 0.97);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow:
        0 18px 40px rgba(0, 0, 0, 0.9),
        0 0 0 0.4px rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(22px) saturate(150%);
    -webkit-backdrop-filter: blur(22px) saturate(150%);
    max-height: 260px;
    overflow-y: auto;
    z-index: 20;
}

.search-suggestion-item {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 6px 8px;
    border-radius: 10px;
    font-size: 13px;
    color: #e4e4e7;
    cursor: pointer;
    transition: background-color 0.12s ease;
}

.search-suggestion-item:hover {
    background: rgba(46, 46, 56, 0.9);
}

.suggestion-main {
    font-weight: 500;
}

.suggestion-sub {
    color: #a1a1aa;
    font-size: 12px;
}

.autosalon-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
}

.autosalon-container.single-result {
    grid-template-columns: minmax(320px, 720px);
    justify-content: center;
}

.car-card {
    position: relative;
    border-radius: 22px;
    display: flex;
    flex-direction: column;
    background:
        radial-gradient(circle at 0% 0%, rgba(255, 255, 255, 0.07), transparent 65%),
        radial-gradient(circle at 100% 100%, rgba(255, 255, 255, 0.04), transparent 65%),
        rgba(22, 22, 30, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow:
        0 24px 52px rgba(0, 0, 0, 0.9),
        0 0 0 0.4px rgba(0, 0, 0, 0.8);
    overflow: hidden;
    backdrop-filter: blur(26px) saturate(140%);
    -webkit-backdrop-filter: blur(26px) saturate(140%);
    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        border-color 0.18s ease,
        filter 0.18s ease,
        background 0.18s ease;
}

.car-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow:
        0 30px 60px rgba(0, 0, 0, 0.96),
        0 0 0 0.6px rgba(0, 0, 0, 0.85);
    filter: brightness(1.03);
}

.car-image-wrapper {
    height: 190px;
    padding: 10px 14px;
    background: #111218;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: filter 0.18s ease;
}

.car-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.car-image-wrapper:hover img {
    filter: drop-shadow(0 0 14px rgba(0, 0, 0, 0.7));
}

.car-card-content {
    padding: 14px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.car-card-content .model {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
}

.model-code {
    color: #a8a8b1;
    font-size: 13px;
}

.price {
    margin-top: 4px;
    display: flex;
    gap: 10px;
    color: #fef9c3;
    font-weight: 600;
    font-size: 15px;
}

.meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 12px;
    font-size: 13px;
    color: #d4d4d8;
}

.meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.meta-icon {
    width: 14px;
    height: 14px;
    border-radius: 4px;
    background: linear-gradient(180deg, #3a3a40, #17171b);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.9);
}

.meta-icon--trunk {
    border-radius: 3px;
}

.meta-icon--tank {
    border-radius: 50%;
}

.meta-icon--fuel {
    border-radius: 50%;
    clip-path: polygon(50% 0%, 85% 40%, 65% 100%, 35% 100%, 15% 40%);
}

.meta-item b {
    color: #fff;
}

mark {
    background: rgba(255, 255, 255, 0.18);
    border-radius: 4px;
}

.copy-btn {
    margin-top: auto;
    width: 100%;
    padding: 10px 14px;
    border-radius: 999px;
    border: none;
    background: linear-gradient(180deg, #2b2b31, #141417);
    color: #f5f5f7;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition:
        opacity 0.15s ease,
        transform 0.08s ease,
        box-shadow 0.15s ease,
        background 0.15s ease;
    box-shadow:
        0 14px 28px rgba(0, 0, 0, 0.8),
        0 0 0 0.4px rgba(0, 0, 0, 0.9);
}

.copy-btn:hover {
    background: linear-gradient(180deg, #33333a, #17171b);
}

.copy-btn:active {
    transform: translateY(1px);
}

.skeleton-card {
    position: relative;
    overflow: hidden;
}

.skeleton-image,
.skeleton-line {
    background: linear-gradient(90deg,
            rgba(255, 255, 255, 0.05),
            rgba(255, 255, 255, 0.12),
            rgba(255, 255, 255, 0.05));
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.2s infinite;
}

.skeleton-image {
    border-radius: 18px 18px 0 0;
}

.skeleton-line {
    border-radius: 999px;
    height: 10px;
    margin-bottom: 8px;
}

.skeleton-line-lg {
    width: 70%;
    height: 14px;
}

.skeleton-line-sm {
    width: 50%;
}

.skeleton-line-btn {
    width: 100%;
    height: 16px;
    margin-top: auto;
}

@keyframes skeleton-shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 26px;
    font-size: 14px;
    color: #e6e6e9;
}

.pagination span {
    line-height: 1;
}

.pagination button {
    padding: 7px 16px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(26, 26, 34, 0.9);
    color: #f5f5f7;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.18s ease;
}

.pagination button:hover:not(:disabled) {
    border-color: rgba(255, 255, 255, 0.32);
}

.pagination button:disabled {
    opacity: 0.35;
    cursor: default;
}

.empty-state {
    margin-top: 32px;
    text-align: center;
    color: #d4d4d8;
}

.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 9px 14px;
    border-radius: 999px;
    background: rgba(20, 20, 26, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #f5f5f7;
    font-size: 13px;
    box-shadow:
        0 20px 38px rgba(0, 0, 0, 0.9),
        0 0 0 0.4px rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(24px) saturate(150%);
    -webkit-backdrop-filter: blur(24px) saturate(150%);
    z-index: 50;
}

@media (max-width: 800px) {
    #root {
        padding-top: 22px;
    }

    .logo-text h1 {
        font-size: 19px;
    }

    .logo-block {
        padding-inline: 14px;
    }

    .autosalon-container {
        grid-template-columns: 1fr;
    }

    .toast {
        left: 50%;
        transform: translateX(-50%);
        right: auto;
    }

    .search-wrapper {
        max-width: 100%;
    }
}

#not-found-root {
    max-width: 1180px;
    margin: 0 auto;
    padding: 32px 18px 44px;
}

.nf-main {
    margin-top: 28px;
    display: flex;
    justify-content: center;
}

.nf-card {
    max-width: 520px;
    width: 100%;
    padding: 26px 24px 24px;
    border-radius: 26px;
    background:
        radial-gradient(circle at 0% 0%, rgba(255, 255, 255, 0.08), transparent 65%),
        radial-gradient(circle at 100% 100%, rgba(255, 255, 255, 0.05), transparent 65%),
        rgba(22, 22, 30, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow:
        0 26px 56px rgba(0, 0, 0, 0.9),
        0 0 0 0.5px rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(28px) saturate(150%);
    -webkit-backdrop-filter: blur(28px) saturate(150%);
    text-align: center;
}

.nf-status {
    font-size: 52px;
    font-weight: 800;
    letter-spacing: 0.06em;
    color: #fef9c3;
    margin-bottom: 4px;
}

.nf-title {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 600;
    color: #f5f5f7;
}

.nf-text {
    margin: 0 0 4px;
    font-size: 14px;
    color: #e4e4e7;
}

.nf-text-secondary {
    margin: 0 0 18px;
    font-size: 13px;
    color: #a1a1aa;
}

.nf-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 18px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: linear-gradient(180deg, #2b2b31, #141417);
    color: #f5f5f7;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    box-shadow:
        0 14px 30px rgba(0, 0, 0, 0.85),
        0 0 0 0.4px rgba(0, 0, 0, 0.9);
    transition:
        background 0.15s ease,
        box-shadow 0.15s ease,
        transform 0.08s ease,
        border-color 0.15s ease;
}

.nf-button:hover {
    background: linear-gradient(180deg, #34343c, #17171b);
    border-color: rgba(255, 255, 255, 0.3);
}

.nf-button:active {
    transform: translateY(1px);
}

@media (max-width: 800px) {
    .nf-card {
        padding: 22px 18px 20px;
    }

    .nf-status {
        font-size: 44px;
    }
}