/* Vision Automation Reminder — Dashboard Styles */

/* === Reset & Base === */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #F7F9FC;
    color: #1E293B;
    line-height: 1.5;
    min-height: 100vh;
    padding-bottom: 60px;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* === Header === */
.header {
    background: #0D6EFD;
    color: #fff;
    padding: 16px 0;
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.2);
}

.header-title {
    font-size: 1.3rem;
    font-weight: 600;
    letter-spacing: -0.3px;
}

/* === Cards === */
.card {
    background: #FFFFFF;
    border: 1px solid #D7E2F0;
    border-radius: 10px;
    padding: 24px;
    margin-top: 24px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1E293B;
    margin-bottom: 16px;
}

/* === Add Form === */
.add-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.form-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 140px;
}

.form-group-wide {
    flex: 1 1 100%;
}

.form-group label {
    font-size: 0.8rem;
    font-weight: 500;
    color: #64748B;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.form-group input,
.form-group select {
    padding: 8px 12px;
    border: 1px solid #D7E2F0;
    border-radius: 6px;
    font-size: 0.9rem;
    color: #1E293B;
    background: #FFFFFF;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #0D6EFD;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
}

.radio-group {
    display: flex;
    gap: 16px;
    padding-top: 4px;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9rem;
    cursor: pointer;
    color: #1E293B;
}

.radio-label input[type="radio"] {
    accent-color: #0D6EFD;
}

.form-group-submit {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    flex: 0 0 auto;
}

.form-message {
    margin-top: 8px;
    font-size: 0.85rem;
    min-height: 20px;
}

.form-message.success {
    color: #28A745;
}

.form-message.error {
    color: #DC3545;
}

/* === Buttons === */
.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.btn:active {
    transform: scale(0.97);
}

.btn-primary {
    background: #0D6EFD;
    color: #fff;
}

.btn-primary:hover {
    background: #0B5ED7;
}

.btn-sm {
    padding: 4px 10px;
    font-size: 0.78rem;
}

.btn-toggle {
    background: #E2E8F0;
    color: #475569;
}

.btn-toggle:hover {
    background: #CBD5E1;
}

.btn-danger {
    background: #FEE2E2;
    color: #DC3545;
}

.btn-danger:hover {
    background: #FECACA;
}

/* === Filters === */
.filters {
    display: flex;
    gap: 8px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 6px 14px;
    border: 1px solid #D7E2F0;
    border-radius: 20px;
    background: #FFFFFF;
    color: #64748B;
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-btn:hover {
    border-color: #0D6EFD;
    color: #0D6EFD;
}

.filter-btn.active {
    background: #0D6EFD;
    border-color: #0D6EFD;
    color: #fff;
}

/* === Table === */
.table-wrap {
    overflow-x: auto;
}

.reminders-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

.reminders-table th {
    text-align: left;
    padding: 10px 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: #64748B;
    border-bottom: 2px solid #E2E8F0;
}

.reminders-table td {
    padding: 12px;
    border-bottom: 1px solid #F1F5F9;
    vertical-align: middle;
}

.reminders-table tr:hover {
    background: #F8FAFC;
}

.td-title {
    font-weight: 500;
    color: #1E293B;
}

.td-actions {
    display: flex;
    gap: 6px;
    white-space: nowrap;
}

.empty-state {
    text-align: center;
    color: #94A3B8;
    padding: 40px 12px;
    font-style: italic;
}

/* === Badges === */
.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Repeat badges */
.badge-once { background: #F1F5F9; color: #6C757D; }
.badge-daily { background: #E0F2FE; color: #0D6EFD; }
.badge-weekly { background: #F3E8FF; color: #6F42C1; }
.badge-monthly { background: #FFF3E0; color: #FD7E14; }

/* Priority badges */
.badge-priority-1 { background: #F1F5F9; color: #6C757D; }
.badge-priority-2 { background: #F1F5F9; color: #6C757D; }
.badge-priority-3 { background: #E0F2FE; color: #0D6EFD; }
.badge-priority-4 { background: #FFF3E0; color: #E67E22; }
.badge-priority-5 { background: #FEE2E2; color: #DC3545; }

/* Delivery badges */
.badge-ntfy { background: #E0F2FE; color: #0D6EFD; }
.badge-telegram { background: #E0F7FA; color: #0088CC; }
.badge-both { background: #E8F5E9; color: #28A745; }

/* Status badges */
.badge-active { background: #E8F5E9; color: #28A745; }
.badge-disabled { background: #F1F5F9; color: #94A3B8; }

/* === Status Bar === */
.status-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1E293B;
    color: #CBD5E1;
    padding: 10px 0;
    font-size: 0.78rem;
    z-index: 100;
}

.status-bar-inner {
    display: flex;
    gap: 24px;
    align-items: center;
    flex-wrap: wrap;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #94A3B8;
}

.dot-green { background: #28A745; }
.dot-yellow { background: #FFC107; }
.dot-red { background: #DC3545; }

/* === Responsive === */
@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
    }

    .form-group {
        min-width: 100%;
    }

    .form-group-submit {
        align-items: stretch;
    }

    .btn-primary {
        width: 100%;
    }

    .td-actions {
        flex-direction: column;
    }

    .status-bar-inner {
        justify-content: center;
    }
}


/* User action badges */
.badge-done { background: #E8F5E9; color: #28A745; }
.badge-pending { background: #FFF3E0; color: #E67E22; }
.badge-snoozed { background: #FFF3E0; color: #FD7E14; }

.text-muted {
    color: #94A3B8;
    font-size: 0.75rem;
}
