/* CSS Reset и базовые стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}


:root {
    /* Фиолетово-чёрная палитра */
    --bg-primary: #08060e;
    --bg-secondary: #130714;
    --bg-surface: #1a081f;
    --bg-card: #240e2a;
    --bg-hover: #2e1238;
    --text-primary: #ffffff;
    --text-secondary: #9f8ba6;
    --text-tertiary: #695a6f;
    --border-color: #35163e;
    --accent-primary: #4a6fff;
    --accent-secondary: #7b61ff;
    --accent-gradient: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    --success: #00d68f;
    --warning: #ffaa00;
    --danger: #ff3d71;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.6);
    --radius-sm: 10px;
    --radius-md: 14px;
    --radius-lg: 18px;
    --radius-full: 999px;
    --transition: all 0.2s ease;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background:
        radial-gradient(ellipse 120% 60% at 50% -10%, rgba(55, 7, 65, 0.85) 0%, transparent 55%),
        radial-gradient(ellipse 80% 50% at 80% 100%, rgba(55, 7, 65, 0.45) 0%, transparent 50%),
        linear-gradient(180deg, #370741 0%, #16071c 35%, #08060e 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.4;
    font-weight: 400;
    overflow-x: hidden;
    min-height: 100vh;
    padding-bottom: calc(60px + env(safe-area-inset-bottom));
    padding-top: env(safe-area-inset-top);
    font-size: 14px;
}

/* Компактные контейнеры */
.container {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    padding: 0 12px;
}

@media (min-width: 1024px) {
    .container {
        max-width: 1200px;
        padding: 0 24px;
    }
}

.section { 
    padding: 16px 0; 
}

@media (min-width: 1024px) {
    .section {
        padding: 24px 0;
        max-width: 1200px;
        margin: 0 auto;
    }
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding: 0 4px;
}

@media (min-width: 1024px) {
    .section-header {
        padding: 0 24px;
        margin-bottom: 20px;
    }
}

.section-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 16px;
    padding: 8px 0;
}

.pagination-btn {
    min-width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.pagination-btn:hover {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

.pagination-btn.active {
    background: var(--accent-gradient);
    border-color: var(--accent-primary);
    color: white;
}

.section-link {
    font-size: 13px;
    font-weight: 600;
    color: var(--accent-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Компактная шапка */
.main-header {
    position: fixed;
    top: env(safe-area-inset-top);
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    padding: 8px 0;
    height: 56px;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 40px;
    padding: 0 12px;
}

.logo {
    font-size: 17px;
    font-weight: 600;
    letter-spacing: 0.03em;
    color: var(--text-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-icon {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.logo-icon:has(> img) {
    background: transparent;
    border-radius: 0;
}

.logo-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 0;
    display: block;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-btn {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    background: var(--bg-surface);
    border: none;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    position: relative;
    transition: var(--transition);
    text-decoration: none;
}

.header-btn:hover { background: var(--bg-hover); }

.header-login-btn {
    width: auto;
    padding: 0 12px;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
}

.header-login-btn i {
    font-size: 14px;
}

/* Компактные CTA: клиенты (светло-зелёная окантовка) / бизнес (светло-оранжевая) */
.header-audience-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    height: 32px;
    padding: 0 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 650;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.04);
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    flex-shrink: 0;
}

.header-audience-cta i {
    font-size: 12px;
    opacity: 0.95;
}

.header-audience-cta--clients {
    color: #b9f5d8;
    border-color: rgba(134, 239, 172, 0.55);
    box-shadow: 0 0 0 1px rgba(134, 239, 172, 0.12) inset;
}

.header-audience-cta--clients:hover {
    background: rgba(134, 239, 172, 0.12);
    border-color: rgba(167, 243, 208, 0.75);
    color: #d8ffe9;
}

.header-audience-cta--business {
    color: #ffd4b0;
    border-color: rgba(253, 186, 116, 0.6);
    box-shadow: 0 0 0 1px rgba(253, 186, 116, 0.12) inset;
}

.header-audience-cta--business:hover {
    background: rgba(253, 186, 116, 0.14);
    border-color: rgba(251, 191, 36, 0.75);
    color: #ffe8d4;
}

.header-audience-cta__short {
    display: inline;
}

.header-audience-cta__full {
    display: none;
}

@media (min-width: 480px) {
    .header-audience-cta {
        padding: 0 11px;
        font-size: 12px;
    }

    .header-audience-cta__short {
        display: none;
    }

    .header-audience-cta__full {
        display: inline;
    }
}

@media (max-width: 360px) {
    .header-audience-cta {
        padding: 0 7px;
        gap: 4px;
    }
}

@media (max-width: 374px) {
    .header-audience-cta {
        width: 32px;
        height: 32px;
        padding: 0;
        gap: 0;
    }

    .header-audience-cta__short,
    .header-audience-cta__full {
        display: none;
    }
}

/* Блок CTA в hero и под поиском */
.home-hero-audience {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.home-hero-audience--below-search {
    padding: 0 12px 10px;
    margin-top: -2px;
}

.home-hero-audience-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 650;
    text-decoration: none;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.05);
    transition: background 0.15s ease, border-color 0.15s ease;
}

.home-hero-audience-btn i {
    font-size: 13px;
    opacity: 0.95;
}

.home-hero-audience-btn--clients {
    color: #c6f7df;
    border-color: rgba(134, 239, 172, 0.55);
}

.home-hero-audience-btn--clients:hover {
    background: rgba(134, 239, 172, 0.12);
    border-color: rgba(167, 243, 208, 0.85);
}

.home-hero-audience-btn--business {
    color: #ffdcc4;
    border-color: rgba(253, 186, 116, 0.62);
}

.home-hero-audience-btn--business:hover {
    background: rgba(253, 186, 116, 0.14);
    border-color: rgba(251, 191, 36, 0.85);
}

@media (min-width: 1024px) {
    .home-hero-audience-btn {
        padding: 8px 14px;
        font-size: 13px;
    }
}

.notification-badge {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--danger);
    border: 2px solid var(--bg-surface);
    box-shadow: 0 0 0 0 rgba(255, 61, 113, 0.7);
    animation: notification-pulse 1.4s infinite;
}

@keyframes notification-pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 61, 113, 0.7);
    }
    70% {
        transform: scale(1.25);
        box-shadow: 0 0 0 8px rgba(255, 61, 113, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 61, 113, 0);
    }
}

