/* ===== page-contacts.css - Стили для страницы Контакты ===== */
.algkod-container {
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* ===== Секция контактов (верхние 4 карточки) ===== */
.algkod-contacts-section {
    padding: 60px 0;
    background-color: var(--bg-white);
}

.algkod-contacts-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.algkod-contact-card {
    background-color: var(--bg-light);
    padding: 30px 20px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
}

.algkod-contact-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.algkod-contact-card__icon {
    width: 60px;
    height: 60px;
    background-color: var(--accent-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    transition: var(--transition);
}

.algkod-contact-card:hover .algkod-contact-card__icon {
    transform: scale(1.1);
    background-color: var(--accent-primary-hover);
}

.algkod-contact-card__icon img {
    width: 30px;
    height: 30px;
    filter: brightness(0) invert(1);
}

.algkod-contact-card__title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.algkod-contact-card__text {
    color: var(--text-gray);
    line-height: 1.5;
    margin: 0;
    font-size: 0.95rem;
}

.algkod-contact-card__link {
    color: var(--accent-primary);
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.algkod-contact-card__link:hover {
    color: var(--accent-primary-hover);
    text-decoration: underline;
}

.algkod-contact-card__emails {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

/* ===== БЛОК С ДВУМЯ КОЛОНКАМИ (Форма + Реквизиты) ===== */
.algkod-bottom-section {
    padding: 0 0 60px 0;
    background: var(--bg-light);
}

.algkod-two-columns {
    display: flex;
    gap: 30px;
    align-items: stretch;
}

.algkod-column {
    flex: 1;
    min-width: 0;
    display: flex;
}

/* Общий стиль для обеих колонок */
.algkod-column--form {
    background: var(--bg-white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-hover);
    overflow: hidden;
    width: 100%;
}

.algkod-form-wrapper {
    height: 100%;
    width: 100%;
    display: flex;
    flex-direction: column;
}

/* Заголовок блока */
.algkod-form-header {
    background: var(--bg-header);
    padding: 25px 30px;
    text-align: center;
    color: white;
}

.algkod-form-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 5px;
    color: white;
}

.algkod-form-subtitle {
    font-size: 1rem;
    opacity: 0.9;
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
}

/* Контент блока */
.algkod-form-content {
    padding: 30px;
    flex: 1;
}

.algkod-form-content--details {
    padding-bottom: 0;
}

/* Футер с кнопкой */
.algkod-form-footer {
    padding: 0 30px 30px 30px;
    margin-top: auto;
}

/* Стили для таблицы реквизитов */
.algkod-details-card {
    margin-bottom: 20px;
}

.algkod-details-table {
    width: 100%;
    border-collapse: collapse;
}

.algkod-details-table tr {
    border-bottom: 1px solid var(--border-color);
}

.algkod-details-table tr:last-child {
    border-bottom: none;
}

.algkod-details-table td {
    padding: 12px 5px 12px 0;
    vertical-align: top;
    line-height: 1.5;
}

.algkod-details-table__label {
    font-weight: 600;
    color: var(--text-dark);
    width: 35%;
    white-space: nowrap;
}

.algkod-details-table__value {
    color: var(--text-gray);
    width: 65%;
}

/* ===== СТИЛИ ДЛЯ КНОПОК ===== */
.algkod-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 24px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 16px;
    text-decoration: none;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    line-height: 1.2;
    font-family: var(--font-primary);
    text-align: center;
    background: var(--accent-primary);
    color: white;
    width: 100%;
    box-sizing: border-box;
    min-height: 48px; /* Фиксированная минимальная высота */
}

.algkod-btn:hover {
    background: var(--accent-primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
    color: white;
    text-decoration: none;
}

/* Специально для кнопки в правой колонке */
.algkod-form-footer .algkod-btn {
    margin-top: 0;
}

/* Стили для кнопки CF7 в левой колонке */
.wpcf7-form .wpcf7-submit {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 14px 24px !important;
    border-radius: 6px !important;
    font-weight: 600 !important;
    font-size: 1rem !important;
    line-height: 1.2 !important;
    border: none !important;
    cursor: pointer !important;
    transition: var(--transition) !important;
    background: var(--accent-primary) !important;
    color: white !important;
    width: 100% !important;
    min-height: 48px !important;
    margin: 0 !important;
}

.wpcf7-form .wpcf7-submit:hover {
    background: var(--accent-primary-hover) !important;
    transform: translateY(-2px) !important;
    box-shadow: var(--shadow-hover) !important;
}

.wpcf7-form .wpcf7-spinner {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    margin: 0 !important;
}

.wpcf7-form p:last-of-type {
    position: relative;
    margin-bottom: 0;
}

/* ===== Стили для формы CF7 ===== */
.algkod-form-field {
    width: 100%;
}

.algkod-form-field--half {
    width: 100%;
}

@media (min-width: 768px) {
    .algkod-form-row {
        display: flex;
        gap: 20px;
    }
    
    .algkod-form-field--half {
        flex: 1;
    }
}

.algkod-form-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--text-dark);
    font-size: 0.95rem;
}

.algkod-required {
    color: var(--accent-primary);
    margin-left: 2px;
}

.algkod-form-input,
.algkod-form-textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 0.95rem;
    font-family: var(--font-primary);
    transition: var(--transition);
    background: var(--bg-white);
    color: var(--text-dark);
    box-sizing: border-box;
}

