.home-hero-grid {
    grid-template-columns: minmax(0, 1fr);
}

.home-selector-card {
    min-width: 0;
}

.home-hero-grid {
    grid-template-columns: minmax(0, 1fr);
}

.home-hero-copy {
    max-width: none;
}

.home-hero-intro {
    max-width: none;
}

.home-selector-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
    width: 100%;
}

.home-plate-card {
    min-width: 0;
}

.home-plate-form-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.75rem;
    align-items: stretch;
}

.home-plate-input-wrap {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: 3.5rem;
    padding: 0.4rem 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 0.95rem;
    background: rgba(8, 28, 56, 0.5);
}

.home-plate-country {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.45rem;
    height: 2.45rem;
    padding: 0 0.5rem;
    border-radius: 0.8rem;
    background: linear-gradient(180deg, rgba(249, 115, 22, 0.18), rgba(249, 115, 22, 0.1));
    color: hsl(var(--accent));
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.home-plate-input-wrap input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: hsl(var(--primary-foreground));
    font-size: 1.05rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.home-plate-input-wrap input::placeholder {
    color: rgba(255, 255, 255, 0.42);
    text-transform: none;
    letter-spacing: 0;
    font-weight: 500;
}

.home-plate-submit {
    width: 100%;
}

.home-plate-helper {
    min-height: 1.5rem;
}

.home-plate-helper[data-state="loading"] {
    color: rgba(255, 255, 255, 0.88);
}

.home-plate-helper[data-state="error"] {
    display: block;
    padding: 0.8rem 0.95rem;
    border: 1px solid rgba(248, 113, 113, 0.42);
    border-radius: 0.95rem;
    background: rgba(127, 29, 29, 0.28);
    color: #fee2e2;
    font-weight: 700;
    line-height: 1.45;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
}

.home-plate-helper[data-state="success"] {
    color: rgba(255, 255, 255, 0.88);
}

.home-plate-results {
    display: grid;
    gap: 0.85rem;
    margin-top: 1rem;
}

.plate-result-card {
    padding: 1rem 1rem 1.1rem;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 1rem;
    background:
        radial-gradient(circle at top right, rgba(249, 115, 22, 0.12), transparent 35%),
        rgba(255, 255, 255, 0.06);
    color: hsl(var(--primary-foreground));
}

.plate-result-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    margin-bottom: 0.6rem;
}

.plate-result-match {
    display: inline-flex;
    align-items: center;
    min-height: 1.85rem;
    padding: 0.2rem 0.7rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.plate-result-vin {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.82rem;
    font-weight: 600;
}

.plate-result-vin strong {
    color: hsl(var(--primary-foreground));
}

.plate-result-title {
    margin: 0;
    color: hsl(var(--primary-foreground));
    font-size: 1.08rem;
    font-weight: 800;
    line-height: 1.3;
}

.plate-result-engine {
    margin-top: 0.2rem;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.92rem;
    font-weight: 600;
}

.plate-result-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem 1rem;
    margin-top: 0.9rem;
}

.plate-result-item {
    min-width: 0;
}

.plate-result-label {
    display: block;
    margin-bottom: 0.12rem;
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.plate-result-value {
    color: hsl(var(--primary-foreground));
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.45;
}

.plate-result-hint {
    margin-top: 0.8rem;
    color: rgba(255, 255, 255, 0.68);
    font-size: 0.84rem;
    line-height: 1.5;
}

.plate-result-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 0.9rem;
}

.plate-result-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 9.5rem;
    padding: 0.78rem 1.35rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #fb923c, #f97316);
    color: #fff;
    font-size: 0.94rem;
    font-weight: 800;
    text-decoration: none;
    box-shadow: 0 14px 26px rgba(249, 115, 22, 0.22);
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.plate-result-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 30px rgba(249, 115, 22, 0.28);
    filter: brightness(1.03);
}

.plate-result-button:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.75);
    outline-offset: 3px;
}

.home-quick-selector-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.75rem;
    align-items: stretch;
}

.home-quick-selector-form select,
.home-quick-submit {
    min-width: 0;
}

.home-quick-submit {
    width: 100%;
}

