/* App-level styles layered on top of Tailwind (CDN). */

html, body { height: 100%; }

:root {
    --theme-navy: #132f3d;
    --theme-teal: #1f6478;
    --theme-teal-light: #eef7f8;
}

.app-theme {
    background:
        radial-gradient(circle at 100% 0, rgba(31, 100, 120, 0.06), transparent 28rem),
        linear-gradient(135deg, #f8fafc 0%, #f3f7f8 100%);
}

.auth-theme {
    background:
        radial-gradient(circle at 18% 20%, rgba(251, 113, 133, 0.10), transparent 18rem),
        radial-gradient(circle at 82% 78%, rgba(52, 211, 153, 0.10), transparent 20rem),
        linear-gradient(135deg, #f7fbfb 0%, #f6f9fc 55%, #fffaf0 100%);
}

.auth-theme > div {
    filter: drop-shadow(0 18px 28px rgba(19, 47, 61, 0.06));
}

.auth-theme .rounded-2xl {
    border-color: #d6e9e9;
    background: rgba(255, 255, 255, 0.94);
}

.app-theme > .flex > aside {
    box-shadow: 8px 0 24px -24px rgba(19, 47, 61, 0.65);
}

.app-theme header {
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 1px 0 rgba(31, 100, 120, 0.08);
}

.app-theme header h1 {
    color: var(--theme-navy);
}

.app-theme aside > div:first-child > span {
    background: linear-gradient(135deg, #1f6478 0%, #132f3d 100%);
    box-shadow: 0 8px 18px -10px rgba(19, 47, 61, 0.8);
}

.dashboard-card {
    position: relative;
    overflow: hidden;
}

.dashboard-card::before {
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: 4px;
}

.dashboard-card-rose::before { background: #fb7185; }
.dashboard-card-emerald::before { background: #34d399; }
.dashboard-card-brand::before { background: #1f6478; }
.dashboard-card-amber::before { background: #f59e0b; }

.dashboard-card-rose:hover { border-color: #fecdd3; }
.dashboard-card-emerald:hover { border-color: #a7f3d0; }
.dashboard-card-brand:hover { border-color: #acd7dc; }
.dashboard-card-amber:hover { border-color: #fde68a; }

/* Consistent light accents for every application page */
.app-theme main {
    background:
        radial-gradient(circle at 100% 0, rgba(31, 100, 120, 0.035), transparent 24rem),
        transparent;
}

.app-theme main .rounded-2xl.border {
    border-color: #dde8e9;
    box-shadow: 0 10px 24px -20px rgba(19, 47, 61, 0.38);
}

.app-theme main table thead {
    background: #f1f7f7;
}

.app-theme main tbody tr {
    transition: background-color 0.12s ease;
}

.app-theme main tbody tr:hover {
    background: #f7fbfb;
}

.app-theme main input,
.app-theme main select,
.app-theme main textarea {
    background-color: rgba(255, 255, 255, 0.96);
    border-color: #d4e2e4;
}

.app-theme main input:focus,
.app-theme main select:focus,
.app-theme main textarea:focus {
    border-color: #7ebbc4;
    box-shadow: 0 0 0 3px rgba(126, 187, 196, 0.18);
}

.app-theme nav a {
    transition: background-color 0.12s ease, color 0.12s ease, border-color 0.12s ease;
}

.app-theme nav a:hover {
    background: #f1f7f7;
    color: #184f63;
}

.app-theme nav a.bg-brand-50 {
    border-left: 3px solid #4e9dad;
    background: #eef7f8;
}

.app-theme main [type="submit"].rounded-lg,
.app-theme main a.rounded-lg.bg-brand-600 {
    background: linear-gradient(135deg, #2f8093 0%, #1f6478 100%);
    border: 1px solid rgba(19, 47, 61, 0.08);
    box-shadow: 0 8px 16px -12px rgba(19, 47, 61, 0.72);
}

.app-theme main [type="submit"].rounded-lg:hover,
.app-theme main a.rounded-lg.bg-brand-600:hover {
    background: linear-gradient(135deg, #1f6478 0%, #184f63 100%);
}

/* MapLibre popup tweaks */
.maplibregl-popup-content {
    border-radius: 0.75rem;
    padding: 0;
    box-shadow: 0 10px 30px -10px rgba(15, 23, 42, 0.35);
    overflow: hidden;
}
.maplibregl-popup-close-button {
    font-size: 1.1rem;
    padding: 0.25rem 0.5rem;
    color: #64748b;
}

/* Emoji markers */
.kp-marker {
    font-size: 20px;
    line-height: 1;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.35));
    cursor: pointer;
    user-select: none;
}

/* Case dot markers */
.case-marker {
    width: 14px;
    height: 14px;
    border-radius: 9999px;
    border: 2px solid #ffffff;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.45);
    cursor: pointer;
    transition: transform 0.12s ease;
}
.case-marker:hover { transform: scale(1.35); }

/* PS markers */
.ps-marker {
    display: grid;
    place-items: center;
    width: 26px;
    height: 26px;
    border-radius: 9999px;
    background: #1d4ed8;
    color: #fff;
    border: 2px solid #fff;
    box-shadow: 0 1px 5px rgba(15, 23, 42, 0.45);
    cursor: pointer;
}
.ps-marker svg { width: 14px; height: 14px; }

/* Location picker map */
.picker-map { height: 260px; border-radius: 0.75rem; overflow: hidden; }

/* Scrollbar polish */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 9999px; border: 2px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; background-clip: content-box; }
