:root {
    --bg-color: #0f172a;
    --text-color: #f8fafc;
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --secondary: #10b981;
    --danger: #ef4444;
    --danger-hover: #dc2626;
    --card-bg: rgba(30, 41, 59, 0.7);
    --border-color: rgba(255, 255, 255, 0.1);
    --font-family: 'Inter', system-ui, sans-serif;
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

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

body {
    background-color: var(--bg-color);
    background-image: radial-gradient(circle at 15% 50%, rgba(59, 130, 246, 0.15), transparent 25%),
                      radial-gradient(circle at 85% 30%, rgba(16, 185, 129, 0.15), transparent 25%);
    background-attachment: fixed;
    color: var(--text-color);
    font-family: var(--font-family);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    flex: 1;
}

h1, h2, h3, h4 {
    font-weight: 600;
    margin-bottom: 15px;
    letter-spacing: -0.025em;
}

h1 {
    font-size: 2rem;
    text-align: center;
    background: linear-gradient(135deg, #60a5fa, #34d399);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 30px;
}

.glass-card {
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255,255,255,0.05);
    margin-bottom: 20px;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
    animation: fadeInUp 0.5s ease backwards;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.glass-card:nth-child(1) { animation-delay: 0.1s; }
.glass-card:nth-child(2) { animation-delay: 0.2s; }
.glass-card:nth-child(3) { animation-delay: 0.3s; }
.glass-card:nth-child(4) { animation-delay: 0.4s; }
.glass-card:nth-child(5) { animation-delay: 0.5s; }

.glass-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255,255,255,0.1);
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: #94a3b8;
    font-weight: 500;
}

input[type="text"],
input[type="number"],
select {
    width: 100%;
    padding: 14px 16px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: white;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
    font-family: var(--font-family);
}

input:focus, select:focus {
    border-color: var(--primary);
    background: rgba(0, 0, 0, 0.4);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15);
}

button {
    background: linear-gradient(135deg, var(--primary), #2563eb);
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: all 0.2s ease;
    font-family: var(--font-family);
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
    filter: brightness(1.1);
}

button:active {
    transform: scale(0.96);
}

button.btn-danger {
    background: linear-gradient(135deg, var(--danger), #b91c1c);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

button.btn-danger:hover {
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
}

button.btn-success {
    background: linear-gradient(135deg, var(--secondary), #047857);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

button.btn-success:hover {
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.balance-display {
    text-align: center;
    padding: 30px;
}

.balance-display .amount {
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(to right, #fbbf24, #f59e0b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 15px rgba(251, 191, 36, 0.4));
}

.players-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.player-card {
    text-align: center;
    padding: 10px;
    cursor: pointer;
    border-radius: 4px !important;
}

.player-card.selected {
    border-color: var(--primary);
    background: rgba(59, 130, 246, 0.4);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
}

.player-name {
    font-weight: 600;
    margin-bottom: 2px;
    font-size: 0.85rem;
    word-break: break-all;
}

.player-balance {
    color: #fbbf24;
    font-weight: 500;
    font-size: 0.8rem;
}

.history-list {
    max-height: 300px;
    overflow-y: auto;
}

.history-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

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

.history-desc {
    font-size: 0.9rem;
    color: #cbd5e1;
}

.history-amount {
    font-weight: 600;
}

.history-amount.positive { color: var(--secondary); }
.history-amount.negative { color: var(--danger); }

#qr-code {
    display: flex;
    justify-content: center;
    margin: 20px 0;
    padding: 20px;
    background: white;
    border-radius: 12px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(5px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 24px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.close-modal {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 1.5rem;
    cursor: pointer;
    width: auto;
    padding: 0;
}

/* Properties Grid */
.properties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
    max-height: 400px;
    overflow-y: auto;
}

.property-card {
    border: 2px solid transparent;
    padding: 15px;
    border-radius: 12px;
    background: rgba(0,0,0,0.3);
    cursor: pointer;
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.property-card:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 24px rgba(0,0,0,0.5);
    border-color: rgba(255,255,255,0.2);
}

.property-card.selected {
    border-color: var(--primary);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.6);
    background: rgba(59, 130, 246, 0.1);
}

.property-card .color-strip {
    height: 10px;
    border-radius: 4px;
    margin-bottom: 10px;
}

.property-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.property-price {
    color: #94a3b8;
    font-size: 0.9rem;
}

.property-status {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(0,0,0,0.5);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
}

/* Color Groups */
.group-Kahverengi { background: #8B4513; }
.group-Açık { background: #32CD32; } /* Açık Yeşil */
.group-Pembe { background: #FF69B4; }
.group-Turuncu { background: #FFA500; }
.group-Kırmızı { background: #FF0000; }
.group-Sarı { background: #FFD700; }
.group-Siyah { background: #000000; }
.group-Yeşil { background: #008000; }
.group-Lacivert { background: #000080; }
.group-Kamu { background: #555555; }
.group-Mor { background: #800080; }
.group-Mavi { background: #007BFF; }

/* Responsive */
@media (max-width: 600px) {
    .container {
        padding: 10px;
    }
    .glass-card {
        padding: 15px;
    }
    .balance-display .amount {
        font-size: 2.5rem;
    }
}