.home-popular-models-intro {
    max-width: none;
}

.home-main-categories-section {
    background:
        radial-gradient(circle at 12% 8%, rgba(249, 115, 22, 0.12), transparent 28%),
        linear-gradient(180deg, transparent, rgba(255, 247, 237, 0.55));
}

.home-main-categories-head {
    display: flex;
    align-items: end;
    margin-bottom: 1.25rem;
}

.home-main-categories-head > div {
    max-width: none;
    width: 100%;
}

.home-main-categories-copy {
    white-space: normal;
}

.home-main-categories-grid {
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 1rem;
}

.home-main-category-card {
    position: relative;
    display: grid;
    gap: 0.55rem;
    min-height: 13rem;
    padding: 1.15rem;
    overflow: hidden;
    border: 1px solid hsl(var(--border));
    border-radius: 1.25rem;
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.92)),
        hsl(var(--card));
    box-shadow: 0 18px 42px rgba(8, 28, 56, 0.07);
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.home-main-category-card::after {
    content: "";
    position: absolute;
    right: -2.6rem;
    bottom: -3rem;
    width: 8.5rem;
    height: 8.5rem;
    border-radius: 999px;
    background: rgba(249, 115, 22, 0.1);
}

.home-main-category-card:hover {
    border-color: hsl(var(--accent));
    box-shadow: 0 22px 48px rgba(8, 28, 56, 0.1);
    transform: translateY(-2px);
}

.home-main-category-card h3 {
    position: relative;
    z-index: 1;
    margin: 0;
    color: hsl(var(--foreground));
    font-size: 1.08rem;
    font-weight: 900;
    letter-spacing: -0.035em;
    line-height: 1.15;
}

.home-main-category-card p {
    position: relative;
    z-index: 1;
    margin: 0;
    color: hsl(var(--muted-foreground));
    font-size: 0.91rem;
    line-height: 1.45;
}

