* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Jost', sans-serif; /* Iestata fontu visiem elementiem */
}

body {
    display: flex;
    background-color: #f5f5dc; /* Bēšs fona krāsa */
    height: 100vh; /* Augstums aizņem visu skatlogu */
}

.sidebar {
    width: 60px;
    height: 100vh;
    background-color: #333; /* Tumšs sānu joslas fons */
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 0;
    position: fixed; /* Fiksēta pozīcija sānu joslai */
    top: 0;
    left: 0;
}

.sidebar-icons {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px; /* Atstarpe starp ikonām */
    justify-content: center; /* Vertikāli centrē ikonas */
}

.sidebar-icons a {
    display: block;
    margin: 15px 0; /* Vertikāla atstarpe starp ikonām */
}

/* Icon default styling */
.sidebar-icons img {
    width: 30px;
    height: 30px;
    filter: brightness(0) invert(1); /* Padara ikonas baltas */
    transition: filter 0.3s, transform 0.3s, filter 0.3s; /* Smooth transitions */
}

/* Active icon styling */
.sidebar-icons a.active img {
    filter: brightness(0.4); /* Padara aktīvo ikonu tumšāku */
}

/* Hover effect: Subtle glow effect on the icon itself */
.sidebar-icons a:hover img {
    transform: scale(1.05); /* Slightly increase the size */
    filter: drop-shadow(0 0 3px rgba(255, 255, 255, 0.5)) brightness(1.3); /* Subtle glow effect */
}

.content {
    margin-left: 80px; /* Atstarpe no sānu joslas */
    padding: 20px;
    width: calc(100% - 80px); /* Pielāgo platumu, ņemot vērā sānu joslu */
    display: flex;
    flex-direction: column;
    height: 100vh; /* Pilna augstuma konteiners */
}

h1 {
    font-size: 24px;
    margin-bottom: 20px;
}

.chat-container {
    flex: 1; /* Izstiepjas līdz brīvajam vietas augstumam */
    overflow-y: auto; /* Vertikāla ritināšana, ja nepieciešams */
    padding: 10px;
    background-color: #fff; /* Balts fons tērzēšanas zonai */
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* Ēnas efekts */
    margin-bottom: 10px;
}

.chat-message {
    display: flex;
    align-items: flex-end;
    margin: 10px 0;
}

.user {
    justify-content: flex-end; /* Lietotāja ziņojums pielīdzināts pa labi */
}

.user .message-bubble {
    background-color: #d3d3d3; /* Lietotāja ziņojuma burbuļa krāsa */
    color: black;
    text-align: right;
}

.message-bubble {
    background-color: #87CEFA; /* AI ziņojuma burbuļa krāsa */
    color: black;
    padding: 10px 15px;
    border-radius: 15px; /* Noapaļotas malas ziņojumu burbuļiem */
    max-width: 60%; /* Maksimālais burbuļa platums */
}

.avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%; /* Apļa formas attēls */
    margin: 0 10px;
}

.user-avatar {
    order: 1; /* Lietotāja avatārs novietots pa labi */
    margin-left: 10px;
}

.input-container {
    display: flex;
    align-items: center;
    padding: 10px;
    background-color: #333; /* Tumšs fons ievades konteineram */
    border-radius: 5px;
}

input[type="text"] {
    flex: 1; /* Izstiepjas līdz atlikušajai vietai */
    padding: 10px;
    font-size: 16px;
    border: none;
    color: white;
    background-color: #333; /* Tumšs ievades lauks */
    outline: none;
}

input::placeholder {
    color: #bbb; /* Viettura teksts gaišāks */
}

button {
    background: none;
    border: none;
    color: white; /* Balts pogas teksts */
    font-size: 20px;
    cursor: pointer;
    padding: 0 10px;
}

/* Tooltip styling */
.sidebar-icons a {
    position: relative;
}

.sidebar-icons a:hover::after {
    content: attr(data-tooltip); /* Display tooltip text */
    position: absolute;
    left: 57px; /* Position tooltip to the right of the icon */
    top: 50%;
    transform: translateY(-50%);
    background-color: #444; /* Dark background */
    color: #fff; /* White text */
    padding: 6px 12px;
    border-radius: 8px;
    white-space: nowrap;
    font-size: 12px;
    font-weight: 500;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3); /* Soft shadow */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 1;
}

/* Arrow styling */
.sidebar-icons a:hover::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 48px; /* Center the arrow relative to the icon */
    transform: translateY(-50%);
    border-width: 6px;
    border-style: solid;
    border-color: transparent transparent transparent #444; /* Arrow pointing left */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 1;
}

/* Display tooltip and arrow on hover */
.sidebar-icons a:hover::after,
.sidebar-icons a:hover::before {
    opacity: 1;
    visibility: visible;
}
