/* ── Dashboard cards ───────────────────────────────────────────── */
#dashboard .card {
    border-radius: 1.125rem;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    cursor: pointer;
    border: none;
}

#dashboard .card.bg-success {
    background: linear-gradient(135deg, #14532d 0%, #16a34a 100%) !important;
}

#dashboard .card.bg-warning {
    background: linear-gradient(135deg, #78350f 0%, #b45309 100%) !important;
    color: white !important;
}

#dashboard .card.bg-warning .text-dark,
#dashboard .card.bg-warning .card-title {
    color: rgba(255, 255, 255, 0.95) !important;
}

#dashboard .card.bg-primary {
    background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%) !important;
}

#dashboard .card.bg-info {
    background: linear-gradient(135deg, #164e63 0%, #0891b2 100%) !important;
    color: white !important;
}

#dashboard .card.bg-info .text-dark,
#dashboard .card.bg-info .card-title {
    color: rgba(255, 255, 255, 0.95) !important;
}

#dashboard .card:hover {
    transform: translateY(-4px);
    box-shadow: 0 1rem 2rem rgba(0, 0, 0, 0.2);
}

#dashboard .card.dashboard-active {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%) !important;
    color: white;
    transform: translateY(-4px);
    box-shadow: 0 0.75rem 1.5rem rgba(79, 70, 229, 0.4);
}

#dashboard .card.dashboard-active .text-muted,
#dashboard .card.dashboard-active .text-dark,
#dashboard .card.dashboard-active .card-title {
    color: rgba(255, 255, 255, 0.9) !important;
}

#dashboard .card-body {
    padding: 1.4rem 1.5rem;
}

#dashboard h2 {
    font-size: 2.1rem;
    font-weight: 700;
    margin-top: 0.4rem;
    margin-bottom: 0;
    letter-spacing: -0.02em;
}

#dashboard .card:last-child.dashboard-active {
    outline-color: #17a2b8;
}

/* ── Toast notifications ──────────────────────────────────────── */
#toast-container {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 1090;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
    max-width: 300px;
}

.app-toast {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 500;
    line-height: 1.35;
    box-shadow: 0 2px 10px rgba(0,0,0,0.12);
    pointer-events: auto;
    opacity: 0;
    transform: translateX(16px);
    transition: opacity 0.18s ease, transform 0.18s ease;
    border: 1px solid transparent;
}

.app-toast--in  { opacity: 1; transform: translateX(0); }
.app-toast--out { opacity: 0; transform: translateX(16px); }

.app-toast--success { background: #f0fdf4; color: #166534; border-color: #bbf7d0; }
.app-toast--info    { background: #f0f9ff; color: #075985; border-color: #bae6fd; }
.app-toast--warning { background: #fffbeb; color: #92400e; border-color: #fde68a; }
.app-toast--danger,
.app-toast--error   { background: #fef2f2; color: #991b1b; border-color: #fecaca; }

.app-toast__icon { font-size: 0.85rem; flex-shrink: 0; }
.app-toast__msg  { flex: 1; }

.app-toast__close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border: none;
    background: none;
    opacity: 0.5;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
    font-size: 0.85rem;
    color: inherit;
    border-radius: 4px;
    transition: opacity 0.15s;
}

.app-toast__close:hover { opacity: 1; }

@media (max-width: 1023.98px) {
    #toast-container {
        top: 12px;
        left: 12px;
        right: 12px;
        max-width: none;
        gap: 10px;
    }

    .app-toast {
        gap: 10px;
        padding: 12px 14px;
        border-radius: 12px;
        font-size: 0.95rem;
        line-height: 1.45;
        box-shadow: 0 8px 24px rgba(15, 23, 42, 0.16);
    }

    .app-toast__icon {
        font-size: 1rem;
    }

    .app-toast__close {
        width: 24px;
        height: 24px;
        font-size: 1rem;
        border-radius: 6px;
    }
}

/* ── Board settings table ─────────────────────────────────────── */
#board-statuses-list .table th,
#board-statuses-list .table td {
    vertical-align: middle;
    padding: 0.4rem 0.5rem;
}

#board-statuses-list .board-status-key {
    font-family: monospace;
    font-size: 0.82rem;
    color: #555;
}

/* ── Billing banner ───────────────────────────────────────────── */
.billing-status-banner {
    display: none;
    align-items: center;
    justify-content: space-between;
    gap: 0.7rem;
    margin: 0.85rem 1rem 0;
    padding: 0.85rem 1rem;
    border: 1px solid transparent;
    border-radius: 12px;
    background: #fef9ee;
    color: #92400e;
}

.billing-status-banner.is-visible {
    display: flex;
}

.billing-status-banner--warning {
    background: #fef9ee;
    border-color: #fde68a;
    color: #92400e;
}

.billing-status-banner--danger {
    background: #fee2e2;
    border-color: #fca5a5;
    color: #991b1b;
}

.billing-status-banner__copy {
    display: flex;
    gap: 0.6rem;
    align-items: flex-start;
    min-width: 0;
}

.billing-status-banner__icon {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(245, 158, 11, 0.12);
    flex: 0 0 auto;
    color: #b45309;
    font-size: 0.95rem;
}

.billing-status-banner--danger .billing-status-banner__icon {
    background: rgba(239, 68, 68, 0.12);
    color: #b91c1c;
}

.billing-status-banner__title {
    font-size: 0.86rem;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 0.12rem;
}

.billing-status-banner__text {
    line-height: 1.45;
    font-size: 0.82rem;
}

.billing-status-banner__action {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    border: 1px solid rgba(146, 64, 14, 0.18);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.72);
    color: inherit;
    padding: 0.54rem 0.78rem;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.13s, border-color 0.13s, transform 0.13s;
    flex: 0 0 auto;
}

.billing-status-banner__action:hover {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(146, 64, 14, 0.3);
    transform: translateY(-1px);
}

.billing-status-banner--danger .billing-status-banner__action {
    border-color: rgba(153, 27, 27, 0.16);
}

@media (max-width: 1023.98px) {
    .billing-status-banner {
        margin: 0.7rem 0.75rem 0;
        padding: 0.8rem 0.9rem;
    }

    .billing-status-banner {
        align-items: flex-start;
    }

    .billing-status-banner__action {
        margin-left: auto;
    }
}
