/* M500 Ekonomi - Dark Blue Professional Theme */

:root {
    /* Dark Blue Color Palette */
    --primary-dark: #0A1929;
    --primary-blue: #1E3A5F;
    --accent-blue: #2E5A8F;
    --light-blue: #4A7BA7;
    --highlight: #6B9FD1;
    
    /* Text Colors */
    --text-primary: #FFFFFF;
    --text-secondary: #B8C5D6;
    --text-muted: #8A9BAE;
    
    /* Background Colors */
    --bg-primary: #0A1929;
    --bg-secondary: #1E3A5F;
    --bg-card: #152238;
    --bg-hover: #1F3A5C;
    
    /* Status Colors */
    --success: #10B981;
    --warning: #F59E0B;
    --danger: #EF4444;
    --info: #3B82F6;
    
    /* Border & Shadow */
    --border-color: #2E4A6F;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #1E3A5F 0%, #2E5A8F 100%);
    --gradient-accent: linear-gradient(135deg, #2E5A8F 0%, #4A7BA7 100%);
    --gradient-glow: linear-gradient(135deg, #4A7BA7 0%, #6B9FD1 100%);
    
    /* Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    
    /* Transitions */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 15px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Animated Background */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 50%, rgba(46, 90, 143, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(74, 123, 167, 0.1) 0%, transparent 50%);
    z-index: -1;
    pointer-events: none;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Header */
header {
    background: rgba(21, 34, 56, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
    box-shadow: var(--shadow-sm);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: var(--transition);
}

.logo:hover {
    transform: translateY(-2px);
}

.logo img {
    height: 48px;
    width: auto;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 800;
    background: var(--gradient-glow);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Navigation */
nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

nav a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition);
    padding: 0.5rem 0;
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-glow);
    transition: width 0.3s ease;
}

nav a:hover,
nav a.active {
    color: var(--text-primary);
}

nav a:hover::after,
nav a.active::after {
    width: 100%;
}

/* Wallet Button */
.wallet-btn {
    background: var(--gradient-primary);
    color: var(--text-primary);
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.wallet-btn:hover {
    background: var(--gradient-accent);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.wallet-connected {
    background: var(--bg-card);
    border: 2px solid var(--highlight);
    box-shadow: 0 0 20px rgba(107, 159, 209, 0.3);
}

/* Main Content */
main {
    min-height: calc(100vh - 200px);
    padding: 2rem 0;
}

/* Cards */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-4px);
    border-color: var(--accent-blue);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.card-title {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient-glow);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 2rem 1.5rem;
    text-align: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 160px;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--gradient-glow);
}

.stat-card::after {
    content: '';
    position: absolute;
    bottom: -50px;
    right: -50px;
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, rgba(107, 159, 209, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

.stat-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-4px);
    border-color: var(--highlight);
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1.3;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-glow);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.4rem;
    line-height: 1.2;
}

.stat-change {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
}

.stat-change.positive { color: var(--success); }
.stat-change.negative { color: var(--danger); }
.stat-change.warning { color: var(--warning); }

/* Buttons */
.btn {
    padding: 0.875rem 1.75rem;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    border: 1px solid transparent;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--text-primary);
    box-shadow: var(--shadow-sm);
    border-color: var(--border-color);
}

.btn-primary:hover:not(:disabled) {
    background: var(--gradient-accent);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 2px solid var(--accent-blue);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--bg-hover);
    border-color: var(--highlight);
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-success:hover:not(:disabled) {
    background: #059669;
    box-shadow: 0 4px 16px rgba(16, 185, 129, 0.4);
}

.btn-warning {
    background: var(--warning);
    color: white;
}

.btn-warning:hover:not(:disabled) {
    background: #D97706;
    box-shadow: 0 4px 16px rgba(245, 158, 11, 0.4);
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-danger:hover:not(:disabled) {
    background: #DC2626;
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.4);
}

/* Table */
.table-container {
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background: var(--bg-card);
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: var(--bg-secondary);
}

