/* --- General & Login Page Styles --- */
@import url('https://fonts.googleapis.com/css2?family=Prompt:wght@400;500;700&display=swap');
:root {
--primary-color: #0D47A1;
--primary-dark: #0B3578;
--primary-light: #1565C0;
--text-color: #333;
--text-light: #f4f4f4;
--bg-color: #f9fbfd;
--white-color: #ffffff;
--gray-color: #e0e0e0;
--shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
--border-radius: 12px;
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'Prompt', sans-serif;
background-color: var(--bg-color);
color: var(--text-color);
line-height: 1.6;
}
.login-container {
display: flex;
justify-content: center;
align-items: center;
min-height: 100vh;
background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
padding: 20px;
}
.login-form {
background: var(--white-color);
padding: 40px;
border-radius: var(--border-radius);
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
width: 100%;
max-width: 400px;
text-align: center;
}
.login-form h1 {
margin-bottom: 10px;
color: var(--primary-dark);
}
.login-form p {
margin-bottom: 30px;
color: #777;
}
.input-group {
position: relative;
margin-bottom: 25px;
}
.input-group i {
position: absolute;
left: 15px;
top: 50%;
transform: translateY(-50%);
color: #aaa;
}
.input-group input {
width: 100%;
padding: 12px 12px 12px 45px;
border: 1px solid var(--gray-color);
border-radius: 8px;
font-size: 16px;
transition: border-color 0.3s, box-shadow 0.3s;
}
.input-group input:focus {
outline: none;
border-color: var(--primary-color);
box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.2);
}
.login-form button {
width: 100%;
padding: 12px;
border: none;
background: linear-gradient(45deg, var(--primary-color), var(--primary-light));
color: var(--white-color);
font-size: 18px;
font-weight: 700;
border-radius: 8px;
cursor: pointer;
transition: transform 0.2s, box-shadow 0.3s;
margin-bottom: 20px;
}
.login-form button:hover {
transform: translateY(-2px);
box-shadow: 0 6px 20px rgba(33, 150, 243, 0.4);
}
.forgot-password {
color: var(--primary-dark);
text-decoration: none;
font-size: 14px;
}
.forgot-password:hover {
text-decoration: underline;
}
/* --- Dashboard Styles --- */
.dashboard-container {
display: grid;
grid-template-columns: 260px 1fr;
min-height: 100vh;
transition: grid-template-columns 0.3s ease;
}
/* Sidebar */
.sidebar {
background: linear-gradient(180deg, var(--primary-dark), var(--primary-color));
color: var(--text-light);
display: flex;
flex-direction: column;
position: fixed;
width: 260px;
height: 100%;
transition: transform 0.3s ease-in-out;
}
.sidebar-header {
display: flex;
align-items: center;
padding: 25px 20px;
gap: 15px;
}
.sidebar-header i {
font-size: 28px;
}
.sidebar-header h2 {
font-weight: 700;
font-size: 22px;
}
.sidebar-nav {
flex-grow: 1;
}
.sidebar-nav ul {
list-style: none;
}
.sidebar-nav li a {
display: flex;
align-items: center;
gap: 15px;
padding: 15px 20px;
color: var(--text-light);
text-decoration: none;
font-size: 16px;
margin: 5px 10px;
border-radius: 8px;
transition: background 0.3s, color 0.3s;
}
.sidebar-nav li a i {
width: 20px;
text-align: center;
font-size: 18px;
}
.sidebar-nav li a:hover, .sidebar-nav li.active a {
background: rgba(255, 255, 255, 0.15);
color: var(--white-color);
}
.sidebar-footer {
padding-bottom: 20px;
}
.sidebar-footer a {
display: flex;
align-items: center;
gap: 15px;
padding: 15px 20px;
color: var(--text-light);
text-decoration: none;
font-size: 16px;
margin: 5px 10px;
border-radius: 8px;
transition: background 0.3s, color 0.3s;
}
.sidebar-footer a:hover {
background: rgba(255, 255, 255, 0.1);
}
/* Main Content */
.main-content {
grid-column: 2 / 3;
background-color: var(--bg-color);
padding: 0;
}
.top-nav {
display: flex;
justify-content: space-between;
align-items: center;
padding: 15px 30px;
background-color: var(--white-color);
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
position: sticky;
top: 0;
z-index: 10;
}
.menu-toggle {
display: none;
/* Hidden on desktop */
font-size: 24px;
cursor: pointer;
color: var(--text-color);
}
.search-box {
position: relative;
width: 350px;
}
.search-box i {
position: absolute;
left: 15px;
top: 50%;
transform: translateY(-50%);
color: #aaa;
}
.search-box input {
width: 100%;
padding: 10px 10px 10px 40px;
border: 1px solid var(--gray-color);
border-radius: 20px;
background-color: var(--bg-color);
}
.search-box input:focus {
outline: none;
border-color: var(--primary-color);
background-color: var(--white-color);
}
.user-profile {
display: flex;
align-items: center;
gap: 10px;
cursor: pointer;
}
.user-profile img {
width: 40px;
height: 40px;
border-radius: 50%;
}
main {
padding: 30px;
}
main h1 {
margin-bottom: 20px;
font-size: 28px;
font-weight: 700;
}
.cards-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
gap: 25px;
margin-bottom: 30px;
}
.card {
background-color: var(--white-color);
border-radius: var(--border-radius);
padding: 25px;
display: flex;
align-items: center;
gap: 20px;
box-shadow: var(--shadow);
transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover {
transform: translateY(-5px);
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}
.card-icon {
width: 50px;
height: 50px;
border-radius: 50%;
display: flex;
justify-content: center;
align-items: center;
font-size: 22px;
color: var(--white-color);
}
.card-icon.blue {
background-color: var(--primary-color);
}
.card-icon.green {
background-color: #388E3C;
}
.card-icon.orange {
background-color: #F57C00;
}
.card-icon.red {
background-color: #C62828;
}
/* --- Table Styles --- */
.table-container {
margin-top: 30px;
}
table {
width: 100%;
border-collapse: collapse;
background: var(--white-color);
box-shadow: var(--shadow);
border-radius: var(--border-radius);
overflow: hidden;
margin-bottom: 30px;
}
th, td {
padding: 14px 18px;
text-align: left;
}
th {
background: var(--primary-color);
color: var(--white-color);
font-weight: 600;
}
tr:nth-child(even) {
background: #f4f8fb;
}
tr:hover {
background: var(--primary-light);
color: var(--white-color);
transition: background 0.2s, color 0.2s;
}
/* --- User Profile Dropdown --- */
.user-profile {
position: relative;
}
.user-dropdown {
display: none;
position: absolute;
top: 110%;
right: 0;
background: var(--white-color);
box-shadow: var(--shadow);
border-radius: 8px;
min-width: 160px;
z-index: 1001;
padding: 10px 0;
}
.user-dropdown.active {
display: block;
}
.user-dropdown a {
display: block;
padding: 10px 20px;
color: var(--text-color);
text-decoration: none;
transition: background 0.2s;
}
.user-dropdown a:hover {
background: var(--primary-light);
color: var(--white-color);
}
.card-info h4 {
margin-bottom: 5px;
color: #777;
font-weight: 500;
}
.card-info p {
font-size: 24px;
font-weight: 700;
}
.charts-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
gap: 25px;
}
.chart-container {
background-color: var(--white-color);
padding: 25px;
border-radius: var(--border-radius);
box-shadow: var(--shadow);
max-height: 300px;
}
.chart-container h3 {
margin-bottom: 20px;
text-align: center;
font-weight: 500;
}
canvas {
width: 100%;
height: 200px;
}
/* --- Responsive Design --- */
@media (max-width: 992px) {
.dashboard-container {
grid-template-columns: 80px 1fr;
}
.sidebar {
width: 80px;
}
.sidebar-header h2, .sidebar-nav span, .sidebar-footer span {
display: none;
}
.sidebar-header, .sidebar-nav li a, .sidebar-footer a {
justify-content: center;
}
}
@media (max-width: 768px) {
.dashboard-container {
grid-template-columns: 1fr;
}
.sidebar {
transform: translateX(-100%);
z-index: 1000;
width: 260px;
}
.sidebar.active {
transform: translateX(0);
}
.sidebar.active .sidebar-header h2,
.sidebar.active .sidebar-nav span,
.sidebar.active .sidebar-footer span {
display: inline;
}
.sidebar.active .sidebar-header,
.sidebar.active .sidebar-nav li a,
.sidebar.active .sidebar-footer a {
justify-content: flex-start;
}
.main-content {
grid-column: 1 / -1;
}
.menu-toggle {
display: block;
}
.search-box {
display: none;
/* Or adjust width */
}
.user-profile span {
display: none;
}
main {
padding: 20px;
}
.charts-grid {
grid-template-columns: 1fr;
}
}