/* Jobs Page Styles */

/* Предотвращение горизонтальной прокрутки на мобильных */
@media (max-width: 768px) {
    body {
        overflow-x: hidden;
    }

    .container {
        max-width: 100%;
        overflow-x: hidden;
    }

    /* Убираем padding у container внутри hero секции */
    .jobs-hero-section .container {
        padding-left: 15px;
        padding-right: 15px;
        max-width: 100%;
    }

    .row {
        margin-left: 0;
        margin-right: 0;
    }

    [class*="col-"] {
        padding-left: 8px;
        padding-right: 8px;
    }
}

/* ===== HERO SECTION - Modern Gradient ===== */
.jobs-hero-section {
    position: relative;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 25%, #f093fb 50%, #4facfe 75%, #00f2fe 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    padding: 40px 0 100px;
    margin: 0 -15px 40px -15px;
    overflow: hidden;
    border-radius: 0 0 30px 30px;
    box-sizing: border-box;
}

/* Breathing space between hero and search bar */
.jobs-hero-section + .jobs-toolbar {
    margin-top: 12px;
}


@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.hero-waves {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 150px;
    overflow: hidden;
}

.waves-svg {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.15;
}

.hero-icons {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0.07;
}

.hero-icon {
    position: absolute;
    font-size: 80px;
    color: white;
    animation: float 6s ease-in-out infinite;
}

.hero-icon-1 {
    top: 10%;
    left: 5%;
    animation-delay: 0s;
}

.hero-icon-2 {
    top: 20%;
    right: 10%;
    animation-delay: 1.5s;
}

.hero-icon-3 {
    bottom: 20%;
    left: 15%;
    animation-delay: 3s;
}

.hero-icon-4 {
    bottom: 15%;
    right: 5%;
    animation-delay: 4.5s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

.hero-content {
    position: relative;
    z-index: 10;
    text-align: center;
    color: white;
    max-width: 900px;
    margin: 0 auto;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
    letter-spacing: -0.5px;
}

.hero-subtitle {
    font-size: 20px;
    font-weight: 400;
    margin-top: 10px;
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.15);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.btn-hero {
    padding: 14px 32px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 12px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    border: 2px solid transparent;
}

.btn-hero-primary {
    background: #8b5cf6;
    color: white;
    border-color: #8b5cf6;
}

.btn-hero-primary:hover {
    background: #7c3aed;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.4);
    color: white;
}

.btn-hero-secondary {
    background: #3b82f6;
    color: white;
    border-color: #3b82f6;
}

.btn-hero-secondary:hover {
    background: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
    color: white;
}

.btn-hero-outline {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
}

.btn-hero-outline:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.2);
    color: white;
}

.btn-hero-admin {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.btn-hero-admin:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.15);
    color: white;
}

