:root {
    --bg: #070707;
    --bg-soft: #111111;
    --panel: rgba(18, 18, 18, 0.9);
    --panel-2: #161616;
    --line: rgba(255, 255, 255, 0.08);
    --line-strong: rgba(255, 255, 255, 0.15);
    --text: #f5f5f5;
    --muted: #b4b4b4;
    --red: #d90d25;
    --red-soft: #8f1521;
    --red-glow: rgba(217, 13, 37, 0.28);
    --shadow: 0 22px 50px rgba(0, 0, 0, 0.35);
    --radius: 24px;
    --radius-sm: 18px;
    --container: 1240px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: rgba(217, 13, 37, 0.72) rgba(5, 5, 5, 0.92);
}

body {
    margin: 0;
    color: var(--text);
    background:
        radial-gradient(circle at top right, rgba(217, 13, 37, 0.14), transparent 26%),
        radial-gradient(circle at left center, rgba(255, 255, 255, 0.03), transparent 22%),
        linear-gradient(180deg, #090909 0%, #050505 100%);
    font-family: "Manrope", sans-serif;
}

*::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

*::-webkit-scrollbar-track {
    background: rgba(5, 5, 5, 0.92);
}

*::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(217, 13, 37, 0.82), rgba(143, 21, 33, 0.82));
    border: 2px solid rgba(5, 5, 5, 0.96);
    border-radius: 999px;
}

*::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(255, 66, 91, 0.92), rgba(143, 21, 33, 0.92));
}

*::-webkit-scrollbar-corner {
    background: transparent;
}

body.filter-drawer-open {
    overflow: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

button,
input,
select,
textarea {
    font: inherit;
}

.site-shell {
    min-height: 100vh;
}

.site-main {
    min-height: 0;
}

.container {
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 30;
    backdrop-filter: blur(18px);
    background: rgba(7, 7, 7, 0.72);
    border-bottom: 1px solid var(--line);
}

.header-row,
.footer-row,
.admin-hero-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.site-header .container,
.site-footer .container {
    padding: 18px 0;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-family: "Oswald", sans-serif;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.brand-logo {
    width: clamp(180px, 22vw, 260px);
    height: auto;
    filter: drop-shadow(0 16px 32px rgba(229, 35, 32, 0.16));
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.site-nav a {
    color: var(--muted);
    transition: color 0.2s ease;
}

.site-nav a:hover,
.site-nav .nav-admin-link {
    color: var(--text);
}

.nav-toggle {
    display: none;
    width: 48px;
    height: 48px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: transparent;
    padding: 0;
}

.nav-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    background: var(--text);
}

.mobile-bottom-nav {
    display: none;
}

.hero-section,
.page-hero {
    padding: 68px 0 34px;
}

.hero-grid,
.contacts-grid,
.detail-layout,
.form-layout,
.catalog-layout {
    display: grid;
    gap: 28px;
}

.hero-grid {
    grid-template-columns: minmax(0, 560px);
    align-items: center;
    min-height: 620px;
}

.hero-copy h1,
.page-hero h1 {
    margin: 10px 0 18px;
    font-family: "Montserrat", sans-serif;
    font-size: clamp(2.8rem, 8vw, 5.1rem);
    line-height: 0.95;
    letter-spacing: -0.04em;
    max-width: 10ch;
}

.hero-stage {
    padding-top: 0;
}

.hero-screen {
    position: relative;
    overflow: hidden;
    min-height: 820px;
    padding: 58px 0 40px;
    background:
        radial-gradient(circle at 78% 28%, rgba(217, 13, 37, 0.18), transparent 18%),
        linear-gradient(115deg, rgba(0, 0, 0, 0.96) 20%, rgba(0, 0, 0, 0.72) 54%, rgba(0, 0, 0, 0.4) 100%);
}

.hero-screen-inner {
    position: relative;
    z-index: 1;
    display: grid;
    align-content: space-between;
    min-height: calc(820px - 58px - 40px);
    gap: 26px;
}

.hero-backdrop,
.hero-overlay {
    position: absolute;
    inset: 0;
}

.hero-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center right;
    opacity: 0.88;
}

.hero-overlay {
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.94) 0%, rgba(0, 0, 0, 0.86) 30%, rgba(0, 0, 0, 0.5) 56%, rgba(0, 0, 0, 0.16) 100%),
        radial-gradient(circle at 78% 54%, rgba(217, 13, 37, 0.12), transparent 24%);
}

.hero-screen .hero-grid,
.hero-services-panel {
    position: relative;
    z-index: 1;
}

.hero-copy p,
.page-hero p,
.footer-copy,
.muted-copy,
.info-card p,
.contacts-card p,
.detail-description p {
    color: var(--muted);
    line-height: 1.7;
}

.not-found-page {
    position: relative;
    min-height: calc(100vh - 190px);
    padding: 48px 0 72px;
    overflow: hidden;
}

.not-found-shell {
    position: relative;
    display: grid;
    place-items: center;
    min-height: calc(100vh - 290px);
    padding: 32px 0;
}

.not-found-card {
    position: relative;
    z-index: 1;
    width: min(760px, 100%);
    padding: clamp(28px, 5vw, 52px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 34px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.02)),
        rgba(10, 10, 10, 0.9);
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.38);
    backdrop-filter: blur(24px);
    text-align: center;
}

.not-found-code {
    margin: 14px 0 10px;
    font-family: "Montserrat", sans-serif;
    font-size: clamp(5rem, 18vw, 10rem);
    line-height: 0.86;
    font-weight: 800;
    letter-spacing: -0.08em;
    color: rgba(255, 255, 255, 0.06);
    text-shadow: 0 0 30px rgba(217, 13, 37, 0.14);
}

.not-found-card h1 {
    margin: 0 0 14px;
    font-family: "Montserrat", sans-serif;
    font-size: clamp(2rem, 5vw, 3.6rem);
    line-height: 0.96;
    letter-spacing: -0.04em;
}

.not-found-card p {
    width: min(520px, 100%);
    margin: 0 auto;
    color: var(--muted);
    font-size: 1rem;
    line-height: 1.75;
}

.not-found-actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

.not-found-meta {
    margin-top: 18px;
    color: #d3c1c4;
    font-size: 0.92rem;
}

.not-found-orb {
    position: absolute;
    border-radius: 999px;
    filter: blur(12px);
    opacity: 0.9;
    pointer-events: none;
}

.not-found-orb-left {
    top: 10%;
    left: -80px;
    width: 280px;
    height: 280px;
    background: radial-gradient(circle, rgba(217, 13, 37, 0.28), rgba(217, 13, 37, 0));
}

.not-found-orb-right {
    right: -110px;
    bottom: 8%;
    width: 340px;
    height: 340px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0));
}

.hero-copy {
    padding-top: 6px;
}

.eyebrow {
    display: inline-block;
    color: #f0aaaa;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 0.78rem;
}

.hero-actions,
.filter-actions,
.detail-actions,
.admin-top-actions,
.table-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.hero-btn {
    gap: 12px;
    min-width: 190px;
    justify-content: center;
}

.hero-btn-glass {
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(18px);
}

.hero-action-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    filter: brightness(0) invert(1);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 0 22px;
    border-radius: 16px;
    border: 1px solid transparent;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
    cursor: pointer;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: linear-gradient(135deg, #ff1b39, #8a0f1d);
    color: white;
    box-shadow: 0 20px 50px var(--red-glow);
}

.btn-secondary {
    background: #181818;
    border-color: var(--line-strong);
    color: var(--text);
}

.btn-ghost {
    background: transparent;
    border-color: var(--line-strong);
    color: var(--text);
}

.btn-danger {
    background: rgba(217, 13, 37, 0.12);
    border-color: rgba(217, 13, 37, 0.35);
    color: #ffb4bc;
}

.btn-small {
    min-height: 40px;
    padding: 0 14px;
    font-size: 0.9rem;
}

.admin-top-actions form,
.table-actions form {
    display: inline-flex;
}

.admin-top-actions .btn,
.table-actions .btn {
    gap: 10px;
    align-items: center;
    justify-content: center;
}

.admin-notify-link {
    position: relative;
    padding-right: 42px;
}

.admin-notify-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 22px;
    padding: 0 6px;
    border-radius: 999px;
    background: linear-gradient(135deg, #ff1b39, #8a0f1d);
    color: #fff;
    font-size: 0.76rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
    box-shadow: 0 10px 24px rgba(217, 13, 37, 0.24);
}

.admin-action-icon {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    display: inline-block;
    background-color: currentColor;
    -webkit-mask-image: var(--admin-icon);
    mask-image: var(--admin-icon);
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
}

.btn-block {
    width: 100%;
}

