* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: #f5f5f7;
    color: #1d1d1f;
    -webkit-font-smoothing: antialiased;
    transition: background 0.3s, color 0.3s;
    touch-action: pan-x pan-y;
}

button,
a,
.task-item,
.tab,
.mobile-tab,
.menu-item {
    touch-action: manipulation;
}

input,
textarea {
    -webkit-user-select: text;
    user-select: text;
}

/* Login Styles */
.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    min-height: 100dvh;
    background: url(girisbckground.jpg);
}

.login-box {
    background: white;
    padding: 48px 40px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-logo {
    max-width: 200px;
    height: auto;
    margin-bottom: 24px;
}

.login-box h1 {
    font-size: 28px;
    margin-bottom: 32px;
    color: #1d1d1f;
    font-weight: 600;
}

.error-message {
    background: #fee;
    color: #c33;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group input[type="text"],
.form-group input[type="password"] {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #d2d2d7;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.remember-group {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.remember-group label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 14px;
    color: #6e6e73;
}

.remember-group input[type="checkbox"] {
    margin-right: 8px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.login-button {
    background: linear-gradient(135deg, #3a3a3a 0%, #1a1a1a 100%);
    color: white;
    border: none;
    padding: 14px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
}

.login-button:hover {
    transform: translateY(-2px);
}

.login-button:active {
    transform: translateY(0);
}

/* App Container */
.app-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    height: 100dvh;
    background: #f5f5f7;
    transition: background 0.3s;
}

.header {
    background: #2c2c2e;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
    gap: 20px;
    transition: background 0.3s, box-shadow 0.3s;
    flex-shrink: 0;
}

.header-logo {
    height: 32px;
    width: auto;
}

.tabs {
    display: flex;
    gap: 12px;
    flex: 1;
    justify-content: center;
    max-width: 500px;
}

.tab {
    background: white;
    border: 3px solid transparent;
    padding: 10px 50px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    color: #6e6e73;
    transition: all 0.2s;
}

.tab.active {
    background: white;
    border-color: #667eea;
    color: #667eea;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-name {
    font-size: 14px;
    color: #f1f1f1;
    font-weight: 500;
    transition: color 0.3s;
}

.logout-button {
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #98989d;
    border-radius: 8px;
    transition: all 0.2s;
}

.logout-button:hover {
    background: #3a3a3c;
}

.desktop-only {
    display: flex;
}

/* Menu Dropdown */
.menu-container {
    position: relative;
}

.menu-button {
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #98989d;
    border-radius: 8px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-button:hover {
    background: #3a3a3c;
}

.menu-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1000;
    overflow: hidden;
}

.menu-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border: none;
    background: transparent;
    width: 100%;
    text-align: left;
    cursor: pointer;
    color: #1d1d1f;
    font-size: 14px;
    transition: background 0.2s;
    position: relative;
}

.menu-item:hover {
    background: #f5f5f7;
}

.menu-item svg {
    flex-shrink: 0;
}

.menu-item span:not(.checkmark) {
    flex: 1;
}

.checkmark {
    margin-left: auto;
    color: #667eea;
    font-weight: bold;
    display: none;
}

.menu-divider {
    height: 1px;
    background: #e5e5e7;
    margin: 4px 0;
}

/* Mobile Tabs */
.mobile-tabs {
    display: none;
}

.content {
    display: flex;
    flex: 1;
    overflow: hidden;
    min-height: 0;
}

.tasks-list {
    width: 600px;
    background: white;
    border-right: 1px solid #e5e5e7;
    overflow-y: auto;
    transition: background 0.3s, border-color 0.3s;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
}

.tasks-list::-webkit-scrollbar {
    width: 6px;
}

.tasks-list::-webkit-scrollbar-track {
    background: transparent;
}

.tasks-list::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.tasks-list::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

.new-task-button {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    cursor: pointer;
    border-bottom: 1px solid #e5e5e7;
    background: #fafafa;
    font-weight: 500;
    color: #667eea;
    transition: background 0.2s, border-color 0.3s;
    flex-shrink: 0;
}

.new-task-button:hover {
    background: #f0f0f2;
}

.task-item {
    padding: 12px 20px;
    border-bottom: 1px solid #e5e5e7;
    cursor: pointer;
    transition: background 0.2s, border-color 0.3s;
}

.task-item:hover {
    background: #fafafa;
}

.task-item.active {
    background: #f5f5f7;
}

.task-item-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1d1d1f;
    transition: color 0.3s;
}

.task-item-preview {
    display: flex;
    gap: 8px;
    font-size: 12px;
    color: #86868b;
    transition: color 0.3s;
}

.task-date {
    flex-shrink: 0;
}

.task-description {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bos-liste {
    padding: 40px 20px;
    text-align: center;
    color: #86868b;
    font-size: 14px;
    transition: color 0.3s;
}

.task-detail {
    flex: 1;
    background: white;
    overflow-y: auto;
    transition: background 0.3s;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
}

.task-detail::-webkit-scrollbar {
    width: 6px;
}

.task-detail::-webkit-scrollbar-track {
    background: transparent;
}

.task-detail::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.task-detail::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #86868b;
    transition: color 0.3s;
}

.empty-state svg {
    margin-bottom: 16px;
    opacity: 0.5;
}

.task-detail-content {
    padding: 32px;
    max-width: 800px;
}

.mobile-back-button {
    display: none;
}

.task-title-input {
    width: 100%;
    border: none;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
    padding: 8px 0;
    color: #1d1d1f;
    transition: color 0.3s, background 0.3s;
}

.task-title-input:focus {
    outline: none;
}

.task-date-info {
    font-size: 13px;
    color: #86868b;
    margin-bottom: 20px;
    transition: color 0.3s;
}

.task-completed-date {
    margin-top: 4px;
    color: #34c759;
}

.task-description-input {
    width: 100%;
    border: none;
    font-size: 16px;
    line-height: 1.6;
    min-height: 300px;
    resize: none;
    color: #1d1d1f;
    font-family: inherit;
    transition: color 0.3s, background 0.3s;
}

.task-description-input:focus {
    outline: none;
}

.task-actions {
    display: flex;
    gap: 12px;
    margin-top: 32px;
}

.save-button,
.complete-button,
.uncomplete-button,
.delete-button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.save-button {
    background: linear-gradient(135deg, #1e7e34 0%, #155724 100%);
    color: white;
}

.save-button:hover {
    background: linear-gradient(135deg, #176329 0%, #0e3d18 100%);
}

.complete-button {
    background: linear-gradient(135deg, #0078d4 0%, #005a9e 100%);
    color: white;
}

.complete-button:hover {
    background: linear-gradient(135deg, #106ebe 0%, #004578 100%);
}

.uncomplete-button {
    background: #ff9500;
    color: white;
}

.uncomplete-button:hover {
    background: #e68600;
}

.delete-button {
    background: #ff3b30;
    color: white;
}

.delete-button:hover {
    background: #e6352a;
}


/* SADECE YENİ İŞ OLUŞTURMA EKRANI İÇİN ÖZEL STİLLER */
@media (max-width: 768px) {
    /* Yeni iş modunda butonları sağ üste al */
    .task-detail-content.new-task-mode .task-actions {
        position: absolute !important;
        top: 16px !important;
        right: 16px !important;
        flex-direction: row !important;
        margin-top: 0 !important;
        z-index: 10;
    }
    
    /* Yeni iş modunda İptal/Sil butonunu gizle */
    .task-detail-content.new-task-mode .delete-button {
        display: none !important;
    }
    
    /* Yeni iş modunda Oluştur butonunu özelleştir */
    .task-detail-content.new-task-mode .complete-button {
        width: 65px !important;
        height: 60px !important;
        padding: 0 !important;
        padding-left: 10px !important;
        font-size: 0 !important;
        line-height: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        border-radius: 12px !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
    }
    
    /* Yeni iş modunda ikon büyüt */
    .task-detail-content.new-task-mode .complete-button svg {
        width: 32px !important;
        height: 32px !important;
        margin: 0 !important;
        display: block !important;
    }
}

/* Masaüstünde menüden çıkış butonunu gizle */
@media (min-width: 769px) {
    .cikis-item,
    .cikis-divider {
        display: none !important;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .desktop-only {
        display: none !important;
    }
    
    .tabs {
        display: none !important;
    }
    
    /* Mobilde active class'ı devre dışı bırak */
    .task-item.active {
        background: transparent !important;
    }
    
    .mobile-tabs {
        display: flex;
        gap: 0;
        background: white;
        border-bottom: 1px solid #e5e5e7;
        flex-shrink: 0;
    }
    
    .mobile-tab {
        flex: 1;
        background: transparent;
        border: none;
        padding: 14px 20px;
        cursor: pointer;
        font-size: 15px;
        font-weight: 600;
        color: #6e6e73;
        transition: all 0.2s;
        border-bottom: 3px solid transparent;
    }
    
    .mobile-tab.active {
        color: #667eea;
        border-bottom-color: #667eea;
    }
    
    .mobile-back-button {
        display: block;
        font-size: 18px;
        color: #667eea;
        cursor: pointer;
        padding: 10px 0;
        font-weight: 600;
        margin-bottom: 10px;
    }
    
    .header {
        padding: 12px 12px;
    }
    
    .header-logo {
        height: 28px;
    }
    
    .user-name {
        display: none;
    }
    
    .content {
        position: relative;
    }
    
    .tasks-list {
        width: 100%;
    }
    
    .task-detail {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1000;
        transform: translateX(100%);
        transition: transform 0.3s ease;
    }
    
    .task-detail.mobile-active {
        transform: translateX(0);
    }
    
    .task-detail-content {
        padding: 20px 16px;
        height: 100%;
        overflow-y: auto;
    }
    
    .task-title-input {
        font-size: 24px;
    }
    
    .task-actions {
        flex-direction: column;
    }
    
    .save-button,
    .complete-button,
    .uncomplete-button,
    .delete-button {
        width: 100%;
        justify-content: center;
    }
    
    /* Mobilde buton sıralaması: Kaydet (1), Bitir (2), Sil (3) */
    .save-button {
        order: 1;
    }
    
    .complete-button {
        order: 2;
    }
    
    .uncomplete-button {
        order: 2;
    }
    
    .delete-button {
        order: 3;
    }
}

/* Yeni iş formunda başlık altına çizgi */
.new-task-mode .task-title-input {
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 15px;
    margin-bottom: 15px;
}

.dark-mode .new-task-mode .task-title-input {
    border-bottom-color: #404040;
}

/* Normal formlarda tarih bilgisi altına çizgi */
.task-date-info {
    padding-bottom: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.dark-mode .task-date-info {
    border-bottom-color: #404040;
}


/* Dark Mode Styles */
body.login-page {
    background: url(girisbckground.jpg) !important;
}

body.dark-mode {
    background: #1d1d1f;
    color: #f5f5f7;
}

body.dark-mode .app-container {
    background: #1d1d1f;
}

body.dark-mode .header {
    background: #2c2c2e;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

body.dark-mode .tab {
    color: #98989d;
}

body.dark-mode .tab.active {
    background: white;
    border-color: #667eea;
    color: #667eea;
}

body.dark-mode .user-name {
    color: #98989d;
}

body.dark-mode .logout-button,
body.dark-mode .menu-button {
    color: #98989d;
}

body.dark-mode .logout-button:hover,
body.dark-mode .menu-button:hover {
    background: #3a3a3c;
}

body.dark-mode .menu-dropdown {
    background: #2c2c2e;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

body.dark-mode .menu-item {
    color: #f5f5f7;
}

body.dark-mode .menu-item:hover {
    background: #3a3a3c;
}

body.dark-mode .menu-divider {
    background: #48484a;
}

body.dark-mode .mobile-tabs {
    background: #2c2c2e;
    border-bottom: 1px solid #3a3a3c;
}

body.dark-mode .mobile-tab {
    color: #98989d;
}

body.dark-mode .mobile-tab.active {
    color: #667eea;
}

body.dark-mode .tasks-list {
    background: #2c2c2e;
    border-right: 1px solid #3a3a3c;
}

body.dark-mode .tasks-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
}

body.dark-mode .tasks-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.4);
}

body.dark-mode .new-task-button {
    background: #3a3a3c;
    color: #667eea;
    border-bottom: 1px solid #48484a;
}

body.dark-mode .new-task-button:hover {
    background: #48484a;
}

body.dark-mode .task-item {
    border-bottom: 1px solid #3a3a3c;
}

body.dark-mode .task-item:hover {
    background: #3a3a3c;
}

body.dark-mode .task-item.active {
    background: #48484a;
}

body.dark-mode .task-item-title {
    color: #f5f5f7;
}

body.dark-mode .task-item-preview {
    color: #98989d;
}

body.dark-mode .bos-liste {
    color: #98989d;
}

body.dark-mode .task-detail {
    background: #2c2c2e;
}

body.dark-mode .task-detail::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
}

body.dark-mode .task-detail::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.4);
}

body.dark-mode .empty-state {
    color: #98989d;
}

body.dark-mode .task-title-input,
body.dark-mode .task-description-input {
    color: #f5f5f7;
    background: #2c2c2e;
}

body.dark-mode .task-date-info {
    color: #98989d;
}

body.dark-mode .task-completed-date {
    color: #34c759;
}

body.dark-mode .mobile-back-button {
    color: #667eea;
}

/* Ekstralar *\

/* Şifre görünürlük butonu */
.password-group {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6e6e73;
    transition: color 0.2s;
}

.toggle-password:hover {
    color: #000000;
}

.toggle-password:focus {
    outline: none;
}

/* Mobil için touch-action ve aktif durum */
.toggle-password {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.toggle-password:active {
    color: #000000;
}

/* Mobil responsive */
@media (max-width: 768px) {
    .toggle-password {
        right: 10px;
        padding: 8px;
    }
    
    .toggle-password svg {
        width: 22px;
        height: 22px;
    }
}