/* Responsive Hero */
@media (max-width: 768px) {
    .jobs-hero-section {
        padding: 30px 0 80px;
        margin: 0 -15px 30px -15px;
        border-radius: 0;
        width: calc(100% + 30px);
        position: relative;
        left: -15px;
        right: -15px;
    }

    .hero-content {
        padding: 0 5px;
    }

    .hero-title {
        font-size: 2rem;
        margin-bottom: 1rem;
        padding: 0 5px;
        word-wrap: break-word;
    }

    .hero-subtitle {
        font-size: 1.1rem;
        margin-bottom: 2rem;
        padding: 0 5px;
        word-wrap: break-word;
    }

    .hero-buttons {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.5rem;
        padding: 0 5px;
    }

    .btn-hero {
        flex: 1 1 auto;
        min-width: calc(50% - 0.25rem);
        justify-content: center;
        padding: 12px 16px;
        font-size: 0.95rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .hero-icon {
        font-size: 50px;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 1.75rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn-hero {
        width: 100%;
        padding: 12px 24px;
        font-size: 1rem;
    }

    /* Улучшение для Firefox на мобильных */
    @-moz-document url-prefix() {
        .jobs-hero-section {
            -webkit-transform: translateZ(0);
            transform: translateZ(0);
        }

        .mobile-cta-fixed {
            -webkit-transform: translateZ(0);
            transform: translateZ(0);
        }
    }
}

/* ===== PERFECT ALIGN: Jobs toolbar ===== */
.jobs-toolbar {
    --jt-h: 44px;
    /* общая высота контролов */
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin: 12px 0 24px;
}

/* каждый элемент ведёт себя как control одинаковой высоты */
.jobs-toolbar>* {
    align-self: stretch;
}

/* поиск тянется, селекты/кнопка — компактные */
.jobs-toolbar .toolbar-search {
    flex: 1 1 520px;
    min-width: 260px;
}

.jobs-toolbar .toolbar-select {
    flex: 0 0 180px;
}

.jobs-toolbar .btn-apply {
    flex: 0 0 auto;
}

/* единый размер шрифта, убираем "скачок" линии */
.jobs-toolbar .form-control,
.jobs-toolbar .form-select,
.jobs-toolbar .btn {
    font-size: 0.95rem;
    line-height: 1.25;
    /* одинаковая базовая линия текста */
    margin: 0;
    /* на случай, если где-то есть margin */
}

/* === input-group: делаем ровный блок без двойных бордеров */
.jobs-toolbar .toolbar-search .input-group {
    display: flex;
    align-items: stretch;
    height: var(--jt-h);
}

.jobs-toolbar .input-group>.input-group-text,
.jobs-toolbar .input-group>.form-control,
.jobs-toolbar .input-group>.btn {
    height: var(--jt-h);
    padding-top: 10px;
    padding-bottom: 10px;
    /* одинаковая "внутрянка" */
}

.jobs-toolbar .input-group>.input-group-text {
    border-right: 0;
}

.jobs-toolbar .input-group>.form-control {
    border-left: 0;
    border-right: 0;
}

.jobs-toolbar .input-group>.btn-clear {
    border-left: 0;
    display: none;
    /* включаем скриптом */
    align-items: center;
    justify-content: center;
}

/* скругления — одинаковые */
.jobs-toolbar .input-group .input-group-text {
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
}

.jobs-toolbar .input-group .btn-clear {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

.jobs-toolbar .form-select,
.jobs-toolbar .btn-apply {
    border-radius: 12px;
}

/* === селекты: у Bootstrap высота считается через em — задаём жёстко */
.jobs-toolbar .form-select {
    height: var(--jt-h);
    min-height: var(--jt-h);
    padding-top: 10px;
    padding-bottom: 10px;
    background-position: right .75rem center;
    background-size: 16px 12px;
}

/* === кнопка Apply: по центру и той же высоты */
.jobs-toolbar .btn-apply {
    height: var(--jt-h);
    min-height: var(--jt-h);
    padding: 0 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* адаптив */
@media (max-width: 992px) {
    .jobs-toolbar .toolbar-search {
        flex-basis: 100%;
    }

    .jobs-toolbar .toolbar-select {
        flex: 1 1 160px;
    }
}

/* Active Filter Chips */
.active-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

.chip {
    padding: 6px 12px;
    border: 1px solid #e2e6f0;
    border-radius: 999px;
    text-decoration: none;
    font-size: 0.9rem;
    color: #495057;
    background: #fff;
    transition: all 0.2s ease;
}

.chip:hover {
    background: #f8f9fa;
    border-color: #6c757d;
    color: #212529;
}

/* Header Styles */
.jobs-header {
    text-align: center;
    padding: 2rem 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px;
    margin-bottom: 2rem;
}

.jobs-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.jobs-title i {
    margin-right: 0.5rem;
    color: #ffd700;
}

.jobs-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.jobs-actions .btn {
    margin: 0.5rem;
    padding: 0.75rem 2rem;
    border-radius: 25px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Job Cards - Compact Design */
.job-card {
    display: flex;
    flex-direction: column;
    background: white;
    border: 1px solid #eef1f6;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    overflow: hidden;
    min-height: 240px;
    cursor: pointer;
    height: 100%;
    position: relative;
}

.job-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 32px rgba(102, 126, 234, 0.2);
    border-color: #c7d2fe;
}

.job-card-body {
    flex: 1 1 auto;
    padding: 14px 16px;
}

.job-card-header {
    padding-bottom: 10px;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 10px;
}

.job-card-footer {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    background: #f8f9fa;
    border-top: 1px solid #eef1f6;
}

/* Badges - Color System */
.badges {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}

.badge {
    font-size: 0.7rem;
    padding: 0.3em 0.55em;
    border-radius: 0.5rem;
    font-weight: 600;
    transition: all 0.2s ease;
    line-height: 1.2;
}

.badge:hover {
    transform: scale(1.05);
}

/* Color-coded badges */
.badge-new {
    background-color: #10b981;
    color: white;
}

.badge-top-right {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
}

/* Убраны бейджи Salary - больше не используются */
.badge-high-salary {
    display: none !important;
}

.badge-salary {
    display: none !important;
}

.badge-cadet {
    background-color: #8b5cf6;
    color: white;
}

.badge-urgent {
    background-color: #ef4444;
    color: white;
}

.badge-discount {
    background-color: #ec4899;
    color: white;
}

.badge-views {
    background-color: #6b7280;
    color: white;
    font-size: 0.65rem;
}

.bg-warning-subtle {
    background-color: #fff3cd;
}

.text-warning {
    color: #856404;
}

.bg-primary-subtle {
    background-color: #cfe2ff;
}

.text-primary {
    color: #084298;
}

.bg-success-subtle {
    background-color: #d1e7dd;
}

.text-success {
    color: #0f5132;
}

.job-title {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
    line-height: 1.3;
}

.job-title a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

.job-title a:hover {
    color: #3498db;
}

.job-company {
    color: #7f8c8d;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
}

.job-company i {
    margin-right: 0.5rem;
    color: #3498db;
}

.job-card-body {
    padding: 1rem 1.5rem;
}

.job-description {
    color: #555;
    line-height: 1.5;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
}

.job-details {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.job-detail {
    display: flex;
    align-items: center;
    font-size: 0.85rem;
    color: #7f8c8d;
    gap: 0.4rem;
}

.job-detail i {
    color: #3498db;
    width: 14px;
    flex-shrink: 0;
}

/* Новый структурированный формат как в Telegram */
.job-details-structured {
    margin-top: 1rem;
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.job-detail-line {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: #333;
    line-height: 1.5;
}

.job-detail-line:last-child {
    margin-bottom: 0;
}

.job-detail-icon {
    font-size: 1.1rem;
    line-height: 1;
    min-width: 1.5rem;
    flex-shrink: 0;
}

.job-detail-text {
    color: #555;
    word-wrap: break-word;
    flex: 1;
}

.job-card-footer {
    padding: 1rem 1.5rem;
    background: #f8f9fa;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.job-card-footer .btn {
    transition: all 0.2s ease-in-out;
    font-size: 0.9rem;
}

.job-card-footer .btn:hover {
    opacity: 0.9;
    transform: scale(1.02);
}

.job-card-footer .btn-primary {
    flex: 1;
    max-width: 50%;
}

.job-card-footer .btn-light {
    flex: 1;
    max-width: 30%;
}

.job-meta {
    font-size: 0.85rem;
}

.job-actions {
    display: flex;
    gap: 0.5rem;
}

/* Pagination */
.pagination-container {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e9ecef;
}

.pagination {
    margin-bottom: 0;
}

.pagination .page-link {
    color: #3498db;
    border: 1px solid #e9ecef;
    padding: 0.5rem 1rem;
    margin: 0 0.25rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.pagination .page-link:hover {
    color: #2c3e50;
    background-color: #f8f9fa;
    border-color: #3498db;
}

.pagination .page-item.active .page-link {
    background-color: #3498db;
    border-color: #3498db;
    color: white;
}

.pagination .page-item.disabled .page-link {
    color: #6c757d;
    background-color: #fff;
    border-color: #e9ecef;
}

.pagination-info {
    margin-top: 1rem;
}

/* No Jobs State */
.no-jobs {
    text-align: center;
    padding: 4rem 2rem;
    color: #7f8c8d;
}

.no-jobs-icon {
    font-size: 4rem;
    color: #bdc3c7;
    margin-bottom: 1rem;
}

.no-jobs h3 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

/* Create Job Page */
.create-job-header {
    text-align: center;
    padding: 2rem 0;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    border-radius: 15px;
    margin-bottom: 2rem;
}

/* AI Button in Header */
.create-job-header .btn-primary {
    background: linear-gradient(135deg, #ffffff, #f8f9fa);
    border: 2px solid #ffffff;
    color: #007bff;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.create-job-header .btn-primary:hover {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-color: #ffffff;
    color: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.create-job-header .btn-primary:focus {
    box-shadow: 0 0 0 0.2rem rgba(255, 255, 255, 0.5);
}

.create-job-header .badge {
    background: #ffc107 !important;
    color: #000 !important;
    font-weight: 600;
}

.create-job-header .text-white-50 {
    color: rgba(255, 255, 255, 0.8) !important;
}

/* Info Cards */
.info-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    height: 100%;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.info-card-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.info-card h6 {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.info-card p {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin: 0;
}

/* Create Job Sidebar */
.create-job-sidebar {
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    position: sticky;
    top: 2rem;
}

.sidebar-section {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.sidebar-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.sidebar-title i {
    margin-right: 0.5rem;
}

/* Tips List */
.tips-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.tip-item {
    display: flex;
    align-items: flex-start;
    font-size: 0.9rem;
    color: #555;
}

.tip-item i {
    margin-right: 0.75rem;
    margin-top: 0.1rem;
    flex-shrink: 0;
}

/* Support Info */
.support-info p {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.support-contacts {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.contact-item {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
}

.contact-item i {
    margin-right: 0.5rem;
    color: #3498db;
    width: 16px;
}

.contact-item a {
    color: #3498db;
    text-decoration: none;
}

.contact-item a:hover {
    text-decoration: underline;
}

.support-hours {
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

/* Status Info */
.status-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.status-item {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-item i {
    margin-right: 0.5rem;
    color: #27ae60;
}

.status-item.approved i {
    color: #27ae60;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.stat-item {
    text-align: center;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: #3498db;
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.8rem;
    color: #7f8c8d;
    font-weight: 500;
}

.create-job-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.create-job-title i {
    margin-right: 0.5rem;
    color: #ffd700;
}

.create-job-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 1rem;
}

.create-job-breadcrumb {
    font-size: 0.9rem;
    opacity: 0.8;
}

.breadcrumb-link {
    color: white;
    text-decoration: none;
}

.breadcrumb-link:hover {
    color: #ffd700;
}

.breadcrumb-separator {
    margin: 0 0.5rem;
}

.breadcrumb-current {
    color: #ffd700;
}

.create-job-form-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.create-job-form .form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
}

.form-label i {
    margin-right: 0.5rem;
    color: #3498db;
    width: 16px;
}

.form-label.required::after {
    content: " *";
    color: #e74c3c;
}

.form-control {
    border-radius: 8px;
    border: 2px solid #e9ecef;
    padding: 0.75rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 0.2rem rgba(52, 152, 219, 0.25);
}

.form-control.is-invalid {
    border-color: #e74c3c;
}

.form-text {
    font-size: 0.85rem;
    color: #6c757d;
}

.form-actions {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

.form-actions .btn {
    margin: 0.5rem;
    padding: 0.75rem 2rem;
    border-radius: 25px;
    font-weight: 600;
}

/* Job Detail Page */
.job-detail-header {
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    margin-bottom: 2rem;
}

.job-detail-title-section {
    margin-bottom: 1rem;
}

.job-detail-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.job-detail-company {
    font-size: 1.2rem;
    color: #3498db;
    display: flex;
    align-items: center;
}

.job-detail-company i {
    margin-right: 0.5rem;
}

.job-detail-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

.job-detail-date {
    color: #7f8c8d;
    font-size: 0.9rem;
}

.job-detail-date i {
    margin-right: 0.5rem;
}

.job-detail-content {
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.job-detail-section {
    margin-bottom: 2rem;
}

.job-detail-section:last-child {
    margin-bottom: 0;
}

.section-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.section-title i {
    margin-right: 0.5rem;
    color: #3498db;
}

.job-description-content,
.job-requirements-content {
    line-height: 1.8;
    color: #555;
}

.contact-info {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.contact-item {
    margin-bottom: 0.5rem;
}

.contact-item:last-child {
    margin-bottom: 0;
}

.contact-link {
    color: #3498db;
    text-decoration: none;
}

.contact-link:hover {
    text-decoration: underline;
}

.apply-instructions {
    background: #e8f5e8;
    border-left: 4px solid #27ae60;
    padding: 1rem;
    border-radius: 0 8px 8px 0;
}

.job-detail-sidebar {
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    position: sticky;
    top: 2rem;
}

.sidebar-section {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.sidebar-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.detail-item {
    margin-bottom: 1rem;
}

.detail-item:last-child {
    margin-bottom: 0;
}

.detail-label {
    font-size: 0.9rem;
    color: #7f8c8d;
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
}

.detail-label i {
    margin-right: 0.5rem;
    color: #3498db;
    width: 16px;
}

.detail-value {
    font-weight: 600;
    color: #2c3e50;
}

.share-buttons {
    display: flex;
    gap: 0.5rem;
}

.share-btn {
    transition: all 0.3s ease;
}

.posted-by-info {
    text-align: center;
}

.posted-by-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

.posted-by-date {
    font-size: 0.85rem;
    color: #7f8c8d;
}

.back-to-jobs {
    text-align: center;
    padding: 2rem 0;
}

/* Animations */
@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Ad Banners (готовые стили для будущей рекламы) */
.ad-banner {
    background: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    color: #6c757d;
    margin: 1rem 0;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ad-banner-top {
    margin-bottom: 2rem;
}

.ad-banner-middle {
    margin: 2rem 0;
}

.ad-sidebar {
    background: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    color: #6c757d;
    margin-bottom: 1rem;
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ad-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px;
    padding: 2rem;
    text-align: center;
    margin: 2rem 0;
}

/* Jobs Sidebar */
.jobs-sidebar {
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    position: sticky;
    top: 2rem;
}

.jobs-sidebar .sidebar-section {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.jobs-sidebar .sidebar-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.jobs-sidebar .sidebar-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.jobs-sidebar .sidebar-title i {
    margin-right: 0.5rem;
}

/* Mobile Info Accordion */
.mobile-info-accordion {
    margin-bottom: 2rem;
}

.mobile-info-accordion .accordion-button {
    font-weight: 600;
    padding: 1rem;
    border-radius: 8px !important;
}

.mobile-info-accordion .accordion-button:not(.collapsed) {
    background-color: #f8f9fa;
    border-color: #e9ecef;
}

.mobile-info-accordion .accordion-button:focus {
    box-shadow: 0 0 0 0.25rem rgba(52, 152, 219, 0.25);
}

.mobile-info-accordion .accordion-body {
    padding: 1rem;
}

.mobile-info-accordion .accordion-item {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.mobile-info-accordion .accordion-item:last-child {
    margin-bottom: 0;
}

/* Responsive Design */
@media (max-width: 768px) {

    .jobs-title,
    .create-job-title,
    .job-detail-title {
        font-size: 2rem;
    }

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

    .job-detail-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .job-detail-sidebar {
        position: static;
        margin-top: 2rem;
    }

    .form-actions .btn {
        display: block;
        width: 100%;
        margin: 0.5rem 0;
    }

    /* Мобильные исправления для карточек вакансий */
    .job-card {
        min-height: auto;
        margin-bottom: 1rem;
    }

    .job-card-body {
        padding: 12px 14px;
    }

    .job-card-header {
        padding-bottom: 8px;
        margin-bottom: 8px;
    }

    .job-title {
        font-size: 1rem;
        line-height: 1.3;
        margin-bottom: 0.3rem;
    }

    .job-title a {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .job-company {
        font-size: 0.85rem;
        margin-bottom: 0.3rem;
    }

    .job-meta {
        font-size: 0.75rem;
    }

    .job-description {
        font-size: 0.85rem;
        line-height: 1.4;
        margin-bottom: 0.5rem;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .job-details {
        gap: 0.5rem;
        margin-top: 0.4rem;
    }

    .job-detail {
        font-size: 0.8rem;
        gap: 0.3rem;
    }

    .job-detail i {
        width: 12px;
        font-size: 0.75rem;
    }

    .job-card-footer {
        padding: 8px 10px;
        flex-wrap: wrap;
        gap: 4px;
    }

    .job-card-footer .btn {
        font-size: 0.8rem;
        padding: 6px 10px;
        flex: 1 1 auto;
        min-width: calc(50% - 2px);
        max-width: none;
    }

    .job-card-footer .btn-primary {
        max-width: 100%;
        margin-bottom: 4px;
    }

    .badges {
        gap: 4px;
        margin-bottom: 4px;
    }

    .badge {
        font-size: 0.65rem;
        padding: 0.25em 0.45em;
    }

    .badge-top-right {
        top: 6px;
        right: 6px;
        font-size: 0.6rem;
        padding: 0.2em 0.4em;
    }

    /* Toolbar на мобильных */
    .jobs-toolbar {
        gap: 8px;
        margin: 8px 0 16px;
    }

    .jobs-toolbar .toolbar-search {
        flex-basis: 100%;
        min-width: 100%;
    }

    .jobs-toolbar .toolbar-select {
        flex: 1 1 calc(50% - 4px);
        min-width: 0;
    }

    .jobs-toolbar .btn-apply {
        flex: 1 1 100%;
        margin-top: 4px;
    }

    /* Active filters на мобильных */
    .active-filters {
        gap: 6px;
        margin-bottom: 12px;
    }

    .chip {
        font-size: 0.8rem;
        padding: 5px 10px;
    }

    /* Container padding на мобильных */
    .container.mt-4 {
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Hero секция выходит за пределы container */
    .jobs-hero-section {
        margin-left: -15px;
        margin-right: -15px;
        width: calc(100% + 30px);
        padding-left: 15px;
        padding-right: 15px;
        box-sizing: border-box;
    }

    /* Внутренний контент должен иметь padding */
    .container.mt-4>*:not(.jobs-hero-section) {
        padding-left: 0;
        padding-right: 0;
    }
}

@media (max-width: 576px) {

    .jobs-header,
    .create-job-header,
    .job-detail-header {
        padding: 1.5rem 1rem;
    }

    .create-job-form-container {
        padding: 1.5rem;
    }

    .job-detail-content {
        padding: 1.5rem;
    }

    .job-detail-sidebar {
        padding: 1rem;
    }

    /* Дополнительные исправления для очень маленьких экранов */
    .job-card-body {
        padding: 10px 12px;
    }

    .job-title {
        font-size: 0.95rem;
    }

    .job-card-footer {
        padding: 6px 8px;
        flex-direction: column;
    }

    .job-card-footer .btn {
        width: 100%;
        min-width: 100%;
        margin: 2px 0;
    }

    .jobs-toolbar .toolbar-select {
        flex: 1 1 100%;
        margin-bottom: 4px;
    }

    .jobs-toolbar .btn-apply {
        margin-top: 0;
    }

    /* Trending jobs на маленьких экранах */
    .trending-jobs-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .trending-job-card {
        padding: 0.7rem;
        min-height: 160px;
    }

    /* Уменьшаем отступы в hero */
    .hero-content {
        padding: 0 10px;
    }

    .hero-title {
        font-size: 1.5rem;
    }

    .hero-subtitle {
        font-size: 0.9rem;
    }

    /* SEO блок на маленьких экранах */
    .seo-block {
        padding: 1.5rem 1rem;
        margin-top: 2rem;
    }

    .seo-title {
        font-size: 1.4rem;
    }

    .seo-text {
        font-size: 0.9rem;
    }

    .seo-keyword {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
}

/* Search Container Styles - перенесено из inline стилей */
.search-container .input-group-text {
    height: calc(2.25rem + 2px) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-right: 0 !important;
    border-left: 2px solid #e2e8f0 !important;
    border-top: 2px solid #e2e8f0 !important;
    border-bottom: 2px solid #e2e8f0 !important;
    background-color: #f8f9fa !important;
    border-color: #e2e8f0 !important;
    border-radius: 0.375rem 0 0 0.375rem !important;
    padding: 0.75rem 1rem !important;
    line-height: 1 !important;
    vertical-align: top !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

.search-container .form-control {
    height: calc(2.25rem + 2px) !important;
    border-left: 0 !important;
    border-right: 0 !important;
    border-top: 2px solid #e2e8f0 !important;
    border-bottom: 2px solid #e2e8f0 !important;
    padding: 0.75rem 1rem !important;
    line-height: 1.5 !important;
    vertical-align: top !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

.search-container .btn {
    height: calc(2.25rem + 2px) !important;
    min-height: calc(2.25rem + 2px) !important;
    max-height: calc(2.25rem + 2px) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-left: none;
    padding: 0.75rem 1rem !important;
    line-height: 1 !important;
    vertical-align: top !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

/* Дополнительные стили для идеального выравнивания */
.search-container .input-group {
    align-items: stretch !important;
}

.search-container .input-group>* {
    vertical-align: top !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

/* Специально для кнопки крестика - используем те же стили что и в change_password.css */
.search-container #clearSearch {
    height: calc(2.25rem + 2px) !important;
    min-height: calc(2.25rem + 2px) !important;
    max-height: calc(2.25rem + 2px) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0.75rem 1rem !important;
    border-radius: 0 0.375rem 0.375rem 0 !important;
    border-left: 0 !important;
    border-right: 2px solid #e2e8f0 !important;
    border-top: 2px solid #e2e8f0 !important;
    border-bottom: 2px solid #e2e8f0 !important;
    background-color: #f8f9fa !important;
    color: #6c757d !important;
    transition: all 0.2s ease;
    line-height: 1 !important;
    min-width: 50px !important;
    width: 50px !important;
    flex-shrink: 0 !important;
    margin-left: -1px !important;
    font-size: 1rem !important;
    vertical-align: top !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

.search-container #clearSearch:hover {
    background-color: #e9ecef !important;
    color: #495057 !important;
}

.search-container #clearSearch i {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 1rem !important;
    line-height: 1 !important;
    vertical-align: top !important;
    width: 1em !important;
    height: 1em !important;
    margin: 0 !important;
    padding: 0 !important;
    text-align: center !important;
}

/* Автокомплит стили */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 0.375rem 0.375rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    max-height: 200px;
    overflow-y: auto;
}

.search-suggestion {
    padding: 0.75rem 1rem;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s ease;
}

.search-suggestion:last-child {
    border-bottom: none;
}

.search-suggestion:hover {
    background-color: #f8f9fa;
}

.search-suggestion.active {
    background-color: #e3f2fd;
}

.search-results-info {
    margin-top: 1rem;
    padding: 0.75rem 1rem;
    background-color: #f8f9fa;
    border-radius: 0.375rem;
    border: 1px solid #e2e8f0;
}

/* Мобильная адаптивность для поиска */
@media (max-width: 768px) {

    .search-container .input-group-text,
    .search-container .form-control,
    .search-container .btn,
    .search-container #clearSearch {
        height: calc(2.5rem + 2px) !important;
        min-height: calc(2.5rem + 2px) !important;
        max-height: calc(2.5rem + 2px) !important;
        padding: 0.875rem 1rem !important;
        font-size: 16px;
        /* Предотвращает зум на iOS */
    }
}

/* AI Assistant Styles */
.ai-assistant-section {
    background: linear-gradient(135deg, #f8f9ff 0%, #e8f2ff 100%);
    border: 2px solid #e3f2fd;
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem 0;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.1);
}

.ai-assistant-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.ai-assistant-title {
    color: #007bff;
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.ai-badge {
    background: linear-gradient(45deg, #ff6b6b, #ff8e53);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ai-assistant-description {
    color: #6c757d;
    font-size: 1rem;
    margin-bottom: 0;
}

.ai-input-section {
    margin-bottom: 1.5rem;
}

.ai-input-section textarea {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    transition: all 0.3s ease;
    resize: vertical;
    min-height: 120px;
}

.ai-input-section textarea:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.ai-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 1rem;
}

.ai-actions .btn {
    padding: 0.75rem 2rem;
    border-radius: 25px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.ai-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

.ai-status {
    text-align: center;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 10px;
    margin: 1rem 0;
}

.ai-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    color: #007bff;
    font-weight: 600;
}

.ai-loading i {
    font-size: 1.5rem;
}

.ai-preview {
    background: #fff;
    border: 2px solid #28a745;
    border-radius: 15px;
    padding: 1.5rem;
    margin: 1rem 0;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.1);
}

.ai-preview h5 {
    color: #28a745;
    font-weight: 700;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ai-preview-content {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.ai-preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #e9ecef;
}

.ai-preview-item:last-child {
    border-bottom: none;
}

.ai-preview-label {
    font-weight: 600;
    color: #495057;
}

.ai-preview-value {
    color: #007bff;
    font-weight: 500;
}

.ai-preview-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.ai-preview-actions .btn {
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.ai-preview-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

/* AI Tips Styles */
.ai-tips {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.ai-tips h6 {
    color: #856404;
    font-weight: 600;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ai-tips-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.ai-tip-item {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.9rem;
    line-height: 1.4;
}

.ai-tip-number {
    background: #007bff;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.ai-tip-item strong {
    color: #495057;
    font-weight: 600;
}

/* AI Success Styles */
.ai-success {
    text-align: center;
    padding: 2rem;
    background: #d4edda;
    border: 2px solid #28a745;
    border-radius: 15px;
    margin: 1rem 0;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.1);
}

.ai-success-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    color: #155724;
    font-weight: 600;
    font-size: 1.1rem;
}

.ai-success-content i {
    font-size: 1.5rem;
}

/* AI Assistant Mobile Styles */
@media (max-width: 768px) {
    .ai-assistant-section {
        padding: 1.5rem;
        margin: 1rem 0;
    }

    .ai-actions {
        flex-direction: column;
        gap: 0.5rem;
    }

    .ai-actions .btn {
        width: 100%;
    }

    .ai-tips {
        padding: 0.75rem;
    }

    .ai-tip-item {
        font-size: 0.85rem;
    }

    .ai-tip-number {
        width: 18px;
        height: 18px;
        font-size: 0.75rem;
    }
}

/* AI Modal Styles */
#aiAssistantModal .modal-header {
    background: linear-gradient(135deg, #007bff, #0056b3);
    border-bottom: none;
}

#aiAssistantModal .modal-title {
    font-weight: 600;
    display: flex;
    align-items: center;
}

#aiAssistantModal .badge {
    font-size: 0.7em;
    padding: 0.25em 0.5em;
}

#aiAssistantModal .alert-info {
    background: linear-gradient(135deg, #d1ecf1, #bee5eb);
    border: 1px solid #bee5eb;
    border-radius: 8px;
}

#aiAssistantModal .alert-info h6 {
    color: #0c5460;
    margin-bottom: 10px;
}

#aiAssistantModal .form-control {
    border-radius: 8px;
    border: 2px solid #e9ecef;
    transition: all 0.3s ease;
}

#aiAssistantModal .form-control:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

#aiAssistantModal .ai-status {
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}

#aiAssistantModal .spinner-border {
    width: 2rem;
    height: 2rem;
}

#aiAssistantModal .ai-preview {
    background: linear-gradient(135deg, #e8f5e8, #d4edda);
    border: 1px solid #c3e6cb;
    border-radius: 8px;
    padding: 20px;
}

#aiAssistantModal .ai-preview h6 {
    color: #155724;
    font-weight: 600;
}

#aiAssistantModal .ai-preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(21, 87, 36, 0.1);
}

#aiAssistantModal .ai-preview-item:last-child {
    border-bottom: none;
}

#aiAssistantModal .ai-preview-label {
    font-weight: 600;
    color: #155724;
    min-width: 120px;
}

#aiAssistantModal .ai-preview-value {
    color: #155724;
    font-weight: 500;
    text-align: right;
    flex: 1;
    margin-left: 15px;
}

#aiAssistantModal .modal-footer .btn {
    border-radius: 6px;
    font-weight: 500;
    padding: 8px 16px;
}

#aiAssistantModal .btn-primary {
    background: linear-gradient(135deg, #007bff, #0056b3);
    border: none;
}

#aiAssistantModal .btn-success {
    background: linear-gradient(135deg, #28a745, #1e7e34);
    border: none;
}

#aiAssistantModal .btn-secondary {
    background: linear-gradient(135deg, #6c757d, #545b62);
    border: none;
}

#aiAssistantModal .btn-outline-secondary {
    border: 2px solid #6c757d;
    color: #6c757d;
    background: transparent;
}

#aiAssistantModal .btn-outline-secondary:hover {
    background: #6c757d;
    border-color: #6c757d;
}

/* Modal mobile optimizations */
@media (max-width: 768px) {
    #aiAssistantModal .modal-dialog {
        margin: 10px;
        max-width: calc(100% - 20px);
    }

    #aiAssistantModal .modal-title {
        font-size: 1.1em;
    }

    #aiAssistantModal .alert-info .row {
        flex-direction: column;
    }

    #aiAssistantModal .ai-preview-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }

    #aiAssistantModal .ai-preview-label {
        min-width: auto;
        margin-bottom: 5px;
    }

    #aiAssistantModal .ai-preview-value {
        text-align: left;
        margin-left: 0;
    }

    #aiAssistantModal .modal-footer {
        flex-direction: column;
        gap: 10px;
    }

    #aiAssistantModal .modal-footer .btn {
        width: 100%;
    }
}

/* Trending Jobs Section */
.trending-jobs-section {
    background: rgba(255, 99, 99, 0.08);
    border: 1px solid rgba(255, 99, 99, 0.15);
    border-radius: 12px;
    padding: 1rem 1.2rem;
    margin-top: -20px;
    margin-bottom: 1.5rem;
}

.trending-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #dc2626;
    display: flex;
    align-items: center;
}

.trending-jobs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}

.trending-job-card {
    background: white;
    border-radius: 10px;
    padding: 0.85rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid #eef1f6;
    position: relative;
    min-height: 180px;
    display: flex;
    flex-direction: column;
}

.trending-job-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.2);
    border-color: #c7d2fe;
}

.trending-job-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.trending-job-header {
    padding-bottom: 0.5rem;
    margin-bottom: 0.5rem;
}

.trending-job-content h4 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
    color: #2c3e50;
    line-height: 1.3;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.trending-job-content h4:hover {
    color: #3498db;
}

.trending-company {
    color: #7f8c8d;
    font-size: 0.85rem;
    margin-bottom: 0;
    word-wrap: break-word;
    display: flex;
    align-items: center;
}

.trending-company i {
    margin-right: 0.5rem;
    color: #3498db;
    font-size: 0.8rem;
}

/* Используем те же стили job-details-structured что и в обычных карточках */
.trending-job-card .job-details-structured {
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    padding: 0.5rem;
    background: #f8f9fa;
    border-radius: 6px;
}

.trending-job-card .job-detail-line {
    margin-bottom: 0.4rem;
    font-size: 0.85rem;
}

.trending-job-card .job-detail-line:last-child {
    margin-bottom: 0;
}

.trending-job-card .job-detail-icon {
    font-size: 1rem;
    min-width: 1.3rem;
}

.trending-job-card .job-detail-text {
    font-size: 0.85rem;
    color: #555;
}

.trending-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 0.6rem;
    border-top: 1px solid #f0f0f0;
}

