:root {
    --primary-dark: #495057;
    --gray-medium: #adb5bd;
    --accent-green: #00d284;
    --bg-light: #f8f9fa;
    --border-light: #e9ecef;
    --glass-effect: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.25) 50%, rgba(255,255,255,0) 100%);
    --shadow: 0 4px 6px rgba(0,0,0,0.05);
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Segoe UI', system-ui, sans-serif; }

body { background-color: var(--bg-light); color: var(--primary-dark); }

/* Authentication Pages */
.auth-container {
    display: flex; justify-content: center; align-items: center; height: 100vh;
}
.auth-card {
    background: #fff; padding: 40px; border-radius: 8px; box-shadow: var(--shadow);
    width: 100%; max-width: 450px; border: 1px solid var(--border-light);
}
.auth-card h2 { margin-bottom: 20px; color: var(--primary-dark); text-align: center; }
.form-group { margin-bottom: 15px; }
.form-group label { display: block; margin-bottom: 5px; font-size: 0.9em; }
.form-control {
    width: 100%; padding: 10px; border: 1px solid var(--gray-medium); border-radius: 4px;
    transition: border-color 0.3s;
}
.form-control:focus { border-color: var(--accent-green); outline: none; }
.btn {
    width: 100%; padding: 12px; background: var(--accent-green); color: #fff;
    border: none; border-radius: 4px; cursor: pointer; font-weight: bold; font-size: 1em;
}
.btn:hover { opacity: 0.9; }

/* Dashboard Layout */
.dashboard-wrapper { display: flex; height: 100vh; overflow: hidden; }

/* Sidebar */
.sidebar {
    width: 260px; background: #fff; border-right: 1px solid var(--border-light);
    display: flex; flex-direction: column;
}
.sidebar-header { padding: 20px; font-size: 1.5em; font-weight: bold; border-bottom: 1px solid var(--border-light); color: var(--accent-green); }
.nav-menu { list-style: none; padding: 20px 0; flex-grow: 1; }
.nav-menu li a {
    display: block; padding: 12px 20px; text-decoration: none; color: var(--primary-dark);
    border-left: 4px solid transparent; transition: all 0.2s;
}
.nav-menu li a:hover, .nav-menu li a.active {
    background: var(--bg-light); border-left-color: var(--accent-green); color: var(--accent-green);
}

/* Main Content */
.main-content { flex-grow: 1; display: flex; flex-direction: column; overflow-y: auto; }

/* Header & Dropdown */
.top-header {
    background: var(--glass-effect); background-color: #fff; padding: 15px 30px;
    display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border-light);
}
.profile-menu { position: relative; cursor: pointer; }
.profile-icon { display: flex; align-items: center; gap: 10px; font-weight: 500; }
.profile-icon img { width: 35px; height: 35px; border-radius: 50%; background: var(--gray-medium); }
.dropdown {
    display: none; position: absolute; right: 0; top: 100%; margin-top: 10px;
    background: #fff; border: 1px solid var(--border-light); box-shadow: var(--shadow);
    border-radius: 4px; min-width: 180px; z-index: 100;
}
.profile-menu:hover .dropdown { display: block; }
.dropdown a { display: block; padding: 10px 15px; text-decoration: none; color: var(--primary-dark); border-bottom: 1px solid var(--bg-light); }
.dropdown a:hover { background: var(--bg-light); color: var(--accent-green); }

/* Ticker */
.ticker-wrap { background: var(--primary-dark); color: #fff; padding: 8px 15px; font-size: 0.9em; }

/* Content Area */
.content-area { padding: 30px; }
.page-title { margin-bottom: 20px; font-size: 1.8em; border-bottom: 2px solid var(--border-light); padding-bottom: 10px; }

/* Responsive Form Grid */
.form-section {
    background: #fff; padding: 25px; border: 1px solid var(--border-light); 
    border-radius: 6px; margin-bottom: 30px; box-shadow: var(--shadow);
}
.section-title {
    font-size: 1.3em; color: var(--primary-dark); margin-bottom: 20px;
    padding-bottom: 10px; border-bottom: 2px solid var(--accent-green);
}
.form-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px;
}
.full-width { grid-column: 1 / -1; }

/* Input Styling */
textarea.form-control { resize: vertical; min-height: 120px; }
.input-with-icon { position: relative; display: flex; align-items: center; }
.input-with-icon input { padding-right: 30px; }
.input-with-icon .icon { position: absolute; right: 10px; color: var(--gray-medium); }
.currency-prefix {
    background: var(--bg-light); border: 1px solid var(--gray-medium); 
    border-right: none; padding: 10px; border-radius: 4px 0 0 4px;
}
.currency-input { border-radius: 0 4px 4px 0 !important; }

/* Radio Button Group */
.radio-group { display: flex; gap: 15px; margin-top: 8px; }
.radio-label {
    display: flex; align-items: center; gap: 5px; font-size: 0.9em; cursor: pointer;
}

/* Sidebar Active State Fix */
.nav-menu li a { display: block; padding: 12px 20px; text-decoration: none; color: var(--primary-dark); }
.nav-menu li a:hover, .nav-menu li a.active {
    background: var(--bg-light); border-left: 4px solid var(--accent-green); color: var(--accent-green);
}
/* Submenu Styling */
.submenu { 
    list-style: none; 
    padding-left: 15px; 
    background: var(--bg-light); 
    overflow: hidden;
}
.submenu li a { 
    padding: 10px 20px; 
    font-size: 0.9em; 
    border-left: 3px solid transparent; 
}
.submenu li a:hover, .submenu li a.active {
    background: #fff;
    border-left-color: var(--accent-green); 
    color: var(--accent-green); 
    font-weight: 500;
}
.has-submenu > a { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
}