/* Client Portal Styles */

.portal-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-dark);
    position: relative;
    overflow: hidden;
}

.portal-container::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: var(--primary-blue);
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.2;
    top: -200px;
    left: -200px;
}

.portal-container::after {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: var(--gold);
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.2;
    bottom: -200px;
    right: -200px;
}

.login-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 24px;
    padding: 48px;
    width: 100%;
    max-width: 450px;
    position: relative;
    z-index: 10;
    box-shadow: var(--shadow-lg);
}

.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-logo {
    width: 60px;
    height: 60px;
    margin-bottom: 16px;
}

.login-header h1 {
    font-size: 32px;
    margin-bottom: 8px;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 16px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
}

.form-group input {
    padding: 14px 16px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: var(--bg-darker);
    color: var(--text-primary);
    font-size: 16px;
    transition: var(--transition);
}

.form-group input:focus {
    outline: none;
    border-color: var(--gold);
    background: var(--bg-dark);
}

.btn-block {
    width: 100%;
    margin-top: 8px;
}

.login-links {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
}

.login-links a {
    color: var(--text-secondary);
}

.login-links a:hover {
    color: var(--gold);
}

/* Dashboard Layout */
.dashboard-container {
    display: flex;
    min-height: 100vh;
    background: var(--bg-dark);
}

.dashboard-sidebar {
    width: 280px;
    background: var(--bg-darker);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 100;
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-header img {
    width: 40px;
    height: 40px;
}

.sidebar-header span {
    font-size: 20px;
    font-weight: 700;
}

.sidebar-nav {
    flex: 1;
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 8px;
    color: var(--text-secondary);
    transition: var(--transition);
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--gold);
    color: var(--bg-dark);
}

.nav-item .icon {
    font-size: 20px;
}

.sidebar-footer {
    padding: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.dashboard-main {
    margin-left: 280px;
    flex: 1;
    padding: 32px;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
}

.dashboard-header h1 {
    font-size: 32px;
    margin-bottom: 4px;
}

.text-secondary {
    color: var(--text-secondary);
}

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

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--gradient-gold);
    color: var(--bg-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

/* Dashboard Stats */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-bottom: 32px;
}

.stat-box {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 24px;
}

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    color: var(--text-secondary);
    font-size: 14px;
}

.stat-icon {
    font-size: 24px;
}

.stat-box .stat-value {
    font-size: 32px;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.stat-change {
    font-size: 14px;
    font-weight: 600;
}

.stat-change.positive {
    color: #00C853;
}

.stat-change.negative {
    color: #FF5252;
}

.stat-change.neutral {
    color: var(--text-secondary);
}

/* Dashboard Cards */
.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}

.dashboard-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 24px;
}

.dashboard-card.large {
    grid-column: span 2;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.card-header h2 {
    font-size: 20px;
}

.link-primary {
    color: var(--gold);
    font-size: 14px;
    font-weight: 600;
}

.link-primary:hover {
    text-decoration: underline;
}

.card-tabs {
    display: flex;
    gap: 8px;
}

.tab {
    padding: 6px 16px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.05);
    border: none;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.tab:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.tab.active {
    background: var(--gold);
    color: var(--bg-dark);
}

.chart-placeholder {
    height: 300px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 2px dashed rgba(255, 255, 255, 0.1);
}

.chart-placeholder p {
    font-size: 18px;
}

/* Activity List */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    transition: var(--transition);
}

.activity-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.activity-icon.buy {
    background: rgba(0, 200, 83, 0.1);
}

.activity-icon.deposit {
    background: rgba(255, 180, 0, 0.1);
}

.activity-details {
    flex: 1;
}

.activity-title {
    font-weight: 600;
    margin-bottom: 4px;
}

.activity-date {
    font-size: 12px;
    color: var(--text-secondary);
}

.activity-amount {
    font-weight: 700;
    color: var(--gold);
}

/* Metrics List */
.metrics-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.metric-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.metric-item:last-child {
    border-bottom: none;
}

.metric-value {
    font-weight: 700;
    color: var(--gold);
}

/* Responsive */
@media (max-width: 1200px) {
    .dashboard-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-card.large {
        grid-column: span 1;
    }
}

@media (max-width: 968px) {
    .dashboard-sidebar {
        width: 70px;
    }
    
    .sidebar-header span,
    .nav-item span:not(.icon) {
        display: none;
    }
    
    .sidebar-header {
        justify-content: center;
    }
    
    .nav-item {
        justify-content: center;
    }
    
    .dashboard-main {
        margin-left: 70px;
    }
}

@media (max-width: 640px) {
    .dashboard-sidebar {
        display: none;
    }
    
    .dashboard-main {
        margin-left: 0;
        padding: 16px;
    }
    
    .dashboard-stats {
        grid-template-columns: 1fr;
    }
    
    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
}