.trending-job-card .badge-new {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
}

.trending-views {
    font-size: 0.85rem;
    color: #7f8c8d;
    display: flex;
    align-items: center;
}

/* Мобильные стили для Trending Jobs */
@media (max-width: 768px) {
    .trending-jobs-section {
        padding: 0.75rem 1rem;
        margin-top: -10px;
        margin-bottom: 1rem;
        border-radius: 10px;
    }

    .trending-title {
        font-size: 1.1rem;
        margin-bottom: 0.6rem;
    }

    .trending-jobs-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .trending-job-card {
        padding: 0.7rem;
        min-height: 160px;
        border-radius: 8px;
    }

    .trending-job-content h4 {
        font-size: 0.9rem;
        margin-bottom: 0.3rem;
    }

    .trending-company {
        font-size: 0.8rem;
        margin-bottom: 0;
    }

    .trending-job-card .job-details-structured {
        padding: 0.4rem;
        margin-top: 0.4rem;
        margin-bottom: 0.4rem;
    }

    .trending-job-card .job-detail-line {
        margin-bottom: 0.3rem;
        font-size: 0.8rem;
    }

    .trending-job-card .job-detail-icon {
        font-size: 0.9rem;
        min-width: 1.2rem;
    }

    .trending-job-card .job-detail-text {
        font-size: 0.8rem;
    }

    .trending-footer {
        padding-top: 0.5rem;
    }

    .trending-views {
        font-size: 0.8rem;
    }

    .trending-job-card .badge-new {
        top: 6px;
        right: 6px;
        font-size: 0.6rem;
        padding: 0.2em 0.4em;
    }
}

