/* Lead Magnet Manager — Front-end Form Styles */

.lmm-wrapper { max-width: 680px; }

.lmm-title {
    margin-bottom: 20px;
}

/* ---- Form layout ---- */
.lmm-form {
    background: #fff;
    padding: 32px;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,.08);
}

.lmm-row {
    display: flex;
    gap: 16px;
}

.lmm-row-2 > .lmm-field-group { flex: 1; min-width: 0; }

@media ( max-width: 540px ) {
    .lmm-row { flex-direction: column; gap: 0; }
    .lmm-form { padding: 20px; }
}

/* ---- Fields ---- */
.lmm-field-group {
    margin-bottom: 18px;
    position: relative;
}

.lmm-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #1d2327;
    margin-bottom: 5px;
}

.lmm-required { color: #d63638; margin-left: 2px; }

.lmm-input {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 10px 14px;
    font-size: 15px;
    line-height: 1.4;
    color: #1d2327;
    background: #f9f9f9;
    border: 1.5px solid #c3c4c7;
    border-radius: 5px;
    transition: border-color .15s, box-shadow .15s;
    appearance: none;
    -webkit-appearance: none;
}

.lmm-input:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 2px rgba(34,113,177,.15);
    background: #fff;
}

.lmm-input.lmm-invalid {
    border-color: #d63638;
    box-shadow: 0 0 0 2px rgba(214,54,56,.12);
}

.lmm-field-error {
    display: block;
    font-size: 12px;
    color: #d63638;
    margin-top: 4px;
    min-height: 16px;
}

/* ---- Checkboxes ---- */
.lmm-checkbox-group { margin-bottom: 14px; }

.lmm-checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: 14px;
    color: #3c434a;
    line-height: 1.5;
}

.lmm-checkbox {
    flex-shrink: 0;
    margin-top: 2px;
    width: 17px;
    height: 17px;
    accent-color: #2271b1;
    cursor: pointer;
}

.lmm-checkbox-text a {
    color: #2271b1;
    text-decoration: underline;
}

/* ---- Form-level error banner ---- */
.lmm-form-error {
    background: #fff0f0;
    border: 1px solid #d63638;
    color: #d63638;
    padding: 10px 14px;
    border-radius: 5px;
    font-size: 14px;
    margin-bottom: 16px;
}

/* ---- Submit button ---- */
.lmm-submit-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #2271b1;
    color: #fff;
    border: none;
    padding: 13px 28px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 5px;
    cursor: pointer;
    transition: background .15s, transform .1s;
    width: 100%;
    justify-content: center;
    margin-top: 6px;
}

.lmm-submit-btn:hover:not(:disabled) { background: #135e96; }
.lmm-submit-btn:active:not(:disabled) { transform: scale(.99); }

.lmm-submit-btn:disabled {
    opacity: .7;
    cursor: not-allowed;
}

/* Spinner */
.lmm-btn-spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2.5px solid rgba(255,255,255,.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: lmm-spin .6s linear infinite;
    flex-shrink: 0;
}

.lmm-submit-btn.lmm-loading .lmm-btn-spinner { display: inline-block; }
.lmm-submit-btn.lmm-loading .lmm-btn-text    { opacity: .8; }

@keyframes lmm-spin { to { transform: rotate(360deg); } }

/* ---- Form note ---- */
.lmm-form-note {
    font-size: 12px;
    color: #787c82;
    margin: 10px 0 0;
    text-align: center;
}

/* ---- Honeypot ---- */
.lmm-hp-field {
    position: absolute;
    left: -9999px;
    visibility: hidden;
    height: 0;
    overflow: hidden;
}

/* ---- Success state ---- */
.lmm-success {
    text-align: center;
    padding: 48px 32px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,.08);
}

.lmm-success-icon {
    width: 60px;
    height: 60px;
    background: #00a32a;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    margin: 0 auto 20px;
}

.lmm-success-title {
    font-size: 22px;
    font-weight: 700;
    color: #1d2327;
    margin: 0 0 10px;
}

.lmm-success-msg {
    font-size: 16px;
    color: #50575e;
    margin: 0;
}

/* ---- Admin notice (visible only to admins) ---- */
.lmm-admin-notice {
    padding: 12px 14px;
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 4px;
    font-size: 13px;
    font-family: monospace;
}