/* Компактный поиск */
.search-section {
    margin-top: calc(56px + env(safe-area-inset-top));
    padding: 12px 12px 8px;
}

.home-hero + .search-section {
    margin-top: 0;
}

.home-hero {
    margin-top: calc(56px + env(safe-area-inset-top));
    padding: 12px;
}

.home-hero-inner {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.08);
    background:
        radial-gradient(700px 260px at 15% 15%, rgba(55, 7, 65, 0.55) 0%, rgba(55, 7, 65, 0.00) 60%),
        radial-gradient(540px 240px at 85% 0%, rgba(104, 34, 121, 0.30) 0%, rgba(104, 34, 121, 0.00) 55%),
        linear-gradient(135deg, rgba(36, 8, 45, 1) 0%, rgba(18, 6, 24, 1) 100%);
    box-shadow: var(--shadow-md);
    padding: 14px 14px 12px;
}

.home-hero-inner {
    max-width: 480px;
    margin: 0 auto;
}

.home-hero-left {
    min-width: 0;
}

.home-hero-right {
    display: none;
}

@media (min-width: 768px) {
    .home-hero {
        max-width: 1200px;
        margin-left: auto;
        margin-right: auto;
    }
    .home-hero-inner {
        max-width: 1200px;
        padding: 16px 18px 14px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 20px;
    }
    .home-hero-right {
        display: flex;
        justify-content: flex-end;
        flex: 0 0 42%;
        min-width: 280px;
        max-width: 480px;
    }
    .home-hero-visual {
        width: 100%;
        border-radius: 18px;
        overflow: hidden;
        position: relative;
        min-height: 200px;
        max-height: 320px;
        background: rgba(0, 0, 0, 0.12);
        box-shadow: 0 16px 48px rgba(0, 0, 0, 0.22);
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .home-hero-visual img {
        width: 100%;
        height: auto;
        max-height: 320px;
        object-fit: contain;
        object-position: center center;
        display: block;
    }
}

@media (min-width: 1024px) {
    .home-hero {
        max-width: 1280px;
        margin: calc(56px + env(safe-area-inset-top)) auto 0;
        padding: 20px 28px 10px;
    }
    .home-hero-inner {
        max-width: 1280px;
        padding: 22px 24px 20px;
        gap: 32px;
    }
    .home-hero-right {
        flex: 0 0 520px;
        max-width: 520px;
    }
    .home-hero-visual {
        min-height: 280px;
        max-height: 420px;
        border-radius: 22px;
        box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
        transform: translateZ(0);
        transition: transform 0.25s ease, box-shadow 0.25s ease;
    }
    .home-hero-visual img {
        max-height: 420px;
    }
    .home-hero-visual::after {
        content: '';
        position: absolute;
        inset: -2px;
        background: radial-gradient(circle at 30% 20%, rgba(74, 111, 255, 0.65), rgba(74, 111, 255, 0) 55%);
        opacity: 0;
        transition: opacity 0.25s ease;
        pointer-events: none;
    }
    .home-hero-visual:hover {
        transform: translateY(-2px);
        box-shadow: 0 0 0 2px rgba(74, 111, 255, 0.35), 0 0 40px rgba(74, 111, 255, 0.55);
    }
    .home-hero-visual:hover::after {
        opacity: 1;
    }
    .home-hero-title {
        font-size: 26px;
        letter-spacing: -0.03em;
    }
    .home-hero-subtitle {
        font-size: 14px;
        max-width: 70ch;
    }
    .home-hero-controls {
        grid-template-columns: 1fr 1fr auto;
        justify-content: start;
    }
    .home-hero-controls .home-hero-btn {
        grid-column: auto;
        justify-self: auto;
        min-width: 120px;
        height: 40px;
    }
}

.home-hero-inner::before {
    content: '';
    position: absolute;
    inset: -40%;
    background: linear-gradient(90deg,
        rgba(255, 255, 255, 0.00) 0%,
        rgba(255, 255, 255, 0.10) 20%,
        rgba(255, 255, 255, 0.00) 40%
    );
    transform: rotate(10deg) translateX(-40%);
    animation: hero-shine 7s ease-in-out infinite;
    pointer-events: none;
}

@keyframes hero-shine {
    0% { transform: rotate(10deg) translateX(-55%); opacity: 0.0; }
    20% { opacity: 0.35; }
    45% { transform: rotate(10deg) translateX(55%); opacity: 0.0; }
    100% { transform: rotate(10deg) translateX(55%); opacity: 0.0; }
}

.home-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.01em;
    margin-bottom: 10px;
}

