@import url("https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700&family=Open+Sans:wght@400;600&display=swap");

/* CSS Variables - matching React design */
:root {
    --background: hsl(0, 0%, 98%);
    --foreground: hsl(220, 13%, 18%);
    --card: hsl(0, 0%, 100%);
    --card-foreground: hsl(220, 13%, 18%);
    --primary: hsl(199, 89%, 48%);
    --primary-foreground: hsl(0, 0%, 100%);
    --secondary: hsl(220, 13%, 91%);
    --secondary-foreground: hsl(220, 13%, 18%);
    --muted: hsl(220, 13%, 95%);
    --muted-foreground: hsl(220, 9%, 46%);
    --destructive: hsl(0, 84%, 60%);
    --destructive-foreground: hsl(0, 0%, 100%);
    --border: hsl(220, 13%, 87%);
    --input: hsl(220, 13%, 91%);
    --ring: hsl(199, 89%, 48%);
    --radius: 0.5rem;
}

/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Base styles */
body {
    background: var(--background);
    color: var(--foreground);
    font-family: "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: "Roboto", sans-serif;
    font-weight: 700;
}

input, textarea, select {
    font-family: "Open Sans", sans-serif;
}

/* Gradient background */
.bg-gradient {
    background: linear-gradient(to bottom right, hsl(199, 100%, 97%), hsl(199, 100%, 92%));
    min-height: 100vh;
}

/* Card styles */
.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.card-header {
    padding: 1.5rem;
    border-bottom: 1px solid var(--border);
}

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

.card-description {
    color: var(--muted-foreground);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.card-content {
    padding: 1.5rem;
}

.card-footer {
    padding: 1.5rem;
    border-top: 1px solid var(--border);
}

/* Form elements */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--foreground);
}

.form-control {
    width: 100%;
    padding: 0.625rem 0.75rem;
    background: var(--card);
    border: 1px solid var(--input);
    border-radius: var(--radius);
    font-size: 0.875rem;
    transition: all 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--ring);
    box-shadow: 0 0 0 3px hsla(199, 89%, 48%, 0.1);
}

.form-control.error {
    border-color: var(--destructive);
}

.form-control:disabled {
    background: var(--muted);
    cursor: not-allowed;
}

textarea.form-control {
    min-height: 100px;
    resize: vertical;
}

.form-error {
    color: var(--destructive);
    font-size: 0.75rem;
    margin-top: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Button styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

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

.btn-primary:hover {
    background: hsl(199, 89%, 42%);
    transform: scale(1.02);
}

.btn-outline {
    background: transparent;
    border-color: var(--input);
    color: var(--foreground);
}

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

.btn-sm {
    padding: 0.375rem 0.875rem;
    font-size: 0.8125rem;
}

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

.btn-block {
    width: 100%;
}

/* Badge styles */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: calc(var(--radius) * 0.75);
    white-space: nowrap;
}

.badge-blue {
    background: hsl(199, 89%, 48%);
    color: white;
}

.badge-yellow {
    background: hsl(45, 93%, 47%);
    color: white;
}

.badge-green {
    background: hsl(142, 71%, 45%);
    color: white;
}

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

/* Icon styles */
.icon-circle {
    width: 64px;
    height: 64px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-foreground);
}

/* Table styles */
.table {
    width: 100%;
    border-collapse: collapse;
}

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

.table th {
    font-weight: 600;
    color: var(--muted-foreground);
    font-size: 0.875rem;
}

.table tr:hover {
    background: var(--muted);
    transition: background 0.2s;
}

/* Grid system */
.grid {
    display: grid;
    gap: 1rem;
}

.grid-cols-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-cols-6 {
    grid-template-columns: repeat(6, 1fr);
}

/* Responsive */
@media (max-width: 768px) {
    .grid-cols-2,
    .grid-cols-3,
    .grid-cols-6 {
        grid-template-columns: 1fr;
    }
}

/* Utilities */
.text-center {
    text-align: center;
}

.flex {
    display: flex;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.flex-gap-2 {
    gap: 0.5rem;
}

.flex-gap-4 {
    gap: 1rem;
}

.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.p-4 { padding: 1rem; }

.text-sm {
    font-size: 0.875rem;
}

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

.font-medium {
    font-weight: 500;
}

.font-bold {
    font-weight: 700;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

.container-sm {
    max-width: 500px;
}

.container-md {
    max-width: 768px;
}

.container-lg {
    max-width: 1024px;
}

.container-xl {
    max-width: 1400px;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.4s ease-out;
}

.hover-scale {
    transition: transform 0.2s;
}

.hover-scale:hover {
    transform: scale(1.02);
}

/* Modal/Dialog */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background: var(--card);
    border-radius: var(--radius);
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 1.5rem;
}

.modal-header {
    margin-bottom: 1.5rem;
}

.modal-title {
    font-size: 1.25rem;
    font-weight: 700;
}

/* Alert/Flash messages */
.alert {
    padding: 1rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
}

.alert-success {
    background: hsl(142, 76%, 92%);
    color: hsl(142, 76%, 36%);
    border: 1px solid hsl(142, 76%, 79%);
}

.alert-error {
    background: hsl(0, 93%, 94%);
    color: hsl(0, 84%, 60%);
    border: 1px solid hsl(0, 93%, 82%);
}

/* Checkbox */
input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    cursor: pointer;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.875rem;
}

/* Section divider */
.section-divider {
    border-top: 1px solid var(--border);
    padding-top: 1.5rem;
    margin-top: 1.5rem;
}

.section-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Profile avatar */
.avatar {
    width: 128px;
    height: 128px;
    border-radius: 50%;
    background: hsla(199, 89%, 48%, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 4rem;
}

/* Info block */
.info-block {
    margin-bottom: 1rem;
}

.info-label {
    font-size: 0.875rem;
    color: var(--muted-foreground);
    margin-bottom: 0.25rem;
}

.info-value {
    font-weight: 500;
    color: var(--foreground);
}
