/* MOBILE HEADER STYLES - Modern Hamburger Menu */

/* Mobile Header - Varsayılan olarak gizli */
.mobile-header {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    right: 0;
    width: 50%;
    max-width: 350px;
    height: 100vh;
    max-height: 100vh;
    background: var(--card-bg) !important;
    z-index: 2000;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -2px 0 15px rgba(0, 0, 0, 0.2);
    visibility: hidden;
}

.mobile-header.show {
    visibility: visible;
    transform: translateX(0);
}

/* Backdrop kaldırıldı - sadece menü görünür olacak */

/* When mobile menu is open, force all texts to black */
.mobile-header.show,
.mobile-header.show .mobile-company-name,
.mobile-header.show .mobile-company-subtitle,
.mobile-header.show .mobile-setting-label,
.mobile-header.show .mobile-setting-select,
.mobile-header.show .mobile-setting-select option,
.mobile-header.show .mobile-nav-link,
.mobile-header.show .mobile-nav-link i {
    color: #000 !important;
}

.mobile-header.show .mobile-nav-link:hover,
.mobile-header.show .mobile-nav-link:hover i {
    color: #000 !important;
}

/* Mobile Menu Button - Hamburger Icon */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.75rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: absolute;
    right: 0;
    bottom: 0;
    z-index: 1001;
    min-width: 44px;
    min-height: 44px;
    justify-content: center;
    align-items: center;
    /* Yanlışlıkla dokunmayı önle */
    touch-action: manipulation;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    /* Normal pointer events */
    pointer-events: auto;
}

/* Mobil cihazlarda kesinlikle görünür olsun */
@media (max-width: 900px) {
    .mobile-menu-btn {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: relative !important;
        z-index: 1001 !important;
    }

    .main-nav {
        display: none !important;
    }

    .header-right {
        display: none !important;
    }
}

.mobile-menu-btn:hover {
    background: rgba(27, 73, 101, 0.08);
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(27, 73, 101, 0.15);
}

.mobile-menu-btn:active {
    transform: scale(0.95);
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 3px;
    background: var(--primary);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    position: relative;
}

/* Hamburger Animation */
.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
    transform: scale(0);
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Mobil Menü Kapatma Butonu */
.mobile-menu-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(27, 73, 101, 0.15);
    border: none;
    color: var(--primary);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.mobile-menu-close:hover {
    background: rgba(27, 73, 101, 0.25);
    transform: scale(1.1) rotate(90deg);
}

.mobile-menu-close:active {
    transform: scale(0.9) rotate(90deg);
}

.mobile-menu-close span {
    font-size: 1.8rem;
    font-weight: bold;
    line-height: 1;
    transition: transform 0.3s ease;
}

/* Mobile Header Top */
.mobile-header-top {
    padding: 1rem;
    border-bottom: 1px solid rgba(27, 73, 101, 0.2);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    backdrop-filter: blur(10px);
    flex-shrink: 0;
}

/* Mobile Brand */
.mobile-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.mobile-logo-link {
    display: block;
    transition: transform 0.3s ease;
}

.mobile-logo-link:hover {
    transform: scale(1.05);
}

.mobile-logo-link img {
    height: 40px;
    max-width: 120px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(27, 73, 101, 0.2);
}

.mobile-company-info {
    flex: 1;
}

.mobile-company-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0.3rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.mobile-company-subtitle {
    font-size: 0.95rem;
    color: #7f8c8d;
    font-weight: 500;
}

/* Mobile Settings */
.mobile-settings {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.mobile-setting {
    position: relative;
}

.mobile-setting-label {
    display: block;
    margin-bottom: 0.5rem;
    color: #7f8c8d;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mobile-setting-select {
    width: 100%;
    height: 40px;
    padding: 0.5rem 2rem 0.5rem 0.75rem;
    font-size: 0.9rem;
    border-radius: 8px;
    border: 1px solid rgba(27, 73, 101, 0.2);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.7));
    color: #2c3e50;
    font-weight: 500;
    cursor: pointer;
    transition: none;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 4px rgba(27, 73, 101, 0.12);
}

.mobile-setting-select:hover {
    border-color: rgba(27, 73, 101, 0.35);
    box-shadow: 0 4px 12px rgba(27, 73, 101, 0.18);
    transform: none;
}

