@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --primary-blue: #004a99;
    --secondary-blue: #0070e0;
    --accent-blue: #00f2ff;
    --deep-navy: #001a33;
    --text-dark: #1a1a1a;
    --text-muted: #6b7280;
    --bg-gradient: linear-gradient(135deg, #001a33 0%, #004a99 100%);
    --card-bg: rgba(255, 255, 255, 0.95);
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.3);
    --shadow-premium: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    --nav-indicator: var(--accent-blue);
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background: var(--bg-gradient);
    background-attachment: fixed;
    min-height: 100vh;
    color: var(--text-dark);
    padding: 20px;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Header Styles */
.chase-header {
    background: var(--glass-bg);
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-premium);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo h1 {
    color: var(--primary-blue);
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.logo .logo-text {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-muted);
    margin-left: 10px;
    border-left: 1px solid #ddd;
    padding-left: 10px;
}

@media (max-width: 600px) {
    .logo .logo-text {
        display: none;
    }
}

.user-actions {
    display: flex;
    gap: 15px;
}

.icon-btn {
    background: transparent;
    border: none;
    font-size: 20px;
    color: #117ACA;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.icon-btn:hover {
    background: rgba(17, 122, 202, 0.1);
    transform: scale(1.1);
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 15px;
    position: relative;
}

.main-nav li a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 12px;
    transition: var(--transition-smooth);
    position: relative;
}

.main-nav li a i {
    font-size: 18px;
    transition: var(--transition-smooth);
}

.main-nav li a:hover {
    color: var(--primary-blue);
    background: rgba(0, 74, 153, 0.05);
}

.main-nav li.active a {
    color: var(--primary-blue);
    background: rgba(0, 74, 153, 0.1);
}

.main-nav li.active a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 4px;
    background: var(--primary-blue);
    border-radius: 10px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { width: 0; opacity: 0; }
    to { width: 20px; opacity: 1; }
}

