/* SNSP Bank - Sparkassen-inspiriertes Design */
@import url('https://fonts.googleapis.com/css2?family=Source+Sans+3:wght@300;400;500;600;700&display=swap');

:root {
    --primary: #E30613;
    --primary-dark: #B8050F;
    --primary-light: #FF1A1A;
    --secondary: #1A1A1A;
    --accent: #FF6B6B;
    
    --bg-main: #F5F5F5;
    --bg-card: #FFFFFF;
    --bg-dark: #1A1A1A;
    
    --text-primary: #1A1A1A;
    --text-secondary: #666666;
    --text-muted: #999999;
    --text-white: #FFFFFF;
    
    --border: #E0E0E0;
    --border-light: #F0F0F0;
    
    --success: #00A650;
    --warning: #FFB800;
    --error: #E30613;
    
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
    
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
}

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

body {
    font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100vh;
}

/* ==================== HEADER ==================== */
.bank-header {
    background: var(--primary);
    color: var(--text-white);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-md);
}

.header-top {
    background: var(--primary-dark);
    padding: 8px 0;
    font-size: 13px;
}

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

.header-top a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
    transition: color 0.2s;
}

.header-top a:hover {
    color: #fff;
}

.header-main {
    padding: 16px 0;
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-white);
}

.logo-icon {
    width: 48px;
    height: 48px;
    background: var(--text-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
}

.logo-text {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.logo-text span {
    font-weight: 300;
    opacity: 0.9;
}

.header-nav {
    display: flex;
    gap: 32px;
}

.header-nav a {
    color: var(--text-white);
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    padding: 8px 0;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}

.header-nav a:hover,
.header-nav a.active {
    border-bottom-color: var(--text-white);
}

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

.user-greeting {
    text-align: right;
    font-size: 14px;
}

.user-greeting strong {
    display: block;
    font-size: 16px;
}

.btn-logout {
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.3);
    color: var(--text-white);
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-logout:hover {
    background: rgba(255,255,255,0.25);
}

/* ==================== CONTAINER ==================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.page-content {
    padding: 32px 0;
}

/* ==================== CARDS ==================== */
.card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.card-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.card-body {
    padding: 24px;
}

/* ==================== KONTOÜBERSICHT ==================== */
.account-overview {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 24px;
    margin-bottom: 32px;
}

@media (max-width: 900px) {
    .account-overview {
        grid-template-columns: 1fr;
    }
}

.account-main-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--text-white);
    border-radius: var(--radius-xl);
    padding: 32px;
    position: relative;
    overflow: hidden;
}

.account-main-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    pointer-events: none;
}

.account-label {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.8;
    margin-bottom: 4px;
}

.account-holder {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 24px;
}

.account-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 32px;
}

.account-detail-item {
    background: rgba(255,255,255,0.1);
    padding: 16px;
    border-radius: var(--radius-md);
}

.account-detail-value {
    font-size: 16px;
    font-weight: 600;
    font-family: 'SF Mono', 'Consolas', monospace;
}

.balance-section {
    border-top: 1px solid rgba(255,255,255,0.2);
    padding-top: 24px;
}

.balance-label {
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 8px;
}

.balance-amount {
    font-size: 42px;
    font-weight: 700;
    letter-spacing: -1px;
}

.balance-amount .currency {
    font-size: 24px;
    font-weight: 400;
    opacity: 0.9;
}

/* Quick Actions Sidebar */
.quick-actions-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.quick-action-btn {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    color: var(--text-primary);
}

.quick-action-btn:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateX(4px);
}

.quick-action-icon {
    width: 44px;
    height: 44px;
    background: var(--primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.quick-action-text {
    flex: 1;
}

.quick-action-title {
    font-weight: 600;
    font-size: 15px;
}

.quick-action-desc {
    font-size: 13px;
    color: var(--text-secondary);
}

.quick-action-arrow {
    color: var(--text-muted);
    font-size: 20px;
}

/* ==================== TRANSAKTIONEN ==================== */
.transactions-section {
    margin-top: 32px;
}

.transactions-filters {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.filter-btn {
    padding: 8px 16px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 20px;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--text-white);
}

.transaction-list {
    display: flex;
    flex-direction: column;
}

.transaction-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-light);
    transition: background 0.2s;
}

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

.transaction-item:hover {
    background: var(--bg-main);
    margin: 0 -24px;
    padding: 16px 24px;
}

.tx-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.tx-icon.incoming {
    background: rgba(0, 166, 80, 0.1);
    color: var(--success);
}

.tx-icon.outgoing {
    background: rgba(227, 6, 19, 0.1);
    color: var(--error);
}

.tx-icon.deposit {
    background: rgba(0, 166, 80, 0.1);
    color: var(--success);
}

.tx-details {
    flex: 1;
    min-width: 0;
}