.home-hero-badge i {
    color: rgba(255, 255, 255, 0.75);
}

.home-hero-badge--tatarstan {
    background: linear-gradient(135deg, rgba(0, 155, 72, 0.18), rgba(227, 6, 19, 0.12));
    border-color: rgba(0, 155, 72, 0.35);
    color: #e8fff0;
}

.home-hero-badge--tatarstan i {
    color: #3ddc84;
}

.home-hero-cities {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.home-hero-city-chip {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.home-hero-city-chip:hover,
.home-hero-city-chip.is-active {
    background: rgba(0, 155, 72, 0.15);
    border-color: rgba(0, 155, 72, 0.4);
    color: #fff;
}

.home-hero-city-chip.is-active {
    box-shadow: 0 0 0 1px rgba(0, 155, 72, 0.25);
}

.home-hero-title {
    font-size: 18px;
    line-height: 1.15;
    font-weight: 850;
    letter-spacing: -0.02em;
    margin-bottom: 8px;
}

.home-hero-title-city {
    display: inline-block;
    margin-left: 0;
    margin-top: 2px;
    background: linear-gradient(135deg, #a8b8ff 0%, #7b61ff 45%, #4a6fff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    position: relative;
    animation: hero-pop 0.55s ease both;
}

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

.home-hero-subtitle {
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.35;
    margin-bottom: 8px;
    max-width: 48ch;
}

.home-hero-lead {
    margin: 0 0 12px;
    padding: 0;
    color: rgba(255, 255, 255, 0.72);
    font-size: 12px;
    line-height: 1.45;
    max-width: 52ch;
}

.home-hero-controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    align-items: center;
}

.home-hero-controls .home-hero-btn {
    grid-column: 1 / -1;
    justify-self: start;
    width: auto;
    min-width: 128px;
}

.home-hero-select-wrap {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    height: 44px;
    padding: 0 14px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.10);
    color: var(--text-primary);
}

.home-hero-select-wrap i {
    color: rgba(255, 255, 255, 0.75);
    font-size: 14px;
}

.home-hero-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    width: 100%;
    border: none;
    outline: none;
    background: transparent;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 700;
    padding-right: 20px;
}

.home-hero-select option {
    background: #16071c;
    color: #ffffff;
}

.home-hero-select:focus-visible {
    box-shadow: 0 0 0 2px rgba(74, 111, 255, 0.22);
    border-radius: 10px;
}

.home-hero-select-caret {
    position: absolute;
    right: 14px;
    font-size: 12px;
    opacity: 0.7;
    pointer-events: none;
}

.home-hero-btn {
    height: 38px;
    padding: 0 18px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(0, 155, 72, 0.38);
    cursor: pointer;
    background: rgba(0, 155, 72, 0.08);
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    font-size: 13px;
    letter-spacing: 0.03em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    box-shadow: none;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
    white-space: nowrap;
}

.home-hero-btn i {
    font-size: 12px;
    opacity: 0.85;
    line-height: 1;
}

.home-hero-btn:hover {
    background: rgba(0, 155, 72, 0.16);
    border-color: rgba(0, 155, 72, 0.55);
    color: #ffffff;
    box-shadow: 0 0 24px rgba(0, 155, 72, 0.14);
}