@media (max-width: 576px) {
    .trending-jobs-section {
        padding: 0.6rem 0.8rem;
        margin-bottom: 0.8rem;
    }

    .trending-title {
        font-size: 1rem;
        margin-bottom: 0.5rem;
    }

    .trending-jobs-grid {
        gap: 0.6rem;
    }

    .trending-job-card {
        padding: 0.6rem;
        min-height: 150px;
    }

    .trending-job-content h4 {
        font-size: 0.85rem;
    }

    .trending-company {
        font-size: 0.75rem;
    }

    .trending-job-card .job-details-structured {
        padding: 0.35rem;
        margin-top: 0.35rem;
        margin-bottom: 0.35rem;
    }

    .trending-job-card .job-detail-line {
        margin-bottom: 0.25rem;
        font-size: 0.75rem;
    }

    .trending-job-card .job-detail-icon {
        font-size: 0.85rem;
        min-width: 1.1rem;
    }

    .trending-job-card .job-detail-text {
        font-size: 0.75rem;
    }

    .trending-views {
        font-size: 0.75rem;
    }
}

/* Load More Button */
.load-more-container {
    margin: 2rem 0;
}

.load-more-btn {
    padding: 0.75rem 2rem;
    font-weight: 600;
    border-radius: 25px;
    transition: all 0.3s ease;
}