.tx-title {
    font-weight: 600;
    font-size: 15px;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.tx-subtitle {
    font-size: 13px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tx-meta {
    text-align: right;
    flex-shrink: 0;
}

.tx-amount {
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 2px;
}

.tx-amount.positive {
    color: var(--success);
}

.tx-amount.negative {
    color: var(--text-primary);
}

.tx-date {
    font-size: 13px;
    color: var(--text-muted);
}

.no-transactions {
    text-align: center;
    padding: 48px 24px;
    color: var(--text-secondary);
}

.no-transactions-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

/* ==================== MODAL ==================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow: hidden;
    transform: translateY(20px);
    transition: transform 0.3s;
}

.modal-overlay.active .modal {
    transform: translateY(0);
}

.modal-header {
    background: var(--primary);
    color: var(--text-white);
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-title {
    font-size: 20px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-white);
    font-size: 28px;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
    line-height: 1;
}

.modal-close:hover {
    opacity: 1;
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    max-height: calc(90vh - 180px);
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-light);
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* ==================== FORMS ==================== */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 16px;
    font-family: inherit;
    transition: all 0.2s;
    background: var(--bg-card);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(227, 6, 19, 0.1);
}

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

.form-hint {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 6px;
}

.form-hint.success {
    color: var(--success);
}

.form-hint.error {
    color: var(--error);
}

.input-group {
    display: flex;
    gap: 12px;
}

.input-group .form-input {
    flex: 1;
}

.input-suffix {
    display: flex;
    align-items: center;
    padding: 0 16px;
    background: var(--bg-main);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-weight: 600;
    color: var(--text-secondary);
}

/* ==================== BUTTONS ==================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

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

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

.btn-primary:disabled {
    background: var(--text-muted);
    cursor: not-allowed;
}

.btn-secondary {
    background: var(--bg-main);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--border-light);
}

.btn-block {
    width: 100%;
}

.btn-lg {
    padding: 18px 32px;
    font-size: 16px;
}

/* ==================== LOGIN PAGE ==================== */
.login-page {
    min-height: 100vh;
    display: flex;
}

.login-left {
    flex: 1;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px;
    position: relative;
    overflow: hidden;
}

.login-left::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 50%);
}

.login-brand {
    text-align: center;
    color: var(--text-white);
    position: relative;
    z-index: 1;
}

.login-logo {
    width: 100px;
    height: 100px;
    background: var(--text-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: 700;
    color: var(--primary);
    margin: 0 auto 24px;
}

.login-brand h1 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 8px;
}

.login-brand p {
    font-size: 18px;
    opacity: 0.9;
}

.login-right {
    width: 480px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px;
    background: var(--bg-card);
}

.login-form-container {
    width: 100%;
    max-width: 360px;
}

.login-form-container h2 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
}

.login-form-container p {
    color: var(--text-secondary);
    margin-bottom: 32px;
}

.login-links {
    text-align: center;
    margin-top: 24px;
    font-size: 14px;
    color: var(--text-secondary);
}

.login-links a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.login-links a:hover {
    text-decoration: underline;
}

@media (max-width: 900px) {
    .login-page {
        flex-direction: column;
    }
    
    .login-left {
        padding: 48px 24px;
        min-height: 200px;
    }
    
    .login-right {
        width: 100%;
        flex: 1;
    }
}

/* ==================== ALERTS / TOASTS ==================== */
.toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.toast {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
    animation: slideIn 0.3s ease;
    border-left: 4px solid var(--text-muted);
}

.toast.success {
    border-left-color: var(--success);
}

.toast.error {
    border-left-color: var(--error);
}

.toast-icon {
    font-size: 20px;
}

.toast-message {
    flex: 1;
    font-size: 14px;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ==================== LOADING ==================== */
.loading-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 16px;
    z-index: 3000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.loading-overlay .loading-spinner {
    width: 48px;
    height: 48px;
}

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

/* ==================== RESPONSIVE ==================== */
@media (max-width: 768px) {
    .header-nav {
        display: none;
    }
    
    .container {
        padding: 0 16px;
    }
    
    .account-main-card {
        padding: 24px;
    }
    
    .account-details {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .balance-amount {
        font-size: 32px;
    }
    
    .quick-actions-card {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
    }
    
    .quick-action-btn {
        flex-direction: column;
        text-align: center;
        padding: 16px;
    }
    
    .quick-action-arrow {
        display: none;
    }
}

/* ==================== UTILITIES ==================== */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }


/* ========================================
   DISCLAIMER
   ======================================== */
.disclaimer-section { margin-top: 24px; }
.disclaimer-card .card-title { margin: 0; }
.disclaimer-text { color: var(--text-muted); font-size: 14px; line-height: 1.7; }
.disclaimer-text b { color: var(--text); }


/* Disclaimer button in header (right side) */
.btn-disclaimer{
    display:inline-flex;
    align-items:center;
    gap:8px;
    padding:8px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,0.18);
    border: 1px solid rgba(255,255,255,0.28);
    color: var(--text-white);
    text-decoration:none;
    font-weight: 600;
    font-size: 14px;
    transition: transform .15s ease, background .15s ease, border-color .15s ease;
    white-space: nowrap;
}
.btn-disclaimer:hover{
    background: rgba(255,255,255,0.26);
    border-color: rgba(255,255,255,0.40);
    transform: translateY(-1px);
}
.btn-disclaimer .icon{font-size:16px; line-height:1;}
@media (max-width: 768px){
    .btn-disclaimer .text{ display:none; }
    .btn-disclaimer{ padding:8px 10px; }
}

/* Auth pages: fixed disclaimer link top-right */
.auth-disclaimer-btn{
    position: fixed;
    top: 14px;
    right: 14px;
    z-index: 10000;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border-radius: 999px;
    background: #ffffff;
    color: var(--primary);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
}
.auth-disclaimer-btn:hover{
    background: #f7f7f7;
}
@media (max-width: 480px){
    .auth-disclaimer-btn{
        padding: 9px 10px;
        font-size: 13px;
    }
}