.home-hero-btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 155, 72, 0.25), 0 0 20px rgba(0, 155, 72, 0.12);
}

.home-hero-btn:active {
    transform: scale(0.98);
    background: rgba(0, 155, 72, 0.22);
    filter: none;
}

.search-wrapper { position: relative; }

.search-section {
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

@media (min-width: 1024px) {
    .search-section {
        max-width: 1200px;
        padding-left: 24px;
        padding-right: 24px;
    }
    .search-wrapper {
        max-width: 760px;
        margin: 0 auto;
    }
}

.search-input {
    width: 100%;
    height: 44px;
    padding: 0 12px 0 44px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 400;
    transition: var(--transition);
}

.search-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(74, 111, 255, 0.2);
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-tertiary);
    font-size: 16px;
}

/* Компактные быстрые действия */
.quick-actions {
    display: none !important; /* Скрыто по запросу */
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    padding: 0 12px;
    margin: 12px 0 16px;
}

.quick-action {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 12px 4px;
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    text-decoration: none;
    transition: var(--transition);
}

.quick-action:active {
    background: var(--bg-hover);
    transform: translateY(-1px);
}

.action-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: white;
}

.quick-action:nth-child(2) .action-icon {
    background: linear-gradient(135deg, #ff6b6b 0%, #ff8e53 100%);
}

.quick-action:nth-child(3) .action-icon {
    background: linear-gradient(135deg, #00d68f 0%, #00b8d4 100%);
}

.quick-action:nth-child(4) .action-icon {
    background: linear-gradient(135deg, #7b61ff 0%, #aa00ff 100%);
}

.action-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.2;
}

/* Компактные категории */
.categories-carousel {
    padding: 0 12px;
    position: relative;
}

@media (min-width: 1024px) {
    .categories-carousel {
        padding: 0 24px;
        max-width: 1200px;
        margin: 0 auto;
    }
}

.categories-scroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 4px 0 16px;
}

@media (min-width: 1024px) {
    .categories-scroll {
        gap: 16px;
        flex-wrap: wrap;
        overflow-x: visible;
        justify-content: flex-start;
    }
}

.categories-scroll::-webkit-scrollbar { display: none; }

.category-wrapper {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100px;
}

.category-item {
    width: 100px;
    height: 100px;
    border-radius: var(--radius-md);
    background: var(--bg-surface);
    position: relative;
    overflow: hidden;
    text-decoration: none;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    display: block;
}

.category-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.category-item.active {
    border: 2px solid var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(74, 111, 255, 0.3), var(--shadow-md);
    transform: translateY(-2px) scale(1.02);
}

.category-item.active .category-image {
    opacity: 1;
}

.category-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.85;
    transition: opacity 0.2s;
}

.category-item:hover .category-image {
    opacity: 1;
}

.category-icon-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #4a6fff 0%, #7b61ff 100%);
    color: white;
    font-size: 32px;
}

.category-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    width: 100%;
    text-align: center;
}

.category-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
    margin: 0;
}

.category-count {
    font-size: 10px;
    color: var(--text-secondary);
    line-height: 1.2;
}

/* Улучшенный рекламный блок - компактный */
.ad-carousel-wrapper {
    margin: 12px;
    position: relative;
}

.ad-carousel {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 12px;
    scroll-behavior: smooth;
}

.ad-carousel::-webkit-scrollbar {
    display: none;
}

.ad-banner {
    flex: 0 0 calc(100% - 0px);
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    height: 140px;
    border: 1px solid var(--border-color);
    scroll-snap-align: start;
}

@media (min-width: 1024px) {
    .ad-carousel-wrapper {
        margin: 16px auto;
        max-width: 1200px;
        padding: 0 24px;
    }
    
    .ad-carousel {
        gap: 16px;
        overflow-x: visible;
        flex-wrap: wrap;
        justify-content: flex-start;
    }
    
    .ad-banner {
        flex: 0 0 calc(50% - 8px);
        min-width: calc(50% - 8px);
        max-width: calc(50% - 8px);
        height: 160px;
    }
    
    .ad-carousel-dots {
        display: none;
    }
}

.ad-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ad-content {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 16px;
    background: linear-gradient(90deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.3) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.ad-badge {
    display: inline-block;
    background: var(--danger);
    color: white;
    padding: 3px 8px;
    border-radius: var(--radius-full);
    font-size: 10px;
    font-weight: 700;
    margin-bottom: 6px;
    align-self: flex-start;
}

.ad-title {
    font-size: 16px;
    font-weight: 700;
    color: white;
    margin-bottom: 4px;
    line-height: 1.2;
}

.ad-text {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 10px;
    line-height: 1.3;
}

.ad-button {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: white;
    color: var(--bg-primary);
    padding: 6px 12px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 700;
    text-decoration: none;
    align-self: flex-start;
    transition: var(--transition);
}

.ad-button:hover { transform: translateX(2px); }

/* Индикаторы карусели */
.ad-carousel-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 12px;
    padding: 0 12px;
}

