html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
    position: relative;
    min-height: 100%;
}

/*body {
    margin-bottom: 60px;
    font-family: 'Open Sans', sans-serif !important;
    font-optical-sizing: auto;
    font-weight: 550;
    font-style: normal;
    font-variation-settings: "wdth" 100;
}*/


body {
    font-family: 'Open Sans', sans-serif !important;
    overflow-x: hidden;
    background-color: #f4f6f8;
    margin: 0;
}

/* Sidebar */
#sidebar {
    width: 235px;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    background-color: #fff;
    border-right: 1px solid #e0e0e0;
    padding-top: 1.5rem;
    box-shadow: 2px 0 6px rgba(0, 0, 0, 0.05);
    z-index: 1030;
    overflow-y: auto;
    transition: margin-left 0.3s ease;
    /* Scrollbar'ı gizle */
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* Internet Explorer 10+ */
}

    #sidebar::-webkit-scrollbar {
        display: none;
        /* Chrome, Safari, Opera */
    }


body.sidebar-collapsed #sidebar {
    margin-left: -260px;
}

/* Topbar artık sidebar'ın yanında */
#topbar {
    position: fixed;
    top: 0;
    left: 235px;
    right: 0;
    height: 50px;
    background-color: #fff;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0 1rem;
    z-index: 1050;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
    transition: left 0.3s ease;
}

body.sidebar-collapsed #topbar {
    left: 0;
}

#sidebarToggle {
    background-color: #fd7e14;
    border: none;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
    box-shadow: 0 2px 6px rgb(0 0 0 / 0.15);
}

    #sidebarToggle:hover {
        background-color: #e06700;
    }

/* İçerik */
#content {
    margin-left: 235px;
    padding: 3.5rem 1rem 1rem 1rem;
    min-height: 100vh;
    position: relative;
    z-index: 1;
    background: white;
    transition: margin-left 0.3s ease;
}

body.sidebar-collapsed #content {
    margin-left: 0;
}

/* Mobilde sidebar gizlenir */
@media (max-width: 768px) {
    #sidebar {
        margin-left: -235px;
        margin-top: 30px;
    }

    body:not(.sidebar-collapsed) #sidebar {
        margin-left: 0;
        box-shadow: 2px 0 8px rgba(0, 0, 0, 0.2);
    }

    #topbar {
        left: 0;
    }

    #content {
        margin-left: 0;
    }
}

/* Sidebar Logo */
#sidebar .logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 1rem;
    user-select: none;
    padding-bottom: 20px;
}

    #sidebar .logo img {
        height: 100px;
    }

    #sidebar .logo span {
        font-weight: 700;
        font-size: 1.3rem;
        color: #2c3e50;
    }

/* Menü */
#sidebar ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

    #sidebar ul li {
        user-select: none;
    }

        #sidebar ul li a,
        #sidebar ul li a:visited {
            display: flex;
            justify-content: space-between;
            align-items: center;
            color: #34495e;
            font-weight: 600;
            padding: 0.75rem 2rem;
            border-left: 4px solid transparent;
            border-bottom: 3px solid transparent;
            text-decoration: none;
            cursor: pointer;
            transition: border-color 0.3s ease, color 0.3s ease;
        }

            #sidebar ul li a:hover {
                color: #fd7e14;
            }

            #sidebar ul li a.active {
                color: #fd7e14;
                border-left-color: #fd7e14;
                font-weight: 700;
            }

        #sidebar ul li.hass-dropdown > a::after {
            font-size: 1rem;
            color: #34495e;
            transition: transform 0.3s ease;
        }

        #sidebar ul li ul.dropdown-menuss {
            max-height: 0;
            overflow: hidden;
            transition: max-height 0.3s ease;
            background: white;
            padding-left: 0;
        }

        #sidebar ul li.open ul.dropdown-menuss {
            max-height: 500px;
            padding-top: 0.5rem;
            padding-bottom: 0.5rem;
        }

        #sidebar ul li ul.dropdown-menuss li a {
            padding: 0.5rem 3rem;
            font-weight: 500;
            color: #34495e;
        }

            #sidebar ul li ul.dropdown-menuss li a:hover,
            #sidebar ul li ul.dropdown-menuss li a.active {
                color: #fd7e14;
            }

        #sidebar ul li.hass-dropdown.open .dropdown-icon {
            transform: rotate(90deg);
            color: #fd7e14;
            transition: transform 0.3s ease;
        }

/* Form-floating container yüksekliği */
.form-floating > .select2-container {
    height: calc(3.5rem + 2px) !important;
}

/* Select alanı: sadece alt border */
.form-floating > .select2-container--bootstrap-5 .select2-selection {
    position: relative;
    height: 100% !important;
    padding-top: 1.625rem !important;
    padding-left: 1.2rem !important;
    /* solda ikon için boşluk */
    border: none !important;
    border-bottom: 1px solid #ccc !important;
    border-radius: 0 !important;
    background-color: transparent !important;
    box-shadow: none !important;
    transition: border-color 0.3s ease-in-out;
}

/* Tıklanınca border animasyonu (alt çizgi siyah) */
.form-floating > .select2-container--bootstrap-5.select2-container--open .select2-selection {
    border-bottom-color: #000 !important;
}

/* Label'ın üstte kalması */
.form-floating > label {
    z-index: 3;
    margin-left: 0.2rem;
}

.select2-container--bootstrap-5 .select2-selection__clear {
    position: absolute;
    top: 70% !important;
    left: 0.3rem !important;
    right: 0rem !important;
    width: .40rem !important;
    height: .40rem !important;
    padding: .20rem !important;
    overflow: hidden;
    text-indent: 100%;
    white-space: nowrap;
    background: transparent url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ff0000'%3e%3cpath d='M.293.293a1 1 0 011.414 0L8 6.586 14.293.293a1 1 0 111.414 1.414L9.414 8l6.293 6.293a1 1 0 01-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 01-1.414-1.414L6.586 8 .293 1.707a1 1 0 010-1.414z'/%3e%3c/svg%3e") 50%/.75rem auto no-repeat !important;
    transform: translateY(-50%);
}

/* Placeholder'ın kaybolmasını önlemek için */
.select2-container--bootstrap-5 .select2-selection__rendered {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered .select2-selection__placeholder {
    font-weight: 400;
    line-height: 1.5;
    color: black !important;
}


@media (min-width: 768px) {
    .border-md-end {
        border-right: 1px solid #dee2e6 !important; /* Bootstrap'in default border rengi */
    }
}



.select2-container.is-invalid .select2-selection {
    border-color: #dc3545 !important; /* Bootstrap kırmızı */
    box-shadow: 0 0 0 0.2rem rgba(220,53,69,.25);
    border-radius: .375rem; /* opsiyonel, form-control gibi */
}



.hover-effect {
    transition: transform 0.2s, box-shadow 0.2s;
}

    .hover-effect:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    }