.glass-card,
.info-card,
.contacts-card,
.filter-panel,
.detail-price-card,
.detail-description,
.spec-card,
.card-form,
.admin-auth-card,
.existing-image-card,
.empty-panel {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.section {
    padding: 46px 0;
}

.section-heading {
    margin-bottom: 24px;
}

.section-heading-row {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
}

.catalog-heading-tools {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    flex-wrap: wrap;
}

.catalog-mobile-filters,
.catalog-filter-close {
    display: none;
}

.catalog-sort-form {
    display: flex;
    align-items: center;
}

.catalog-sort-menu .admin-filter-trigger {
    min-width: 210px;
}

.admin-filter-dropdown a.admin-filter-option {
    display: block;
}

.filter-menu-field {
    display: grid;
    gap: 8px;
    position: relative;
}

.catalog-inline-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.catalog-checkbox {
    display: flex !important;
    align-items: center;
    gap: 12px;
    min-height: 52px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
    cursor: pointer;
}

.catalog-checkbox input {
    width: 18px;
    min-width: 18px;
    height: 18px;
    min-height: 18px;
    margin: 0;
    padding: 0;
    accent-color: #d90d25;
}

.catalog-checkbox span {
    color: var(--text);
}

.catalog-filter-menu .admin-filter-dropdown {
    left: 0;
    right: auto;
    width: 100%;
    max-height: 280px;
    overflow-y: auto;
    scrollbar-width: none;
    z-index: 18;
    background:
        linear-gradient(180deg, rgba(18, 18, 18, 0.995), rgba(10, 10, 10, 0.995)),
        #0a0a0a;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

.catalog-filter-menu[open],
.catalog-filter-menu.is-opening {
    z-index: 20;
}

.catalog-filter-menu .admin-filter-dropdown::-webkit-scrollbar {
    display: none;
}

.catalog-filter-trigger {
    width: 100%;
    min-height: 54px;
    padding: 0 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.catalog-filter-trigger:hover {
    border-color: rgba(255, 255, 255, 0.16);
    background: rgba(255, 255, 255, 0.04);
}

.catalog-filter-trigger .admin-action-icon {
    color: var(--muted);
}

.catalog-pagination {
    margin-top: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.catalog-pagination__pages {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.catalog-pagination__page {
    min-width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border: 1px solid var(--line-strong);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted);
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.catalog-pagination__page:hover {
    color: var(--text);
    border-color: rgba(255, 255, 255, 0.16);
    background: rgba(255, 255, 255, 0.05);
}

.catalog-pagination__page.is-active {
    color: #fff;
    border-color: rgba(217, 13, 37, 0.3);
    background: linear-gradient(135deg, rgba(255, 27, 57, 0.9), rgba(138, 15, 29, 0.9));
    box-shadow: 0 12px 24px rgba(217, 13, 37, 0.18);
}

.catalog-pagination .is-disabled {
    opacity: 0.42;
    pointer-events: none;
}

.featured-cars-dots {
    display: none;
}

.catalog-filter-overlay {
    display: none;
}

.catalog-filter-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.catalog-mobile-filters__count {
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(217, 13, 37, 0.18);
    color: #ffd4da;
    font-size: 0.78rem;
    font-weight: 800;
    box-shadow: 0 8px 18px rgba(217, 13, 37, 0.16);
}

.no-stepper::-webkit-outer-spin-button,
.no-stepper::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.no-stepper {
    -moz-appearance: textfield;
    appearance: textfield;
}

.section-heading h2 {
    margin: 8px 0 0;
    font-family: "Montserrat", sans-serif;
    font-size: clamp(1.8rem, 4vw, 2.6rem);
}

.tight {
    margin-bottom: 18px;
}

.hero-services-panel {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    margin-top: -72px;
    width: min(1120px, calc(100% - 48px));
    margin-left: auto;
    margin-right: auto;
    padding: 12px 14px;
    backdrop-filter: blur(22px);
    background: linear-gradient(180deg, rgba(28, 28, 28, 0.38), rgba(16, 16, 16, 0.5));
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 26px;
}

.hero-service-item {
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 98px;
    padding: 12px 18px;
}

.hero-service-item + .hero-service-item {
    border-left: 1px solid rgba(255, 255, 255, 0.08);
}

.hero-service-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    flex: 0 0 58px;
    border-radius: 18px;
    background: rgba(217, 13, 37, 0.08);
    border: 1px solid rgba(217, 13, 37, 0.14);
}

.hero-service-icon img {
    width: 26px;
    height: 26px;
    object-fit: contain;
    filter: brightness(0) saturate(100%) invert(18%) sepia(95%) saturate(5219%) hue-rotate(347deg) brightness(104%) contrast(103%);
}

.hero-service-item h3 {
    margin: 0 0 6px;
    font-family: "Montserrat", sans-serif;
    font-size: 1.55rem;
}

.hero-service-item p {
    margin: 0;
    max-width: 20ch;
    color: var(--muted);
    line-height: 1.45;
}

.info-card,
.contacts-card,
.filter-panel,
.detail-price-card,
.detail-description,
.card-form,
.admin-auth-card {
    padding: 24px;
}

.info-card h3,
.contacts-card h3,
.detail-description h2 {
    margin-top: 0;
}

.car-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.car-card {
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform 0.25s ease, border-color 0.25s ease;
}

.car-card:hover {
    transform: translateY(-6px);
    border-color: rgba(217, 13, 37, 0.34);
}

.car-image-wrap {
    position: relative;
    display: block;
    background: #101010;
}

.car-image-wrap img {
    width: 100%;
    aspect-ratio: 16 / 11;
    object-fit: cover;
}

.car-card-body {
    padding: 18px;
}

.car-card-top {
    margin-bottom: 8px;
}

.car-card h3 {
    margin: 0;
    font-size: 1.15rem;
}

.car-price,
.detail-price {
    font-family: "Montserrat", sans-serif;
    font-weight: 700;
    font-size: 1.2rem;
}

.car-price-block {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 10px;
    margin-bottom: 14px;
}

.car-price {
    white-space: nowrap;
}

.car-price-old,
.detail-price-old {
    color: rgba(255, 255, 255, 0.44);
    text-decoration: line-through;
    text-decoration-thickness: 1px;
    white-space: nowrap;
}

.car-price-old {
    font-size: 0.92rem;
}

.discount-badge {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(217, 13, 37, 0.14);
    border: 1px solid rgba(217, 13, 37, 0.24);
    color: #ffb8c0;
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
}

.ev-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    justify-self: start;
    min-height: 22px;
    padding: 0;
    border-radius: 999px;
    border: 0;
    background: transparent;
    color: #f1f1f1;
    font-size: 0.7rem;
    font-weight: 700;
    white-space: nowrap;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.ev-badge-icon {
    width: 12px;
    height: 12px;
    flex: 0 0 12px;
    filter: brightness(0) saturate(100%) invert(70%) sepia(94%) saturate(723%) hue-rotate(358deg) brightness(103%) contrast(103%);
}

.detail-ev-badge {
    min-height: 24px;
    font-size: 0.72rem;
    margin-bottom: 0;
}

.detail-ev-badge .ev-badge-icon {
    width: 13px;
    height: 13px;
    flex-basis: 13px;
}

.car-title-row,
.detail-title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.car-title-row h3,
.detail-title-row h1 {
    margin: 0;
}

.ev-badge-compact {
    min-height: 0;
    gap: 0;
}

.car-meta {
    display: flex;
    flex-wrap: nowrap;
    gap: 0;
    margin-bottom: 18px;
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.car-meta span,
.spec-card span {
    display: inline-flex;
    align-items: center;
    gap: 0;
    flex: 0 0 auto;
}

.car-meta span:not(:last-child)::after {
    content: "·";
    margin: 0 5px;
    color: rgba(255, 255, 255, 0.24);
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(55, 160, 78, 0.16);
    color: #b9f6c8;
    font-size: 0.85rem;
    border: 1px solid rgba(55, 160, 78, 0.28);
}

.status-badge.sold {
    background: rgba(217, 13, 37, 0.14);
    color: #ffadb7;
    border-color: rgba(217, 13, 37, 0.35);
}

.status-badge.overlay {
    position: absolute;
    top: 16px;
    left: 16px;
}

.status-badge-icon {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    display: inline-block;
    background-color: currentColor;
    -webkit-mask-image: var(--status-icon);
    mask-image: var(--status-icon);
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
}

.contacts-grid {
    grid-template-columns: 1.05fr 1fr 1fr;
}

.contact-list {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.contact-list a {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.15rem;
    font-weight: 700;
}

.contact-heading,
.contact-title {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.contact-heading {
    color: var(--text);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: normal;
    text-transform: none;
}

.contact-title {
    margin-top: 0;
}

.contact-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    display: block;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 22px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    border: 1px solid var(--line-strong);
    background: rgba(255, 255, 255, 0.04);
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.social-links a:hover {
    transform: translateY(-1px);
    border-color: rgba(217, 13, 37, 0.35);
    background: rgba(217, 13, 37, 0.08);
}

.social-icon {
    width: 20px;
    height: 20px;
    display: block;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.contact-map-carousel {
    margin-top: 18px;
}

.contact-map-tabs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.contact-map-tab {
    min-height: 36px;
    padding: 0 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--muted);
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
    cursor: pointer;
}

.contact-map-tab.is-active {
    color: #fff;
    border-color: rgba(217, 13, 37, 0.32);
    background: linear-gradient(135deg, rgba(217, 13, 37, 0.18), rgba(217, 13, 37, 0.06));
}

.contact-map-frame {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)),
        rgba(12, 12, 12, 0.9);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.contact-map-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(3, 3, 3, 0.08), rgba(3, 3, 3, 0.18)),
        radial-gradient(circle at top right, rgba(217, 13, 37, 0.12), transparent 34%);
    pointer-events: none;
}

.contact-map-frame iframe {
    display: block;
    width: 100%;
    height: 220px;
    border: 0;
    filter: grayscale(1) invert(0.92) contrast(0.92) brightness(0.72) saturate(0.7);
}

.contact-hours-card {
    display: grid;
    align-content: start;
    gap: 16px;
}

.contact-hours-badge {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(217, 13, 37, 0.2);
    background: rgba(255, 255, 255, 0.05);
    color: #f0b5be;
    font-size: 0.9rem;
    font-weight: 700;
}

.contact-hours-badge.is-open {
    border-color: rgba(55, 160, 78, 0.28);
    background: rgba(55, 160, 78, 0.14);
    color: #b9f6c8;
}

.contact-hours-badge.is-closed {
    border-color: rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.05);
    color: #d0d0d0;
}

.contact-hours-today {
    margin: 0;
    padding: 16px 18px;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02)),
        rgba(12, 12, 12, 0.88);
    color: var(--text);
    font-size: 1rem;
    line-height: 1.5;
}

.contact-hours-list {
    display: grid;
    gap: 10px;
}

.contact-hours-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
}

.contact-hours-row span {
    color: var(--muted);
}

.contact-hours-row strong {
    font-family: "Montserrat", sans-serif;
    font-size: 0.96rem;
}

.contact-callback-panel {
    display: grid;
    gap: 0;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02)),
        rgba(10, 10, 10, 0.9);
    overflow: hidden;
}

.contact-callback-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px;
    border: 0;
    background: transparent;
    color: inherit;
    text-align: left;
    cursor: pointer;
}

.contact-callback-toggle:hover .contact-callback-title {
    color: #fff;
}

.contact-callback-copy {
    display: grid;
    gap: 6px;
}

.contact-callback-title {
    font-size: 1rem;
    font-weight: 700;
    transition: color 0.2s ease;
}

.contact-callback-description {
    color: var(--muted);
    line-height: 1.5;
}

.contact-callback-chevron {
    width: 14px;
    height: 14px;
    flex: 0 0 14px;
    border-right: 2px solid rgba(255, 255, 255, 0.72);
    border-bottom: 2px solid rgba(255, 255, 255, 0.72);
    transform: rotate(45deg);
    transition: transform 0.24s ease, opacity 0.24s ease;
    opacity: 0.88;
    margin-right: 4px;
}

.contact-callback-panel.is-open .contact-callback-chevron {
    transform: rotate(225deg);
}

.contact-callback-content {
    display: grid;
    grid-template-rows: 0fr;
    opacity: 0;
    visibility: hidden;
    overflow: hidden;
    transition: grid-template-rows 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.contact-callback-content[hidden] {
    display: grid;
}

.contact-callback-panel.is-open .contact-callback-content {
    grid-template-rows: 1fr;
    opacity: 1;
    visibility: visible;
}

.contact-callback-form {
    min-height: 0;
    overflow: hidden;
    padding: 0 18px 18px;
}

.contact-callback-form {
    display: grid;
    gap: 12px;
}

.contact-callback-form label {
    display: grid;
    gap: 8px;
}

.contact-callback-form label span {
    color: var(--muted);
    font-size: 0.92rem;
}

.contact-callback-form input {
    min-height: 48px;
    border-radius: 14px;
    border-color: rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.04);
}

.contact-callback-form input:focus {
    outline: none;
    border-color: rgba(217, 13, 37, 0.34);
    box-shadow: 0 0 0 3px rgba(217, 13, 37, 0.12);
}

.contact-form-hint,
.contact-form-error {
    font-size: 0.88rem;
    line-height: 1.45;
}

.contact-form-hint {
    color: var(--muted);
}

.contact-form-error {
    color: #ffb4bc;
}

.contact-callback-submit {
    width: 100%;
    justify-content: center;
}

.contact-callback-success {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 58px;
    padding: 14px 16px 18px;
    color: #d7f7df;
    animation: callback-success-in 0.42s cubic-bezier(0.22, 1, 0.36, 1);
}

.contact-callback-success[hidden],
.contact-callback-form[hidden],
.contact-form-error[hidden] {
    display: none;
}

