﻿/* ============================================
   Строгий стиль для калькуляторов
   ============================================ */
.ducts-calculator-page,
.fasteners-calculator-page {
    padding: 2.5rem 1rem;
    background: #ffffff;
}

.page-title {
    font-size: 2rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.page-subtitle {
    font-size: 1rem;
    color: #64748b;
    margin-bottom: 2.5rem;
    font-weight: 400;
}

.calculator-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.calc-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.75rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.02);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
    gap: 1rem;
}

    .card-header h3 {
        margin: 0;
        font-size: 1.25rem;
        font-weight: 600;
        color: #0f172a;
    }

.type-select {
    width: auto;
    min-width: 200px;
    padding: 0.6rem 2.2rem 0.6rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #fff;
    font-size: 0.9rem;
    color: #0f172a;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.8rem center;
    background-size: 1rem;
    transition: border-color 0.15s;
}

    .type-select:hover {
        border-color: #94a3b8;
    }

    .type-select:focus {
        outline: none;
        border-color: #2563eb;
        box-shadow: 0 0 0 2px rgba(37,99,235,0.1);
    }

.drawing-area {
    text-align: center;
    margin: 1rem 0 1.5rem;
    background: #f8fafc;
    border-radius: 8px;
    padding: 0.5rem;
    border: 1px solid #e2e8f0;
}

.drawing-img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

.inputs-group {
    margin: 1.5rem 0;
}

.input-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
}

.input-field {
    flex: 1 0 120px;
    min-width: 100px;
}

    .input-field label {
        display: block;
        font-size: 0.8rem;
        font-weight: 500;
        color: #475569;
        margin-bottom: 0.25rem;
    }

    .input-field input {
        width: 100%;
        padding: 0.6rem 0.8rem;
        border: 1px solid #cbd5e1;
        border-radius: 6px;
        font-size: 0.9rem;
        color: #0f172a;
        background: #fff;
        transition: border-color 0.15s;
    }

        .input-field input:focus {
            outline: none;
            border-color: #2563eb;
            box-shadow: 0 0 0 2px rgba(37,99,235,0.1);
        }

.calc-btn {
    background: #2563eb;
    color: white;
    border: none;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.95rem;
    width: 100%;
    cursor: pointer;
    transition: background-color 0.15s;
    margin-top: 0.5rem;
}

    .calc-btn:hover {
        background: #1d4ed8;
    }

.result-block {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem 1.5rem;
    margin-top: 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    color: #334155;
}

    .result-block span {
        font-size: 1.6rem;
        font-weight: 700;
        color: #0f172a;
        margin-left: 0.5rem;
    }

/* Для страницы метизов (дополнительные стили, не конфликтующие) */
.calculator-card {
    max-width: 680px;
    margin: 0 auto;
}

.select-group {
    margin-bottom: 1.25rem;
}

    .select-group label {
        display: block;
        font-size: 0.875rem;
        font-weight: 500;
        color: #334155;
        margin-bottom: 0.5rem;
    }

.calc-select {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #fff;
    font-size: 0.95rem;
}

/* Адаптивность */
@media (max-width: 768px) {
    .calculator-grid {
        grid-template-columns: 1fr;
    }

    .card-header {
        flex-direction: column;
        align-items: stretch;
    }

    .type-select {
        width: 100%;
    }

    .input-field {
        min-width: 100%;
    }
}
/* ============================================
   Строгий стиль для страницы выбора калькулятора
   ============================================ */
.calculator-select-page {
    padding: 3rem 1rem;
    background: #ffffff;
    min-height: 70vh;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.page-subtitle {
    font-size: 1.1rem;
    color: #64748b;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.5;
    font-weight: 400;
}

.selector-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 400px));
    gap: 2rem;
    justify-content: center;
    margin-bottom: 3rem;
}

.selector-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 2rem 1.8rem;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 1px 3px rgba(0,0,0,0.02);
    transition: border-color 0.15s, box-shadow 0.15s;
    display: flex;
    flex-direction: column;
}

    .selector-card:hover {
        border-color: #2563eb;
        box-shadow: 0 4px 8px -2px rgba(0,0,0,0.05);
    }

.card-icon-wrapper {
    width: 64px;
    height: 64px;
    background: #f1f5f9;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.8rem;
    border: 1px solid #e2e8f0;
}

    .card-icon-wrapper i {
        font-size: 2.2rem;
        color: #2563eb;
    }