th {
    padding: 1.25rem 1rem;
    text-align: left;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

td {
    padding: 1.25rem 1rem;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.95rem;
    color: var(--text-primary);
}

tbody tr {
    transition: var(--transition);
}

tbody tr:hover {
    background: var(--bg-hover);
}

tbody tr:last-child td {
    border-bottom: none;
}

/* Badge */
.badge {
    display: inline-flex;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-success {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
    border: 1px solid var(--success);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.2);
    color: var(--warning);
    border: 1px solid var(--warning);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.2);
    color: var(--danger);
    border: 1px solid var(--danger);
}

/* Form */
.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 0.95rem;
}

input, select, textarea {
    width: 100%;
    padding: 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: var(--transition);
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--highlight);
    box-shadow: 0 0 0 3px rgba(107, 159, 209, 0.2);
}

input::placeholder {
    color: var(--text-muted);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 25, 41, 0.9);
    backdrop-filter: blur(8px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: var(--shadow-lg);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: var(--danger);
    color: white;
    border-color: var(--danger);
}

/* Alert */
.alert {
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius-sm);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    border: 1px solid;
}

.alert-success {
    background: rgba(16, 185, 129, 0.15);
    border-color: var(--success);
    color: var(--success);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.15);
    border-color: var(--warning);
    color: var(--warning);
}

.alert-danger {
    background: rgba(239, 68, 68, 0.15);
    border-color: var(--danger);
    color: var(--danger);
}

/* Spinner */
.spinner {
    border: 3px solid var(--bg-secondary);
    border-top: 3px solid var(--highlight);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 0.8s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Footer */
footer {
    background: var(--bg-card);
    border-top: 1px solid var(--border-color);
    padding: 3rem 0 1.5rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2.5rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    margin-bottom: 1.25rem;
    font-size: 1.1rem;
    color: var(--text-primary);
    font-weight: 700;
}

.footer-section ul {
    list-style: none;
}

.footer-section li {
    margin-bottom: 0.75rem;
}

.footer-section a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--highlight);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Mobile Bottom Nav */
.mobile-bottom-nav {
    display: none;
}