.contact-callback-success-icon {
    position: relative;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    border-radius: 999px;
    background: rgba(55, 160, 78, 0.16);
    border: 1px solid rgba(55, 160, 78, 0.28);
    box-shadow: 0 10px 24px rgba(55, 160, 78, 0.12);
    animation: callback-check-pop 0.45s cubic-bezier(0.2, 0.9, 0.2, 1);
}

.contact-callback-success-icon::after {
    content: "";
    position: absolute;
    left: 10px;
    top: 8px;
    width: 10px;
    height: 6px;
    border-left: 2px solid #b9f6c8;
    border-bottom: 2px solid #b9f6c8;
    transform: rotate(-45deg) scale(0.7);
    transform-origin: center;
    opacity: 0;
    animation: callback-check-draw 0.28s ease 0.12s forwards;
}

.contact-callback-success-text {
    line-height: 1.5;
}

@keyframes callback-success-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes callback-check-pop {
    0% {
        transform: scale(0.7);
    }
    65% {
        transform: scale(1.08);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes callback-check-draw {
    from {
        opacity: 0;
        transform: rotate(-45deg) scale(0.7);
    }
    to {
        opacity: 1;
        transform: rotate(-45deg) scale(1);
    }
}

.catalog-layout {
    grid-template-columns: 280px minmax(0, 1fr);
    align-items: start;
}

.filters-form,
.admin-form {
    display: grid;
    gap: 16px;
}

.filters-form label,
.admin-form label {
    display: grid;
    gap: 8px;
}

label span {
    font-size: 0.93rem;
    color: var(--muted);
}

input,
select,
textarea {
    width: 100%;
    min-height: 50px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    padding: 0 16px;
}

textarea {
    min-height: 150px;
    padding: 14px 16px;
    resize: vertical;
}

.page-hero.compact-hero h1 {
    max-width: 100%;
    font-size: clamp(2rem, 5vw, 3.4rem);
}

.detail-layout {
    grid-template-columns: 1.15fr 0.85fr;
    align-items: start;
}

.detail-main-image {
    position: relative;
    overflow: hidden;
    padding: 14px;
}

.detail-main-image[data-lightbox-open] {
    cursor: zoom-in;
}

.detail-main-image img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 18px;
    display: block;
}

.detail-mobile-carousel {
    display: none;
}

.detail-photo-count-badge {
    position: absolute;
    top: 24px;
    right: 24px;
    z-index: 2;
    display: none;
    align-items: center;
    min-height: 34px;
    padding: 7px 11px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    background: rgba(8, 8, 8, 0.62);
    color: var(--text);
    font-size: 0.82rem;
    font-weight: 700;
    backdrop-filter: blur(14px);
}

.thumb-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-top: 14px;
}

.thumb-grid.is-expanded .thumb-card.is-extra {
    animation: reveal-thumb 0.28s ease;
}

.thumb-card {
    padding: 0;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.03);
    border-radius: 18px;
    overflow: hidden;
    cursor: pointer;
}

.thumb-card.is-active {
    border-color: rgba(217, 13, 37, 0.5);
    box-shadow: 0 0 0 1px rgba(217, 13, 37, 0.24);
}

.thumb-card img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.detail-sidebar {
    display: grid;
    gap: 20px;
    align-content: start;
}

.detail-price-card {
    display: grid;
    gap: 18px;
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.03);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
    overflow: hidden;
}

.detail-sidebar-section {
    display: grid;
    gap: 12px;
}

.detail-sidebar-section + .detail-sidebar-section {
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.detail-sidebar-status .status-badge {
    justify-self: start;
}

.detail-price-stack {
    display: grid;
    gap: 6px;
}

.detail-price {
    white-space: nowrap;
    font-size: clamp(2rem, 3vw, 2.6rem);
    line-height: 0.95;
    letter-spacing: -0.05em;
}

.detail-price-old {
    font-size: 1rem;
}

.detail-discount-row {
    display: flex;
    align-items: center;
}

.detail-discount-badge {
    min-height: 32px;
    padding: 0 12px;
    font-size: 0.86rem;
}

.detail-sidebar-primary-actions,
.detail-sidebar-secondary-actions {
    display: grid;
    gap: 10px;
}

.detail-cta-main,
.detail-sidebar-button,
.detail-share-button {
    width: 100%;
    min-height: 54px;
    justify-content: center;
    gap: 10px;
}

.detail-cta-main {
    min-height: 58px;
    font-weight: 700;
    box-shadow: 0 22px 46px rgba(217, 13, 37, 0.24);
}

.detail-sidebar-button.btn-secondary {
    background: rgba(255, 255, 255, 0.03);
    border-color: var(--line);
    color: var(--text);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
}

.detail-sidebar-button.btn-secondary:hover {
    border-color: rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.05);
}

.detail-action-icon,
.detail-spec-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
}

.detail-action-icon {
    display: block;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.detail-spec-icon {
    display: block;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.detail-social-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.detail-social-cards-primary {
    margin-top: 2px;
}

.detail-social-card {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 12px;
    border: 1px solid var(--line-strong);
    border-radius: 14px;
    background: transparent;
    color: var(--text);
    font-size: 0.9rem;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
    cursor: pointer;
}

.detail-social-card:hover {
    transform: translateY(-1px);
    border-color: rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.05);
}

.detail-share-card.is-copied {
    border-color: rgba(55, 160, 78, 0.35);
    background: linear-gradient(180deg, rgba(55, 160, 78, 0.14), rgba(255, 255, 255, 0.03));
}

.detail-social-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    display: block;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.detail-share-button {
    min-height: 50px;
}

.detail-sidebar-note {
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.55;
}

.spec-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.detail-battery-panel {
    display: grid;
    gap: 14px;
    margin-top: 14px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
}

.detail-battery-panel .detail-section-title {
    margin: 0;
    font-size: 1rem;
}

.detail-battery-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.detail-specs-link {
    width: 100%;
    margin-top: 14px;
    min-height: 54px;
    gap: 10px;
    justify-content: center;
    border-color: var(--line);
    background: rgba(255, 255, 255, 0.03);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
}

.detail-specs-link:hover {
    border-color: rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.05);
}

.spec-card {
    padding: 18px;
}

.spec-label,
.detail-section-title {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.spec-card strong {
    display: block;
    margin-top: 6px;
    font-size: 1.04rem;
}

.detail-section-title {
    margin-top: 0;
}

.detail-section-title .detail-spec-icon {
    width: 1em;
    height: 1em;
    flex: 0 0 1em;
}

.detail-gallery-toggle {
    margin-top: 14px;
    min-height: 46px;
    padding: 0 18px;
    align-self: start;
}

.detail-description {
    margin-top: 18px;
}

.detail-description p {
    margin: 0;
    color: var(--muted);
    line-height: 1.7;
}

.detail-specs-panel {
    display: grid;
    gap: 18px;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
}

.detail-specs-layout {
    display: grid;
    grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.detail-specs-sidebar {
    display: grid;
    gap: 18px;
    padding: 22px;
}

.detail-specs-sidebar-copy {
    display: grid;
    gap: 8px;
}

.detail-specs-sidebar-copy h2,
.detail-specs-sidebar-copy p {
    margin: 0;
}

.detail-specs-sidebar-copy p {
    color: var(--muted);
    line-height: 1.6;
}

.detail-specs-header {
    display: grid;
    gap: 6px;
}

.detail-specs-header h2 {
    margin: 0;
    font-size: clamp(1.5rem, 3vw, 2.1rem);
}

.detail-specs-header p {
    margin: 0;
    max-width: 68ch;
    color: var(--muted);
    line-height: 1.6;
}

.detail-specs-groups {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: 32px;
    row-gap: 24px;
    align-items: start;
}

.detail-specs-group {
    display: grid;
    gap: 10px;
    align-content: start;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    backdrop-filter: none;
    box-shadow: none;
    height: auto;
    min-height: 0;
}

.detail-specs-group h3 {
    margin: 0;
    font-size: 1rem;
    line-height: 1.3;
}

.detail-specs-table {
    display: grid;
    gap: 0;
}

.detail-specs-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(140px, 0.9fr);
    gap: 18px;
    align-items: start;
    padding: 9px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.detail-specs-row:first-child {
    border-top: 0;
    padding-top: 0;
}

.detail-specs-key {
    color: var(--muted);
    line-height: 1.5;
}

.detail-specs-value {
    text-align: right;
    line-height: 1.5;
    color: var(--text);
    overflow-wrap: anywhere;
}

.detail-specs-empty {
    padding: 12px 0 0;
    border: 0;
    border-radius: 0;
    color: var(--muted);
    line-height: 1.7;
}

body.lightbox-open {
    overflow: hidden;
    touch-action: none;
}

.lightbox-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    z-index: 120;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    background:
        radial-gradient(circle at top, rgba(217, 13, 37, 0.14), transparent 24%),
        rgba(4, 5, 8, 0.92);
    backdrop-filter: blur(18px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.28s ease;
}

.lightbox-modal[hidden] {
    display: none !important;
}

.lightbox-modal.is-open {
    opacity: 1;
    pointer-events: auto;
}

.lightbox-shell {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 24px;
}

.lightbox-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-right: 88px;
}

.lightbox-counter {
    padding: 12px 16px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    background: rgba(18, 18, 18, 0.46);
    color: var(--text);
    backdrop-filter: blur(16px);
}

.lightbox-close,
.lightbox-nav {
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(18, 18, 18, 0.5);
    color: var(--text);
    backdrop-filter: blur(16px);
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        background 0.2s ease,
        opacity 0.2s ease,
        box-shadow 0.2s ease;
}

.lightbox-close:hover,
.lightbox-hit-area:hover .lightbox-nav,
.lightbox-hit-area:focus-visible .lightbox-nav {
    transform: translateY(-1px);
    border-color: rgba(217, 13, 37, 0.36);
    background: rgba(28, 28, 28, 0.78);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.26);
}

.lightbox-close {
    position: absolute;
    top: 24px;
    right: 24px;
    z-index: 3;
    width: 54px;
    height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    cursor: pointer;
}

.lightbox-close img,
.lightbox-nav img {
    width: 22px;
    height: 22px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.lightbox-stage {
    position: relative;
    flex: 1;
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(56px, 8vw) minmax(0, 1fr) minmax(56px, 8vw);
    align-items: center;
    gap: 0;
    padding: 8px 0;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 32px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01)),
        rgba(10, 12, 16, 0.68);
    overflow: hidden;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.lightbox-media {
    position: relative;
    grid-column: 2;
    width: min(100%, 1460px);
    height: 100%;
    min-height: 0;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    cursor: default;
    overflow: hidden;
}

.lightbox-image {
    display: block;
    width: auto;
    max-width: 100%;
    max-height: calc(100vh - 132px);
    object-fit: contain;
    user-select: none;
    pointer-events: auto;
    transform-origin: center center;
    transition: transform 0.2s ease;
    cursor: zoom-in;
}

.lightbox-image.is-zoomed {
    cursor: grab;
}

.lightbox-image.is-panning {
    cursor: grabbing;
}

.lightbox-mobile-carousel {
    display: none;
}

.lightbox-hit-area {
    position: relative;
    height: 100%;
    min-height: 0;
    display: flex;
    align-items: center;
    padding: 8px;
    border: 0;
    background: transparent;
    cursor: pointer;
    transition: background 0.2s ease;
}

