/* Common Styles for Zinses-rechner.de */

:root {
    /* German Corporate Colors */
    --primary-color: #1e3a8a;        /* Professional Blue */
    --secondary-color: #1f2937;      /* Dark Gray */
    --accent-color: #059669;         /* Success Green */
    --warning-color: #d97706;        /* Warning Orange */
    --danger-color: #dc2626;         /* Error Red */
    --info-color: #0284c7;           /* Info Blue */
    
    /* German Financial Colors */
    --gold-color: #fbbf24;           /* Gold */
    --silver-color: #9ca3af;         /* Silver */
    --euro-color: #1e40af;           /* Euro Blue */
    
    /* Gradients */
    --primary-gradient: linear-gradient(135deg, #1e3a8a 0%, #3730a3 100%);
    --success-gradient: linear-gradient(135deg, #059669 0%, #047857 100%);
    --warning-gradient: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    
    /* Spacing & Layout */
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    
    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    
    /* German Number Formatting */
    --decimal-separator: ',';
    --thousands-separator: '.';
}

/* Base Styles */
* {
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    color: #1f2937;
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

/* Professional Header */
.header-professional {
    background: white;
    border-bottom: 1px solid #e5e7eb;
    padding: 1.5rem 0;
    box-shadow: var(--shadow-sm);
}

/* Smart Navigation */
.navbar {
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1030;
    transform: translateY(0);
    background: white !important;
}

.navbar.navbar-hidden {
    transform: translateY(-100%);
}

.navbar.navbar-visible {
    transform: translateY(0);
}

/* Add padding to body to compensate for fixed navbar */
body {
    padding-top: 76px; /* Adjust based on navbar height */
}

.brand-section {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin: 0;
    display: flex;
    align-items: center;
}

.brand-icon {
    color: var(--accent-color);
    margin-right: 0.5rem;
}

.brand-subtitle {
    font-size: var(--font-size-sm);
    color: #6b7280;
    margin: 0;
    font-weight: 500;
}

/* Market Data Header */
.market-data-header {
    text-align: right;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 12px;
    padding: 1rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.market-item {
    text-align: center;
    padding: 0.5rem;
}

.market-label {
    font-size: var(--font-size-xs);
    color: #6b7280;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.market-value {
    font-size: var(--font-size-sm);
    font-weight: 700;
    color: #1f2937;
    margin: 0.25rem 0;
}

.market-change {
    font-size: var(--font-size-xs);
    font-weight: 600;
}

.trend-up {
    color: var(--accent-color);
}

.trend-down {
    color: var(--danger-color);
}

.market-update {
    font-size: var(--font-size-xs);
    color: #6b7280;
    margin-top: 0.5rem;
    text-align: center;
}

/* Market Change Colors */
.market-change.positive {
    color: var(--accent-color);
}

.market-change.negative {
    color: var(--danger-color);
}



/* Breadcrumb Professional */
.breadcrumb-professional {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid #e2e8f0;
}

.breadcrumb-professional .breadcrumb {
    margin: 0;
    background: none;
    padding: 0;
}

.breadcrumb-professional .breadcrumb-item a {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
}

.breadcrumb-professional .breadcrumb-item a:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

.breadcrumb-professional .breadcrumb-item.active {
    color: #374151;
    font-weight: 600;
}

/* Main Content */
.main-content {
    padding: 3rem 0;
    min-height: calc(100vh - 200px);
}

/* Professional Footer */
.footer-professional {
    background: #1f2937;
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-title {
    color: white;
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-subtitle {
    color: #d1d5db;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-text {
    color: #9ca3af;
    font-size: var(--font-size-sm);
    line-height: 1.6;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #9ca3af;
    text-decoration: none;
    font-size: var(--font-size-sm);
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: white;
}

.footer-links a.active {
    color: white;
    font-weight: 600;
}

.footer-divider {
    border-color: #374151;
    margin: 2rem 0 1rem;
}

.footer-copyright {
    color: #9ca3af;
    font-size: var(--font-size-sm);
    margin: 0;
}

.footer-disclaimer {
    color: #6b7280;
    font-size: var(--font-size-xs);
    margin: 0;
}

.security-badges {
    margin-top: 1rem;
}

.security-badges .badge {
    font-size: var(--font-size-xs);
    padding: 0.375rem 0.75rem;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
}

/* Utility Classes */
.text-german-number {
    font-variant-numeric: tabular-nums;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', monospace;
}

.currency-euro::before {
    content: '€ ';
}

.currency-euro::after {
    content: ' €';
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-professional {
        padding: 0.75rem 0;
    }
    
    .brand-title {
        font-size: 1.25rem;
    }
    
    .market-data-header {
        margin-top: 1rem;
    }
    
    .market-item {
        padding: 0.25rem;
    }
    
    .market-value {
        font-size: var(--font-size-xs);
    }
    
    .main-content {
        padding: 1rem 0;
    }
    
    .footer-professional {
        padding: 2rem 0 1rem;
    }
}

@media (max-width: 576px) {
    .market-data-header .row > div {
        flex: 0 0 50%;
        max-width: 50%;
    }
    
    .market-item:nth-child(n+5) {
        display: none;
    }
}

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 1000;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Print Styles */
@media print {
    .header-professional,
    .footer-professional {
        display: none;
    }
    
    .main-content {
        padding: 0;
    }
    
    body {
        background: white;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #000080;
        --accent-color: #008000;
        --danger-color: #800000;
    }
    
    .market-change {
        font-weight: 700;
    }
}
