:root {
    --bg-dark: #0f172a;
    --bg-darker: #020617;
    --glass-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --danger: #ef4444;
}

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

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, var(--bg-dark), var(--bg-darker));
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* View transitions */
.view-container {
    display: none;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.view-container.active {
    display: flex;
    opacity: 1;
}

/* Login View */
#login-view {
    justify-content: center;
    align-items: center;
    height: 100vh;
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

.login-panel {
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-panel h1 {
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.login-panel p {
    color: var(--text-muted);
    margin-bottom: 2rem;
    font-size: 0.9rem;
}

/* Form Elements */
.input-group {
    display: flex;
    flex-direction: column;
    text-align: left;
    margin-bottom: 1.5rem;
}

.input-group label {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: var(--text-main);
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}

input:focus {
    border-color: var(--primary);
}

.btn {
    width: 100%;
    padding: 0.75rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

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

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

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

.outline-btn {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--glass-border);
    width: auto;
    padding: 0.5rem 1rem;
}

.outline-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}

.error-msg {
    color: var(--danger);
    font-size: 0.85rem;
    margin-top: 1rem;
    min-height: 1.2rem;
}

/* Dashboard View */
#dashboard-view {
    flex-direction: column;
    min-height: 100vh;
}

.glass-header {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dashboard-content {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

/* Table styling */
.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

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

th {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.9rem;
}

tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

/* Pagination */
.pagination-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--glass-border);
}

.pagination-controls .btn {
    width: auto;
    padding: 0.5rem 1rem;
}

.pagination-controls .btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-info {
    font-size: 0.9rem;
    color: var(--text-muted);
}
