/**
 * Sistema de Revisão Espaçada (SRS) - Estilos
 */

/* Container principal */
.srs-container {
    max-width: 100%;
    margin: 0 auto;
}

/* Resumo/Estatísticas */
.srs-summary-card {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(59, 130, 246, 0.1));
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.srs-summary-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: rgb(167, 139, 250);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.srs-summary-title i,
.srs-summary-title [data-lucide] {
    width: 1.25rem;
    height: 1.25rem;
}

.srs-summary-content {
    color: rgb(203, 213, 225);
    line-height: 1.7;
    font-size: 0.95rem;
}

/* Grid de KPIs */
.srs-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.srs-stat-card {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(71, 85, 105, 0.5);
    border-radius: 0.5rem;
    padding: 1rem;
    text-align: center;
    transition: all 0.2s;
}

.srs-stat-card:hover {
    border-color: rgba(139, 92, 246, 0.5);
    transform: translateY(-2px);
}

.srs-stat-value {
    font-size: 2rem;
    font-weight: 700;
    display: block;
    margin-bottom: 0.25rem;
}

.srs-stat-label {
    font-size: 0.875rem;
    color: rgb(148, 163, 184);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.srs-stat-card.overdue .srs-stat-value {
    color: rgb(239, 68, 68);
}

.srs-stat-card.urgent .srs-stat-value {
    color: rgb(251, 146, 60);
}

.srs-stat-card.soon .srs-stat-value {
    color: rgb(234, 179, 8);
}

.srs-stat-card.scheduled .srs-stat-value {
    color: rgb(96, 165, 250);
}

/* Filtros */
.srs-filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.srs-filter-group {
    flex: 1;
    min-width: 200px;
}

.srs-filter-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: rgb(203, 213, 225);
    margin-bottom: 0.5rem;
}

.srs-filter-select {
    width: 100%;
    padding: 0.625rem 2rem 0.625rem 0.75rem;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(71, 85, 105, 0.5);
    border-radius: 0.5rem;
    color: rgb(226, 232, 240);
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 12px;
}

.srs-filter-select:hover,
.srs-filter-select:focus {
    outline: none;
    border-color: rgb(139, 92, 246);
    background-color: rgba(15, 23, 42, 0.8);
}

/* Lista de Revisões */
.srs-revisions-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.srs-revision-card {
    background: rgba(15, 23, 42, 0.4);
    border: 1px solid rgba(71, 85, 105, 0.5);
    border-left: 4px solid transparent;
    border-radius: 0.5rem;
    padding: 1rem;
    transition: all 0.2s;
}

.srs-revision-card:hover {
    background: rgba(15, 23, 42, 0.6);
    border-color: rgba(139, 92, 246, 0.5);
    transform: translateX(4px);
}

.srs-revision-card.overdue {
    border-left-color: rgb(239, 68, 68);
}

.srs-revision-card.urgent {
    border-left-color: rgb(251, 146, 60);
}

.srs-revision-card.soon {
    border-left-color: rgb(234, 179, 8);
}

.srs-revision-card.scheduled {
    border-left-color: rgb(96, 165, 250);
}

.srs-revision-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
    gap: 1rem;
}

.srs-revision-title-section {
    flex: 1;
}

.srs-revision-title {
    font-size: 1rem;
    font-weight: 600;
    color: rgb(226, 232, 240);
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.srs-revision-subtitle {
    font-size: 0.875rem;
    color: rgb(148, 163, 184);
}

.srs-revision-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    white-space: nowrap;
}

.srs-revision-badge.overdue {
    background: rgba(239, 68, 68, 0.2);
    color: rgb(239, 68, 68);
}

.srs-revision-badge.urgent {
    background: rgba(251, 146, 60, 0.2);
    color: rgb(251, 146, 60);
}

.srs-revision-badge.soon {
    background: rgba(234, 179, 8, 0.2);
    color: rgb(234, 179, 8);
}

.srs-revision-badge.scheduled {
    background: rgba(96, 165, 250, 0.2);
    color: rgb(96, 165, 250);
}

.srs-revision-info {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
}

.srs-revision-info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: rgb(148, 163, 184);
}

.srs-revision-info-item i,
.srs-revision-info-item [data-lucide] {
    width: 1rem;
    height: 1rem;
    color: rgb(139, 92, 246);
}

/* Timer da Revisão */
.srs-revision-timer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    margin-bottom: 0.75rem;
}

.srs-timer-display-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.srs-timer-icon {
    font-size: 1.5rem;
}

.srs-timer-display {
    font-family: 'Courier New', monospace;
    font-size: 1.5rem;
    font-weight: 700;
    color: rgb(226, 232, 240);
    letter-spacing: 0.05em;
}