.algkod-form-textarea {
    min-height: 100px;
    resize: vertical;
}

.algkod-form-input:focus,
.algkod-form-textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(43, 179, 193, 0.1);
}

/* Политика конфиденциальности */
.algkod-form-privacy {
    font-size: 0.85rem;
    color: var(--text-gray);
    line-height: 1.5;
}

.algkod-form-privacy p {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 10px 0;
}

.algkod-form-privacy input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--accent-primary);
    margin-top: 2px;
    flex-shrink: 0;
}

.algkod-form-privacy a {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 500;
}

.algkod-form-privacy a:hover {
    text-decoration: underline;
}

/* ===== Адаптивность ===== */
@media (max-width: 1024px) {
    .algkod-contacts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .algkod-two-columns {
        gap: 20px;
    }
    
    .algkod-form-header {
        padding: 20px;
    }
    
    .algkod-form-title {
        font-size: 1.6rem;
    }
    
    .algkod-form-content {
        padding: 20px;
    }
    
    .algkod-form-footer {
        padding: 0 20px 20px 20px;
    }
}

@media (max-width: 900px) {
    .algkod-two-columns {
        flex-direction: column;
    }
    
    .algkod-column {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .algkod-contacts-section {
        padding: 40px 0;
    }
    
    .algkod-contacts-grid {
        grid-template-columns: 1fr;
    }
    
    .algkod-bottom-section {
        padding: 0 0 40px 0;
    }
    
    .algkod-form-header {
        padding: 20px 15px;
    }
    
    .algkod-form-title {
        font-size: 1.5rem;
    }
    
    .algkod-form-content {
        padding: 20px 15px;
    }
    
    .algkod-form-footer {
        padding: 0 15px 20px 15px;
    }
    
    .algkod-details-table td {
        padding: 10px 5px;
        font-size: 0.9rem;
    }
    
    .algkod-btn,
    .wpcf7-form .wpcf7-submit {
        padding: 12px 20px !important;
        font-size: 0.95rem !important;
        min-height: 44px !important;
    }
}

@media (max-width: 480px) {
    .algkod-details-table td {
        display: block;
        width: 100%;
        padding: 5px 0;
    }
    
    .algkod-details-table__label {
        padding-top: 10px;
        white-space: normal;
    }
    
    .algkod-details-table__value {
        padding-bottom: 10px;
    }
    
    .algkod-form-title {
        font-size: 1.3rem;
    }
}

/* Анимации */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.algkod-contact-card {
    animation: fadeInUp 0.6s ease forwards;
}

.algkod-contact-card:nth-child(1) { animation-delay: 0.1s; }
.algkod-contact-card:nth-child(2) { animation-delay: 0.2s; }
.algkod-contact-card:nth-child(3) { animation-delay: 0.3s; }
.algkod-contact-card:nth-child(4) { animation-delay: 0.4s; }