.lightbox-hit-area.prev {
    grid-column: 1;
    justify-content: flex-start;
}

.lightbox-hit-area.next {
    grid-column: 3;
    justify-content: flex-end;
}

.lightbox-hit-area:hover,
.lightbox-hit-area:focus-visible {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.04), transparent 78%);
    outline: none;
}

.lightbox-hit-area.next:hover,
.lightbox-hit-area.next:focus-visible {
    background: linear-gradient(270deg, rgba(255, 255, 255, 0.04), transparent 78%);
}

.lightbox-nav {
    width: 64px;
    height: 64px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 22px;
    opacity: 0.72;
    pointer-events: none;
}

@keyframes reveal-thumb {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-layout {
    grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
    align-items: start;
}

.form-section {
    display: grid;
    gap: 16px;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.form-section[hidden] {
    display: none;
}

.form-section:first-of-type {
    padding-top: 0;
    border-top: 0;
}

.form-section-heading h2 {
    margin: 0 0 6px;
    font-size: 1.18rem;
}

.form-section-heading p {
    margin: 0;
    color: var(--muted);
    line-height: 1.5;
}

.form-section-heading-toggle {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.form-section-content {
    display: grid;
    gap: 16px;
}

.form-section-mobile-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: var(--muted);
    flex: 0 0 44px;
}

.form-section.is-collapsed-mobile .form-section-mobile-toggle .form-section-toggle-icon {
    transform: rotate(180deg);
}

.form-section-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 52px;
    cursor: pointer;
    list-style: none;
}

.form-section-summary::-webkit-details-marker {
    display: none;
}

.form-section-summary .form-section-heading {
    display: block;
}

.form-section-toggle-icon {
    color: var(--muted);
    transition: color 0.22s ease, transform 0.22s ease;
}

.form-section-summary:hover .form-section-toggle-icon,
.form-section-summary:focus-visible .form-section-toggle-icon {
    color: var(--accent);
}

.form-section-summary:focus-visible {
    outline: none;
}

.form-section-collapsible[open] .form-section-toggle-icon {
    color: var(--accent);
    transform: rotate(180deg);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.form-help-text {
    color: var(--muted);
    font-size: 0.84rem;
    line-height: 1.45;
}

.form-checkbox-card {
    display: grid;
    gap: 10px;
}

.form-checkbox-row {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 52px;
    padding: 14px 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
}

.form-checkbox-row input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #d90d25;
}

.admin-form input,
.admin-form select,
.admin-form textarea {
    transition: border-color 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.admin-form input:focus,
.admin-form select:focus,
.admin-form textarea:focus {
    outline: none;
    border-color: rgba(217, 13, 37, 0.42);
    background-color: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 0 3px rgba(217, 13, 37, 0.14);
}

.admin-form select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding-right: 44px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14' fill='none'%3E%3Cpath d='M3 5.25 7 9.25l4-4' stroke='%23D9D9D9' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 14px 14px;
    cursor: pointer;
}

.admin-form select:focus {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14' fill='none'%3E%3Cpath d='M3 5.25 7 9.25l4-4' stroke='%23FF9AA6' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.form-choice-menu {
    width: 100%;
}

.form-choice-with-action {
    display: flex;
    align-items: stretch;
    gap: 10px;
}

.form-choice-with-action .form-choice-menu {
    flex: 1 1 auto;
}

.form-choice-action {
    width: 50px;
    min-width: 50px;
    min-height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted);
    transition: border-color 0.22s ease, box-shadow 0.22s ease, background 0.22s ease, color 0.22s ease;
}

.form-choice-action:hover {
    border-color: rgba(217, 13, 37, 0.32);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
}

.form-choice-action:focus-visible {
    outline: none;
    border-color: rgba(217, 13, 37, 0.42);
    box-shadow: 0 0 0 3px rgba(217, 13, 37, 0.14);
}

.form-choice-action[hidden] {
    display: none;
}

.form-choice-trigger {
    width: 100%;
    min-width: 0;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
    transition: border-color 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.form-choice-menu[open] > .form-choice-trigger,
.form-choice-trigger:hover {
    border-color: rgba(217, 13, 37, 0.32);
    background: rgba(255, 255, 255, 0.05);
}

.form-choice-trigger:focus-visible {
    outline: none;
    border-color: rgba(217, 13, 37, 0.42);
    box-shadow: 0 0 0 3px rgba(217, 13, 37, 0.14);
}

.spec-admin-accordion {
    display: grid;
    gap: 12px;
}

.spec-admin-group {
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.015));
    overflow: hidden;
}

.spec-admin-group-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 20px;
    cursor: pointer;
    list-style: none;
}

.spec-admin-group-summary::-webkit-details-marker {
    display: none;
}

.spec-admin-group-summary span:first-child {
    font-weight: 700;
}

.spec-admin-group[open] .spec-admin-group-summary {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.spec-admin-group-content {
    display: grid;
    gap: 14px;
    padding: 18px 20px 20px;
}

.spec-admin-group-copy {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.spec-template-list,
.spec-custom-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 18px;
}

.spec-creator,
.feature-creator {
    display: grid;
    gap: 12px;
    padding: 16px;
    border: 1px dashed rgba(255, 255, 255, 0.1);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.02);
}

.spec-creator[hidden],
.feature-creator[hidden] {
    display: none;
}

.spec-template-row,
.spec-custom-row {
    display: grid;
    gap: 8px;
    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;
}

.spec-template-row,
.feature-option {
    position: relative;
}

.item-row-actions {
    position: absolute;
    top: 12px;
    right: 12px;
    display: none;
    align-items: center;
    gap: 6px;
}

.item-row-actions-inline {
    position: static;
    display: none;
    justify-content: flex-end;
}

.item-row-action {
    width: 34px;
    min-height: 34px;
    height: 34px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color 0.22s ease, background 0.22s ease;
}

.item-row-action-danger {
    color: #ff304f;
    border-color: rgba(255, 48, 79, 0.24);
}

.item-row-action:hover,
.item-row-action:focus-visible {
    border-color: rgba(217, 13, 37, 0.28);
    background: rgba(217, 13, 37, 0.12);
    outline: none;
}

.item-row-action-danger:hover,
.item-row-action-danger:focus-visible {
    border-color: rgba(255, 48, 79, 0.52);
    background: rgba(255, 48, 79, 0.14);
}


.spec-template-label-row {
    display: grid;
    gap: 4px;
}

.spec-template-label-row small {
    color: var(--muted);
    line-height: 1.45;
}

.spec-template-row-custom {
    grid-template-columns: 1fr;
}

.spec-custom-toolbar {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 10px;
}

.feature-creator-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.feature-creator-message {
    margin: 0;
    color: var(--muted);
    line-height: 1.45;
}

.feature-creator-message.is-error {
    color: #ffb6bf;
}

.feature-creator-message.is-success {
    color: #d8efe0;
}

.admin-inline-check {
    display: inline-flex !important;
    align-items: center;
    gap: 10px;
    color: var(--muted);
}

.admin-inline-check input {
    width: 18px;
    min-height: 18px;
    height: 18px;
    margin: 0;
    accent-color: rgb(217, 13, 37);
}

.admin-inline-check span {
    color: var(--muted);
}

.spec-custom-row-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
}

.spec-creator-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.spec-admin-group-note {
    padding: 14px 16px;
    border: 1px dashed rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    color: var(--muted);
    line-height: 1.6;
}

.feature-admin-accordion {
    display: grid;
    gap: 12px;
}

.feature-admin-group {
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.015));
    overflow: hidden;
}

.feature-admin-group-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 20px;
    cursor: pointer;
    list-style: none;
}

.feature-admin-group-summary::-webkit-details-marker {
    display: none;
}

.feature-admin-group-summary span:first-child {
    font-weight: 700;
}

.feature-admin-group[open] .feature-admin-group-summary {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.feature-admin-group-content {
    display: grid;
    gap: 16px;
    padding: 18px 20px 20px;
}

.feature-group-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.feature-group-search {
    max-width: 280px;
}

.feature-option-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.feature-option {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-height: 62px;
    padding: 14px 15px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
    cursor: pointer;
    transition: border-color 0.22s ease, background 0.22s ease, box-shadow 0.22s ease, transform 0.22s ease;
}

.feature-option:hover {
    border-color: rgba(217, 13, 37, 0.26);
    background: rgba(255, 255, 255, 0.045);
    transform: translateY(-1px);
}

.feature-option-input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.feature-option-box {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 1px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 7px;
    background: rgba(0, 0, 0, 0.16);
    transition: border-color 0.22s ease, background 0.22s ease, box-shadow 0.22s ease;
}

.feature-option-mark {
    width: 10px;
    height: 6px;
    border-left: 2px solid transparent;
    border-bottom: 2px solid transparent;
    transform: rotate(-45deg) translate(0, -1px);
    transition: border-color 0.18s ease;
}

.feature-option-label {
    color: var(--text);
    line-height: 1.45;
}

.feature-option-copy,
.feature-option-text-head {
    display: grid;
    gap: 5px;
}

.feature-option-caption {
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.45;
}

.feature-option-text {
    display: grid;
    align-content: start;
    gap: 12px;
    cursor: default;
}

.feature-option-text input {
    min-height: 46px;
}

.feature-option-custom {
    align-content: start;
}

.feature-option-custom.is-selected .feature-option-box {
    border-color: rgba(217, 13, 37, 0.42);
    background: rgba(217, 13, 37, 0.18);
    box-shadow: 0 0 0 3px rgba(217, 13, 37, 0.12);
}

.feature-option-custom.is-selected .feature-option-mark {
    border-color: #ffb8c0;
}

.feature-option-input:checked + .feature-option-box {
    border-color: rgba(217, 13, 37, 0.42);
    background: rgba(217, 13, 37, 0.18);
    box-shadow: 0 0 0 3px rgba(217, 13, 37, 0.12);
}

.feature-option-input:checked + .feature-option-box .feature-option-mark {
    border-color: #ffb8c0;
}

.feature-option-input:checked ~ .feature-option-label {
    color: #fff4f5;
}

.feature-option-input:focus-visible + .feature-option-box {
    border-color: rgba(217, 13, 37, 0.46);
    box-shadow: 0 0 0 3px rgba(217, 13, 37, 0.14);
}

.feature-option.is-hidden {
    display: none;
}

.feature-admin-group-content.is-editing .item-row-actions,
.feature-admin-group-content.is-editing .item-row-actions-inline,
.spec-admin-group-content.is-editing .item-row-actions,
.spec-admin-group-content.is-editing .item-row-actions-inline {
    display: inline-flex;
}

.feature-admin-group-content:not(.is-editing) [data-feature-add-row],
.spec-admin-group-content:not(.is-editing) [data-detail-spec-open-creator] {
    display: none;
}

.feature-admin-group-content:not(.is-editing) .feature-option input[type="text"],
.spec-admin-group-content:not(.is-editing) .spec-template-row input[type="text"],
.spec-admin-group-content:not(.is-editing) .spec-custom-row input[type="text"] {
    pointer-events: none;
}

.feature-admin-group-content:not(.is-editing) .feature-option-input {
    pointer-events: none;
}

.feature-custom-list {
    display: grid;
    gap: 12px;
}

.feature-custom-row {
    display: grid;
    gap: 12px;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.025);
}