.ad-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--text-tertiary);
    cursor: pointer;
    transition: var(--transition);
}

.ad-dot.active {
    background: var(--accent-primary);
    width: 20px;
    border-radius: var(--radius-full);
}

/* Компактная карусель популярного */
.popular-carousel { 
    padding: 0 12px; 
}

@media (min-width: 1024px) {
    .popular-carousel {
        padding: 0 24px;
        max-width: 1200px;
        margin: 0 auto;
    }
}

.popular-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 4px 0 12px;
}

.popular-scroll::-webkit-scrollbar { display: none; }

.popular-card {
    flex: 0 0 auto;
    width: 240px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

@media (min-width: 1024px) {
    .popular-scroll {
        gap: 16px;
        flex-wrap: wrap;
        overflow-x: visible;
        justify-content: flex-start;
    }
    
    .popular-card {
        width: calc(25% - 12px);
        min-width: 260px;
        flex: 0 0 calc(25% - 12px);
    }
}

@media (min-width: 1440px) {
    .popular-card {
        width: calc(25% - 12px);
        flex: 0 0 calc(25% - 12px);
    }
}

.popular-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent-primary);
}

.popular-image {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.popular-content { padding: 12px; }

.popular-master {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

.popular-master-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 14px;
    flex-shrink: 0;
    overflow: hidden;
    border: 2px solid var(--accent-primary);
}

.master-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.master-avatar-initials {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.popular-master-info {
    flex: 1;
    min-width: 0;
}

.popular-master-name-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 2px;
    min-width: 0;
}
.popular-master-name {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.popular-master-name-row .master-badge { flex-shrink: 0; }

.popular-master-specialty {
    font-size: 11px;
    color: var(--text-secondary);
    line-height: 1.2;
    margin-bottom: 2px;
}

.popular-master-rating {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 10px;
    color: var(--warning);
    font-weight: 600;
}

.popular-master-rating i {
    font-size: 9px;
}

.popular-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
    gap: 8px;
}

.popular-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.3;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.popular-title-name {
    display: block;
}

.popular-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

@media (max-width: 768px) {
    .popular-badges {
        flex-wrap: nowrap;
        white-space: nowrap;
    }
}

.popular-discount-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: 700;
    color: #ecfff3;
    background: rgba(0, 214, 143, 0.45);
    border: 1px solid rgba(0, 214, 143, 0.8);
    border-radius: 8px;
}

.popular-promo-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: 700;
    border-radius: 8px;
}

.popular-promo-badge.highlight {
    color: #ecfff3;
    background: rgba(0, 214, 143, 0.45);
    border: 1px solid rgba(0, 214, 143, 0.8);
}

.popular-promo-badge.vip {
    color: #fff6e5;
    background: rgba(255, 170, 0, 0.5);
    border: 1px solid rgba(255, 170, 0, 0.85);
}

.popular-price {
    font-size: 16px;
    font-weight: 700;
    color: var(--accent-primary);
    margin-left: 8px;
    white-space: nowrap;
}

.popular-price-old {
    margin-left: 6px;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-decoration: line-through;
}

@media (max-width: 768px) {
    .popular-price {
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        gap: 2px;
        white-space: normal;
    }

    .popular-price-old {
        margin-left: 0;
    }
}

.popular-price-new {
    color: var(--success);
    font-weight: 800;
    white-space: nowrap;
}

.popular-card.is-promo-highlight {
    border-color: rgba(134, 239, 172, 0.6);
    box-shadow: 0 0 0 1px rgba(134, 239, 172, 0.35);
}

.popular-card.is-promo-vip {
    border-color: rgba(255, 193, 7, 0.7);
    box-shadow: 0 0 0 1px rgba(255, 193, 7, 0.4);
}

.popular-info {
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.popular-location {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--text-tertiary);
}

.popular-rating {
    display: flex;
    align-items: center;
    gap: 2px;
    color: var(--warning);
    font-weight: 600;
}

.popular-actions {
    display: flex;
    gap: 6px;
}

.btn {
    flex: 1;
    height: 32px;
    border-radius: var(--radius-sm);
    border: none;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--accent-gradient);
    color: white;
}

.btn-primary:active { transform: scale(0.98); }

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    width: 32px;
    flex: 0 0 auto;
}

/* Улучшенные спецпредложения - компактные */
.specials-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 0 12px;
}

.special-card {
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.special-image {
    width: 100%;
    height: 90px;
    object-fit: cover;
}

.special-content { padding: 10px; }

.special-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
    height: 34px;
}

