/* Polish layer on top of DaisyUI 5 — elevation, glass, and shell chrome.
   Uses the DaisyUI 5 CSS custom properties (`--color-*`, which hold full
   color values), not the removed v4 `--p`/`--b1` HSL-channel aliases. */

/* ── Base ── */

html {
    scroll-behavior: smooth;
}

*:focus {
    outline: none;
}

a,
button {
    transition: all 0.15s ease;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ── Admin shell ──
   Flat paper: a plain base fill, with the sidebar set one step darker. */

.admin-shell {
    min-height: 100vh;
    background: var(--color-base-100);
}

.admin-shell .drawer-content {
    background: transparent;
}

/* Glass sidebar + mobile navbar */
.glass-panel {
    background: color-mix(in srgb, var(--color-base-100) 85%, transparent);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.admin-shell .drawer-side > aside {
    background: color-mix(in srgb, var(--color-base-200) 95%, transparent);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* ── Nav links ── */

.nav-link {
    border-radius: 0.75rem;
    padding: 0.6rem 0.75rem;
    gap: 0.6rem;
    transition:
        background 0.15s ease,
        color 0.15s ease;
}

.nav-link:hover {
    background: color-mix(in srgb, var(--color-base-300) 60%, transparent);
}

.nav-link.active {
    background: var(--color-base-300);
    color: var(--color-base-content);
}

/* ── Cards ──
   `.card-elevated` is the resting surface (border + soft shadow). The lift on
   hover is handled by `.card-hover` in tailwind.css so the two never fight. */

.card-elevated {
    border-radius: 0.875rem;
    border: 1px solid var(--color-base-300);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

/* ── Buttons ── */

.btn-strong {
    border: 1px solid var(--color-primary);
    font-weight: 500;
}

.btn-strong:hover {
    opacity: 0.86;
}

/* ── Docs cards: feature-card style ── */

.docs-shell .not-prose > div[class*="bg-base-300"] {
    background: color-mix(in srgb, var(--color-base-200) 96%, transparent);
    border: 1px solid
        color-mix(in srgb, var(--color-base-300) 70%, transparent);
    border-radius: 14px;
    padding: 0;
    transition:
        border-color 0.25s,
        transform 0.25s,
        box-shadow 0.25s;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.03),
        0 8px 22px rgba(0, 0, 0, 0.12);
}

.docs-shell .not-prose > div[class*="bg-base-300"]:hover {
    border-color: color-mix(
        in srgb,
        var(--color-base-content) 20%,
        var(--color-base-300) 80%
    );
    transform: translateY(-2px);
    box-shadow:
        0 2px 0 rgba(255, 255, 255, 0.04),
        0 14px 30px rgba(0, 0, 0, 0.2);
}

/* ── Modals ── */

.modal .modal-box.modal-polished {
    border-radius: 1rem;
    border: 1px solid
        color-mix(in srgb, var(--color-base-300) 70%, transparent);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.modal-backdrop {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

/* ── Tables ── */

.table-wrap {
    border-radius: 1rem;
    border: 1px solid
        color-mix(in srgb, var(--color-base-300) 70%, transparent);
    background: color-mix(in srgb, var(--color-base-200) 96%, transparent);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.table-polished thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: color-mix(in srgb, var(--color-base-200) 96%, transparent);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.table-polished tbody tr {
    transition:
        background 160ms ease,
        box-shadow 160ms ease;
}

.table-polished tbody tr:hover {
    background: var(--color-base-200);
}

/* ── Empty state ── */

.empty-state {
    border-radius: 1.5rem;
    border: 1px dashed
        color-mix(in srgb, var(--color-base-300) 70%, transparent);
    background: var(--color-base-200);
}

/* ── oxidt-auth LocalLoginPage hooks (AUTH_MODE=local) ── */
/* The crate's page renders fine without these; they give it the same
   gradient backdrop and glass card as the rest of the template. */

.auth-bg {
    background:
        radial-gradient(color-mix(in oklab, var(--color-base-content) 14%, transparent) 1px, transparent 1.2px) 0 0 / 22px 22px,
        var(--color-base-100);
}

.auth-card {
    background: color-mix(in oklab, var(--color-base-200) 60%, transparent);
    backdrop-filter: blur(24px);
    border: 1px solid color-mix(in oklab, var(--color-base-300) 50%, transparent);
    box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25);
}
