/* Admin Styling - Curated Canvas Inspired */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
    --primary-blue: #0d47ff; /* Deeper vibrant blue */
    --primary-blue-hover: #0a35db;
    --bg-color: #f7f9fa;
    --card-bg: #ffffff;
    --text-main: #141619;
    --text-muted: #6b7280;
    --sidebar-width: 240px;
    --border-color: #e5e7eb;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --radius-md: 12px;
    --radius-lg: 16px;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background-color: var(--card-bg);
    border-right: 1px solid var(--border-color);
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 100;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 40px;
    padding: 0 12px;
}
.brand span {
    color: var(--text-muted);
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    display: block;
    margin-top: 2px;
}

.nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-links a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
}

.nav-links a:hover, .nav-links a.active {
    background-color: var(--bg-color);
    color: var(--primary-blue);
}

.nav-links a.active {
    background-color: #edf2ff;
}

/* User Profile in Sidebar */
.user-profile {
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 12px;
    border-top: 1px solid var(--border-color);
}
.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--text-main);
}
.user-info .name {
    font-size: 0.875rem;
    font-weight: 600;
}
.user-info .role {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 32px 48px;
}

/* Header row (Title and actions) */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
}

h1 {
    font-size: 1.875rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.top-bar-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-bar {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 8px 16px;
    font-size: 0.875rem;
    width: 250px;
    outline: none;
}

.btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.btn-primary {
    background-color: var(--primary-blue);
    color: white;
}
.btn-primary:hover {
    background-color: var(--primary-blue-hover);
}
.btn-outline {
    background-color: white;
    border: 1px solid var(--border-color);
    color: var(--text-main);
}
.btn-outline:hover {
    background-color: var(--bg-color);
}

/* Cards */
.card {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 32px;
}

/* Dashboard Stats */
.stat-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.stat-card .value {
    font-size: 2.5rem;
    font-weight: 700;
    margin-top: 8px;
}
.stat-card .label {
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
}
.stat-card .icon-box {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background-color: #edf2ff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-blue);
}

/* Project Grid */
.grid-projects {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.project-card {
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.project-img {
    width: 100%;
    height: 200px;
    background-color: #2c2f33; /* Placeholder color before img loads */
    object-fit: cover;
}

.project-info {
    padding: 16px;
}
.project-title {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 4px;
}
.project-subtitle {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    font-weight: 600;
}
.project-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}
.icon-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-muted);
}
.icon-btn:hover {
    background: white;
    color: var(--text-main);
}

/* Auth Pages (Login) */
.auth-wrapper {
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-color);
}
.auth-card {
    background: white;
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    width: 100%;
    max-width: 400px;
}
.auth-card h2 {
    margin-bottom: 24px;
    font-size: 1.5rem;
    text-align: center;
}
.form-group {
    margin-bottom: 16px;
}
.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 8px;
    color: var(--text-main);
}
.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.875rem;
    outline: none;
}
.form-control:focus {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(13, 71, 255, 0.1);
}
.btn-block {
    width: 100%;
    justify-content: center;
}

/* Forms general */
.edit-section {
    background: #fdfdfd;
    padding: 24px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    margin-bottom: 20px;
}
.section-title {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 16px;
    letter-spacing: 0.05em;
}
