/* Soft UI Design System */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;600;700&display=swap');

:root {
    --bg-body: #f8f9fa;
    --bg-card: #f8f9fa;
    --text-main: #344767;
    --text-secondary: #8392ab;
    --primary: #2152ff;
    --primary-hover: #0236eb;
    --danger: #ea0606;
    --success: #82d616;
    --warning: #f53939;

    /* Neumorphic Shadows */
    --shadow-base: 20px 20px 60px #d1d9e6, -20px -20px 60px #ffffff;
    --shadow-inset: inset 5px 5px 10px #d1d9e6, inset -5px -5px 10px #ffffff;
    --shadow-card: 0 20px 27px 0 rgba(0, 0, 0, 0.05);
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);

    --radius: 1rem;
    --radius-sm: 0.5rem;
}

[data-theme="dark"] {
    --bg-body: #1a1a1a;
    --bg-card: #1a1a1a;
    --text-main: #ffffff;
    --text-secondary: #a0a0a0;
    --shadow-base: 10px 10px 20px #0d0d0d, -10px -10px 20px #262626;
    --shadow-inset: inset 5px 5px 10px #0d0d0d, inset -5px -5px 10px #262626;
    --shadow-card: 0 20px 27px 0 rgba(0, 0, 0, 0.2);
}

body {
    font-family: 'Open Sans', sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Soft UI Card */
.card-soft {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-base);
    border: none;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    transition: transform 0.2s ease;
}

/* Inputs - Simplified */
.form-control-soft {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: var(--radius-sm);
    box-shadow: none;
    color: var(--text-main);
    padding: 0.75rem 1rem;
}

.form-control-soft:focus {
    background: #fff;
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(33, 82, 255, 0.25);
    color: var(--text-main);
    outline: none;
}

/* Buttons - Simplified */
.btn-soft-primary {
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 6px rgba(50, 50, 93, 0.11), 0 1px 3px rgba(0, 0, 0, 0.08);
    font-weight: 600;
    transition: all 0.2s ease;
    padding: 0.5rem 1.5rem;
}

.btn-soft-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 7px 14px rgba(50, 50, 93, 0.1), 0 3px 6px rgba(0, 0, 0, 0.08);
    color: white;
}

.btn-soft-danger {
    background: linear-gradient(310deg, #ea0606, #ff667c);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 6px rgba(50, 50, 93, 0.11), 0 1px 3px rgba(0, 0, 0, 0.08);
    padding: 0.5rem 1.5rem;
}

.btn-soft-action {
    background: var(--bg-card);
    color: var(--text-secondary);
    box-shadow: var(--shadow-base);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 0.25rem;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.btn-soft-action:hover {
    color: var(--primary);
    transform: translateY(-2px);
}

/* Table */
.table-soft {
    color: var(--text-main);
    border-collapse: separate;
    border-spacing: 0 0.5rem;
    width: 100%;
}

.table-soft thead th {
    border: none;
    text-transform: uppercase;
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: 700;
    padding: 1rem;
    opacity: 0.7;
}

.table-soft tbody tr {
    background: var(--bg-card);
    box-shadow: var(--shadow-sm);
    border-radius: var(--radius-sm);
    transition: transform 0.2s ease;
}

.table-soft tbody tr:hover {
    transform: scale(1.01);
}

.table-soft td {
    border: none;
    padding: 1rem;
    vertical-align: middle;
}

.table-soft td:first-child {
    border-top-left-radius: var(--radius-sm);
    border-bottom-left-radius: var(--radius-sm);
}

.table-soft td:last-child {
    border-top-right-radius: var(--radius-sm);
    border-bottom-right-radius: var(--radius-sm);
}

/* Sidebar */
.sidebar-soft {
    background: var(--bg-card);
    box-shadow: var(--shadow-base);
    border-radius: var(--radius);
    height: calc(100vh - 2rem);
    margin: 1rem;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
}

.nav-link-soft {
    color: var(--text-secondary);
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    margin-bottom: 0.5rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    font-weight: 600;
    text-decoration: none;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
}

.nav-link-soft:hover,
.nav-link-soft.active {
    background: white;
    box-shadow: var(--shadow-sm);
    color: var(--text-main);
}

.nav-link-soft.active {
    background: white;
    box-shadow: 0 20px 27px 0 rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] .nav-link-soft:hover,
[data-theme="dark"] .nav-link-soft.active {
    background: #2c2c2c;
    color: white;
}

/* Modal - Simplified */
.modal-content-soft {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: 0 15px 35px rgba(50, 50, 93, 0.1), 0 5px 15px rgba(0, 0, 0, 0.07);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 2rem;
}

.modal-header {
    border-bottom: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.modal-footer {
    border-top: none;
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1.5rem;
}

/* Toast */
.toast-soft {
    background: var(--bg-card);
    color: var(--text-main);
    box-shadow: var(--shadow-base);
    border-radius: var(--radius-sm);
    border: none;
    padding: 1rem 2rem;
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1050;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
}

.toast-soft.show {
    transform: translateY(0);
    opacity: 1;
}

.toast-soft.success {
    border-left: 4px solid var(--success);
}

.toast-soft.error {
    border-left: 4px solid var(--danger);
}

/* Utilities */
.text-gradient {
    background: linear-gradient(310deg, #2152ff, #21d4fd);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hidden {
    display: none !important;
}

/* Chart */
.chart-container {
    height: 200px;
    display: flex;
    align-items: flex-end;
    gap: 1rem;
    padding: 1rem 0;
}

.bar-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    justify-content: flex-end;
}

.bar {
    width: 100%;
    background: linear-gradient(310deg, #2152ff, #21d4fd);
    border-radius: 4px 4px 0 0;
    transition: height 0.3s ease;
    min-height: 4px;
}

.bar-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
}
/* Mobile Navigation */
.nav-link-mobile {
    color: var(--text-secondary);
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.nav-link-mobile.active {
    color: var(--primary);
    background: rgba(33, 82, 255, 0.1);
}

.nav-link-mobile:hover {
    color: var(--primary);
}

@media (max-width: 768px) {
    .sidebar-soft {
        display: none;
    }
    
    main {
        padding-bottom: 80px !important; /* Space for bottom nav */
    }
}