.load-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

/* Mini Preview Tooltip */
.job-preview-tooltip {
    position: fixed;
    background: white;
    border: 2px solid #3498db;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    max-width: 400px;
    min-width: 300px;
    animation: fadeInUp 0.3s ease;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid #e9ecef;
    background: #f8f9fa;
    border-radius: 12px 12px 0 0;
}

.preview-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.preview-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #6c757d;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.preview-close:hover {
    background: #e9ecef;
    color: #2c3e50;
}

.preview-content {
    padding: 1rem;
    max-height: 300px;
    overflow-y: auto;
}

.preview-content p {
    margin-bottom: 0.75rem;
    color: #555;
    line-height: 1.6;
}

.preview-content strong {
    color: #2c3e50;
}

.preview-footer {
    padding: 1rem;
    border-top: 1px solid #e9ecef;
    text-align: center;
    background: #f8f9fa;
    border-radius: 0 0 12px 12px;
}

/* Fixed Mobile CTA */
.mobile-cta-fixed {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 0.75rem 1rem;
    border-top: 2px solid #e9ecef;
    transform: translateY(0);
    transition: transform 0.3s ease;
    /* Учитываем безопасную зону на iOS */
    padding-bottom: calc(0.75rem + env(safe-area-inset-bottom));
}

.mobile-cta-fixed.hidden {
    transform: translateY(100%);
}