/* Responsive - Geniş Yelpazeli Mobile Support */
@media (max-width: 1024px) {
    body {
        font-size: 14px;
        padding-bottom: 85px;
    }
    
    .container {
        padding: 0 20px;
    }
    
    header nav {
        display: none !important;
    }
    
    .mobile-bottom-nav {
        display: block !important;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: rgba(21, 34, 56, 0.98);
        backdrop-filter: blur(10px);
        border-top: 2px solid var(--border-color);
        padding: 0.5rem 0;
        z-index: 999;
        box-shadow: 0 -6px 20px rgba(0, 0, 0, 0.5);
    }
    
    .mobile-bottom-nav ul {
        display: flex;
        justify-content: space-around;
        align-items: center;
        list-style: none;
        max-width: 600px;
        margin: 0 auto;
        padding: 0 0.5rem;
    }
    
    .mobile-bottom-nav a {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 6px;
        padding: 0.6rem 0.5rem;
        color: var(--text-secondary);
        font-size: 0.65rem;
        font-weight: 700;
        transition: var(--transition);
        border-radius: var(--radius-md);
        text-decoration: none;
        min-width: 60px;
        position: relative;
    }
    
    .mobile-bottom-nav a::before {
        content: '';
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 0;
        height: 3px;
        background: var(--gradient-glow);
        border-radius: 0 0 3px 3px;
        transition: width 0.3s ease;
    }
    
    .mobile-bottom-nav a.active::before {
        width: 80%;
    }
    
    .mobile-bottom-nav a.active {
        color: var(--highlight);
        background: rgba(107, 159, 209, 0.2);
        transform: translateY(-2px);
    }
    
    .mobile-bottom-nav a:active {
        transform: scale(0.95);
    }
    
    .mobile-bottom-nav .nav-icon {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .mobile-bottom-nav .nav-icon img {
        filter: brightness(0.8);
        transition: var(--transition);
    }
    
    .mobile-bottom-nav a.active .nav-icon img {
        filter: brightness(1.2);
    }
    
    .logo img {
        height: 40px;
    }
    
    .logo-text {
        font-size: 1.2rem;
    }
    
    .wallet-btn {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    
    .stat-card {
        padding: 1.25rem 1rem;
    }
    
    .stat-label {
        font-size: 0.65rem;
        margin-bottom: 0.5rem;
    }
    
    .stat-value {
        font-size: 1.5rem;
        margin-bottom: 0.3rem;
    }
    
    .stat-change {
        font-size: 0.65rem;
    }
    
    .card {
        padding: 1.5rem;
    }
    
    table {
        min-width: 600px;
    }
    
    th, td {
        padding: 1rem 0.75rem;
        font-size: 0.85rem;
    }
}

@media (min-width: 1025px) {
    .mobile-bottom-nav {
        display: none !important;
    }
}

/* Tablet Optimization (768px - 1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
    .container {
        padding: 0 32px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .stat-card {
        padding: 1.5rem 1.25rem;
    }
    
    .stat-label {
        font-size: 0.7rem;
    }
    
    .stat-value {
        font-size: 1.75rem;
    }
    
    .mobile-bottom-nav a {
        font-size: 0.75rem;
        padding: 0.7rem 1rem;
        min-width: 70px;
    }
    
    .mobile-bottom-nav .nav-icon img {
        width: 26px;
        height: 26px;
    }
    
    .logo img {
        height: 44px;
    }
    
    .wallet-btn {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }
}

/* Small Mobile (< 375px) */
@media (max-width: 374px) {
    body {
        font-size: 13px;
    }
    
    .container {
        padding: 0 12px;
    }
    
    .mobile-bottom-nav a {
        font-size: 0.6rem;
        padding: 0.5rem 0.3rem;
        min-width: 50px;
        gap: 4px;
    }
    
    .mobile-bottom-nav .nav-icon img {
        width: 20px;
        height: 20px;
    }
    
    .logo img {
        height: 36px;
    }
    
    .wallet-btn {
        padding: 0.5rem 0.8rem;
        font-size: 0.75rem;
    }
    
    .stats-grid {
        gap: 0.6rem;
    }
    
    .stat-card {
        padding: 1rem 0.75rem;
    }
    
    .stat-label {
        font-size: 0.6rem;
        margin-bottom: 0.4rem;
    }
    
    .stat-value {
        font-size: 1.35rem;
        margin-bottom: 0.25rem;
    }
    
    .stat-change {
        font-size: 0.6rem;
    }
    
    .card {
        padding: 1rem;
    }
}

/* Large Mobile / Small Tablet (375px - 767px) */
@media (min-width: 375px) and (max-width: 767px) {
    .mobile-bottom-nav a {
        font-size: 0.7rem;
        padding: 0.6rem 0.6rem;
        min-width: 65px;
    }
    
    .mobile-bottom-nav .nav-icon img {
        width: 24px;
        height: 24px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.7rem;
    }
    
    .stat-card {
        padding: 1.15rem 0.9rem;
    }
    
    .stat-label {
        font-size: 0.63rem;
    }
    
    .stat-value {
        font-size: 1.4rem;
    }
    
    .stat-change {
        font-size: 0.63rem;
    }
}

/* Extra Large Mobile (414px+) */
@media (min-width: 414px) and (max-width: 767px) {
    .mobile-bottom-nav a {
        font-size: 0.72rem;
        padding: 0.65rem 0.8rem;
        min-width: 70px;
    }
    
    .mobile-bottom-nav .nav-icon img {
        width: 25px;
        height: 25px;
    }
}

/* Landscape Mobile */
@media (max-width: 1024px) and (orientation: landscape) {
    body {
        padding-bottom: 70px;
    }
    
    .mobile-bottom-nav {
        padding: 0.4rem 0;
    }
    
    .mobile-bottom-nav a {
        padding: 0.4rem 0.5rem;
        gap: 4px;
    }
    
    .mobile-bottom-nav .nav-icon img {
        width: 22px;
        height: 22px;
    }
}

/* Utility Classes */
.text-center { text-align: center; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }