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

:root {
    /* Microsoft Fluent Design Colors */
    --primary-color: #0078d4;
    --primary-hover: #106ebe;
    --primary-pressed: #005a9e;
    --secondary-color: #00b7c3;
    --success-color: #107c10;
    --danger-color: #d13438;
    --warning-color: #ffb900;
    --text-primary: #323130;
    --text-secondary: #605e5c;
    --text-tertiary: #8a8886;
    --border-color: #edebe9;
    --bg-primary: #ffffff;
    --bg-secondary: #faf9f8;
    --bg-tertiary: #f3f2f1;
    --shadow-light: 0 1.6px 3.6px 0 rgba(0,0,0,0.132), 0 0.3px 0.9px 0 rgba(0,0,0,0.108);
    --shadow-medium: 0 3.2px 7.2px 0 rgba(0,0,0,0.132), 0 0.6px 1.8px 0 rgba(0,0,0,0.108);
    --shadow-large: 0 6.4px 14.4px 0 rgba(0,0,0,0.132), 0 1.2px 3.6px 0 rgba(0,0,0,0.108);
}

body {
    font-family: 'Segoe UI', 'Segoe UI Web', -apple-system, BlinkMacSystemFont, 'Roboto', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-secondary);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header & Navigation */
header {
    background: var(--bg-primary);
    box-shadow: var(--shadow-light);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    padding: 0.75rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    color: var(--primary-color);
    font-size: 1.75rem;
    font-weight: 600;
    letter-spacing: -0.5px;
}

.logo .tagline {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: -4px;
    font-weight: 400;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

.nav-links a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

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

/* Hero Section - New Layout */
.hero {
    background: linear-gradient(135deg, #0078d4 0%, #00b7c3 100%);
    min-height: calc(100vh - 80px);
    padding: 60px 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 40%;
    height: 100%;
    background: rgba(255, 255, 255, 0.05);
    transform: skewX(-15deg);
    transform-origin: top;
}

.hero-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 60px;
    align-items: start;
    position: relative;
    z-index: 1;
}

/* Login Card */
.hero-login {
    position: sticky;
    top: 100px;
}

.login-card {
    background: var(--bg-primary);
    border-radius: 8px;
    padding: 32px;
    box-shadow: var(--shadow-large);
    backdrop-filter: blur(10px);
}

.login-card h2 {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 24px;
    letter-spacing: -0.3px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 0.875rem;
}

.form-group input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.9375rem;
    font-family: inherit;
    transition: all 0.2s ease;
    background-color: var(--bg-primary);
}

.form-group input:hover {
    border-color: var(--text-tertiary);
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 1px var(--primary-color);
}

.form-group input::placeholder {
    color: var(--text-tertiary);
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.9375rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
    font-family: inherit;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
}

.btn-primary:active {
    background-color: var(--primary-pressed);
}

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

.error-message {
    background-color: #fde7e9;
    color: var(--danger-color);
    padding: 12px;
    border-radius: 4px;
    margin-bottom: 16px;
    font-size: 0.875rem;
    border-left: 3px solid var(--danger-color);
}

/* Hero Content */
.hero-content {
    color: white;
    padding-top: 40px;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 600;
    margin-bottom: 20px;
    line-height: 1.2;
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: 1.75rem;
    margin-bottom: 16px;
    font-weight: 400;
    opacity: 0.95;
}

.hero-description {
    font-size: 1.125rem;
    margin-bottom: 40px;
    opacity: 0.9;
    max-width: 600px;
    line-height: 1.7;
}

.hero-features {
    display: flex;
    gap: 40px;
    margin-top: 60px;
}

.feature-item {
    text-align: center;
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 12px;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}

.feature-item p {
    font-size: 0.9375rem;
    font-weight: 500;
    opacity: 0.95;
}
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: #1557b0;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-block {
    display: block;
    width: 100%;
}

/* Services Section */
.services {
    padding: 80px 0;
    background: var(--bg-light);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--text-color);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.service-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.service-card p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.service-features {
    list-style: none;
    padding-left: 0;
}

.service-features li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-secondary);
}

.service-features li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
}

/* About Section */
.about {
    padding: 80px 0;
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
}

.about-text p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.stat-item {
    text-align: center;
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: 10px;
}

.stat-item h3 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

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

/* Login Section */
.login-section {
    padding: 80px 0;
    background: var(--bg-light);
}

.login-box {
    max-width: 400px;
    margin: 0 auto;
    background: white;
    padding: 3rem;
    border-radius: 10px;
    box-shadow: var(--shadow-lg);
}

.login-box h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--primary-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.error-message {
    background: #fef2f2;
    color: var(--danger-color);
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 1rem;
    border-left: 3px solid var(--danger-color);
}

.login-help {
    margin-top: 2rem;
    padding: 1rem;
    background: var(--bg-light);
    border-radius: 5px;
    text-align: center;
}

.login-help p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0.25rem 0;
}

/* Dashboard */
.dashboard {
    min-height: calc(100vh - 200px);
    padding: 3rem 0;
    background: var(--bg-light);
}

.dashboard h2 {
    margin-bottom: 2rem;
    color: var(--text-color);
}

.dashboard-section {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.dashboard-section h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 0.5rem;
}

/* Accounts Grid */
.accounts-grid, .cards-grid, .investments-grid, .loans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.account-card, .card-card, .investment-card, .loan-card {
    background: linear-gradient(135deg, var(--primary-color), #667eea);
    color: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.card-card {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.investment-card {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.loan-card {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.account-type, .card-type, .investment-type, .loan-type {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-bottom: 0.5rem;
}

.account-number, .card-number {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

.account-balance, .card-limit, .investment-value, .loan-amount {
    font-size: 2rem;
    font-weight: 700;
    margin: 1rem 0;
}

.account-details, .card-details, .investment-details, .loan-details {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Transactions Table */
.transactions-table {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

table th {
    background: var(--bg-light);
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: var(--text-color);
    border-bottom: 2px solid var(--border-color);
}

table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.transaction-credit {
    color: var(--secondary-color);
    font-weight: 600;
}

.transaction-debit {
    color: var(--danger-color);
    font-weight: 600;
}

/* Footer */
footer {
    background: var(--text-color);
    color: white;
    text-align: center;
    padding: 2rem 0;
}

footer p {
    margin: 0.5rem 0;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-content h2 {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .nav-links {
        gap: 1rem;
        font-size: 0.9rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Dashboard Card Clickable Styles */
.clickable {
    cursor: pointer;
    transition: all 0.3s ease;
}

.clickable:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-medium);
    border-color: var(--primary-color);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    overflow: auto;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.modal-content {
    background-color: var(--bg-primary);
    margin: 3% auto;
    padding: 0;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    padding: 28px 32px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h2 {
    margin: 0;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
}

.modal-close {
    color: var(--text-tertiary);
    font-size: 28px;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
    transition: color 0.2s, transform 0.2s;
    background: none;
    border: none;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover,
.modal-close:focus {
    color: var(--danger-color);
    transform: rotate(90deg);
}

.modal-body {
    padding: 32px;
    overflow-y: auto;
    flex: 1;
}

/* Detail Summary Cards */
.detail-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
    padding: 24px;
    background: var(--bg-secondary);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.summary-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.summary-item .label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.summary-item .value {
    font-size: 1.5rem;
    color: var(--text-primary);
    font-weight: 700;
}

.summary-item .value.positive {
    color: var(--success-color);
}

.summary-item .value.negative {
    color: var(--danger-color);
}

/* Detail Section Headers */
.modal-body h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 32px 0 16px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-color);
}

.modal-body h3:first-of-type {
    margin-top: 0;
}

/* Detail Tables */
.detail-table-wrapper {
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin-bottom: 24px;
}

.detail-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-primary);
}

.detail-table thead {
    background: var(--bg-secondary);
}

.detail-table th {
    padding: 14px 16px;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border-color);
}

.detail-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.detail-table tbody tr {
    transition: background-color 0.2s;
}

.detail-table tbody tr:hover {
    background: var(--bg-secondary);
}

.detail-table tbody tr:last-child td {
    border-bottom: none;
}

/* Badge Styles */
.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-success {
    background: #e6f4ea;
    color: var(--success-color);
}

.badge-danger {
    background: #fce8e6;
    color: var(--danger-color);
}

.badge-info {
    background: #e3f2fd;
    color: #1976d2;
}

.badge-warning {
    background: #fff4e5;
    color: var(--warning-color);
}

.badge-primary {
    background: #e3f2fd;
    color: var(--primary-color);
}

/* Amount Colors */
.amount-positive {
    color: var(--success-color) !important;
    font-weight: 600;
}

.amount-negative {
    color: var(--danger-color) !important;
    font-weight: 600;
}

/* Loading Indicator */
.loading {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

.loading::after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% {
        content: '.';
    }
    40% {
        content: '..';
    }
    60%, 100% {
        content: '...';
    }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.empty-state svg {
    width: 80px;
    height: 80px;
    margin-bottom: 16px;
    opacity: 0.3;
}

/* Investment Holdings Grid */
.holdings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.holding-card {
    padding: 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    transition: all 0.2s;
}

.holding-card:hover {
    box-shadow: var(--shadow-light);
    border-color: var(--primary-color);
}

.holding-name {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.holding-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.holding-detail {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
}

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

.holding-detail .value {
    color: var(--text-primary);
    font-weight: 600;
}

/* Loan Schedule */
.schedule-info {
    background: var(--bg-secondary);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 24px;
    line-height: 1.8;
}

.schedule-info p {
    margin: 8px 0;
    color: var(--text-secondary);
}

.schedule-info strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* Modal Responsive */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        margin: 10% auto;
        max-height: 85vh;
    }
    
    .modal-header {
        padding: 20px;
    }
    
    .modal-header h2 {
        font-size: 1.25rem;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .detail-summary {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 16px;
    }
    
    .holdings-grid {
        grid-template-columns: 1fr;
    }
    
    .detail-table-wrapper {
        font-size: 0.875rem;
    }
    
    .detail-table th,
    .detail-table td {
        padding: 10px 8px;
    }
}