.srs-timer-controls {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.srs-timer-btn {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.5rem 0.8rem;
    border-radius: 0.375rem;
    border: 1px solid transparent;
    background: rgba(71, 85, 105, 0.3);
    color: rgb(203, 213, 225);
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.srs-timer-btn i,
.srs-timer-btn [data-lucide] {
    width: 1rem;
    height: 1rem;
}

.srs-timer-btn-label {
    font-size: 0.72rem;
    font-weight: 600;
    line-height: 1;
}

.srs-timer-play-btn {
    background: rgba(34, 197, 94, 0.2);
    border-color: rgba(34, 197, 94, 0.5);
    color: rgb(34, 197, 94);
}

.srs-timer-play-btn:hover {
    background: rgba(34, 197, 94, 0.3);
    border-color: rgb(34, 197, 94);
    transform: translateY(-1px);
}

.srs-timer-pause-btn {
    background: rgba(251, 146, 60, 0.2);
    border-color: rgba(251, 146, 60, 0.5);
    color: rgb(251, 146, 60);
}

.srs-timer-pause-btn:hover {
    background: rgba(251, 146, 60, 0.3);
    border-color: rgb(251, 146, 60);
    transform: translateY(-1px);
}

.srs-timer-stop-btn {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
    color: rgb(239, 68, 68);
}

.srs-timer-stop-btn:hover {
    background: rgba(239, 68, 68, 0.3);
    border-color: rgb(239, 68, 68);
    transform: translateY(-1px);
}

.srs-revision-note {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 0.75rem;
    padding: 0.45rem 0.7rem;
    border-radius: 999px;
    border: 1px solid rgba(59, 130, 246, 0.28);
    background: rgba(37, 99, 235, 0.12);
    color: rgb(147, 197, 253);
    font-size: 0.78rem;
    font-weight: 500;
}

.srs-revision-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

.srs-btn {
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid transparent;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.srs-btn i,
.srs-btn [data-lucide] {
    width: 1rem;
    height: 1rem;
}

.srs-btn-primary {
    background: rgba(139, 92, 246, 0.2);
    border-color: rgba(139, 92, 246, 0.5);
    color: rgb(167, 139, 250);
}

.srs-btn-primary:hover {
    background: rgba(139, 92, 246, 0.3);
    border-color: rgb(167, 139, 250);
    transform: translateY(-1px);
}

.srs-btn-secondary {
    background: rgba(71, 85, 105, 0.2);
    border-color: rgba(71, 85, 105, 0.5);
    color: rgb(148, 163, 184);
}

.srs-btn-secondary:hover {
    background: rgba(71, 85, 105, 0.3);
    border-color: rgb(148, 163, 184);
}

.srs-btn-success {
    background: rgba(34, 197, 94, 0.2);
    border-color: rgba(34, 197, 94, 0.5);
    color: rgb(34, 197, 94);
}

.srs-btn-success:hover {
    background: rgba(34, 197, 94, 0.3);
    border-color: rgb(34, 197, 94);
    transform: translateY(-1px);
}

/* Estado vazio */
.srs-empty-state {
    text-align: center;
    padding: 3rem 1rem;
}

.srs-empty-icon {
    width: 4rem;
    height: 4rem;
    margin: 0 auto 1rem;
    color: rgb(71, 85, 105);
}

.srs-empty-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: rgb(203, 213, 225);
    margin-bottom: 0.5rem;
}

.srs-empty-description {
    font-size: 0.875rem;
    color: rgb(148, 163, 184);
}

/* Widget do Dashboard */
.srs-widget {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.srs-widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.srs-widget-title {
    font-size: 1rem;
    font-weight: 600;
    color: rgb(167, 139, 250);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.srs-widget-title i,
.srs-widget-title [data-lucide] {
    width: 1.125rem;
    height: 1.125rem;
}

.srs-widget-count {
    background: rgba(239, 68, 68, 0.2);
    color: rgb(239, 68, 68);
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 600;
}

.srs-widget-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.srs-widget-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem;
    background: rgba(15, 23, 42, 0.4);
    border-radius: 0.375rem;
    font-size: 0.875rem;
}

.srs-widget-item-name {
    color: rgb(203, 213, 225);
    font-weight: 500;
}

.srs-widget-item-status {
    color: rgb(148, 163, 184);
    font-size: 0.75rem;
}

.srs-widget-item.overdue .srs-widget-item-status {
    color: rgb(239, 68, 68);
    font-weight: 600;
}

.srs-widget-footer {
    text-align: center;
}

.srs-widget-link {
    color: rgb(96, 165, 250);
    font-size: 0.875rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: all 0.2s;
}

.srs-widget-link:hover {
    color: rgb(147, 197, 253);
    text-decoration: underline;
}

.srs-widget-link i,
.srs-widget-link [data-lucide] {
    width: 0.875rem;
    height: 0.875rem;
}

/* Responsividade */
@media (max-width: 768px) {
    .srs-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .srs-filters {
        flex-direction: column;
    }

    .srs-filter-group {
        width: 100%;
    }

    .srs-revision-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .srs-revision-info {
        gap: 1rem;
    }

    .srs-revision-timer {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    .srs-timer-display-container {
        justify-content: center;
    }

    .srs-timer-controls {
        justify-content: center;
    }

    .srs-revision-actions {
        width: 100%;
        justify-content: stretch;
    }

    .srs-btn {
        flex: 1;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .srs-stats-grid {
        grid-template-columns: 1fr;
    }
}

/* Modal Backdrop */
#srs-revision-modal-backdrop {
    overflow-y: auto;
    padding: 1rem;
}

#srs-revision-modal-backdrop:not(.hidden) {
    display: flex !important;
    align-items: center;
    justify-content: center;
}

/* ===== VISUAL REFINEMENTS ===== */

.srs-revision-actions {
    flex-wrap: wrap;
}

.srs-btn {
    min-height: 2.75rem;
    gap: 0.55rem;
    border-radius: 0.8rem;
    box-shadow:
        0 14px 28px rgba(2, 8, 23, 0.18),
        inset 0 0 0 1px rgba(255, 255, 255, 0.03);
}

.srs-btn i,
.srs-btn [data-lucide] {
    width: 1rem;
    height: 1rem;
    flex-shrink: 0;
}

.srs-timer-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 999px;
    background: rgba(59, 130, 246, 0.14);
    color: rgb(125, 211, 252);
}