.special-price-container {
    display: flex;
    align-items: baseline;
    gap: 4px;
    margin-bottom: 4px;
}

.special-price {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
}

.special-old-price {
    font-size: 11px;
    color: var(--text-tertiary);
    text-decoration: line-through;
}

.special-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

.special-discount {
    background: linear-gradient(135deg, #ff3d71 0%, #ff6b6b 100%);
    color: white;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-size: 10px;
    font-weight: 700;
}

.special-btn {
    background: var(--accent-primary);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.special-btn:active { transform: scale(0.95); }

/* Блок рекомендованных салонов */
.recommended-section {
    padding: 12px;
    margin: 12px 0;
    background: var(--bg-surface);
    border-radius: var(--radius-md);
}

.recommended-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 12px;
}

@media (min-width: 1024px) {
    .recommended-section {
        max-width: 1200px;
        margin: 24px auto;
        padding: 24px;
    }
    
    .recommended-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 16px;
        margin-top: 16px;
    }
}

@media (min-width: 1440px) {
    .recommended-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 20px;
    }
}

.recommended-card {
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid var(--border-color);
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
    display: block;
}

.recommended-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent-primary);
}

.recommended-image-wrapper {
    position: relative;
    width: 100%;
    height: 120px;
    overflow: hidden;
}

.recommended-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.recommended-card:hover .recommended-image {
    transform: scale(1.05);
}

.recommended-card.is-promo-highlight {
    border-color: rgba(134, 239, 172, 0.6);
    background: rgba(134, 239, 172, 0.08);
}

.recommended-card.is-promo-pin {
    border-color: rgba(167, 139, 250, 0.6);
    background: rgba(167, 139, 250, 0.08);
}

.recommended-card.is-promo-boost {
    border-color: rgba(59, 130, 246, 0.5);
}

.recommended-promo-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 4px 8px;
    border-radius: var(--radius-full);
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
}

.recommended-card.is-promo-highlight .recommended-promo-badge {
    background: rgba(255, 170, 0, 0.2);
    color: #ffb545;
    border: 1px solid rgba(255, 170, 0, 0.5);
}

.recommended-rating-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    color: var(--warning);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
}

.recommended-content { 
    padding: 12px; 
}

.recommended-master {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.recommended-master-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--bg-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    font-weight: 700;
    font-size: 12px;
    flex-shrink: 0;
}

.recommended-master-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.recommended-master-placeholder {
    line-height: 1;
}

.recommended-master-name-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    min-width: 0;
}
.recommended-master-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.recommended-master-name-row .master-badge { flex-shrink: 0; }