.home-main-category-count {
    position: relative;
    z-index: 1;
    width: fit-content;
    padding: 0.28rem 0.62rem;
    border-radius: 999px;
    background: rgba(249, 115, 22, 0.12);
    color: hsl(var(--accent));
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.home-main-category-cta {
    position: relative;
    z-index: 1;
    align-self: end;
    color: hsl(var(--accent));
    font-size: 0.88rem;
    font-weight: 900;
}

.home-extra-categories-grid {
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 1rem;
}

.home-extra-category-card {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    min-height: 100%;
    padding: 1.5rem;
    border: 1px solid hsl(var(--border));
    border-radius: 1rem;
    background:
        radial-gradient(circle at top right, rgba(249, 115, 22, 0.12), transparent 40%),
        hsl(var(--card));
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.home-extra-category-card:hover {
    border-color: hsl(var(--accent));
    box-shadow: 0 14px 28px rgba(8, 28, 56, 0.08);
    transform: translateY(-2px);
}

.home-extra-category-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: max-content;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: rgba(249, 115, 22, 0.12);
    color: hsl(var(--accent));
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.home-extra-category-title {
    color: hsl(var(--foreground));
    font-size: 1.35rem;
    line-height: 1.15;
    font-weight: 800;
}

.home-extra-category-description {
    color: hsl(var(--muted-foreground));
    font-size: 0.98rem;
    line-height: 1.65;
}

.home-extra-category-cta {
    margin-top: auto;
    color: hsl(var(--accent));
    font-size: 0.95rem;
    font-weight: 700;
}

@media (max-width: 767px) {
    .hero-section > .container,
    .home-hero-grid,
    .home-hero-copy,
    .home-selector-row,
    .home-selector-row > *,
    .home-hero-copy > * {
        box-sizing: border-box;
        min-width: 0;
        max-width: 100%;
    }

    .hero-section,
    .home-hero-grid,
    .home-hero-copy,
    .home-plate-card,
    .home-selector-card {
        overflow: visible;
    }

    .home-hero-copy .hero-heading {
        width: 100%;
        max-width: 100%;
        font-size: clamp(1.9rem, 9.2vw, 2.85rem);
        line-height: 1.05;
        overflow-wrap: anywhere;
        word-break: normal;
    }

    .home-hero-intro,
    .home-plate-card p,
    .home-selector-card p {
        max-width: 100%;
        overflow-wrap: break-word;
        word-break: normal;
    }

    .home-plate-input-wrap,
    .home-plate-submit,
    .home-quick-selector-form select,
    .home-quick-selector-form button {
        width: 100%;
        min-width: 0;
    }

    .home-main-categories-head {
        display: grid;
        align-items: start;
    }

    .home-main-categories-copy {
        white-space: normal;
    }

    .home-hero-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.75rem;
        align-items: stretch;
    }

    .home-hero-actions > a {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 100%;
        min-width: 0;
        text-align: center;
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .plate-result-grid {
        grid-template-columns: 1fr;
    }

    .plate-result-actions {
        justify-content: stretch;
    }

    .plate-result-button {
        width: 100%;
    }
}

@media (max-width: 379px) {
    .home-hero-actions {
        grid-template-columns: 1fr;
    }
}

.home-brand-logo-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

.home-brand-logo-card {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 126px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.85rem 0.65rem 0.75rem;
    overflow: hidden;
    border: 1px solid #d9e3ee;
    border-radius: 16px;
    background: linear-gradient(150deg, #ffffff 0%, #f8fbfe 100%);
    box-shadow: 0 2px 8px rgb(17 39 68 / 0.04);
    text-align: center;
    transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.home-brand-logo-card::after {
    position: absolute;
    right: 0.7rem;
    bottom: 0.62rem;
    width: 0.35rem;
    height: 0.35rem;
    border-right: 2px solid #ff7417;
    border-bottom: 2px solid #ff7417;
    content: "";
    opacity: 0;
    transform: translateX(-3px) rotate(-45deg);
    transition: opacity 180ms ease, transform 180ms ease;
}

.home-brand-logo-card:hover,
.home-brand-logo-card:focus-visible {
    border-color: #ff9b58;
    box-shadow: 0 10px 24px rgb(17 39 68 / 0.11);
    transform: translateY(-2px);
}

.home-brand-logo-card:hover::after,
.home-brand-logo-card:focus-visible::after {
    opacity: 1;
    transform: translateX(0) rotate(-45deg);
}

.home-brand-logo-card:focus-visible {
    outline: 3px solid rgb(255 116 23 / 0.24);
    outline-offset: 2px;
}

.home-brand-logo-frame {
    display: flex;
    width: 100%;
    height: 68px;
    align-items: center;
    justify-content: center;
}

.home-brand-logo-frame img {
    width: auto;
    max-width: 112px;
    height: auto;
    max-height: 68px;
    object-fit: contain;
}

.home-brand-logo-card h3 {
    max-width: 100%;
    color: #132a47;
    font-size: 0.96rem;
    font-weight: 750;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

@media (min-width: 540px) {
    .home-brand-logo-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 760px) {
    .home-brand-logo-grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }
}

@media (min-width: 1120px) {
    .home-brand-logo-grid {
        grid-template-columns: repeat(7, minmax(0, 1fr));
        gap: 0.75rem;
    }

    .home-brand-logo-card {
        min-height: 120px;
        padding: 0.72rem 0.55rem 0.65rem;
    }

    .home-brand-logo-frame {
        height: 62px;
    }

    .home-brand-logo-frame img {
        max-width: 102px;
        max-height: 62px;
    }
}

@media (min-width: 860px) {
    .home-quick-selector-form {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
    }

    .home-quick-submit {
        width: auto;
    }

    .home-plate-form-row {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .home-plate-submit {
        width: auto;
    }
}

@media (min-width: 900px) {
    .home-main-categories-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .home-extra-categories-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 1120px) {
    .home-main-categories-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 1260px) {
    .home-quick-selector-form {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }

    .home-quick-submit {
        grid-column: 1 / -1;
        width: 100%;
    }
}

@media (min-width: 960px) {
    .home-selector-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .home-selector-row > * {
        min-height: 100%;
    }
}

@media (max-width: 859px) {
    .home-quick-selector-form {
        grid-template-columns: 1fr;
    }
}
