/* Uno Forms — runtime CSS shipped with the plugin. */

/* Hide content until Alpine resolves x-show/x-cloak so users don't see a
   pre-render flash of the success banner or error slots. */
[x-cloak] { display: none !important; }

/* Honeypot — visually hidden via the standard sr-only offscreen pattern so
   bots that skip `display: none` elements still fill the trap. */
.uno-form-hp {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
    left: -9999px;
}

/* Success state: hide every direct child of the form EXCEPT the banner. */
form[data-uno-form][data-state="success"] > *:not(.uno-form-success) {
    display: none !important;
}

/* Default success banner — Pencil "Request sent" layout: lime check inside
   a glowing circle, large title, muted body. Theme authors can override any
   of these by targeting `.uno-form-success` from their own stylesheet. */
.uno-form-success {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 16px;
    min-height: 320px;
    padding: 40px 24px;
    color: #eef0e8;
}
.uno-form-success__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 9999px;
    background: #a8d96c;
    color: #0d2318;
    box-shadow: 0 0 32px 4px rgba(168, 217, 108, 0.45);
    margin-bottom: 8px;
}
.uno-form-success__title {
    margin: 0;
    font-family: 'Inter Tight', system-ui, sans-serif;
    font-weight: 400;
    font-size: 28px;
    line-height: 1.2;
    color: #eef0e8;
}
.uno-form-success__body {
    margin: 0;
    max-width: 38ch;
    font-family: 'Inter', 'DM Sans', system-ui, sans-serif;
    font-weight: 300;
    font-size: 14px;
    line-height: 1.5;
    color: rgba(238, 240, 232, 0.7);
}
/* Empty-title support: when no title is set, drop its row entirely. */
.uno-form-success__title:empty { display: none; }
.uno-form-success__body:empty  { display: none; }

/* Inline field error slots — Alpine drives x-show/x-text. */
.uno-form-error {
    color: #d33;
    font-size: 13px;
    margin-top: 6px;
}
.uno-form-error--top {
    margin: 0 0 12px;
    font-size: 14px;
}