/* Бейджи мастеров: PRO (10+ заказов), галочка (20+ заказов) */
.master-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 2px 5px;
    border-radius: 3px;
    line-height: 1.2;
}
.master-badge-pro {
    background: linear-gradient(135deg, #8b5cf6 0%, #6366f1 100%);
    color: #fff;
}
.master-badge-verified {
    background: transparent;
    color: #22c55e;
    padding: 0 2px;
    font-size: 12px;
}
.master-badge-verified i { font-size: 1em; }

.recommended-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

@media (min-width: 1024px) {
    .recommended-master-avatar {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }
}

.recommended-specialty {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.recommended-location {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.recommended-location i {
    font-size: 11px;
    color: var(--accent-primary);
}

.recommended-address {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.recommended-address i {
    font-size: 11px;
    color: var(--accent-primary);
}

.recommended-reviews {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: var(--text-tertiary);
}

.recommended-reviews i {
    font-size: 10px;
}

/* Быстрая запись - компактная */
.quick-booking {
    padding: 12px;
    margin: 12px 0;
    background: var(--bg-surface);
    border-radius: var(--radius-md);
}

.quick-booking-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.booking-steps {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.booking-step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 12px 8px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
}

.step-number {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--accent-gradient);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

.step-text {
    font-size: 11px;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.2;
}

.booking-form {
    display: flex;
    gap: 8px;
}

.form-select {
    flex: 1;
    height: 36px;
    padding: 0 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.form-select:focus {
    outline: none;
    border-color: var(--accent-primary);
}

/* Мобильное меню и нижняя навигация теперь в mobile-nav.css */

/* Анимации */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in { animation: fadeIn 0.3s ease forwards; }

/* Адаптивность для экранов 360px */
@media (max-width: 360px) {
    .container { padding: 0 8px; }

    .section-header, .search-section, .quick-actions,
    .categories-carousel, .popular-carousel, .specials-grid,
    .recommended-section, .quick-booking {
        padding-left: 8px;
        padding-right: 8px;
    }

    .ad-banner {
        height: 130px;
    }

    .quick-actions { grid-template-columns: repeat(2, 1fr); }
    .specials-grid, .recommended-grid { grid-template-columns: 1fr; gap: 8px; }
    .popular-card { width: 200px; }
    .category-item { width: 90px; height: 90px; }
    .ad-title { font-size: 14px; }
    .ad-text { font-size: 11px; margin-bottom: 8px; }
    .ad-button { padding: 5px 10px; font-size: 10px; }
    .special-title { font-size: 12px; height: 32px; }
    .special-image { height: 80px; }
    .booking-steps { flex-direction: column; gap: 6px; }
    .booking-form { flex-direction: column; }
}

@media (max-width: 768px) {
    .section-categories {
        padding-bottom: 8px;
    }

    .section-categories + .ad-carousel-wrapper {
        margin-top: 6px;
    }

    .ad-carousel-wrapper {
        margin: 8px 8px 12px;
    }
}

@media (max-width: 360px) {
    .ad-carousel-wrapper {
        margin: 6px 6px 10px;
    }
}

@media (min-width: 768px) {
    .models-carousel {
        gap: 16px;
    }
    
    .model-card-compact {
        min-width: 300px;
        max-width: 350px;
        padding: 16px;
    }
    
    .model-card-compact .model-avatar {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .model-card-compact .model-master-name {
        font-size: 13px;
    }
    
    .model-card-compact .model-title {
        font-size: 15px;
    }
}

@media (min-width: 1024px) {
    .models-carousel {
        gap: 20px;
    }
    
    .model-card-compact {
        min-width: 320px;
        max-width: 380px;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .container { max-width: 480px; }
    .specials-grid, .recommended-grid { grid-template-columns: repeat(2, 1fr); }
    
    .models-carousel {
        gap: 16px;
    }
    
    .model-card-compact {
        min-width: 300px;
        max-width: 350px;
        padding: 16px;
    }
    
    .model-card-compact .model-avatar {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .model-card-compact .model-master-name {
        font-size: 13px;
    }
    
    .model-card-compact .model-title {
        font-size: 15px;
    }
}

@media (min-width: 1024px) {
    .models-carousel {
        gap: 20px;
    }
    
    .model-card-compact {
        min-width: 320px;
        max-width: 380px;
    }
}

/* Дополнительные компактные стили */
.compact-text { font-size: 12px !important; }
.compact-btn { padding: 6px 12px !important; height: 30px !important; font-size: 11px !important; }
.compact-card { padding: 10px !important; }

/* Индикатор загрузки */
.loading-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* Поиск моделей */
.models-section {
    padding: 20px 0;
}

@media (min-width: 1024px) {
    .models-section {
        max-width: 1200px;
        margin: 0 auto;
        padding: 24px 0;
    }
}

.models-carousel-wrapper {
    padding: 0 12px;
}

@media (min-width: 1024px) {
    .models-carousel-wrapper {
        padding: 0 24px;
    }
}

.models-carousel {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 4px 0 12px;
    scroll-behavior: smooth;
}

@media (min-width: 1024px) {
    .models-carousel {
        gap: 16px;
        flex-wrap: wrap;
        overflow-x: visible;
        justify-content: flex-start;
    }
}

.models-carousel::-webkit-scrollbar {
    display: none;
}

.model-card-compact {
    flex: 0 0 calc(100% - 0px);
    min-width: 280px;
    max-width: 320px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    gap: 10px;
    scroll-snap-align: start;
}

.model-card-compact:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent-primary);
}

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

.model-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 170, 0, 0.4);
    border-radius: var(--radius-md);
    padding: 14px;
    box-shadow: var(--shadow-sm);
}

.model-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.model-master {
    display: flex;
    align-items: center;
    gap: 10px;
}

.model-avatar {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    overflow: hidden;
    background: #fff4e5;
    color: #ff9800;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}

.model-card-compact .model-avatar {
    width: 36px;
    height: 36px;
    font-size: 12px;
}

.model-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.model-master-name {
    font-size: 14px;
    font-weight: 700;
}

.model-card-compact .model-master-name {
    font-size: 12px;
}

.model-master-sub {
    font-size: 12px;
    color: var(--text-secondary);
}

.model-card-compact .model-master-sub {
    font-size: 10px;
}

.model-date {
    font-size: 12px;
    color: #ff9800;
    font-weight: 600;
    text-align: right;
}

.model-title {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 6px;
}

.model-card-compact .model-title {
    font-size: 14px;
}

.model-title-row-compact {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.model-title-row-compact .model-title {
    flex: 1;
    min-width: 0;
    margin-bottom: 0;
}

.model-price-badge-compact {
    flex-shrink: 0;
}

.price-free-compact {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background: linear-gradient(135deg, rgba(0, 214, 143, 0.15), rgba(0, 184, 212, 0.15));
    border: 1px solid rgba(0, 214, 143, 0.4);
    border-radius: var(--radius-full);
    color: #00d68f;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}

.price-free-compact i {
    font-size: 10px;
}

.price-amount-compact {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background: linear-gradient(135deg, rgba(74, 111, 255, 0.15), rgba(123, 97, 255, 0.15));
    border: 1px solid rgba(74, 111, 255, 0.4);
    border-radius: var(--radius-full);
    color: var(--accent-primary);
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}

.price-amount-compact i {
    font-size: 10px;
}

.model-description {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.model-card-compact .model-description {
    font-size: 11px;
    -webkit-line-clamp: 2;
}

.model-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    font-size: 12px;
    color: var(--text-tertiary);
    margin-bottom: 10px;
}

.model-meta i {
    margin-right: 6px;
    color: #ff9800;
}

.model-meta-compact {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.model-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    background: var(--bg-surface);
    border-radius: var(--radius-sm);
    font-size: 11px;
}

.model-meta-item i {
    font-size: 10px;
    color: var(--accent-primary);
    opacity: 0.8;
    flex-shrink: 0;
}

.model-meta-item span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.model-apply-btn {
    width: 100%;
    border: none;
    border-radius: 12px;
    padding: 10px 12px;
    background: linear-gradient(135deg, #ffb347 0%, #ff9800 100%);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: auto;
}

.model-apply-btn i {
    font-size: 12px;
}

.model-apply-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(255, 152, 0, 0.3);
}

@media (max-width: 480px) {
    .model-card-compact {
        min-width: 260px;
        max-width: 300px;
        padding: 12px;
        gap: 8px;
    }
    
    .model-card-compact .model-avatar {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }
    
    .model-card-compact .model-master-name {
        font-size: 11px;
    }
    
    .model-card-compact .model-master-sub {
        font-size: 9px;
    }
    
    .model-title-row-compact .model-title {
        font-size: 13px;
    }
    
    .price-free-compact,
    .price-amount-compact {
        padding: 3px 6px;
        font-size: 10px;
    }
    
    .model-meta-compact {
        gap: 4px;
    }
    
    .model-meta-item {
        padding: 3px 6px;
        font-size: 10px;
    }
    
    .model-apply-btn {
        padding: 8px 10px;
        font-size: 12px;
    }
}

@media (max-width: 360px) {
    .model-card-compact {
        min-width: 240px;
        max-width: 280px;
        padding: 10px;
        gap: 6px;
    }
    
    .model-apply-btn span {
        display: none;
    }
    
    .model-apply-btn {
        padding: 10px;
    }
    
    .model-title-row-compact {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    
    .price-free-compact,
    .price-amount-compact {
        padding: 3px 6px;
        font-size: 10px;
    }
    
    .model-meta-compact {
        gap: 4px;
    }
    
    .model-meta-item {
        padding: 3px 6px;
        font-size: 10px;
    }
    
    .model-meta-item span {
        max-width: 120px;
    }
}

.model-empty {
    background: var(--bg-card);
    border: 1px dashed rgba(255, 170, 0, 0.4);
    border-radius: var(--radius-md);
    padding: 16px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 13px;
}

/* Модальное окно отклика на модель */
.model-apply-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(5, 5, 10, 0.6);
    z-index: 3000;
    padding: 16px;
}

.model-apply-modal.active {
    display: flex;
}

.model-apply-card {
    width: 100%;
    max-width: 420px;
    background: var(--bg-card);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 18px;
    box-shadow: var(--shadow-lg);
}

.model-apply-card .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.model-apply-card .modal-title {
    font-size: 16px;
    font-weight: 700;
}

.model-apply-card .modal-close {
    border: none;
    background: var(--bg-surface);
    color: var(--text-primary);
    width: 32px;
    height: 32px;
    border-radius: 10px;
    cursor: pointer;
}

.model-apply-card .form-group {
    margin-bottom: 12px;
}

.model-apply-card .form-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
    display: block;
}

.model-apply-card .form-input,
.model-apply-card .form-textarea {
    width: 100%;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: var(--bg-surface);
    color: var(--text-primary);
    font-size: 14px;
}

.model-apply-card .form-textarea {
    resize: vertical;
}

.model-apply-card .form-actions {
    margin-top: 10px;
}

.model-apply-card .btn-primary {
    width: 100%;
    padding: 10px 12px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, #ffb347 0%, #ff9800 100%);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.model-apply-card .form-hint {
    margin-top: 10px;
    font-size: 12px;
    color: var(--text-tertiary);
    text-align: center;
}

@media (max-width: 480px) {
    .models-grid {
        grid-template-columns: 1fr;
    }
}