/* Скрываем CTA при прокрутке вверх */
@media (max-width: 767px) {
    body.scrolling-up .mobile-cta-fixed {
        transform: translateY(100%);
    }
}

.mobile-cta-buttons {
    display: flex;
    gap: 0.75rem;
    max-width: 600px;
    margin: 0 auto;
}

.mobile-cta-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    white-space: nowrap;
}

/* Улучшение для Firefox на мобильных */
@-moz-document url-prefix() {
    .mobile-cta-fixed {
        -webkit-backface-visibility: hidden;
        backface-visibility: hidden;
    }

    .mobile-cta-btn {
        -webkit-tap-highlight-color: transparent;
    }
}

.mobile-cta-primary {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
}

.mobile-cta-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
    color: white;
}

.mobile-cta-secondary {
    background: #f8f9fa;
    color: #2c3e50;
    border: 2px solid #e9ecef;
}

.mobile-cta-secondary:hover {
    background: #e9ecef;
    color: #2c3e50;
}

/* SEO Block */
.seo-block {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 2rem;
    margin-top: 3rem;
}

.seo-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.seo-text {
    font-size: 1rem;
    line-height: 1.8;
    color: #555;
    margin-bottom: 1.5rem;
}

.seo-keywords {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.seo-keyword {
    background: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    color: #2c3e50;
    border: 1px solid #e9ecef;
    transition: all 0.2s ease;
}

.seo-keyword:hover {
    background: #e9ecef;
    border-color: #6c757d;
}