/* ---------------------------------------------------------------------------
 * SLOMO.TV — contact form styles (IBC2026 landing page).
 *
 * All classes are prefixed with "cf-" so they cannot collide with the site
 * theme. To re-brand, change the variables in .cf-wrap below.
 * If the CMS strips <link> tags, paste this file into the site stylesheet.
 * ------------------------------------------------------------------------- */

.cf-wrap {
    /* Brand variables — adjust here */
    --cf-accent: #111111;
    --cf-accent-contrast: #ffffff;
    --cf-text: #16181d;
    --cf-muted: #6b7280;
    --cf-border: #d7dbe2;
    --cf-border-focus: #111111;
    --cf-bg: #ffffff;
    --cf-bg-soft: #f6f7f9;
    --cf-error: #c0392b;
    --cf-success-bg: #e8f5ec;
    --cf-success-text: #1b5e20;
    --cf-error-bg: #fdecea;
    --cf-error-text: #b3261e;
    --cf-radius: 10px;

    position: relative;
    margin: 28px 0 0;
    max-width: 720px;
    color: var(--cf-text);
}

/* Honeypot field — hidden from humans, visible to naive bots */
.cf-wrap .cf-hp {
    position: absolute !important;
    left: -9999px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.cf-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 20px;
    padding: 24px;
    background: var(--cf-bg);
    border: 1px solid var(--cf-border);
    border-radius: var(--cf-radius);
    box-sizing: border-box;
}

.cf-form *,
.cf-form *::before,
.cf-form *::after {
    box-sizing: border-box;
}

.cf-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.cf-field--wide {
    grid-column: 1 / -1;
}

.cf-field label,
.cf-label {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.35;
    color: var(--cf-text);
}

.cf-req {
    color: var(--cf-error);
    font-weight: 700;
}

.cf-field input[type="text"],
.cf-field input[type="email"],
.cf-field input[type="tel"],
.cf-field textarea {
    width: 100%;
    padding: 12px 14px;
    font: inherit;
    font-size: 16px;
    line-height: 1.4;
    color: var(--cf-text);
    background: var(--cf-bg);
    border: 1px solid var(--cf-border);
    border-radius: 8px;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    -webkit-appearance: none;
    appearance: none;
}

.cf-field textarea {
    min-height: 130px;
    resize: vertical;
}

.cf-field input::placeholder,
.cf-field textarea::placeholder {
    color: var(--cf-muted);
    opacity: 0.75;
}

.cf-field input:focus,
.cf-field textarea:focus {
    border-color: var(--cf-border-focus);
    box-shadow: 0 0 0 3px rgba(17, 17, 17, 0.12);
}

.cf-field input.cf-invalid,
.cf-field textarea.cf-invalid {
    border-color: var(--cf-error);
    box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.12);
}

/* Row state added by the script together with .cf-invalid */
.cf-field.cf-has-error > label,
.cf-field.cf-has-error > .cf-label {
    color: var(--cf-error);
}

.cf-error {
    margin: 0;
    font-size: 13px;
    line-height: 1.4;
    color: var(--cf-error);
}

.cf-error[hidden] {
    display: none;
}

/* Consent row */
.cf-consent {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    line-height: 1.5;
    color: var(--cf-text);
}

.cf-consent input[type="checkbox"] {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    margin: 2px 0 0;
    accent-color: var(--cf-accent);
    cursor: pointer;
}

.cf-consent label {
    font-weight: 400;
    cursor: pointer;
}

.cf-consent a {
    color: inherit;
    text-decoration: underline;
}

.cf-consent input[type="checkbox"].cf-invalid {
    outline: 2px solid var(--cf-error);
    outline-offset: 2px;
    border-radius: 3px;
}

.cf-label-hint,
.cf-muted {
    font-weight: 400;
    color: var(--cf-muted);
}

.cf-note {
    margin: 0;
    font-size: 13px;
    color: var(--cf-muted);
}

/* Submit button */
.cf-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
    grid-column: 1 / -1;
}

.cf-form .cf-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 12px 32px;
    font: inherit;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    color: var(--cf-accent-contrast);
    background: var(--cf-accent);
    border: 1px solid var(--cf-accent);
    border-radius: 999px;
    cursor: pointer;
    transition: opacity 0.15s ease, transform 0.15s ease;
}

.cf-form .cf-submit:hover:not(:disabled):not([aria-disabled="true"]) {
    opacity: 0.88;
}

.cf-form .cf-submit:active:not(:disabled) {
    transform: translateY(1px);
}

.cf-submit:disabled,
.cf-submit[aria-disabled="true"],
.cf-submit[aria-busy="true"] {
    opacity: 0.6;
    cursor: default;
}

/* Status + success messages */
.cf-form .cf-status {
    grid-column: 1 / -1;
    padding: 12px 16px;
    font-size: 14px;
    line-height: 1.5;
    border-radius: 8px;
    background: var(--cf-bg-soft);
    color: var(--cf-text);
}

.cf-form .cf-status[hidden] {
    display: none;
}

.cf-form .cf-status--info {
    background: var(--cf-bg-soft);
    color: var(--cf-text);
}

.cf-form .cf-status--error {
    background: var(--cf-error-bg);
    color: var(--cf-error-text);
}

.cf-form .cf-status--success {
    background: var(--cf-success-bg);
    color: var(--cf-success-text);
}

.cf-wrap .cf-success {
    margin: 0 0 18px;
    padding: 18px 20px;
    font-size: 16px;
    line-height: 1.55;
    background: var(--cf-success-bg);
    color: var(--cf-success-text);
    border-radius: var(--cf-radius);
    outline: none;
}

.cf-wrap .cf-success[hidden] {
    display: none;
}

/* After a successful submission the form is replaced by the success panel */
.cf-wrap.is-submitted .cf-form {
    display: none;
}

/* Responsive: one column on narrow screens */
@media (max-width: 640px) {
    .cf-form {
        grid-template-columns: minmax(0, 1fr);
        padding: 18px;
        gap: 16px;
    }

    .cf-form .cf-submit {
        width: 100%;
    }
}
