/* Component Styles for pgdesktop */

/* Cards */
.card {
    background-color: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: box-shadow 150ms ease, transform 150ms ease;
}

.card-hover:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.card-body {
    color: var(--muted-foreground);
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 9999px;
    line-height: 1;
}

.badge-primary {
    background-color: var(--primary);
    color: var(--primary-foreground);
}

.badge-secondary {
    background-color: var(--secondary);
    color: var(--secondary-foreground);
}

.badge-outline {
    background-color: transparent;
    border: 1px solid var(--border);
    color: var(--foreground);
}

/* Alerts */
.alert {
    position: relative;
    padding: 1rem;
    margin-bottom: 1rem;
    border: 1px solid transparent;
    border-radius: var(--radius);
}

.alert-success {
    background-color: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.3);
    color: #15803d;
}

.alert-info {
    background-color: rgba(28, 138, 219, 0.1);
    border-color: rgba(28, 138, 219, 0.3);
    color: var(--primary);
}

.alert-warning {
    background-color: rgba(234, 179, 8, 0.1);
    border-color: rgba(234, 179, 8, 0.3);
    color: #a16207;
}

.alert-danger {
    background-color: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #b91c1c;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius);
    font-weight: 500;
    cursor: pointer;
    transition: all 150ms ease;
    gap: 0.5rem;
}

.btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

.btn-md {
    padding: 0.5rem 1rem;
    font-size: 1rem;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.125rem;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--primary-foreground);
    border: 1px solid var(--primary);
}

.btn-primary:hover {
    background-color: color-mix(in srgb, var(--primary) 80%, black);
    border-color: color-mix(in srgb, var(--primary) 80%, black);
}

.btn-secondary {
    background-color: var(--secondary);
    color: var(--secondary-foreground);
    border: 1px solid var(--secondary);
}

.btn-secondary:hover {
    background-color: color-mix(in srgb, var(--secondary) 90%, black);
    border-color: color-mix(in srgb, var(--secondary) 90%, black);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: var(--primary-foreground);
}

.btn-ghost {
    background-color: transparent;
    color: var(--foreground);
    border: 1px solid transparent;
}

.btn-ghost:hover {
    background-color: var(--secondary);
}

.btn-destructive {
    background-color: var(--destructive);
    color: var(--destructive-foreground);
    border: 1px solid var(--destructive);
}

.btn-destructive:hover {
    background-color: color-mix(in srgb, var(--destructive) 80%, black);
    border-color: color-mix(in srgb, var(--destructive) 80%, black);
}

.btn-icon {
    padding: 0.5rem;
}

/* Navbars and Menus */
.navbar {
    background-color: var(--background);
    border-bottom: 1px solid var(--border);
    padding: 1rem 0;
}

.navbar-sticky {
    position: sticky;
    top: 0;
    z-index: 50;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--foreground);
}

.navbar-nav {
    display: flex;
    list-style: none;
}

.nav-item {
    margin-right: 1.5rem;
}

.nav-link {
    color: var(--muted-foreground);
    transition: color 150ms ease;
}

.nav-link:hover {
    color: var(--foreground);
}

.nav-link.active {
    color: var(--primary);
}

/* Form Controls */
.form-control {
    width: 100%;
    padding: 0.5rem 1rem;
    background-color: var(--background);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--foreground);
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(28, 138, 219, 0.2);
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-text {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

.form-check {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
}

.form-check-input {
    width: auto;
    margin-right: 0.5rem;
}

/* Tables */
.table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
}

.table th,
.table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.table th {
    font-weight: 600;
}

.table-hover tbody tr:hover {
    background-color: var(--muted);
}

.table-striped tbody tr:nth-child(odd) {
    background-color: var(--muted);
}

/* Tabs */
.tabs {
    display: flex;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1rem;
}

.tab {
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    transition: color 150ms ease, border-color 150ms ease;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
}

.tab:hover {
    color: var(--primary);
}

.tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.tab-content {
    padding: 1rem 0;
}

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

.modal {
    background-color: var(--background);
    border-radius: var(--radius);
    width: 100%;
    max-width: 32rem;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem;
    border-bottom: 1px solid var(--border);
}

.modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.modal-body {
    padding: 1.25rem;
}

.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 1.25rem;
    border-top: 1px solid var(--border);
}

/* Hero sections */
.hero {
    padding: 4rem 0;
    background-color: var(--background);
}

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--muted-foreground);
    margin-bottom: 2rem;
}