/* Genel Stiller */
:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --secondary-color: #64748b;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --background: #f8fafc;
    --surface: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    background-color: var(--background);
    color: var(--text-primary);
}

/* Header Stili */
.main-header {
    background-color: var(--surface);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    height: 64px;
}

.logo a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    letter-spacing: -0.025em;
}

/* Ana Menü */
.main-nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.main-nav a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}

.main-nav a:hover {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

/* Kullanıcı Menüsü */
.user-menu {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-name {
    color: var(--text-secondary);
    font-weight: 500;
}

.logout-btn {
    padding: 0.5rem 1rem;
    background-color: var(--surface);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

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

/* İçerik Konteyneri */
.content-container {
    max-width: 1280px;
    margin: 2rem auto;
    padding: 0 2rem;
}

/* Başlık Alanı */
.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.content-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* Butonlar */
.button {
    display: inline-flex;
    align-items: center;
    padding: 0.625rem 1rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0.375rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
}

.button:hover {
    background-color: var(--primary-hover);
}

.button.secondary {
    background-color: var(--surface);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.button.secondary:hover {
    background-color: var(--background);
    color: var(--text-primary);
}

.button.small {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

/* Tablolar */
.data-table {
    width: 100%;
    background-color: var(--surface);
    border-radius: 0.5rem;
    box-shadow: var(--shadow-sm);
    border-collapse: collapse;
    margin: 1rem 0;
}

.data-table th {
    background-color: var(--background);
    color: var(--text-secondary);
    font-weight: 500;
    text-align: left;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.data-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
}

.data-table tr:last-child td {
    border-bottom: none;
}

/* Formlar */
.form {
    background-color: var(--surface);
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.625rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    background-color: var(--surface);
    color: var(--text-primary);
    transition: all 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Durum Rozetleri */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
}

.status-badge.pending {
    background-color: var(--warning-color);
    color: #fff;
}

.status-badge.paid {
    background-color: var(--success-color);
    color: #fff;
}

.status-badge.overdue {
    background-color: var(--danger-color);
    color: #fff;
}

/* İstatistik Kartları */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.stat-box {
    background-color: var(--surface);
    padding: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
}

.stat-box h4 {
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.stat-box p {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
}

/* Uyarı ve Bildirimler */
.success,
.error {
    padding: 1rem;
    border-radius: 0.375rem;
    margin-bottom: 1rem;
}

.success {
    background-color: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.error {
    background-color: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* Abonelik Detay Sayfası */
.subscription-details .section {
    background: var(--surface);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
}

.subscription-details .section h3 {
    color: var(--text-primary);
    font-size: 1.25rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.subscription-details p {
    margin-bottom: 0.5rem;
}

.subscription-details p strong {
    color: var(--text-secondary);
    display: inline-block;
    width: 150px;
}

/* Fatura Detay Sayfası */
.invoice-details {
    max-width: 1000px;
    margin: 0 auto;
}

.invoice-header {
    background: var(--surface);
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.invoice-header .company-info h2 {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.invoice-header .invoice-info {
    text-align: right;
}

.invoice-header .invoice-info h1 {
    font-size: 2rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.invoice-header .invoice-number {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.invoice-header .invoice-dates {
    color: var(--text-secondary);
    margin-top: 1rem;
}

.invoice-body {
    background: var(--surface);
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.invoice-body .customer-details {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.invoice-body h3 {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.invoice-items {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}

.invoice-items th {
    background: var(--background);
    padding: 1rem;
    text-align: left;
    font-weight: 500;
    color: var(--text-secondary);
}

.invoice-items td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.invoice-items tr:last-child td {
    border-bottom: none;
}

.invoice-items .amount {
    text-align: right;
}

.invoice-totals {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 2px solid var(--border-color);
}

.invoice-totals table {
    width: 100%;
    max-width: 400px;
    margin-left: auto;
}

.invoice-totals td {
    padding: 0.5rem 1rem;
}

.invoice-totals .total-label {
    color: var(--text-secondary);
    font-weight: 500;
}

.invoice-totals .total-amount {
    text-align: right;
    font-weight: 700;
    font-size: 1.1rem;
}

.invoice-totals .grand-total {
    font-size: 1.25rem;
    color: var(--primary-color);
}

.invoice-footer {
    background: var(--surface);
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.payment-history {
    background: var(--surface);
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
}

.payment-history h3 {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.payment-list {
    width: 100%;
    border-collapse: collapse;
}

.payment-list th {
    background: var(--background);
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 500;
    color: var(--text-secondary);
}

.payment-list td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.payment-list tr:last-child td {
    border-bottom: none;
}

.payment-method {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    background: var(--background);
    border-radius: 9999px;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.invoice-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.status-badge.draft {
    background-color: var(--secondary-color);
    color: #fff;
}

.status-badge.cancelled {
    background-color: var(--text-secondary);
    color: #fff;
}

@media print {
    .no-print {
        display: none;
    }
    
    body {
        background: white;
    }
    
    .invoice-details {
        max-width: none;
        margin: 0;
        padding: 20px;
    }
    
    .invoice-header,
    .invoice-body,
    .invoice-footer {
        box-shadow: none;
        border: none;
        padding: 0;
        margin-bottom: 30px;
    }
}

/* Rapor Bölümleri */
.report-section {
    background: var(--surface);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
}

.report-section h3 {
    color: var(--text-primary);
    font-size: 1.25rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.filter-section {
    background: var(--surface);
    padding: 1rem;
    margin-bottom: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
}

.filter-form {
    display: flex;
    gap: 1rem;
    align-items: flex-end;
}

.filter-form .form-group {
    margin: 0;
}

.chart-container {
    min-height: 300px;
    margin-top: 1rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stat-box {
    background: var(--surface);
    padding: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
    text-align: center;
}

.stat-box h3 {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.stat-box p {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
}

.no-data {
    text-align: center;
    color: var(--text-secondary);
    padding: 2rem;
    font-style: italic;
}

.button-group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.button.danger {
    background-color: var(--danger-color);
}

.button.danger:hover {
    background-color: #dc2626;
} 