.feature-custom-row-grid {
    display: grid;
    grid-template-columns: 1.25fr 0.8fr 1fr 1fr;
    gap: 12px;
}

.feature-custom-remove {
    justify-self: start;
    min-height: 38px;
    padding: 0 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted);
    cursor: pointer;
    transition: border-color 0.22s ease, color 0.22s ease, background 0.22s ease;
}

.feature-custom-remove:hover,
.feature-custom-remove:focus-visible {
    border-color: rgba(217, 13, 37, 0.3);
    background: rgba(217, 13, 37, 0.1);
    color: #fff2f4;
    outline: none;
}

.feature-custom-remove-inline {
    margin-top: 2px;
}

.admin-toast-stack {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 80;
    display: grid;
    gap: 10px;
}

.admin-toast {
    min-width: min(320px, calc(100vw - 32px));
    padding: 14px 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    background: rgba(12, 12, 12, 0.94);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.3);
    color: var(--text);
}

.admin-toast.is-success {
    border-color: rgba(101, 214, 145, 0.26);
}

.admin-toast.is-error {
    border-color: rgba(217, 13, 37, 0.28);
}

.detail-options-panel {
    display: grid;
    gap: 22px;
    padding: clamp(22px, 3vw, 30px);
}

.detail-options-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    cursor: pointer;
    list-style: none;
}

.detail-options-summary::-webkit-details-marker {
    display: none;
}

.detail-options-summary-icon {
    color: var(--muted);
    transition: transform 0.22s ease, color 0.22s ease;
}

.detail-options-panel[open] .detail-options-summary-icon {
    transform: rotate(180deg);
    color: var(--text);
}

.detail-options-header {
    display: grid;
    gap: 6px;
}

.detail-options-header h2,
.detail-options-header p {
    margin: 0;
}

.detail-options-header p {
    color: var(--muted);
    line-height: 1.6;
}

.detail-options-groups {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 22px;
    align-items: start;
}

.detail-options-group {
    display: grid;
    gap: 12px;
    align-content: start;
}

.detail-options-group h3 {
    margin: 0;
    font-size: 1rem;
}

.detail-options-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: flex-start;
    align-content: flex-start;
}

.detail-option-chip {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    min-height: 34px;
    padding: 0 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
    line-height: 1.4;
}

.upload-field {
    display: grid;
    gap: 8px;
}

.file-picker {
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 58px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.file-picker:hover {
    border-color: rgba(217, 13, 37, 0.3);
    background: rgba(255, 255, 255, 0.05);
}

.file-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.file-picker-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 38px;
    padding: 0 16px;
    border-radius: 12px;
    background: linear-gradient(135deg, #ff1b39, #8a0f1d);
    color: white;
    font-weight: 700;
    box-shadow: 0 12px 28px rgba(217, 13, 37, 0.18);
}

.file-picker-icon {
    width: 16px;
    height: 16px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.file-picker-text {
    color: var(--muted);
    line-height: 1.5;
}

.upload-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
}

.upload-preview-grid[hidden] {
    display: none;
}

.upload-preview-card {
    position: relative;
    display: grid;
    gap: 8px;
}

.upload-preview-media {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.03);
}

.upload-preview-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.upload-preview-name {
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.4;
    word-break: break-word;
}

.upload-preview-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    background: rgba(217, 13, 37, 0.88);
    color: #fff;
    font-size: 0.74rem;
    font-weight: 800;
}

.upload-preview-remove {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 1;
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 999px;
    background: rgba(10, 10, 12, 0.78);
    color: #fff;
    font-size: 1rem;
    line-height: 1;
    cursor: pointer;
}

.upload-preview-remove:hover {
    background: rgba(217, 13, 37, 0.9);
}

.existing-image-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    max-height: 720px;
    overflow-y: auto;
    padding-right: 6px;
}

.image-order-note {
    margin: 0 0 14px;
}

.existing-image-card {
    position: relative;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.02));
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.existing-image-card:hover {
    transform: translateY(-2px);
    border-color: rgba(217, 13, 37, 0.28);
}

.existing-image-card.is-dragging {
    opacity: 0.2;
    border-color: rgba(217, 13, 37, 0.45);
    transform: scale(0.98);
}

.existing-image-card.is-drop-target {
    border-color: rgba(217, 13, 37, 0.45);
    background: linear-gradient(180deg, rgba(217, 13, 37, 0.12), rgba(255, 255, 255, 0.03));
}

.existing-image-card.is-placeholder {
    border-style: dashed;
    border-color: rgba(217, 13, 37, 0.45);
    background: linear-gradient(180deg, rgba(217, 13, 37, 0.08), rgba(255, 255, 255, 0.02));
}

.existing-image-card img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 14px;
    margin-bottom: 10px;
}

.existing-image-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 1;
    display: none;
    align-items: center;
    min-height: 30px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(217, 13, 37, 0.92);
    color: white;
    font-size: 0.78rem;
    font-weight: 700;
    box-shadow: 0 12px 24px rgba(217, 13, 37, 0.22);
}

.existing-image-badge.is-visible {
    display: inline-flex;
}

.drag-handle {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 1;
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    background: rgba(7, 7, 7, 0.46);
    backdrop-filter: blur(12px);
    cursor: grab;
    transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.drag-handle:hover {
    border-color: rgba(217, 13, 37, 0.32);
    background: rgba(217, 13, 37, 0.12);
}

.drag-handle:active {
    cursor: grabbing;
    transform: scale(0.96);
}

.drag-handle span {
    width: 14px;
    height: 2px;
    margin: 0 auto;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
}

.existing-image-actions {
    display: grid;
    gap: 8px;
    margin-bottom: 10px;
}

.existing-image-actions .btn {
    width: 100%;
}

.existing-image-actions-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.is-hidden {
    display: none;
}

.drag-ghost {
    position: fixed;
    z-index: 999;
    width: 220px;
    pointer-events: none;
    opacity: 0.96;
    transform: rotate(-1.5deg);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
}

.admin-auth-body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top, rgba(217, 13, 37, 0.16), transparent 30%),
        linear-gradient(180deg, #090909, #040404);
}

.admin-auth-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
}

.admin-auth-card {
    width: min(460px, 100%);
}

.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.03);
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 880px;
}

.admin-table th,
.admin-table td {
    padding: 16px 18px;
    text-align: left;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}

.admin-table td span {
    display: block;
    margin-top: 6px;
    color: var(--muted);
}

.admin-table tbody tr {
    transition: background 0.18s ease, box-shadow 0.18s ease;
}

.admin-table tbody tr.is-selected {
    background: rgba(217, 13, 37, 0.12);
    box-shadow: inset 3px 0 0 var(--accent);
}

.admin-table tbody tr.is-selected td {
    border-bottom-color: rgba(217, 13, 37, 0.24);
}

.admin-car-id {
    display: inline-block !important;
    margin-top: 0 !important;
    color: var(--text) !important;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.admin-th-sort {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text);
    transition: color 0.2s ease;
}

.admin-th-sort:hover {
    color: #fff;
}

.admin-th-sort-arrow {
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1;
    transition: color 0.2s ease, transform 0.2s ease;
}

.admin-th-sort:hover .admin-th-sort-arrow,
.admin-th-sort-arrow.is-active {
    color: #ffb5be;
}

.admin-thumb-cell {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.admin-thumb {
    width: 72px;
    height: 52px;
    object-fit: cover;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
}

.admin-thumb-count {
    display: inline-block !important;
    margin-top: 0;
    min-width: 22px;
    text-align: left;
    color: var(--text) !important;
    font-weight: 700;
}

.admin-price-cell,
.admin-mobile-price-block {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.admin-price-stack {
    display: grid;
    gap: 4px;
}

.admin-price-current {
    display: block;
    color: var(--text);
    font-weight: 700;
    line-height: 1.1;
}

.admin-price-old {
    display: block;
    margin-top: 0 !important;
    color: var(--muted) !important;
    font-size: 0.82rem;
    line-height: 1;
    text-decoration: line-through;
}

.admin-price-old[hidden] {
    display: none !important;
}

.admin-price-edit-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--muted);
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.admin-price-edit-button:hover {
    border-color: rgba(217, 13, 37, 0.24);
    background: rgba(217, 13, 37, 0.1);
    color: #fff;
    transform: translateY(-1px);
}

.admin-price-edit-button:focus-visible {
    outline: 0;
    border-color: rgba(217, 13, 37, 0.36);
    background: rgba(217, 13, 37, 0.12);
    color: #fff;
}

.admin-price-edit-button-mobile {
    width: 44px;
    height: 44px;
    border-radius: 14px;
}

.admin-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.admin-stats-grid-compact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.admin-stat-card {
    position: relative;
    display: grid;
    gap: 8px;
    padding: 18px 18px 16px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
    overflow: hidden;
}

.admin-stat-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: linear-gradient(180deg, rgba(255, 92, 106, 0.92), rgba(255, 92, 106, 0.2));
}

.admin-stat-label {
    color: var(--muted);
    font-size: 0.92rem;
}

.admin-stat-value {
    font-size: clamp(1.55rem, 3vw, 2rem);
    line-height: 1;
    color: var(--text);
    letter-spacing: -0.03em;
}

.admin-search-form {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}

.admin-search-field {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-height: 54px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
}

.admin-search-field input {
    flex: 1;
    min-height: 54px;
    padding: 0;
    border: 0;
    background: transparent;
}

.admin-search-field input:focus {
    outline: none;
}

.admin-search-field input::-webkit-search-cancel-button {
    display: none;
    -webkit-appearance: none;
}

.admin-search-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    display: inline-block;
    background-color: currentColor;
    color: var(--muted);
    -webkit-mask-image: var(--admin-icon);
    mask-image: var(--admin-icon);
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
}

