/* bagarino.my — custom utilities on top of Tailwind CDN.
   Anything that needs to feel like a "component" lives here. */

/* === Forms ============================================================ */
/* Style raw Django-rendered form widgets so we don't have to override
   them on every form. Anything matching one of these selectors gets a
   Tailwind-style input look. */
.bm-form input[type="text"],
.bm-form input[type="email"],
.bm-form input[type="password"],
.bm-form input[type="tel"],
.bm-form input[type="number"],
.bm-form input[type="url"],
.bm-form textarea,
.bm-form select {
    width: 100%;
    padding: 0.5rem 0.75rem;
    background-color: #fff;
    color: #111827;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    line-height: 1.25rem;
    transition: border-color .15s, box-shadow .15s;
}
.dark .bm-form input[type="text"],
.dark .bm-form input[type="email"],
.dark .bm-form input[type="password"],
.dark .bm-form input[type="tel"],
.dark .bm-form input[type="number"],
.dark .bm-form input[type="url"],
.dark .bm-form textarea,
.dark .bm-form select {
    background-color: #374151;
    color: #f9fafb;
    border-color: #4b5563;
}
.bm-form input:focus,
.bm-form textarea:focus,
.bm-form select:focus {
    outline: none;
    border-color: rgb(var(--tw-color-brand-500, 253 107 5));
    box-shadow: 0 0 0 3px rgb(253 107 5 / 0.18);
}
.bm-form label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.25rem;
}
.dark .bm-form label { color: #d1d5db; }

.bm-form .errorlist {
    list-style: none;
    margin: 0 0 0.5rem 0;
    padding: 0;
    color: #b91c1c;
    font-size: 0.75rem;
}
.dark .bm-form .errorlist { color: #fca5a5; }

.bm-form .helptext {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: #6b7280;
}

/* === Buttons ========================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 0.5rem;
    border: 1px solid transparent;
    cursor: pointer;
    transition: background-color .15s, border-color .15s, color .15s;
    text-decoration: none;
}
.btn-primary { background-color: #fd6b05; color: #fff; }
.btn-primary:hover { background-color: #ea580c; }
.btn-secondary { background-color: #f3f4f6; color: #111827; border-color: #e5e7eb; }
.dark .btn-secondary { background-color: #374151; color: #f9fafb; border-color: #4b5563; }
.btn-secondary:hover { background-color: #e5e7eb; }
.dark .btn-secondary:hover { background-color: #4b5563; }
.btn-danger { background-color: #dc2626; color: #fff; }
.btn-danger:hover { background-color: #b91c1c; }
.btn-success { background-color: #16a34a; color: #fff; }
.btn-success:hover { background-color: #15803d; }
.btn-ghost { background-color: transparent; color: #4b5563; }
.dark .btn-ghost { color: #9ca3af; }
.btn-ghost:hover { background-color: #f3f4f6; color: #111827; }
.dark .btn-ghost:hover { background-color: #374151; color: #f9fafb; }

/* === Cards / Tables =================================================== */
.bm-card {
    background-color: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    box-shadow: 0 1px 2px rgb(0 0 0 / 0.04);
}
.dark .bm-card {
    background-color: #1f2937;
    border-color: #374151;
}
