:root {
    --primary-yellow: #FFD60A;
    --dark-bg: #212529;
    --dark-panel: #343A40;
    --light-text: #f8f9fa;
    --dark-text: #212529;
    --border-color: #495057;
    --sidebar-width: 260px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f4f7f6;
    color: var(--dark-text);
    display: flex;
}

a {
    text-decoration: none;
    color: inherit;
}


.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    background-color: var(--dark-bg);
    color: var(--light-text);
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease-in-out;
    z-index: 1000;
}

.sidebar-header {
    padding: 20px;
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-header .logo {
    color: var(--primary-yellow);
}

.sidebar-nav {
    flex-grow: 1;
    list-style: none;
    padding-top: 20px;
}

.sidebar-nav li a {
    display: block;
    padding: 15px 20px;
    color: var(--light-text);
    transition: background-color 0.2s;
}

.sidebar-nav li a:hover {
    background-color: var(--dark-panel);
}

.sidebar-nav li a.active {
    background-color: var(--primary-yellow);
    color: var(--dark-text);
    font-weight: 500;
}

.sidebar-nav li a i {
    margin-right: 15px;
    width: 20px;
    text-align: center;
}

.sidebar-nav li.has-submenu > a {
    position: relative;
}


.submenu-indicator {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    transition: transform 0.3s ease;
}


.submenu {
    list-style: none;
    height: 0;
    overflow: hidden;
    background-color: var(--dark-panel);
    transition: height 0.3s ease-in-out;
}


.submenu li a {
    padding-left: 55px; 
}


.sidebar-nav li.has-submenu.active > .submenu {
    height: auto; 
}


.sidebar-nav li.has-submenu.active > a .submenu-indicator {
    transform: translateY(-50%) rotate(90deg);
}


.main-content {
    margin-left: var(--sidebar-width);
    width: calc(100% - var(--sidebar-width));
    transition: margin-left 0.3s ease-in-out;
    padding: 20px;
}

/* --- Üst Bar (Header) --- */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    padding: 10px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.menu-toggle {
    display: none;
    /* Mobilde görünecek */
    font-size: 24px;
    cursor: pointer;
}

.user-profile {
    font-weight: 500;
}

/* --- İçerik Bileşenleri (Dashboard) --- */
.content-area {
    margin-top: 20px;
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.card {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.card h3 {
    font-size: 16px;
    color: #6c757d;
}

.card .value {
    font-size: 32px;
    font-weight: 600;
    color: var(--dark-text);
}

.card .icon {
    font-size: 36px;
    color: var(--primary-yellow);
    opacity: 0.7;
}

.panel {
    background: #fff;
    margin-top: 30px;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.panel-header {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}


.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.table th {
    font-weight: 600;
}


@media (max-width: 992px) {
    :root {
        --sidebar-width: 220px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .main-content {
        width: 100%;
        margin-left: 0;
    }

    .menu-toggle {
        display: block;
    }
}

.card {
    background-color: #fff;
    border: 1px solid #e3e6f0;
    border-radius: 8px;
    margin-bottom: 25px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background-color: #f8f9fc;
    border-bottom: 1px solid #e3e6f0;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

.card-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--dark-text); 
}

.card-body {
    padding: 20px;
}

.card-footer {
    padding: 15px 20px;
    background-color: #f8f9fc;
    border-top: 1px solid #e3e6f0;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

.btn-primary {
    color: var(--dark-text);
    background-color: var(--primary-yellow);
    border-color: var(--primary-yellow);
    font-weight: 600;
}

.btn-primary:hover,
.btn-primary:focus {
    color: var(--dark-text);
    background-color: #ffde2e;
    border-color: #ffde2e;
    opacity: 1;
}

.form-control:focus {
    border-color: var(--primary-yellow);
    box-shadow: 0 0 0 0.2rem rgba(255, 214, 10, .25);
}

.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 26px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  -webkit-transition: .4s;
  transition: .4s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  -webkit-transition: .4s;
  transition: .4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: #28a745; 
  border-color: #145523;
}

input:focus + .slider {
  box-shadow: 0 0 1px var(--primary-yellow);
}

input:checked + .slider:before {
  -webkit-transform: translateX(24px);
  -ms-transform: translateX(24px);
  transform: translateX(24px);
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px; /* Başlık ile altındaki kart arasına boşluk */
    padding-bottom: 10px;
    border-bottom: 1px solid #e3e6f0;
}

.page-header h1 {
    margin: 0;
    font-size: 24px;
    font-weight: 500;
}

.swal2-container {
    z-index: 9999 !important;
}

body.swal2-shown:not(.modal-open) {
    padding-right: 0px !important;
}

.swal2-popup {
    font-size: 16px !important;
}

.message-detail-page .card-body .info-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.message-detail-page .info-list li {
    display: flex;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
    font-size: 15px;
}

.message-detail-page .info-list li:last-child {
    border-bottom: none;
}

.message-detail-page .info-list li .info-icon {
    width: 30px;
    font-size: 16px;
    color: #888;
    margin-right: 10px;
    text-align: center;
}

.message-detail-page .info-list li a {
    color: #007bff;
    text-decoration: none;
}

.message-detail-page .info-list li a:hover {
    text-decoration: underline;
}

.message-detail-page .message-content {
    font-size: 16px;
    line-height: 1.8;
    white-space: pre-wrap; 
    color: #333;
}