.card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

    .card-content h3 {
        font-size: 1.5rem;
        font-weight: 600;
        margin-bottom: 0.75rem;
        color: #0f172a;
        line-height: 1.3;
    }

    .card-content p {
        color: #475569;
        font-size: 0.95rem;
        line-height: 1.6;
        margin-bottom: 1.8rem;
    }

.card-link {
    margin-top: auto;
    font-weight: 500;
    color: #2563eb;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: gap 0.15s;
    font-size: 0.95rem;
}

.selector-card:hover .card-link {
    gap: 10px;
    color: #1d4ed8;
}

.card-link i {
    font-size: 0.85rem;
}

/* Убираем декоративный фон */
.card-bg-pattern {
    display: none;
}

/* Информационный футер */
.info-footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2.5rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: #475569;
    font-size: 0.9rem;
}

    .info-item i {
        font-size: 1.3rem;
        color: #2563eb;
        opacity: 0.8;
    }

/* Адаптивность */
@media (max-width: 768px) {
    .calculator-select-page {
        padding: 2rem 1rem;
    }

    .page-title {
        font-size: 2rem;
    }

    .page-subtitle {
        font-size: 1rem;
    }

    .selector-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .selector-card {
        padding: 1.8rem 1.5rem;
    }

    .card-content h3 {
        font-size: 1.3rem;
    }

    .info-footer {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }
}

@media (max-width: 480px) {
    .page-title {
        font-size: 1.8rem;
    }

    .card-icon-wrapper {
        width: 56px;
        height: 56px;
        border-radius: 10px;
    }

        .card-icon-wrapper i {
            font-size: 2rem;
        }
}
/* ============================================
   Строгий стиль для калькулятора метизов
   ============================================ */
.fasteners-calculator-page {
    padding: 2.5rem 1rem;
    background: #fff;
}

.page-title {
    font-size: 2rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.page-subtitle {
    font-size: 1rem;
    color: #64748b;
    margin-bottom: 2.5rem;
    font-weight: 400;
}

.calculator-card {
    max-width: 680px;
    margin: 0 auto;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.calc-section {
    margin-bottom: 2rem;
}

    .calc-section:last-of-type {
        margin-bottom: 1.5rem;
    }

.select-group {
    margin-bottom: 1.25rem;
}

    .select-group label,
    .input-group label,
    .rounding-group .label {
        display: block;
        font-size: 0.875rem;
        font-weight: 500;
        color: #334155;
        margin-bottom: 0.5rem;
    }

.calc-select {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #fff;
    font-size: 0.95rem;
    color: #0f172a;
    transition: border 0.15s;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1rem;
}

    .calc-select:hover {
        border-color: #94a3b8;
    }

    .calc-select:focus {
        outline: none;
        border-color: #2563eb;
        box-shadow: 0 0 0 2px rgba(37,99,235,0.1);
    }

.input-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.25rem;
}

.calc-input {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 0.95rem;
    color: #0f172a;
    background: #fff;
    transition: border 0.15s;
}

    .calc-input:focus {
        outline: none;
        border-color: #2563eb;
        box-shadow: 0 0 0 2px rgba(37,99,235,0.1);
    }

.rounding-group {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.95rem;
    color: #334155;
    cursor: pointer;
}

    .radio-label input[type="radio"] {
        accent-color: #2563eb;
        width: 16px;
        height: 16px;
        margin: 0;
    }

.result-block {
    background: #f8fafc;
    border-radius: 8px;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
}

.result-title {
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #64748b;
    margin-bottom: 0.5rem;
}

.result-value {
    font-size: 2.5rem;
    font-weight: 600;
    color: #0f172a;
    line-height: 1.2;
}

.result-hint {
    font-size: 0.8rem;
    color: #94a3b8;
    margin-top: 0.5rem;
}
.dev-notice {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.2rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    color: #475569;
    font-size: 0.9rem;
    line-height: 1.5;
}

    .dev-notice i {
        font-size: 1.2rem;
        color: #2563eb;
        opacity: 0.8;
        margin-top: 2px;
    }

    .dev-notice span {
        flex: 1;
    }

.dev-notice-top {
    margin-bottom: 2rem;
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
}
/* Адаптивность */
@media (max-width: 600px) {
    .fasteners-calculator-page {
        padding: 1.5rem 1rem;
    }

    .page-title {
        font-size: 1.6rem;
    }

    .calculator-card {
        padding: 1.5rem;
    }

    .input-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .rounding-group {
        flex-wrap: wrap;
        gap: 1rem;
    }

    .result-value {
        font-size: 2rem;
    }
}