@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Inter', sans-serif; background: #f6f7f9; color: #1a1a2e; line-height: 1.5; overflow-x: hidden; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== HEADER ===== */
.header {
    background: #fff;
    position: sticky; top: 0; z-index: 200;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}
.header-inner {
    max-width: 1200px; margin: 0 auto; padding: 0 20px;
    display: flex; align-items: center; justify-content: space-between; height: 68px;
}
.logo {
    text-decoration: none; display: flex; align-items: center;
    font-size: 22px; font-weight: 800; color: #1a1a2e; letter-spacing: -0.5px;
}
.logo span { color: #22c55e; }
.main-nav { display: flex; gap: 8px; justify-content: flex-end; }
.main-nav a {
    text-decoration: none; color: #444; font-size: 15px; font-weight: 500;
    padding: 8px 14px; border-radius: 8px; transition: all 0.18s; white-space: nowrap;
}
.main-nav a:hover, .main-nav a.active { background: #f0fdf4; color: #22c55e; }

.burger { display: none; }

/* ===== HERO ===== */
.hero {
    background: linear-gradient(135deg, #111827 0%, #1f2937 60%, #374151 100%);
    padding: 50px 20px 40px;
    text-align: center; position: relative; overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute; inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Ccircle cx='30' cy='30' r='20'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-content { position: relative; max-width: 720px; margin: 0 auto; }
.hero h1 { font-size: 34px; font-weight: 800; color: #fff; letter-spacing: -0.8px; line-height: 1.15; margin-bottom: 10px; }
.hero p { font-size: 18px; color: rgba(255,255,255,0.85); margin-bottom: 25px; }

/* Filter Widget Overlaying Hero */
.search-widget {
    background: #fff; border-radius: 20px;
    padding: 28px 32px; max-width: 820px; margin: 0 auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.18);
    position: relative;
    text-align: left;
}
.widget-title {
    font-size: 18px; font-weight: 700; margin-bottom: 15px; color: #1a1a2e;
}
.search-fields { display: grid; grid-template-columns: 1fr 1fr auto; gap: 12px; align-items: end; }
.search-field-wrapper {
    display: flex; flex-direction: column; gap: 8px;
}
.search-field-wrapper label {
    font-size: 13px; font-weight: 600; color: #555;
}
.range-slider {
    width: 100%;
}
.search-btn {
    background: #22c55e; color: #fff; border: none; border-radius: 12px;
    padding: 12px 28px; font-size: 15px; font-weight: 700; cursor: pointer;
    transition: 0.18s; white-space: nowrap; height: 45px;
}
.search-btn:hover { background: #16a34a; transform: translateY(-1px); }

/* ===== DIVIDER SECTION ===== */
.section { max-width: 1200px; margin: 0 auto; padding: 40px 20px; }
.section-title { font-size: 28px; font-weight: 800; margin-bottom: 24px; letter-spacing: -0.5px; }

/* ===== PROMO BANNERS ===== */
.promo-grid { display: grid; grid-template-columns: 1fr; max-width: 800px; margin: 0 auto 30px auto; gap: 20px; }
.promo-card { position: relative; border-radius: 24px; padding: 35px 30px; color: #fff; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; min-height: 220px; box-shadow: 0 10px 30px rgba(0,0,0,0.05); transition: transform 0.3s ease, box-shadow 0.3s ease; text-decoration: none; }
.promo-card:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(0,0,0,0.1); color: #fff; }
.promo-content { position: relative; z-index: 2; max-width: 85%; }
.promo-title { font-size: 24px; font-weight: 800; margin-bottom: 12px; line-height: 1.2; letter-spacing: -0.5px; }
.promo-desc { font-size: 14px; line-height: 1.4; color: rgba(255,255,255,0.9); margin-bottom: 24px; }
.promo-btn { display: inline-flex; align-items: center; justify-content: center; background: #fff; font-size: 14px; font-weight: 700; padding: 12px 24px; border-radius: 12px; text-decoration: none; transition: 0.2s ease; box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.promo-card:nth-child(1) .promo-btn { color: #3b5bde; }
.promo-card:nth-child(2) .promo-btn { color: #6155e2; }
.promo-card:nth-child(3) .promo-btn { color: #8d61ef; }
.promo-btn:hover { background: #f8f9ff; transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,0.12); color: #333; }

/* ===== OFFERS SECTION (MFO CARDS) ===== */
.offers-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.offers-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.offer-tab {
    padding: 8px 18px; border-radius: 100px; border: 1.5px solid #e5e7eb;
    font-size: 14px; font-weight: 600; cursor: pointer;
    background: none; color: #555; transition: 0.18s; white-space: nowrap;
}
.offer-tab.active, .offer-tab:hover { background: #22c55e; color: #fff; border-color: #22c55e; }

.mfo-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:12px; margin-top:24px; }
.mfo-card { background:#fff; border-radius:14px; border:1.5px solid #eee; transition:all .2s; display:flex; flex-direction:column; overflow:hidden; position:relative; }
.mfo-card:hover { border-color:#22c55e; box-shadow:0 6px 24px rgba(34,197,94,.1); transform:translateY(-2px); }
.mfo-card-top { padding:14px 14px 10px; flex:1; }
.mfo-logo-row { display:flex; align-items:center; gap:10px; margin-bottom:10px; }
.mfo-clogo { height:30px; max-width:80px; background: #f0fdf4; padding: 2px; border-radius: 4px; object-fit:contain; object-position:left; }
.mfo-cname { font-size:13px; font-weight:700; color:#1a1a2e; line-height:1.2; text-decoration:none; }
.mfo-badges { display:flex; flex-wrap:wrap; gap:3px; margin-bottom:8px; min-height:18px; }
.mfo-badge { font-size:10px; font-weight:700; padding:2px 7px; border-radius:100px; }
.mfo-badge-green { background:#10b981; color:#fff; }
.mfo-badge-blue { background:#3b82f6; color:#fff; }
.mfo-badge-gold { background:#f59e0b; color:#fff; }

.mfo-stats { display:grid; grid-template-columns:1fr 1fr; gap:5px; margin-bottom:10px; }
.mfo-stat { background:#f8f9fb; border-radius:7px; padding:7px 9px; }
.mfo-stat-v { font-size:12px; font-weight:700; color:#1a1a2e; white-space:nowrap; }
.mfo-stat-v.accent { color:#22c55e; font-size:13px; }
.mfo-stat-l { font-size:9px; color:#bbb; margin-top:1px; text-transform:uppercase; letter-spacing:.3px; line-height:1; }

.mfo-card-bot { padding:8px 14px 12px; border-top:1px solid #f5f5f5; }
.mfo-appr-row { display:flex; align-items:center; gap:5px; margin-bottom:7px; }
.mfo-appr-d { width:7px; height:7px; border-radius:50%; flex-shrink:0; background:#22c55e; }
.mfo-appr-t { font-size:11px; color:#aaa; }
.mfo-appr-v { font-size:11px; font-weight:700; color:#22c55e; }
.mfo-get-btn { width:100%; background:#22c55e; color:#fff; border:none; border-radius:8px; padding:9px; font-size:13px; font-weight:700; cursor:pointer; transition:.18s; font-family:inherit; text-align:center; text-decoration:none; display:inline-block; }
.mfo-get-btn:hover { background:#15803d; }

/* ===== STEPS WIDGET ===== */
.steps-section { margin-top: 50px; margin-bottom: 20px; }
.steps-title { font-size: 22px; font-weight: 800; color: #111827; margin-bottom: 18px; }
.steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.step-card { background: #ffffff; border-radius: 12px; padding: 20px; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05); border: 1px solid #f3f4f6; display: flex; flex-direction: column; justify-content: space-between; min-height: 120px; transition: transform 0.2s, box-shadow 0.2s; }
.step-card:hover { transform: translateY(-2px); box-shadow: 0 6px 12px -2px rgba(0, 0, 0, 0.05), 0 3px 6px -3px rgba(0, 0, 0, 0.05); }
.step-icon { width: 44px; height: 44px; margin-bottom: 18px; display: flex; align-items: center; justify-content: flex-start; }
.step-icon svg { width: 100%; height: 100%; }
.step-text { font-size: 15px; font-weight: 700; color: #111827; line-height: 1.3; }

@media (max-width: 768px) {
    .steps-section { margin-top: 30px; margin-bottom: 5px; }
    .steps-grid { grid-template-columns: 1fr; gap: 12px; }
    .step-card { min-height: auto; padding: 16px; flex-direction: row; align-items: center; justify-content: flex-start; gap: 16px; box-shadow: 0 2px 4px -2px rgba(0, 0, 0, 0.05); }
    .step-icon { margin-bottom: 0; width: 36px; height: 36px; flex-shrink: 0; }
    .steps-title { font-size: 18px; margin-bottom: 12px; }
}

/* ===== MAIN SEO ARTICLE ===== */
.seo-article-block { margin-top: 40px; margin-bottom: 40px; background: #fff; padding: 25px 30px; border-radius: 12px; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05); border: 1px solid #f3f4f6; }
.seo-article-title { font-size: 20px; font-weight: 800; color: #111827; margin-bottom: 20px; border-bottom: 2px solid #e5e7eb; padding-bottom: 15px; line-height: 1.3; }
.seo-article-content h3 { font-size: 16px; font-weight: 700; color: #1f2937; margin-top: 24px; margin-bottom: 12px; }
.seo-article-content p { font-size: 14.5px; color: #4b5563; line-height: 1.65; margin-bottom: 16px; }

@media (max-width: 768px) {
    .seo-article-block { padding: 20px; margin-top: 25px; margin-bottom: 25px; }
    .seo-article-title { font-size: 18px; }
}

/* ===== FOOTER ===== */
.footer { background: #fff; border-top: 1px solid #f0f0f0; color: #555; padding: 50px 20px 30px; margin-top: 50px; }
.footer-inner { max-width: 1200px; margin: 0 auto; text-align: center; }
.footer-logo { font-size: 22px; font-weight: 800; color: #1a1a2e; margin-bottom: 12px; }
.footer-logo span { color: #22c55e; }

/* ===== CITY SELECTOR ===== */
.city-btn {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(255, 255, 255, 0.15); border: 1px solid rgba(255,255,255,0.2);
    color: #fff; padding: 10px 20px; border-radius: 100px;
    font-size: 15px; font-weight: 600; cursor: pointer;
    transition: all 0.2s; font-family: inherit;
}
.city-btn:hover { background: rgba(255, 255, 255, 0.25); border-color: rgba(255,255,255,0.4); }

.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5); z-index: 1000;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; visibility: hidden; transition: 0.3s;
}
.modal-overlay.active { opacity: 1; visibility: visible; }
.modal-content {
    background: #fff; width: 100%; max-width: 500px; border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2); overflow: hidden;
    transform: translateY(20px); transition: 0.3s; max-height: 90vh; display: flex; flex-direction: column;
}
.modal-overlay.active .modal-content { transform: translateY(0); }
.modal-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 20px 24px; border-bottom: 1px solid #eee;
}
.modal-header h3 { font-size: 18px; color: #1a1a2e; margin: 0; }
.modal-close {
    background: none; border: none; font-size: 28px; color: #888;
    cursor: pointer; line-height: 1; padding: 0 5px;
}
.modal-close:hover { color: #111; }
.modal-body { padding: 20px 24px; overflow-y: auto; }
.city-search-input {
    width: 100%; padding: 12px 16px; border: 2px solid #f0fdf4; border-radius: 12px;
    font-size: 15px; font-family: inherit; margin-bottom: 15px; outline: none; transition: 0.2s;
}
.city-search-input:focus { border-color: #22c55e; }
.city-list { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.city-item {
    padding: 10px 12px; border-radius: 8px; cursor: pointer; transition: 0.2s;
    color: #444; font-size: 15px; font-weight: 500;
}
.city-item:hover { background: #f0fdf4; color: #22c55e; }

/* ===== SHOW ALL BUTTON ===== */
.show-all-wrap { margin-top: 15px; margin-bottom: 20px; text-align: center; grid-column: 1/-1; }
.show-all-btn { display: inline-flex; align-items: center; justify-content: center; background: #f0fdf4; color: #16a34a; font-size: 18px; font-weight: 800; padding: 16px 40px; border-radius: 16px; border: none; cursor: pointer; transition: 0.2s; font-family: inherit; text-decoration: none; }
.show-all-btn:hover { background: #dcfce7; transform: translateY(-1px); }

/* ===== COMPLEX FOOTER ===== */
.main-footer {
    background: #fff;
    border-top: 1px solid #f0f0f0;
    padding: 40px 0 20px;
    margin-top: 40px;
    font-family: inherit;
}
.footer-grid {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 16px;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 30px;
}
.footer-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-size: 22px;
    font-weight: 800;
    color: #111;
    margin-bottom: 12px;
}
.footer-logo img {
    height: 32px;
    width: auto;
    object-fit: contain;
}
.footer-desc {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
    margin-bottom: 16px;
}
.ru-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
    text-decoration: none;
    background: #f7f9fa;
    padding: 8px 12px;
    border-radius: 8px;
    transition: background 0.2s;
}
.ru-link:hover {
    background: #eef1f4;
}
.f-title {
    font-size: 15px;
    font-weight: 700;
    color: #111;
    margin-bottom: 16px;
}
.links-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.links-col a {
    color: #555;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s;
}
.links-col a:hover {
    color: #22c55e;
}

.footer-rating {
    max-width: 1100px;
    margin: 30px auto 0;
    text-align: center;
}
.stars {
    color: #7b8391;
    font-size: 24px;
    letter-spacing: 2px;
    margin-bottom: 6px;
}
.rating-text {
    font-size: 14px;
    color: #7b8391;
    font-weight: 500;
}

.footer-bottom {
    max-width: 1100px;
    margin: 30px auto 0;
    padding: 20px 16px 0;
    border-top: 1px solid #f0f0f0;
    font-size: 12px;
    color: #999;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1100px) { .mfo-grid { grid-template-columns:repeat(3,1fr); } }
@media (max-width: 900px) {
    .main-nav { display: flex; gap: 4px; }
    .main-nav a { padding: 6px 10px; font-size: 14px; }
    .promo-grid { grid-template-columns: 1fr; gap: 16px; }
    .hero h1 { font-size: 26px; }
    .search-fields { grid-template-columns: 1fr 1fr; }
    .search-btn { grid-column: 1/-1; }
    .mfo-grid { grid-template-columns:repeat(2,1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
    .mfo-grid { grid-template-columns:repeat(2,1fr); gap:8px; }
    .search-fields { grid-template-columns: 1fr; }
    .city-list { grid-template-columns: 1fr; }
    .mfo-license { font-size: 8px; line-height: 1.1; margin-top: 4px; padding-bottom: 2px; }
    .mfo-license-title { font-size: 8px; }
    .footer-grid { grid-template-columns: 1fr; gap: 40px; }
}

.auth-btn { background: #2563eb; color: #fff; border: none; padding: 8px 16px; border-radius: 8px; font-weight: 600; cursor: pointer; transition: 0.2s; font-size: 14px; }
.auth-btn:hover { background: #1d4ed8; }
.profile-btn { display: flex; align-items: center; gap: 8px; text-decoration: none; color: #1e293b; font-weight: 600; padding: 6px 12px; border-radius: 8px; border: 1px solid #e2e8f0; font-size: 14px; }
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); display: none; align-items: center; justify-content: center; z-index: 1000; }
.modal-overlay.active { display: flex; }
.modal-content { background: #fff; padding: 30px; border-radius: 16px; width: 100%; max-width: 400px; position: relative; }
.modal-close { position: absolute; top: 15px; right: 15px; cursor: pointer; font-size: 20px; color: #64748b; }
.auth-form { display: flex; flex-direction: column; gap: 15px; }
.auth-form input { padding: 12px; border: 1px solid #e2e8f0; border-radius: 8px; font-size: 15px; }
.auth-form button { background: #2563eb; color: #fff; border: none; padding: 12px; border-radius: 8px; font-weight: 600; font-size: 16px; cursor: pointer; }