.admin-search-clear {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.admin-search-clear:hover {
    opacity: 1;
    transform: scale(1.04);
}

.admin-search-clear img {
    width: 18px;
    height: 18px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.admin-search-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.admin-mobile-search-submit,
.admin-mobile-toolbar,
.admin-mobile-card-list,
.admin-mobile-filter-overlay,
.admin-mobile-filter-panel,
.admin-form-sticky-actions {
    display: none;
}

.admin-mobile-filter-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.admin-mobile-filter-header h2 {
    margin: 4px 0 0;
    font-size: 1.2rem;
}

.admin-mobile-filter-body {
    display: grid;
    gap: 16px;
}

.admin-mobile-filter-section {
    display: grid;
    gap: 10px;
}

.admin-mobile-choice-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.admin-mobile-choice-grid .btn.is-active {
    border-color: rgba(217, 13, 37, 0.38);
    background: rgba(217, 13, 37, 0.12);
    color: #fff4f5;
}

.admin-mobile-filter-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.admin-mobile-car-card__top,
.admin-mobile-car-card__body,
.admin-mobile-car-card__actions,
.admin-mobile-car-card__badges,
.admin-mobile-car-card__meta,
.admin-mobile-car-card__media {
    display: flex;
}

.admin-mobile-car-card__top,
.admin-mobile-car-card__actions {
    align-items: center;
    justify-content: space-between;
}

.admin-mobile-car-card__body {
    gap: 14px;
    align-items: flex-start;
    justify-content: space-between;
}

.admin-mobile-car-card__copy {
    display: grid;
    gap: 6px;
    min-width: 0;
}

.admin-mobile-car-card__copy strong {
    font-size: 1rem;
    line-height: 1.2;
}

.admin-mobile-car-card__copy > span {
    color: var(--muted);
    font-size: 0.9rem;
}

.admin-mobile-car-card__meta {
    gap: 8px;
    flex-wrap: wrap;
    color: var(--text);
    font-weight: 700;
}

.admin-mobile-price-block {
    flex-wrap: nowrap;
}

.admin-mobile-car-card__badges {
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.admin-mobile-car-card__media {
    width: 96px;
    flex-direction: column;
    gap: 8px;
    align-items: stretch;
}

.admin-mobile-car-card__media .admin-thumb {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 14px;
}

.admin-mobile-car-card__actions {
    gap: 10px;
}

.admin-mobile-car-card__actions > .btn {
    flex: 1;
}

.admin-row-menu-trigger-mobile {
    min-width: 52px;
    min-height: 52px;
    padding: 0 14px;
}

.admin-row-menu-trigger-mobile__dots {
    font-size: 1.7rem;
    line-height: 1;
    transform: translateY(-1px);
}

.admin-row-menu-dropdown-mobile {
    min-width: 220px;
}

.admin-filter-menu {
    position: relative;
}

.admin-price-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 79;
    background: rgba(0, 0, 0, 0.58);
    backdrop-filter: blur(8px);
}

.admin-price-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    z-index: 80;
    width: min(460px, calc(100vw - 32px));
    display: grid;
    gap: 18px;
    padding: 24px;
    transform: translate(-50%, -50%);
    background: rgba(14, 14, 14, 0.94);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.38);
}

.admin-price-modal[hidden],
.admin-price-modal-overlay[hidden] {
    display: none;
}

.admin-price-modal__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.admin-price-modal__header h2 {
    margin: 4px 0 0;
}

.admin-price-modal__subtitle {
    margin: 8px 0 0;
    color: var(--muted);
    line-height: 1.45;
}

.admin-price-modal__form {
    display: grid;
    gap: 16px;
}

.admin-price-modal__actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.admin-filter-menu[open] > .admin-filter-trigger,
.admin-row-menu[open] > .admin-row-menu-trigger {
    border-color: rgba(217, 13, 37, 0.34);
    background: rgba(217, 13, 37, 0.08);
}

.admin-filter-menu summary {
    list-style: none;
}

.admin-filter-menu summary::-webkit-details-marker {
    display: none;
}

.admin-filter-trigger {
    min-width: 168px;
}

.admin-filter-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 8;
    display: grid;
    min-width: 220px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(10, 10, 10, 0.96);
    box-shadow: 0 22px 50px rgba(0, 0, 0, 0.35);
    transform-origin: top right;
    will-change: transform, opacity;
    opacity: 0;
    transform: translateY(-8px) scale(0.96);
    pointer-events: none;
}

.admin-filter-menu[open] > .admin-filter-dropdown,
.admin-filter-menu.is-opening > .admin-filter-dropdown,
.admin-filter-menu.is-closing > .admin-filter-dropdown,
.admin-row-menu[open] > .admin-row-menu-dropdown,
.admin-row-menu.is-opening > .admin-row-menu-dropdown,
.admin-row-menu.is-closing > .admin-row-menu-dropdown {
    display: grid;
}

.admin-filter-menu[open] > .admin-filter-dropdown,
.admin-filter-menu.is-opening > .admin-filter-dropdown,
.admin-row-menu[open] > .admin-row-menu-dropdown,
.admin-row-menu.is-opening > .admin-row-menu-dropdown {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.admin-filter-menu.is-opening > .admin-filter-dropdown,
.admin-row-menu.is-opening > .admin-row-menu-dropdown {
    animation: admin-menu-reveal 0.22s cubic-bezier(0.22, 1, 0.36, 1);
}

.admin-filter-menu.is-closing > .admin-filter-dropdown,
.admin-row-menu.is-closing > .admin-row-menu-dropdown {
    opacity: 0;
    transform: translateY(-8px) scale(0.96);
    pointer-events: none;
    animation: admin-menu-hide 0.2s cubic-bezier(0.4, 0, 1, 1);
}

.admin-filter-option {
    width: 100%;
    display: block;
    padding: 10px 12px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: var(--muted);
    text-align: left;
    font: inherit;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.admin-filter-option:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
}

.admin-filter-option.is-active {
    background: rgba(229, 9, 20, 0.12);
    color: var(--text);
    box-shadow: inset 0 0 0 1px rgba(229, 9, 20, 0.2);
}

.admin-row-actions {
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
}

.admin-row-menu {
    position: relative;
    flex: 0 0 auto;
}

.admin-row-menu summary {
    list-style: none;
}

.admin-row-menu summary::-webkit-details-marker {
    display: none;
}

.admin-row-menu-trigger {
    min-width: 40px;
    width: 40px;
    padding: 0;
}

.admin-row-menu-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 10;
    display: grid;
    min-width: 220px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(10, 10, 10, 0.96);
    box-shadow: 0 22px 50px rgba(0, 0, 0, 0.35);
    transform-origin: top right;
    will-change: transform, opacity;
    opacity: 0;
    transform: translateY(-8px) scale(0.96);
    pointer-events: none;
}

.admin-row-menu-dropdown form {
    display: block;
}

.admin-row-menu-item {
    width: 100%;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 11px 12px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: var(--muted);
    text-align: left;
    font: inherit;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.admin-row-menu-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
}

.admin-row-menu-item.is-danger {
    color: #ffb4bc;
}

.admin-row-menu-item.is-danger:hover {
    background: rgba(217, 13, 37, 0.14);
    color: #ffd0d5;
}

.admin-selection-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 14px;
    padding: 12px 14px;
    border: 1px solid rgba(217, 13, 37, 0.24);
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(217, 13, 37, 0.14), rgba(255, 255, 255, 0.035));
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.22);
}

.admin-selection-bar[hidden] {
    display: none;
}

.admin-selection-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.admin-selection-actions [hidden] {
    display: none;
}

.admin-context-menu {
    position: fixed;
    z-index: 80;
    display: grid;
    min-width: 190px;
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 18px;
    background: rgba(10, 10, 10, 0.96);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.42);
    backdrop-filter: blur(18px);
}

.admin-context-menu[hidden] {
    display: none;
}

.status-badge-neutral {
    background: rgba(255, 255, 255, 0.08) !important;
    border-color: rgba(255, 255, 255, 0.14) !important;
    color: #d7d7d7 !important;
}

.btn-danger-soft {
    color: #ffbac3;
    border-color: rgba(217, 13, 37, 0.26);
    background: rgba(217, 13, 37, 0.08);
}

.btn-danger-soft:hover {
    border-color: rgba(217, 13, 37, 0.38);
    background: rgba(217, 13, 37, 0.14);
}

.admin-table-callbacks {
    min-width: 720px;
}

