.dashboard {
    padding: 100px 0 40px;
}

.dashboard-header {
    display: flex;
    align-items: flex-end;
    gap: 2rem;
    margin-bottom: 2rem;
    padding-top: 1rem;
}

.org-selector {
    flex: 0 0 400px;
}

.org-selector label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.org-selector select {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
}

.summary-cards {
    display: flex;
    gap: 1rem;
    flex: 1;
}

.card {
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px var(--shadow);
    flex: 1;
    max-width: 200px;
}

.card h3 {
    color: var(--text);
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.card p {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary);
}

.pr-list {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px var(--shadow);
}

.pr-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.pr-list-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.pr-list-header h2 {
    font-size: 1.5rem;
    color: var(--text);
}

#prFilter {
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    width: 300px;
}

#prList {
    min-height: 200px;
}

.pr-item {
    padding: 0.5rem;
    border-bottom: 1px solid #eee;
    transition: background-color 0.2s ease;
}

.pr-item:last-child {
    border-bottom: none;
}

.pr-item:hover {
    background-color: #f8f9fa;
}

.pr-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.25rem;
}

.pr-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--text);
    flex: 1;
}

.pr-header h3 a {
    color: var(--text);
    text-decoration: none;
    transition: color 0.2s ease;
}

.pr-header h3 a:hover {
    color: var(--primary);
}

.pr-header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.pr-status {
    font-size: 0.85rem;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-weight: 500;
}

.pr-status.open {
    background-color: #e6f4ea;
    color: #1e7e34;
}

.pr-status.draft {
    background-color: #f1f3f4;
    color: #666;
}

.pr-status.closed {
    background-color: #fce8e6;
    color: #c5221f;
}

.pr-details {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.25rem;
    font-size: 0.9rem;
    color: #666;
}

.pr-details a {
    color: #666;
    text-decoration: none;
    transition: color 0.2s ease;
}

.pr-details a:hover {
    color: var(--primary);
}

.pr-participants {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0;
}

.participant {
    font-size: 0.85rem;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    background-color: #f1f3f4;
    color: #666;
}

.participant.approved {
    background-color: #e6f4ea;
    color: #1e7e34;
}

.pr-actions {
    display: flex;
    align-items: center;
}

.review-required {
    color: #ff8f00;
    font-weight: 500;
    background: #fff3e0;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.85rem;
}

.loading-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    color: #666;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Remove default link styling */
a {
    color: inherit;
    text-decoration: none;
}

a:visited {
    color: inherit;
}

a:hover {
    color: inherit;
}

a:active {
    color: inherit;
}

.text-link {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.text-link:hover {
    opacity: 0.7;
}

.pr-item a.text-link:hover,
.pr-item h3 a.text-link:hover {
    opacity: 0.7;
    color: var(--text) !important;
}

/* Review button states */
.btn-review {
    transition: all 0.2s ease;
}

.btn-review:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.btn-review.loading {
    background-color: #f0f0f0;
    color: #666;
}

.btn-review.reviewed {
    background-color: #e6f4ea;
    color: #1e7e34;
    border-color: #c3e6cb;
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    max-width: 500px;
    width: 100%;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.modal-content h2 {
    margin-top: 0;
    color: #333;
}

.modal-content p {
    margin: 1rem 0;
    color: #666;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1.5rem;
}

.modal-actions .btn {
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    font-weight: 500;
}

.modal-actions .btn-secondary {
    background: #f0f0f0;
    border: 1px solid #ddd;
    color: #333;
}

.modal-actions .btn-primary {
    background: #2ea44f;
    border: 1px solid #2ea44f;
    color: white;
}

.modal-actions .btn:hover {
    opacity: 0.9;
}

/* Model options styling */
.model-options {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1rem 0;
}

.model-options label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;  /* Prevent text selection when tapping */
}

.model-options label:hover {
    background: #f5f5f5;
}

.model-options input[type="radio"] {
    margin: 0;
}

.model-options input[type="radio"]:checked + span {
    font-weight: 500;
    color: var(--primary);
}

/* Responsive styles */
@media (max-width: 768px) {
    .dashboard {
        padding: 100px 0 20px;
    }

    .dashboard-header {
        flex-direction: column;
        align-items: stretch;
    }

    .org-selector {
        flex: none;
        width: 100%;
    }

    .summary-cards {
        display: none;
    }

    .pr-list-header {
        flex-direction: column;
        gap: 1rem;
    }

    .pr-list-controls {
        flex-direction: column;
        width: 100%;
    }

    #prFilter {
        width: 100%;
    }

    .pr-details {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .modal-content {
        margin: 1rem;
        width: calc(100% - 2rem);
    }
}
