
:root {
    --primary: #AF1B57;
    --primary-dark: #8e1446;
    --primary-light: #e63981;
    --secondary: #2d3748;
    --light: #f8f9fa;
    --gray: #e2e8f0;
    --dark: #1a202c;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f5f5f5;
    color: var(--secondary);
    line-height: 1.5;
}

.container {
    width: 100%;
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Header */
header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

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

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

.logo-icon {
    color: var(--primary);
    font-size: 28px;
}

.logo-text h1 {
    font-size: 22px;
    color: var(--primary);
    line-height: 1.2;
}

.logo-text span {
    color: var(--secondary);
    font-size: 12px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.phone {
    font-size: 18px;
    font-weight: bold;
    color: var(--primary);
}

.work-hours {
    font-size: 12px;
    color: var(--secondary);
}

/* Hero Banner */
.hero-banner {
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('https://images.unsplash.com/photo-1560518883-ce09059eeffa?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1770&q=80');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 50px 0;
    text-align: center;
    border-radius: 0 0 15px 15px;
    margin-bottom: 25px;
}

.hero-content h2 {
    font-size: 32px;
    margin-bottom: 12px;
    line-height: 1.3;
}

.hero-content p {
    font-size: 15px;
    max-width: 700px;
    margin: 0 auto 20px;
    line-height: 1.5;
}

.cta-button {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 12px 30px;
    font-size: 15px;
    font-weight: bold;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(175, 27, 87, 0.4);
}

.cta-button:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(175, 27, 87, 0.5);
}

/* Main Content */
.main-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

/* Calculator Section - СУПЕР КОМПАКТНЫЙ */
.calculator-section {
    background-color: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.section-title {
    color: var(--primary);
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--gray);
    font-size: 20px;
}

.calculator {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.input-group label {
    font-weight: 600;
    color: var(--secondary);
    font-size: 13px;
}

.input-with-unit {
    position: relative;
}

.input-with-unit input {
    width: 100%;
    padding: 8px 30px 8px 10px;
    border: 1.5px solid var(--gray);
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.input-with-unit input:focus {
    border-color: var(--primary);
    outline: none;
}

.unit {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--primary);
    font-weight: 600;
    font-size: 12px;
}

.slider-container {
    margin-top: 5px;
}

.slider {
    width: 100%;
    height: 5px;
    border-radius: 3px;
    background: var(--gray);
    outline: none;
    -webkit-appearance: none;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.slider-values {
    display: flex;
    justify-content: space-between;
    margin-top: 3px;
    font-size: 11px;
    color: #666;
}

.result {
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-top: 5px;
    border-left: 4px solid var(--primary);
}

.result h3 {
    color: var(--primary);
    margin-bottom: 10px;
    font-size: 16px;
}

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

.result-item {
    display: flex;
    flex-direction: column;
}

.result-label {
    font-size: 11px;
    color: #666;
    margin-bottom: 2px;
}

.result-value {
    font-size: 16px;
    font-weight: bold;
    color: var(--primary);
    line-height: 1.2;
}

/* Блок с уведомлением */
.calculator-notice {
    background-color: rgba(175, 27, 87, 0.05);
    border: 1px solid rgba(175, 27, 87, 0.2);
    border-radius: 6px;
    padding: 10px 12px;
    margin-top: 12px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.calculator-notice-icon {
    color: var(--primary);
    font-size: 14px;
    margin-top: 1px;
    flex-shrink: 0;
}

.calculator-notice-text {
    font-size: 12px;
    color: #666;
    line-height: 1.4;
}

.calculator-notice-text a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px dotted var(--primary);
    transition: all 0.2s;
}

.calculator-notice-text a:hover {
    color: var(--primary-dark);
    border-bottom: 1px solid var(--primary-dark);
}

/* Credit Programs */
.programs-section {
    background-color: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
    margin-bottom: 25px;
}

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

.programs-header h2 {
    color: var(--primary);
    margin: 0;
    font-size: 20px;
}

.programs-filter {
    display: flex;
    gap: 6px;
}

.filter-btn {
    padding: 5px 12px;
    background-color: #f0f0f0;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    font-weight: 600;
    font-size: 12px;
    transition: all 0.3s;
}

.filter-btn.active {
    background-color: var(--primary);
    color: white;
}

.filter-btn:hover:not(.active) {
    background-color: var(--gray);
}

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

.program-card {
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid #eee;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.program-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.program-card-header {
    background-color: var(--primary);
    color: white;
    padding: 10px 12px;
}

.program-bank {
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 3px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.program-bank .bank-logo {
    font-weight: 700;
    font-size: 11px;
    background-color: rgba(255, 255, 255, 0.2);
    padding: 1px 5px;
    border-radius: 3px;
}

.program-name {
    font-size: 14px;
    font-weight: 700;
    margin: 0;
    line-height: 1.3;
}

.program-card-body {
    padding: 12px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.program-rate {
    font-size: 18px;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 8px;
    text-align: center;
    padding: 6px;
    background-color: rgba(175, 27, 87, 0.05);
    border-radius: 6px;
}

.program-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 10px;
}

.program-detail {
    display: flex;
    flex-direction: column;
}

.detail-label {
    font-size: 10px;
    color: #666;
    margin-bottom: 2px;
    display: flex;
    align-items: center;
    gap: 3px;
}

.detail-value {
    font-size: 12px;
    font-weight: 600;
    color: var(--secondary);
}

.program-security {
    background-color: #f8f9fa;
    padding: 8px 10px;
    border-radius: 6px;
    margin-top: auto;
}

.security-label {
    font-size: 11px;
    color: #666;
    margin-bottom: 3px;
    display: flex;
    align-items: center;
    gap: 3px;
}

.security-value {
    font-size: 12px;
    color: var(--secondary);
}

/* Help Form Section */
.help-form-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 12px;
    padding: 30px 20px;
    margin-bottom: 30px;
    color: white;
    text-align: center;
    box-shadow: 0 8px 20px rgba(175, 27, 87, 0.2);
}

.help-form-container {
    max-width: 800px;
    margin: 0 auto;
}

.help-form-title {
    font-size: 24px;
    margin-bottom: 10px;
    font-weight: 700;
    line-height: 1.3;
}

.help-form-subtitle {
    font-size: 14px;
    margin-bottom: 20px;
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.4;
}

.help-form {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
    text-align: left;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-bottom: 12px;
}

.form-group {
    margin-bottom: 0;
}

.help-form .form-group label {
    color: var(--secondary);
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    font-size: 13px;
}

.help-form .form-group input,
.help-form .form-group select,
.help-form .form-group textarea {
    width: 100%;
    padding: 9px 10px;
    border: 1.5px solid var(--gray);
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s;
}

.help-form .form-group input:focus,
.help-form .form-group select:focus,
.help-form .form-group textarea:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(175, 27, 87, 0.1);
}

.form-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.privacy-note {
    font-size: 12px;
    color: #666;
    max-width: 280px;
    line-height: 1.4;
}

.help-form-btn {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: bold;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.help-form-btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* News Section - ОБНОВЛЕННЫЙ */
.news-section {
    background-color: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.news-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.news-item {
    display: flex;
    flex-direction: column;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--gray);
}

.news-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.news-content h3 {
    color: var(--secondary);
    margin-bottom: 6px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
}

.news-full-date {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: #777;
    margin-bottom: 8px;
}

.news-full-date i {
    color: var(--primary);
    font-size: 12px;
}

.news-content p {
    color: #666;
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 0;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-calc {
    background-color: white;
    border-radius: 12px;
    width: 90%;
    max-width: 450px;
    padding: 20px;
    position: relative;
    transform: translateY(30px);
    transition: transform 0.3s;
}

.modal-overlay.active .modal-calc {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 20px;
    color: #666;
    cursor: pointer;
}

.modal-calc h2 {
    color: var(--primary);
    margin-bottom: 15px;
    text-align: center;
    font-size: 20px;
}

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

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--secondary);
    font-size: 13px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 9px 10px;
    border: 1.5px solid var(--gray);
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    outline: none;
}

.submit-btn {
    background-color: var(--primary);
    color: white;
    border: none;
    width: 100%;
    padding: 12px;
    font-size: 14px;
    font-weight: bold;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.submit-btn:hover {
    background-color: var(--primary-dark);
}

/* Footer */
footer {
    background-color: var(--secondary);
    color: white;
    padding: 25px 0 12px;
    margin-top: 30px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
}

.footer-column {
    flex: 1;
    min-width: 180px;
}

.footer-column h3 {
    color: var(--primary-light);
    margin-bottom: 12px;
    font-size: 16px;
}

.footer-column p, .footer-column a {
    color: #cbd5e0;
    margin-bottom: 6px;
    display: block;
    text-decoration: none;
    font-size: 13px;
}

.footer-column a:hover {
    color: white;
}

.copyright {
    text-align: center;
    padding-top: 12px;
    border-top: 1px solid #4a5568;
    color: #a0aec0;
    font-size: 12px;
}

/* Responsive */
@media (max-width: 1200px) {
    .container {
        max-width: 1000px;
    }

    .programs-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
}

@media (max-width: 992px) {
    .main-content {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .hero-content h2 {
        font-size: 26px;
    }

    .programs-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    }

    .help-form-title {
        font-size: 22px;
    }

    .help-form-subtitle {
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 10px;
        padding: 10px 0;
    }

    .contact-info {
        align-items: center;
    }

    .hero-banner {
        padding: 35px 0;
        margin-bottom: 20px;
    }

    .hero-content h2 {
        font-size: 22px;
    }

    .hero-content p {
        font-size: 14px;
    }

    .cta-button {
        padding: 10px 25px;
        font-size: 14px;
    }

    .result-grid {
        grid-template-columns: 1fr;
        gap: 8px;
    }

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

    .programs-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .programs-filter {
        width: 100%;
        overflow-x: auto;
        padding-bottom: 5px;
    }

    .program-details {
        grid-template-columns: 1fr;
    }

    .help-form {
        padding: 15px;
    }

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

    .form-footer {
        flex-direction: column;
        align-items: stretch;
    }

    .privacy-note {
        max-width: 100%;
        text-align: center;
        margin-bottom: 8px;
    }

    .footer-content {
        flex-direction: column;
        gap: 15px;
    }

    .news-item {
        padding-bottom: 14px;
    }

    .news-content h3 {
        font-size: 15px;
    }
}

@media (max-width: 576px) {
    .container {
        padding: 0 12px;
    }

    .calculator-section,
    .programs-section,
    .news-section,
    .help-form-section {
        padding: 15px 12px;
    }

    .section-title {
        font-size: 18px;
    }

    .help-form-title {
        font-size: 20px;
    }

    .help-form-subtitle {
        font-size: 12px;
    }

    .help-form-btn {
        width: 100%;
        justify-content: center;
    }

    .program-card-header {
        padding: 8px 10px;
    }

    .program-name {
        font-size: 13px;
    }

    .program-rate {
        font-size: 16px;
    }

    .modal-calc {
        padding: 15px 12px;
    }

    .news-full-date {
        font-size: 11px;
    }

    .news-content p {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .logo-text h1 {
        font-size: 19px;
    }

    .phone {
        font-size: 16px;
    }

    .hero-content h2 {
        font-size: 20px;
    }

    .section-title {
        font-size: 17px;
    }

    .result-value {
        font-size: 15px;
    }

    .help-form-title {
        font-size: 18px;
    }

    .result-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .news-content h3 {
        font-size: 14px;
    }
}

/* Оптимизация для ноутбуков */
@media (min-width: 992px) and (max-width: 1366px) {
    .hero-banner {
        padding: 40px 0;
        margin-bottom: 20px;
    }

    .hero-content h2 {
        font-size: 28px;
    }

    .main-content {
        gap: 15px;
    }

    .calculator-section,
    .programs-section,
    .news-section {
        padding: 18px;
    }

    .programs-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 10px;
    }
}

.displayN {
    display: none;
}

.opacity05 {
    opacity: 0.5;
}