@keyframes admin-menu-reveal {
    from {
        opacity: 0;
        transform: translateY(-8px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes admin-menu-hide {
    from {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateY(-8px) scale(0.96);
    }
}

.empty-state,
.empty-panel,
.empty-table {
    color: var(--muted);
}

.empty-panel {
    padding: 28px;
}

.link-arrow {
    color: #ffc4cc;
}

.flash-stack {
    position: fixed;
    top: 90px;
    right: 24px;
    z-index: 95;
    display: grid;
    gap: 12px;
    width: min(420px, calc(100vw - 48px));
    margin-top: 0;
    pointer-events: none;
}

.flash-stack.compact {
    margin: 0;
}

.flash {
    position: relative;
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 14px;
    padding: 15px 18px;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015)),
        rgba(9, 10, 14, 0.62);
    backdrop-filter: blur(18px) saturate(130%);
    box-shadow:
        0 18px 42px rgba(0, 0, 0, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
    opacity: 0;
    transform: translateX(120%);
    animation: flash-in 0.3s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    transition: margin 0.3s ease, padding 0.3s ease;
    pointer-events: auto;
    overflow: hidden;
}

.flash.is-hiding {
    animation: flash-out 0.3s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    margin: 0;
    padding-top: 0;
    padding-bottom: 0;
}

.flash::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: linear-gradient(180deg, rgba(255, 92, 106, 0.95), rgba(255, 92, 106, 0.28));
}

.flash-message {
    flex: 1;
    line-height: 1.45;
}

.flash-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    cursor: pointer;
    opacity: 0.72;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.flash-close:hover {
    opacity: 1;
    transform: scale(1.04);
}

.flash-close img {
    width: 18px;
    height: 18px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.flash-success {
    border-color: rgba(55, 160, 78, 0.28);
    color: #c5f7d1;
}

.flash-success::before {
    background: linear-gradient(180deg, rgba(55, 160, 78, 0.95), rgba(55, 160, 78, 0.26));
}

.flash-error,
.flash-danger {
    border-color: rgba(217, 13, 37, 0.35);
    color: #ffc2ca;
}

.flash-error::before,
.flash-danger::before {
    background: linear-gradient(180deg, rgba(217, 13, 37, 0.98), rgba(217, 13, 37, 0.3));
}

.flash-warning {
    border-color: rgba(234, 168, 58, 0.34);
    color: #ffe2a5;
}

.flash-warning::before {
    background: linear-gradient(180deg, rgba(234, 168, 58, 0.98), rgba(234, 168, 58, 0.28));
}

.flash-info {
    border-color: rgba(89, 152, 255, 0.3);
    color: #cfe0ff;
}

.flash-info::before {
    background: linear-gradient(180deg, rgba(89, 152, 255, 0.95), rgba(89, 152, 255, 0.24));
}

@keyframes flash-in {
    from {
        opacity: 0;
        transform: translateX(120%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes flash-out {
    from {
        opacity: 1;
        transform: translateX(0);
    }
    to {
        opacity: 0;
        transform: translateX(120%);
    }
}

@media (max-width: 780px) {
    .flash-stack {
        top: 90px;
        left: 16px;
        right: 16px;
        width: auto;
        gap: 10px;
    }
}

.admin-page .mobile-bottom-nav {
    display: none !important;
}

.admin-page .site-main > .section:last-child {
    padding-bottom: 42px;
}

@media (max-width: 900px) {
    .admin-search-actions {
        display: none;
    }

    .admin-mobile-card-list {
        display: grid;
        gap: 12px;
    }

    .table-wrap,
    .admin-context-menu,
    .admin-selection-bar {
        display: none !important;
    }

    .admin-stats-grid {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .admin-stat-card {
        min-height: 112px;
        padding: 16px;
    }

    .admin-search-form {
        display: grid;
        gap: 12px;
    }

    .admin-mobile-search-submit {
        display: inline-flex;
        min-height: 52px;
        width: 100%;
        justify-content: center;
    }

    .admin-mobile-toolbar {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .admin-mobile-toolbar .btn,
    .admin-mobile-toolbar a {
        min-height: 48px;
        justify-content: center;
        text-align: center;
    }

    .admin-mobile-filter-overlay {
        position: fixed;
        inset: 0;
        z-index: 80;
        background: rgba(4, 5, 8, 0.72);
        backdrop-filter: blur(6px);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.26s ease;
    }

    .admin-mobile-filter-overlay[hidden] {
        display: none;
    }

    .admin-mobile-filter-overlay.is-open {
        display: block;
        opacity: 1;
        pointer-events: auto;
    }

    .admin-mobile-filter-panel {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 90;
        display: grid;
        gap: 16px;
        width: 100%;
        max-height: min(88dvh, 820px);
        margin: 0;
        padding: 18px 16px calc(18px + env(safe-area-inset-bottom));
        border-radius: 26px 26px 0 0;
        overflow-y: auto;
        transform: translateY(104%);
        transition: transform 0.26s ease;
        pointer-events: none;
        background:
            linear-gradient(180deg, rgba(22, 22, 24, 0.98), rgba(12, 12, 14, 0.98)),
            rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(22px);
    }

    .admin-mobile-filter-panel.is-open {
        transform: translateY(0);
        pointer-events: auto;
    }

    .admin-mobile-car-card {
        display: grid;
        gap: 14px;
        padding: 16px;
    }

    .admin-mobile-price-block {
        width: 100%;
        justify-content: space-between;
    }

    .admin-mobile-empty-state {
        display: block;
        padding: 18px;
    }

    .admin-row-menu-dropdown-mobile {
        right: 0;
        left: auto;
    }

    .form-section-mobile-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .form-section[data-mobile-collapsible].is-collapsed-mobile [data-mobile-section-content] {
        display: none;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .filter-actions {
        display: none;
    }

    .admin-form-sticky-actions {
        position: fixed;
        left: 12px;
        right: 12px;
        bottom: calc(12px + env(safe-area-inset-bottom));
        z-index: 35;
        display: grid;
        grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
        gap: 10px;
        padding: 10px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 22px;
        background:
            linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02)),
            rgba(9, 10, 14, 0.9);
        backdrop-filter: blur(20px);
        box-shadow: 0 18px 42px rgba(0, 0, 0, 0.28);
    }

    .admin-form-sticky-actions .btn,
    .admin-form-sticky-actions a {
        min-height: 48px;
        justify-content: center;
    }

    .existing-images {
        margin-top: 16px;
    }

    .drag-handle {
        display: none;
    }

    .admin-page .flash-stack {
        top: max(76px, calc(58px + env(safe-area-inset-top)));
        left: 12px;
        right: 12px;
        width: auto;
    }

    .admin-page .flash {
        padding: 12px 14px;
        border-radius: 16px;
    }

    .admin-price-modal {
        top: auto;
        left: 16px;
        right: 16px;
        bottom: calc(16px + env(safe-area-inset-bottom));
        width: auto;
        max-height: min(82dvh, 640px);
        overflow-y: auto;
        transform: none;
        padding: 20px 16px;
        border-radius: 24px;
    }
}

@media (max-width: 768px) {
    .catalog-inline-grid {
        grid-template-columns: 1fr;
    }

    body.admin-page {
        padding-bottom: calc(92px + env(safe-area-inset-bottom));
    }

    .admin-page .site-main > .section:last-child {
        padding-bottom: calc(156px + env(safe-area-inset-bottom));
    }

    .file-picker {
        align-items: flex-start;
        flex-direction: column;
    }

    .existing-image-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }
}

@media (max-width: 560px) {
    .admin-stats-grid,
    .admin-mobile-choice-grid,
    .admin-mobile-toolbar,
    .existing-image-actions-row {
        grid-template-columns: 1fr;
    }

    .admin-mobile-car-card__body {
        flex-direction: column;
    }

    .admin-mobile-car-card__media {
        width: 100%;
        flex-direction: row;
        align-items: center;
    }

    .admin-mobile-car-card__media .admin-thumb {
        width: 92px;
        flex: 0 0 92px;
    }

    .admin-mobile-car-card__actions {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
    }
}

.site-footer {
    border-top: 1px solid var(--line);
    margin-top: 36px;
}

.footer-meta {
    display: grid;
    gap: 6px;
    text-align: right;
    color: var(--muted);
}

@media (max-width: 1100px) {
    .car-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hero-grid,
    .detail-layout,
    .contacts-grid,
    .catalog-layout,
    .form-layout {
        grid-template-columns: 1fr;
    }

    .hero-screen {
        min-height: 740px;
        padding: 72px 0 24px;
    }

    .hero-services-panel {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        margin-top: 28px;
    }

    .hero-service-item:nth-child(3),
    .hero-service-item:nth-child(4) {
        border-top: 1px solid rgba(255, 255, 255, 0.08);
    }

    .hero-service-item:nth-child(3) {
        border-left: none;
    }

    .detail-specs-groups {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 24px;
    }

    .feature-option-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .feature-custom-row-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .spec-custom-row-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .spec-template-list,
    .spec-custom-list {
        grid-template-columns: 1fr;
    }

}

@media (max-width: 780px) {
    .detail-price-card {
        gap: 16px;
        padding: 18px;
        border-radius: 24px;
    }

    .detail-price {
        font-size: clamp(1.8rem, 8vw, 2.3rem);
    }

    .detail-social-cards {
        grid-template-columns: 1fr;
    }

    .detail-social-card,
    .detail-share-button {
        min-height: 50px;
        justify-content: flex-start;
        padding: 0 14px;
    }

    .detail-sidebar-primary-actions,
    .detail-sidebar-secondary-actions {
        grid-template-columns: 1fr;
    }

    .site-nav {
        position: absolute;
        top: calc(100% + 8px);
        right: 16px;
        left: 16px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding: 16px;
        border: 1px solid var(--line);
        border-radius: 22px;
        background: rgba(10, 10, 10, 0.96);
    }

    .site-nav.is-open {
        display: flex;
    }

    .nav-toggle {
        display: inline-block;
    }

    .hero-section,
    .page-hero,
    .section {
        padding: 32px 0;
    }

    .hero-stage {
        padding-top: 0;
    }

    .hero-screen {
        min-height: auto;
        padding: 56px 0 18px;
    }

    .hero-copy h1 {
        max-width: 12ch;
        font-size: clamp(2.7rem, 16vw, 4.8rem);
    }

    .hero-copy p {
        max-width: 30ch;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-btn {
        width: 100%;
    }

    .hero-services-panel {
        grid-template-columns: 1fr;
        padding: 10px;
        border-radius: 24px;
    }

    .hero-service-item,
    .hero-service-item:nth-child(3),
    .hero-service-item:nth-child(4) {
        min-height: auto;
        padding: 16px;
        border-top: none;
        border-left: none;
    }

    .hero-service-item + .hero-service-item {
        border-top: 1px solid rgba(255, 255, 255, 0.08);
    }

    .section-heading-row,
    .header-row,
    .footer-row,
    .admin-hero-row {
        align-items: start;
        flex-direction: column;
    }

    .admin-search-form,
    .admin-search-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .admin-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-filter-trigger,
    .admin-filter-dropdown {
        width: 100%;
        min-width: 0;
    }

    .admin-filter-dropdown {
        left: 0;
        right: auto;
    }

    .car-grid,
    .detail-specs-layout,
    .detail-options-groups,
    .existing-image-grid,
    .detail-specs-groups,
    .detail-battery-grid,
    .detail-social-cards,
    .form-grid,
    .spec-grid {
        grid-template-columns: 1fr;
    }

    .feature-option-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

    .car-card-top {
        flex-direction: column;
    }

    .detail-specs-row {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .detail-specs-value {
        text-align: left;
    }

    .footer-meta {
        text-align: left;
    }
}

@media (max-width: 768px) {
    body {
        padding-bottom: calc(110px + env(safe-area-inset-bottom));
    }

    .nav-toggle,
    .site-nav {
        display: none !important;
    }

    .header-row {
        justify-content: center;
    }

    .site-header {
        position: static;
        z-index: 30;
    }

    .site-header .container {
        padding: 14px 0;
    }

    .feature-group-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .feature-group-search {
        max-width: none;
    }

    .feature-option-grid,
    .feature-custom-row-grid,
    .spec-custom-row-grid {
        grid-template-columns: 1fr;
    }

    .brand-logo {
        width: clamp(156px, 42vw, 210px);
    }

    .hero-section {
        padding: 0;
    }

    .hero-screen {
        min-height: min(calc(100dvh - 80px), 680px);
        padding: 14px 0 calc(24px + env(safe-area-inset-bottom));
        background:
            radial-gradient(circle at 74% 22%, rgba(217, 13, 37, 0.2), transparent 22%),
            linear-gradient(135deg, rgba(0, 0, 0, 0.98) 12%, rgba(0, 0, 0, 0.82) 50%, rgba(0, 0, 0, 0.52) 100%);
    }

    .hero-screen-inner {
        display: grid;
        align-content: space-between;
        min-height: calc(min(100dvh - 80px, 680px) - 14px - 24px - env(safe-area-inset-bottom));
        gap: 14px;
    }

    .hero-grid {
        min-height: clamp(236px, 35vh, 320px);
        align-items: start;
    }

    .hero-copy {
        max-width: min(100%, 34rem);
        padding-top: 0;
    }

    .hero-copy .eyebrow {
        margin-bottom: 8px;
        font-size: 0.68rem;
        letter-spacing: 0.14em;
    }

    .hero-copy h1 {
        margin: 6px 0 12px;
        max-width: 10ch;
        font-size: clamp(42px, 12vw, 64px);
        line-height: 0.9;
    }

    .hero-copy p {
        max-width: 28ch;
        margin: 0;
        font-size: 0.96rem;
        line-height: 1.5;
    }

    .hero-actions {
        gap: 8px;
        margin-top: 16px;
    }

    .hero-btn {
        min-height: 46px;
        min-width: 0;
        padding: 0 16px;
        gap: 10px;
        border-radius: 14px;
    }

    .hero-backdrop img {
        object-position: 64% center;
        transform: scale(1.04);
    }

    .hero-overlay {
        background:
            linear-gradient(180deg, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.12) 18%, rgba(0, 0, 0, 0.7) 100%),
            linear-gradient(98deg, rgba(0, 0, 0, 0.97) 0%, rgba(0, 0, 0, 0.9) 32%, rgba(0, 0, 0, 0.58) 62%, rgba(0, 0, 0, 0.24) 100%),
            radial-gradient(circle at 74% 52%, rgba(217, 13, 37, 0.14), transparent 26%);
    }

    .hero-services-panel {
        margin-top: 6px;
        width: 100%;
        padding: 8px;
        border-radius: 22px;
    }

    .hero-service-item,
    .hero-service-item:nth-child(3),
    .hero-service-item:nth-child(4) {
        gap: 14px;
        padding: 14px;
    }

    .hero-service-icon {
        width: 48px;
        height: 48px;
        flex: 0 0 48px;
        border-radius: 16px;
    }

    .hero-service-icon img {
        width: 22px;
        height: 22px;
    }

    .hero-service-item h3 {
        margin-bottom: 4px;
        font-size: 1.1rem;
    }

    .hero-service-item p {
        max-width: none;
        font-size: 0.88rem;
        line-height: 1.35;
    }

    .section {
        padding: 26px 0;
    }

    .hero-section + .section {
        padding-top: 18px;
    }

    .site-main > .section:last-child {
        padding-bottom: calc(132px + env(safe-area-inset-bottom));
    }

    .mobile-bottom-nav {
        position: fixed;
        left: 12px;
        right: 12px;
        bottom: calc(12px + env(safe-area-inset-bottom));
        z-index: 40;
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 6px;
        padding: 8px;
        border: 1px solid var(--line);
        border-radius: 26px;
        background:
            linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012)),
            rgba(10, 10, 10, 0.74);
        backdrop-filter: blur(20px);
        box-shadow:
            0 18px 42px rgba(0, 0, 0, 0.48),
            inset 0 1px 0 rgba(255, 255, 255, 0.04);
    }

    .mobile-bottom-nav__item {
        min-width: 0;
        min-height: 58px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding: 8px 4px;
        border-radius: 18px;
        color: var(--muted);
        transition:
            color 0.2s ease,
            background 0.2s ease,
            transform 0.2s ease,
            box-shadow 0.2s ease;
        -webkit-tap-highlight-color: transparent;
    }

    .mobile-bottom-nav__item:hover,
    .mobile-bottom-nav__item:active {
        color: var(--text);
        background: rgba(255, 255, 255, 0.035);
    }

    .mobile-bottom-nav__item.is-active {
        color: var(--red);
        background: linear-gradient(180deg, rgba(217, 13, 37, 0.18), rgba(217, 13, 37, 0.08));
        box-shadow: inset 0 0 0 1px rgba(217, 13, 37, 0.24);
    }

    .mobile-bottom-nav__icon {
        width: 24px;
        height: 24px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex: 0 0 24px;
    }

    .mobile-bottom-nav__icon svg {
        width: 22px;
        height: 22px;
    }

    .mobile-bottom-nav__icon img {
        width: 22px;
        height: 22px;
        object-fit: contain;
        opacity: 0.78;
        filter: brightness(0) invert(1);
    }

    .mobile-bottom-nav__item.is-active .mobile-bottom-nav__icon img {
        opacity: 1;
        filter: brightness(0) saturate(100%) invert(16%) sepia(92%) saturate(4161%) hue-rotate(343deg) brightness(89%) contrast(98%);
    }

    .mobile-bottom-nav__label {
        max-width: 100%;
        font-size: 0.68rem;
        font-weight: 700;
        line-height: 1;
        letter-spacing: 0.01em;
        text-align: center;
        white-space: nowrap;
    }

    body.lightbox-open .mobile-bottom-nav {
        opacity: 0;
        transform: translateY(16px);
        pointer-events: none;
    }

    body.filter-drawer-open .mobile-bottom-nav {
        opacity: 0;
        transform: translateY(16px);
        pointer-events: none;
    }

    .featured-cars-carousel {
        margin: 0;
        padding: 0;
        overflow: hidden;
    }

    .featured-cars-track {
        display: flex;
        gap: 12px;
        overflow-x: auto;
        overflow-y: hidden;
        padding: 2px 0 6px;
        scroll-snap-type: x mandatory;
        scroll-padding-left: 0;
        scrollbar-width: none;
    }

    .featured-cars-track::-webkit-scrollbar {
        display: none;
    }

    .featured-cars-track .car-card {
        flex: 0 0 100%;
        min-width: 100%;
        scroll-snap-align: start;
        scroll-snap-stop: always;
    }

    .featured-cars-dots {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        margin-top: 10px;
        padding-right: 16px;
    }

    .featured-cars-dot {
        width: 8px;
        height: 8px;
        padding: 0;
        border: 0;
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.2);
        transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    }

    .featured-cars-dot.is-active {
        background: var(--red);
        transform: scale(1.15);
        box-shadow: 0 0 0 4px rgba(217, 13, 37, 0.12);
    }

    .catalog-layout {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .catalog-heading-tools {
        width: 100%;
        justify-content: space-between;
        align-items: center;
        gap: 10px;
    }

    .catalog-heading-tools .muted-copy {
        display: none;
    }

    .catalog-sort-menu .admin-filter-trigger,
    .catalog-mobile-filters {
        min-width: 0;
        min-height: 44px;
        padding: 0 14px;
        gap: 8px;
        border-radius: 14px;
    }

    .catalog-mobile-filters {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .filter-panel {
        position: fixed;
        top: 0;
        left: 0;
        z-index: 90;
        width: min(88vw, 380px);
        max-width: 100%;
        height: 100dvh;
        margin: 0;
        padding: calc(18px + env(safe-area-inset-top)) 16px calc(24px + env(safe-area-inset-bottom));
        border-radius: 0 26px 26px 0;
        overflow-y: auto;
        transform: translateX(-104%);
        pointer-events: none;
        transition: transform 0.26s ease;
        background:
            linear-gradient(180deg, rgba(22, 22, 24, 0.98), rgba(12, 12, 14, 0.98)),
            rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(22px);
        scrollbar-width: none;
    }

    .filter-panel::-webkit-scrollbar {
        display: none;
    }

    .filter-panel.is-open {
        transform: translateX(0);
        pointer-events: auto;
    }

    .catalog-filter-close {
        width: 44px;
        height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex: 0 0 44px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 14px;
        background: rgba(255, 255, 255, 0.04);
        color: var(--text);
    }

    .catalog-filter-close img {
        width: 18px;
        height: 18px;
        object-fit: contain;
        filter: brightness(0) invert(1);
    }

    .catalog-filter-overlay {
        position: fixed;
        inset: 0;
        z-index: 80;
        display: block;
        background: rgba(4, 5, 8, 0.72);
        backdrop-filter: blur(6px);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.26s ease;
    }

    .catalog-filter-overlay[hidden] {
        display: none;
    }

    .catalog-filter-overlay.is-open {
        opacity: 1;
        pointer-events: auto;
    }

    .filters-form {
        gap: 14px;
    }

    .filter-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
        position: sticky;
        bottom: calc(-10px - env(safe-area-inset-bottom));
        padding-top: 12px;
        padding-bottom: 10px;
        background: linear-gradient(180deg, rgba(12, 12, 14, 0), rgba(12, 12, 14, 0.96) 36%);
        z-index: 2;
    }

    .filter-actions .btn {
        min-height: 50px;
        justify-content: center;
    }

    .catalog-car-grid {
        gap: 8px;
        padding-bottom: 8px;
    }

    .car-card {
        border-radius: 16px;
    }

    .car-image-wrap img {
        aspect-ratio: 16 / 6.4;
    }

    .car-card-body {
        padding: 8px 9px 9px;
    }

    .car-card-top {
        display: grid;
        gap: 3px;
        margin-bottom: 6px;
    }

    .car-card h3 {
        font-size: 1rem;
        line-height: 1.16;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .car-price {
        font-size: 0.98rem;
    }

    .car-meta {
        display: block;
        margin-bottom: 8px;
        font-size: 0.74rem;
        line-height: 1.2;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .car-meta span {
        gap: 0;
    }

    .car-meta span:not(:last-child)::after {
        content: "·";
        margin: 0 4px 0 5px;
        color: rgba(255, 255, 255, 0.24);
    }

    .btn.btn-block {
        min-height: 34px;
        font-size: 0.82rem;
        border-radius: 12px;
        padding: 0 12px;
    }

    .status-badge.overlay {
        top: 8px;
        left: 8px;
        padding: 4px 8px;
        font-size: 0.68rem;
    }
}

@media (max-width: 560px) {
    .thumb-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .lightbox-modal {
        height: 100dvh;
    }

    .lightbox-topbar {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding-right: 72px;
    }

    .lightbox-stage {
        grid-template-columns: minmax(44px, 12vw) minmax(0, 1fr) minmax(44px, 12vw);
        padding: 0;
        border-radius: 22px;
    }

    .lightbox-media {
        padding: 6px 2px;
    }

    .lightbox-image {
        max-height: calc(100dvh - 148px);
    }

    .lightbox-shell {
        gap: 14px;
        padding: 14px;
    }

    .lightbox-close {
        top: 14px;
        right: 14px;
        width: 50px;
        height: 50px;
    }

    .lightbox-hit-area {
        padding: 4px;
    }

    .lightbox-nav {
        width: 58px;
        height: 58px;
        border-radius: 20px;
    }

    .admin-stats-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .detail-layout {
        display: grid;
        grid-template-columns: 1fr;
    }

    .detail-gallery {
        display: contents;
    }

    .detail-main-image {
        order: 1;
        padding: 0;
        border-radius: 24px;
    }

    .detail-main-image img {
        border-radius: 24px;
        aspect-ratio: 4 / 3;
    }

    .detail-main-image > #mainCarImage {
        display: none;
    }

    .detail-mobile-carousel {
        display: flex;
        width: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        scroll-snap-type: x mandatory;
        scroll-behavior: smooth;
        border-radius: 24px;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .detail-mobile-carousel::-webkit-scrollbar {
        display: none;
    }

    .detail-mobile-carousel__image {
        flex: 0 0 100%;
        width: 100%;
        aspect-ratio: 4 / 3;
        object-fit: cover;
        scroll-snap-align: center;
        scroll-snap-stop: always;
        user-select: none;
    }

    .detail-photo-count-badge {
        display: inline-flex;
        top: 12px;
        right: 12px;
    }

    .detail-sidebar {
        order: 2;
    }

    .detail-description {
        order: 3;
    }

    .thumb-grid,
    .detail-gallery-toggle {
        display: none !important;
    }

    .feature-option-grid {
        grid-template-columns: 1fr;
    }

    .lightbox-modal {
        width: 100vw;
        height: 100dvh;
        padding: 0;
        overflow: hidden;
    }

    .lightbox-shell {
        gap: 0;
        padding: 0;
        width: 100vw;
        height: 100dvh;
        overflow: hidden;
    }

    .lightbox-topbar {
        position: absolute;
        top: max(12px, env(safe-area-inset-top));
        left: 12px;
        right: 12px;
        z-index: 5;
        display: block;
        padding: 0;
        pointer-events: none;
    }

    .lightbox-counter {
        display: inline-flex;
        align-items: center;
        min-height: 36px;
        padding: 8px 12px;
        font-size: 0.92rem;
        background: rgba(12, 13, 18, 0.58);
        pointer-events: auto;
    }

    .lightbox-close {
        top: max(12px, env(safe-area-inset-top));
        right: 12px;
        width: 44px;
        height: 44px;
        border-radius: 14px;
        z-index: 6;
    }

    .lightbox-close img {
        width: 18px;
        height: 18px;
    }

    .lightbox-stage {
        width: 100vw;
        height: 100dvh;
        display: block;
        padding: 0;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }

    .lightbox-media {
        width: 100%;
        height: 100%;
        padding: 0;
        display: block;
        overflow: hidden;
        touch-action: pan-x pinch-zoom;
    }

    .lightbox-image {
        display: none;
    }

    .lightbox-mobile-carousel {
        display: flex;
        width: 100%;
        height: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        scroll-snap-type: x mandatory;
        scroll-behavior: smooth;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        touch-action: pan-x pinch-zoom;
    }

    .lightbox-mobile-carousel::-webkit-scrollbar {
        display: none;
    }

    .lightbox-mobile-carousel__image {
        flex: 0 0 100%;
        width: 100vw;
        min-width: 100vw;
        max-height: 100dvh;
        scroll-snap-align: center;
        scroll-snap-stop: always;
        object-fit: contain;
        user-select: none;
    }

    .lightbox-hit-area {
        display: none;
    }
}
