/* FixCalculator Pro - Frontend Styles v3.4.1 */
/* ===== MINT INPUTS + RED CTA BUTTON ===== */

.sfcp-form-root { max-width: 100%; margin: 0 auto; }
.sfcp-loader { text-align: center; padding: 40px 20px; color: #6b7280; font-size: 16px; }

.sfc-form {
    max-width: 640px;
    margin: 0 auto;
    padding: 24px;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.sfc-form h3 {
    margin: 0 0 20px;
    font-size: 24px;
    font-weight: 600;
    color: #111827;
}

.sfc-field { margin-bottom: 16px; }

.sfc-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 14px;
    color: #374151;
}

.sfc-req { color: #ef4444; font-weight: 700; }

/* ========================= */
/* INPUTS (MINT LOOK) */
/* ========================= */

.sfc-control input[type="text"],
.sfc-control input[type="email"],
.sfc-control input[type="number"],
.sfc-control input[type="date"],
.sfc-control input[type="time"],
.sfc-control select,
.sfc-control textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 15px;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    box-sizing: border-box;

    /* мятный еле заметный фон */
    background: #f2fbf7;
}

/* MINT focus (НЕ красный) */
.sfc-control input:focus,
.sfc-control select:focus,
.sfc-control textarea:focus {
    outline: none;
    border-color: #10b981;                 /* mint border */
    box-shadow: 0 0 0 3px rgba(16,185,129,0.15);
    background: #ecfdf5;                   /* чуть ярче при фокусе */
}

/* OPTIONS */
.sfc-opt {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 6px 0;
    padding: 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
}
.sfc-opt:hover { background: #f9fafb; }

.sfc-opt input[type="radio"],
.sfc-opt input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    flex-shrink: 0;
}

/* INVALID (оставляем красным — это ошибка) */
.sfc-invalid > .sfc-control > input,
.sfc-invalid > .sfc-control > select,
.sfc-invalid > .sfc-control > textarea,
input.sfc-invalid {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239,68,68,0.1) !important;
    background: #fff5f5 !important;
}

.sfc-field.sfc-invalid > .sfc-label { color: #ef4444; }
.sfc-field.sfc-invalid .sfc-opt { background: #fef2f2; }

/* MESSAGES (оставим стандарт: ok зелёный, err красный) */
.sfc-msg {
    margin-top: 16px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    min-height: 20px;
}
.sfc-msg:empty { display: none; }

.sfc-msg.ok {
    display: block;
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #10b981;
}

.sfc-msg.err {
    display: block;
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #ef4444;
}

/* CALC FIELD (Celkem и т.п.) — мятный, НЕ красный */
.sfc-calc-field {
    background: #ecfdf5 !important;
    font-weight: 700;
    color: #065f46;
    cursor: default;
    border-color: #a7f3d0 !important;
}

.sfc-calc-suffix {
    display: inline-block;
    margin-left: 8px;
    font-weight: 600;
    color: #6b7280;
    font-size: 14px;
}

.sfc-control { position: relative; }

/* GRID */
.sfc-row-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
.sfc-row-pair > .sfc-field { margin-bottom: 16px; }

/* Multi-step forms */
.sfc-steps { margin-bottom: 40px; }

.sfc-step { display: none; }

.sfc-step.active {
    display: block;
    animation: sfcSlideIn 0.3s ease-out;
}

@keyframes sfcSlideIn {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

/* ========================= */
/* RED CTA BUTTON (только кнопка) */
/* ========================= */

.sfc-step-nav {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
    margin-top: 20px;
}

/* главная CTA */
.sfc-step-nav button {
    padding: 12px 24px;
    border-radius: 8px;
    border: 1px solid #dc2626;
    background: #dc2626;
    color: #ffffff;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.25s ease, border-color 0.25s ease, transform 0.1s ease, box-shadow 0.2s ease;
}

/* hover — ещё краснее/темнее, текст белый */
.sfc-step-nav button:hover {
    background: #991b1b;
    border-color: #991b1b;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateY(-1px);
}

/* active */
.sfc-step-nav button:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

/* secondary — мятная (назад/зrušit и т.п.) */
.sfc-step-nav button.secondary {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #10b981;
}

.sfc-step-nav button.secondary:hover {
    background: #d1fae5;
    border-color: #059669;
    color: #065f46;
}

/* disabled */
.sfc-step-nav button[disabled] {
    opacity: 0.6;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

/* HTML blocks */
.sfc-html {
    padding: 16px;
    background: #f9fafb;
    border-radius: 8px;
    margin: 12px 0;
}

/* Flatpickr overrides */
.sfc-control .flatpickr-input { cursor: pointer; }

/* MOBILE */
@media (max-width: 640px) {
    .sfc-form { padding: 20px 16px; }
    .sfc-step-nav { flex-direction: column-reverse; }
    .sfc-step-nav button { width: 100%; }
    .sfc-row-pair { grid-template-columns: 1fr; gap: 0; }
}