/* Notification Panel Styles */
.notification-panel {
    position: absolute;
    top: 70px;
    right: 20px;
    width: 350px;
    background: white;
    border-radius: 16px;
    box-shadow: var(--shadow-premium);
    z-index: 1000;
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #eee;
    animation: fadeInDown 0.3s ease;
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.notification-panel.active {
    display: flex;
}

.notification-header {
    padding: 15px 20px;
    background: #f8f9fa;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.notification-header h3 {
    font-size: 16px;
    font-weight: 700;
}

.clear-btn {
    background: none;
    border: none;
    color: var(--primary-blue);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
}

.notification-list {
    max-height: 400px;
    overflow-y: auto;
}

.notification-item {
    padding: 15px 20px;
    display: flex;
    gap: 15px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s ease;
    cursor: pointer;
}

.notification-item:hover {
    background: #f9fafb;
}

.notification-item.unread {
    background: #f0f7ff;
}

.notification-item i {
    width: 35px;
    height: 35px;
    background: rgba(0, 74, 153, 0.1);
    color: var(--primary-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.notification-content p {
    font-size: 14px;
    margin-bottom: 4px;
    font-weight: 500;
}

.notification-content .time {
    font-size: 12px;
    color: var(--text-muted);
}

.notification-badge {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 8px;
    height: 8px;
    background: #ef4444;
    border-radius: 50%;
    display: none;
}

/* Dashboard Content */
.dashboard-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-header h2 {
    color: white;
    font-size: 24px;
    font-weight: 600;
}

.view-all {
    color: #117ACA;
    text-decoration: none;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.9);
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.view-all:hover {
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Account Summary */
.account-summary {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.summary-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.summary-header h2 {
    color: #117ACA;
    font-size: 24px;
}

.refresh-btn {
    background: #117ACA;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.refresh-btn:hover {
    background: #0d5a9e;
    transform: translateY(-2px);
}

.accounts-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.account-card {
    background: linear-gradient(135deg, #f5f7fa 0%, #e4edf5 100%);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border: 1px solid rgba(17, 122, 202, 0.1);
}

.account-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.account-card.primary {
    border-left: 5px solid #117ACA;
}

.account-card.savings {
    border-left: 5px solid #28a745;
}

.account-card.credit {
    border-left: 5px solid #dc3545;
}

.account-info h3 {
    color: #333;
    font-size: 18px;
    margin-bottom: 5px;
}

.account-number {
    color: #666;
    font-size: 14px;
}

.balance-label {
    color: #666;
    font-size: 14px;
    margin-top: 15px;
}

.balance-amount {
    font-size: 28px;
    font-weight: 700;
    margin-top: 5px;
}

.account-card.primary .balance-amount {
    color: #117ACA;
}

.account-card.savings .balance-amount {
    color: #28a745;
}

.account-card.credit .balance-amount {
    color: #dc3545;
}

/* Recent Transactions */
.recent-transactions {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.transactions-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.transaction-item {
    display: flex;
    align-items: center;
    padding: 15px;
    border-radius: 12px;
    background: rgba(248, 249, 250, 0.7);
    transition: all 0.3s ease;
}

.transaction-item:hover {
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.transaction-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: rgba(17, 122, 202, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: #117ACA;
    font-size: 18px;
}

.transaction-details {
    flex: 1;
}

.transaction-details h4 {
    color: #333;
    font-size: 16px;
    margin-bottom: 3px;
}

.transaction-date {
    color: #666;
    font-size: 14px;
}

.transaction-amount {
    font-weight: 700;
    font-size: 18px;
}

.transaction-amount.positive {
    color: #28a745;
}

.transaction-amount.negative {
    color: #dc3545;
}

/* Quick Actions */
.quick-actions {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin-bottom: 30px;
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
}

.action-btn {
    background: rgba(17, 122, 202, 0.1);
    border: none;
    border-radius: 12px;
    padding: 20px 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #117ACA;
    font-weight: 600;
}

.action-btn:hover {
    background: rgba(17, 122, 202, 0.2);
    transform: translateY(-5px);
}

.action-btn i {
    font-size: 24px;
}

/* Premium Quick Actions */
.action-card-premium {
    background: white;
    border: 1px solid rgba(0,0,0,0.05);
    border-radius: 20px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    cursor: pointer;
    border: none;
    width: 100%;
}

.action-card-premium:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

.action-icon-wrapper {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-bottom: 18px;
}

.action-title {
    font-weight: 700;
    color: #1e293b;
    font-size: 16px;
    margin-bottom: 6px;
}

.action-subtitle {
    font-size: 12px;
    color: #64748b;
    line-height: 1.4;
}

.transaction-group-header {
    padding: 12px 15px;
    color: #64748b;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    border-bottom: 1px solid rgba(0,0,0,0.04);
    margin-bottom: 10px;
}

/* Form Styles */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: #117ACA;
    box-shadow: 0 0 0 3px rgba(17, 122, 202, 0.1);
}

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
    width: 100%;
}

@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
        gap: 15px;
    }
    
    .form-row .form-group {
        margin-right: 0 !important;
        margin-bottom: 0;
    }
}

.transfer-actions {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 5px;
    scrollbar-width: none; /* Firefox */
}

.transfer-actions::-webkit-scrollbar {
    display: none; /* Safari/Chrome */
}

@media (max-width: 768px) {
    .transfer-actions {
        margin: 0 -10px;
        padding: 0 10px 10px 10px;
    }
    
    .transfer-actions .refresh-btn {
        flex: 0 0 auto;
        white-space: nowrap;
    }
}

.transfer-form {
    max-width: 800px;
    margin: 0 auto;
}

/* Mobile Bottom Nav Overhaul */
.mobile-nav {
    display: none;
    position: fixed;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 400px;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    justify-content: space-around;
    padding: 12px 10px;
    border-radius: 30px;
    z-index: 2000;
}

.mobile-nav a {
    text-decoration: none;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 10px;
    font-weight: 700;
    gap: 4px;
    transition: var(--transition-smooth);
    position: relative;
    z-index: 2;
    padding: 5px 10px;
}

.mobile-nav a.active {
    color: var(--primary-blue);
    transform: translateY(-5px);
}

.mobile-nav a.active i {
    transform: scale(1.2);
}

.mobile-nav i {
    font-size: 22px;
}

/* Active indicator for mobile */
.mobile-nav::before {
    content: '';
    position: absolute;
    bottom: 12px;
    left: var(--mobile-nav-x, 10%);
    width: 50px;
    height: 50px;
    background: rgba(0, 74, 153, 0.1);
    border-radius: 20px;
    transition: var(--transition-smooth);
    z-index: 1;
    display: none; /* Will be shown if I add JS to update position, or I can use static positions for now */
}

@media (max-width: 768px) {
    body {
        padding-bottom: 100px;
    }
    
    .main-nav {
        display: none;
    }
    
    .mobile-nav {
        display: flex;
    }
    
    .header-top {
        margin-bottom: 0;
    }
    
    .notification-panel {
        width: calc(100% - 40px);
        right: 20px;
    }
}

/* Transfer Dashboard Enhancements */
.transfer-form .form-row {
    margin-bottom: 25px;
}

/* Radio Cards for Account Selection */
.account-selector {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 10px;
}

.radio-card {
    cursor: pointer;
    position: relative;
    background: white;
    border: 2px solid #eee;
    border-radius: 12px;
    padding: 15px;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

.radio-card::before {
    content: '';
    position: absolute;
    top: 15px;
    right: 15px;
    width: 20px;
    height: 20px;
    border: 2px solid #ddd;
    border-radius: 50%;
    transition: var(--transition-smooth);
}

.radio-card.selected::before {
    border-color: var(--primary-blue);
    background: var(--primary-blue);
    box-shadow: inset 0 0 0 4px white;
}

.radio-card input {
    position: absolute;
    opacity: 0;
}

.radio-card:hover {
    border-color: var(--secondary-blue);
    background: rgba(0, 112, 224, 0.02);
}

.radio-card.selected {
    border-color: var(--primary-blue);
    background: rgba(0, 74, 153, 0.05);
    box-shadow: 0 4px 15px rgba(0, 74, 153, 0.1);
}

.radio-card h4 {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 2px;
}

.radio-card .account-number {
    font-size: 13px;
    color: #64748b;
    margin-bottom: 8px;
}

.radio-card .amount {
    font-size: 18px;
    font-weight: 800;
    color: var(--primary-blue);
    margin-top: auto;
}

/* Status Badges */
.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
}

.status-badge.completed {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.status-badge.pending {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

/* Refined Transfer Buttons */
.transfer-actions .refresh-btn {
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) {
    .header-top {
        flex-direction: row; /* Keep row for logo and actions */
        justify-content: space-between;
        gap: 15px;
    }
    
    .account-selector {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }
    
    .chase-header {
        padding: 15px;
    }
    
    .main-nav ul {
        gap: 5px;
    }
    
    .main-nav li a {
        padding: 8px 10px;
        font-size: 14px;
    }
    
    .account-card {
        padding: 15px;
    }
    
    .balance-amount {
        font-size: 24px;
    }
    
    .transaction-item {
        padding: 12px;
    }
}