.mobile-setting-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(27, 73, 101, 0.2), 0 4px 12px rgba(27, 73, 101, 0.18);
    background: linear-gradient(135deg, rgba(255, 255, 255, 1), rgba(248, 244, 255, 0.9));
    transform: none;
}

.mobile-setting-select option {
    background: linear-gradient(135deg, var(--white), var(--background));
    color: #2c3e50;
    padding: 0.75rem;
    font-weight: 500;
}

.mobile-setting-select option:hover {
    background: linear-gradient(135deg, #ffffff, #f8fbff);
    color: var(--primary);
}

.mobile-setting-select option:checked {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}

/* Mobile Navigation */
.mobile-nav {
    padding: 0.75rem;
    position: relative;
    flex: 1;
    overflow-y: auto;
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    padding: 0.5rem 0.75rem;
    color: #2c3e50;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 0.25rem;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(27, 73, 101, 0.12);
}

.mobile-nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(27, 73, 101, 0.12), transparent);
    transition: left 0.5s ease;
}

.mobile-nav-link:hover::before {
    left: 100%;
}

.mobile-nav-link:hover {
    background: linear-gradient(135deg, rgba(108, 166, 205, 0.15), rgba(108, 166, 205, 0.08));
    color: var(--secondary-dark);
    transform: translateX(8px);
    box-shadow: 0 4px 12px rgba(27, 73, 101, 0.18);
    border-color: rgba(27, 73, 101, 0.25);
}

.mobile-nav-link:active {
    transform: translateX(8px) scale(0.98);
}

.mobile-nav-link i {
    margin-right: 0.75rem;
    width: 20px;
    height: 20px;
    color: var(--muted);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-nav-link:hover i {
    color: var(--primary);
    transform: scale(1.1);
}

/* Responsive Design */
@media (max-width: 900px) {
    .mobile-menu-btn {
        display: flex !important;
    }

    .main-nav {
        display: none !important;
    }

    .header-right {
        display: none !important;
    }
}

@media (max-width: 768px) {
    .mobile-header {
        /* Mobil cihazlarda hazır olsun ama gizli */
        position: fixed;
    }

    .mobile-menu-btn {
        display: flex !important;
    }
}

@media (max-width: 480px) {
    .mobile-header {
        width: 70%;
        max-width: 300px;
    }

    .mobile-settings {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .mobile-header-top {
        padding: 0.75rem;
    }

    .mobile-nav {
        padding: 0.5rem;
    }

    .mobile-nav-link {
        padding: 0.4rem 0.6rem;
        font-size: 0.85rem;
        margin-bottom: 0.2rem;
    }

    .mobile-brand {
        margin-bottom: 0.75rem;
        gap: 0.5rem;
    }

    .mobile-logo-link img {
        height: 36px;
        max-width: 100px;
    }

    .mobile-company-name {
        font-size: 1rem;
    }

    .mobile-company-subtitle {
        font-size: 0.8rem;
    }

    .mobile-setting-select {
        height: 36px;
        font-size: 0.85rem;
    }
}

/* Dark Theme Support */
@media (prefers-color-scheme: dark) {
    .mobile-header {
        background: linear-gradient(135deg, #0f1b26, #0c1620);
    }

    .mobile-header-top {
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
        border-bottom-color: rgba(27, 73, 101, 0.3);
    }

    .mobile-company-name {
        color: #e2e8f0;
    }

    .mobile-company-subtitle {
        color: #94a3b8;
    }

    .mobile-setting-label {
        color: #94a3b8;
    }

    .mobile-setting-select {
        background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(51, 65, 85, 0.7));
        color: #e2e8f0;
        border-color: rgba(27, 73, 101, 0.35);
    }

    .mobile-setting-select:focus {
        background: linear-gradient(135deg, rgba(30, 41, 59, 1), rgba(51, 65, 85, 0.9));
    }

    .mobile-nav-link {
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
        color: #e2e8f0;
        border-color: rgba(27, 73, 101, 0.25);
    }

    .mobile-nav-link:hover {
        background: linear-gradient(135deg, rgba(108, 166, 205, 0.18), rgba(108, 166, 205, 0.1));
        color: var(--secondary-dark);
    }

    .mobile-nav-link i {
        color: #94a3b8;
    }

    .mobile-nav-link:hover i {
        color: var(--primary);
    }
}