@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Josefin+Sans:ital,wght@0,100..700;1,100..700&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');
body {
  margin: 0;
  background-color: #0f0422;
  color: #eee;
  font-family: 'Poppins', sans-serif;
}
 
/* Onemogući selektovanje teksta i slika */
body, img {
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    -moz-user-select: none;
   
}

/* Prilagođeni scrollbar - AnimeKai stil */
::-webkit-scrollbar {
    width: 12px; /* Širina skrolbara */
}

::-webkit-scrollbar-track {
    background: #1a1a1a; /* Tamna pozadina skrolbara */
    border-radius: 6px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #6a0dad, #9b30ff); /* Ljubičasti gradijent */
    border-radius: 6px;
    border: 3px solid #1a1a1a; /* Ostavlja tamni okvir za efekat */
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #9b30ff, #6a0dad); /* Efekat pri hoveru */
}

::-webkit-scrollbar-corner {
    background: transparent; /* Uklanja ćošak */
}

#preloader {
    position: fixed;
    width: 100%;
    height: 100%;
    background: #010101;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}
.spinner {
    border: 6px solid rgba(255, 255, 255, 0.2);
    border-top: 6px solid #6a0dad;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}



/* Navbar */
.navbar {
  width: 89%;
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(to left, #370242, #5e1b96, rgba(0, 0, 0, 0.8));
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 25px;
  border-radius: 20px;
  box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.5);
  z-index: 100000000000000000000;
}

.nav-left {
  display: flex;
  align-items: center;
}

.dropdown-button {
  background: none;
  border: none;
  color: white;
  font-size: 28px;
  cursor: pointer;
  margin-right: 15px;
}

.logo {
    display: flex;
    align-items: center;
    height: 50px; /* Održava stabilnu visinu */
}

.logo img {
    width: 170px; /* Povećaj sliku */
    height: auto;
    cursor: pointer;
    display: block;
    margin-top: 13px;
    
}

.nav-search {
    width: 450px;
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(0, 0, 0, 0.5); /* Blago providna pozadina */
    border-radius: 20px;
    padding: 5px 15px;
    height: 30px;
}

.nav-search input {
    background: transparent; /* Providna pozadina */
    outline: none;
    border: none;
    color: white;
    padding-left: 30px; /* Prostor za ikonicu */
    flex: 1;
    
}

.nav-search input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.nav-search::before {
    content: '\f002'; /* FontAwesome search ikona */
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    position: absolute;
    left: 10px;
    color: white;
}

.nav-right .login-icon {
    font-size: 26px;
    margin-left: 13px;
    margin-top: 0px;
    color: white;
}

.nav-right .user-icon {
    font-size: 26px;
    margin-left: 13px;
    margin-bottom: -10px;
    color: white;
}

.nav-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px; /* razmak između zvonca i slike */
  height: 44px;
}

.notification-bell {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.notification-bell i {
  font-size: 22px;
  color: #fff;
  transition: color 0.3s ease, transform 0.2s ease;
}

.notification-bell:hover i {
  color: #ffd25f;
  transform: scale(1.1);
}

.notif-count {
  position: absolute;
  top: -5px;
  right: -5px;
  background: #ff4747;
  color: #fff;
  font-size: 10px;
  padding: 2px 5px;
  border-radius: 50%;
  font-weight: bold;
  line-height: 1;
}

.notif-dropdown {
  position: absolute;
  right: 0;
  top: 35px;
  width: 280px;
  background: #1f1f1f;
  border: 1px solid #333;
  border-radius: 10px;
  display: none;
  flex-direction: column;
  box-shadow: 0 4px 10px rgba(0,0,0,0.6);
  z-index: 9999;
}


.notif-dropdown .notif-header {
  padding: 10px;
  font-weight: bold;
  border-bottom: 1px solid #333;
  color: #ffd25f;
  text-align: center;
}

.notif-dropdown ul {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 220px;
  overflow-y: auto;
}

.notif-dropdown ul li {
  padding: 10px;
  border-bottom: 1px solid #2c2c2c;
  color: #ddd;
  font-size: 14px;
  cursor: pointer;
}

.notif-dropdown ul li.unread {
  background-color: rgba(255, 210, 95, 0.1);
  font-weight: 600;
}

.notif-dropdown ul li:hover {
  background: #2c2c2c;
}

.notif-footer {
  text-align: center;
  padding: 10px;
}

.notif-footer a {
  color: #ffd25f;
  font-weight: bold;
  text-decoration: none;
}

.notif-footer a:hover {
  text-decoration: underline;
}

.nav-right #userIcon{
    width: 44px;
    height: 44px;
    border-radius: 30px;
    object-fit: cover;
    padding-top: -5px;
    margin-left: -13px;
    margin-top: -2px;
    border: 2px solid #4b0082;
}

.lang-switch {
    display: flex; /* Postavlja horizontalni raspored dugmadi */
    gap: 10px; /* Razmak između dugmadi */
}

.lang-switch button {
    background-color: rgba(255, 255, 255, 0.7); /* Bez pozadine dok dugme nije aktivno */
    border: none;
    padding: 10px;
    cursor: pointer;
    font-size: 14px;
    width: 40px; /* Širina kružića */
    height: 40px; /* Visina kružića */
    border-radius: 50%; /* Pravi kružni oblik */
    display: flex;
    align-items: center; /* Poravnanje teksta u centru */
    justify-content: center; /* Poravnanje teksta u centru */
    color: #800080; /* Crna boja teksta za neaktivno stanje */
}

.lang-switch button.active {
    background-color: #800080; /* Ljubičasta za aktivno dugme */
    color: #fff; /* Bela boja teksta za aktivno stanje */
    font-weight: bold;
}

.lang-switch button:hover {
    opacity: 0.8; /* Efekat kada se prelazi mišem preko dugmeta */
}

/* Dropdown meni */
.dropdown-content {
  display: none;
  position: absolute;
  top: 70px;
  left: 25px;
  background-color: #222;
  min-width: 180px;
  border-radius: 10px;
  box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
  z-index: 999;
  flex-direction: column;
}

.dropdown-content a {
  color: white;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
  transition: 0.3s;
}

.dropdown-content a:hover {
  background-color: #6a0dad;
}

#search-results {
    position: absolute;
    top: 100%;
    left: 0;
    background: #1a1a1a;
    border-radius: 8px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.3);
    max-height: 300px;
    overflow-y: auto;
    width: 100%;
    z-index: 200; /* ✅ Pobrinite se da rezultati budu iznad svega */
    display: block !important; /* ✅ Forsiramo da ostane vidljiv */

}

.search-item {
    display: flex;
    align-items: center;
    padding: 10px;
    cursor: pointer;
    transition: background 0.2s;
}

.search-item:hover {
    background: #333;
}

.search-thumbnail {
    width: 50px;
    height: 75px;
    margin-right: 10px;
    border-radius: 4px;
}

.search-info {
    flex: 1;
}

.search-title {
    font-size: 16px;
    color: white;
}

h2 {
    font-family: 'Josefin Sans', sans-serif;
    margin-left: 15px;
}

#anime-list {
    margin-left: 15px;
}

.modal {
    display: none;
    position: fixed;
    overflow: hidden;
    margin-top: -140px;
    z-index: 500000;
    left: 0;
    top: 0;
    width: 100%;
    height: 120%;
    background: rgba(0, 0, 0, 0.7);
    transform: translateY(-30px);
    filter: blur(20px);
    opacity: 0;
    animation: showContent .3s .3s ease-in-out 1 forwards;
}

.body-no-scroll {
    overflow: hidden;
  }


.modal-content {
    background: whitesmoke; /* svetlo ljubičasta sa prozirnošću */
    margin: 17% auto;
    padding: 30px 20px;
    width: 400px;
    height: 500px;
    max-width: 90%;
    position: relative;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 8px 30px rgba(128, 0, 128, 0.4);
    overflow: hidden; /* da ništa ne "iskače" napolje */
}

.modal-content h2 {
    color: #800080;
    margin-bottom: 20px;
    font-size: 22px;
    margin-left: -7px;
}

.modal-content input {
    width: 90%; /* smanjena širina da ne ide do ivica */
    padding: 12px 15px;
    margin: 10px auto;
    border: 1px solid #d1b3e0;
    border-radius: 8px;
    background-color: #ffffff;
    color: #4b0082;
    display: block;
    box-sizing: border-box;
}

.modal-content input::placeholder {
    color: #aa6ac9;
    opacity: 1;
}

.modal-content button {
    width: 90%;
    padding: 12px;
    margin: 20px auto 0;
    background-color: #800080;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    display: block;
    box-sizing: border-box;
}

.modal-content button:hover {
    background: #9932cc;
}

.modal-content p {
    color: #4b0082;
    font-size: 16px;
    margin-bottom: 20px;
}

.modal-content .zaboravljenaLozinka{
    color: #4b0082;
    font-size: 16px;
    margin-top: -10px;
}

.modal-content a {
    color: #9932cc;
    text-decoration: none;
    font-weight: bold;
}



.modal-content textarea {
    width: 100%;
    min-height: 80px;
    border: 1px solid #d1b3e0;
    border-radius: 8px;
    padding: 10px;
    resize: vertical;
    background: #fff;
    color: #4b0082;
}

.modal-content a:hover {
    text-decoration: underline;
}

.close-button {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 28px;
    color: #800080;
    cursor: pointer;
}

.logo-container {
    margin-bottom: 10px;
}

.logo-container img {
    width: 150px; /* povećan logo */
    height: auto;
    margin-left: -7px;
}

.profile-dropdown {
    position: absolute;
    right: 10px;
    top: 70px;
    background-color: #222;
    min-width: 200px;
    border-radius: 10px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
    z-index: 999;
    display: flex;
    flex-direction: column;
    padding: 10px 0;
}

.profile-dropdown a, .profile-dropdown button {
    display: block;
    width: 100%;
    color: white;
    padding: 12px 16px;
    background: none;
    border: none;
    text-align: left;
    font-size: 16px;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.3s;
    box-sizing: border-box;
}

.profile-dropdown a:hover{
    background-color: #6a0dad;
}

/* Stil za gornji deo gde je username + logout */
.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #444;
}

.profile-header a {
    color: white;
    font-weight: bold;
    text-decoration: none;
    font-size: 16px;
}


.logout-button {
    border: none;
    color: white;
    font-size: 18px;
    cursor: pointer;
    padding: 0;
}

.logout-button:hover {
    color: #6a0dad;
}
/* Animacija za dropdown otvaranje */
@keyframes dropdownFadeSlide {
    0% {
      opacity: 0;
      transform: translateY(-10px);
    }
    100% {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  /* Kada se dropdown prikazuje */
  .profile-dropdown.show {
      animation: dropdownFadeSlide 0.3s ease forwards;
  }

.footer-section {
  flex: 1 1 180px;
  margin-top: -65px;
 
}
.footer-section h4 {
  color: #fff;
  font-size: 16px;
  margin-bottom: 10px;
}
.footer-section p {
  font-size: 14px;
  color: #888;
  font-family: Georgia, 'Times New Roman', Times, serif;
}
.footer-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-section ul li {
  margin: 6px 0;
}
.footer-section ul li a {
  color: #aaa;
  text-decoration: none;
  font-size: 14px;
}
.footer-section ul li a:hover {
  color: #fff;
}
.footer-bottom {
  border-top: 1px solid #222;
  text-align: center;
  margin-top: 30px;
  padding-top: 15px;
  margin-bottom:-13px ;
  font-size: 13px;
  color: #666;
  background-color: #000;
}
.footer-bottom a {
  color: #888;
  text-decoration: none;
}
.footer-bottom a:hover {
  text-decoration: underline;
}

.footer-section img{
  width: 10%;
  margin-bottom: -90px;
  margin-left: -190px;
}

.footer-socials i:hover{
 color: #6a0dad;
}

.footer-socials a{
  font-size: 1.5rem;
 gap: 20px;
}

.footer-socials{
  position: absolute;
  margin-left: 50.5%;
  margin-top: -40px;
  border-left: 0.5px solid #222;
  padding-left: 30px;
  
}

html, body {
  height: 100%;
  margin: 0;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* === GMAIL-LIKE LAYOUT ZA OBAVEŠTENJA === */
.mail-layout {
  display: flex;
  flex-direction: column;
  margin-top: 120px; /* da se vidi ispod navbara */
  width: 90%;
  max-width: 1300px;
  margin-left: auto;
  margin-right: auto;
  background: #0b0217;
  border-radius: 12px;
  box-shadow: 0 0 25px rgba(90, 0, 150, 0.4);
  overflow: hidden;
}

/* Gornji deo - naslov i kategorije */
.mail-topbar {
  background: linear-gradient(90deg, #180036, #27005e);
  border-bottom: 1px solid #2a0050;
  padding: 15px 25px;
}

.mail-topbar h1 {
  color: #d7b6ff;
  margin: 0 0 10px 0;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.mail-categories {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.mail-categories .category {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #3a0075;
  color: #cdaaff;
  padding: 8px 15px;
  border-radius: 20px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 8px;
}

.mail-categories .category.active {
  background: linear-gradient(90deg, #6a0dad, #9b30ff);
  border: none;
  color: #fff;
}

.mail-categories .category:hover {
  background: rgba(155, 48, 255, 0.2);
}

/* Glavni deo - lista obaveštenja */
.mail-body {
  display: flex;
  flex-direction: column;
  background: #0f0422;
  padding: 0;
}

.mail-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 25px;
  border-bottom: 1px solid #2a0050;
  background: rgba(255, 255, 255, 0.03);
}

.mail-tools {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mail-tools button {
  background: none;
  border: none;
  color: #b57aff;
  font-size: 1rem;
  cursor: pointer;
  transition: color 0.2s;
}

.mail-tools button:hover {
  color: #fff;
}

.mark-all {
  background: linear-gradient(90deg, #6a0dad, #9b30ff);
  border: none;
  color: white;
  padding: 8px 16px;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
}

.mark-all:hover {
  background: linear-gradient(90deg, #9b30ff, #6a0dad);
}

/* Lista obaveštenja */
.mail-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mail-item {
  display: grid;
  grid-template-columns: 220px 1fr 2fr 100px;
  padding: 12px 25px;
  align-items: center;
  border-bottom: 1px solid #1d003a;
  color: #ddd;
  cursor: pointer;
  transition: all 0.15s;
}

.mail-item:hover {
  background: rgba(155, 48, 255, 0.07);
}

.mail-item.unread {
  background: rgba(155, 48, 255, 0.05);
  border-left: 3px solid #9b30ff;
}

.mail-item .sender {
  font-weight: 600;
  color: #e2c9ff;
}

.mail-item .subject {
  font-weight: 500;
  color: #fff;
}

.mail-item .preview {
  color: #aaa;
  font-size: 0.9rem;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.mail-item .date {
  text-align: right;
  font-size: 0.85rem;
  color: #888;
}

.mail-item.unread .subject {
  font-weight: 700;
}

/* Scroll */
.mail-body::-webkit-scrollbar {
  width: 10px;
}
.mail-body::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #6a0dad, #9b30ff);
  border-radius: 6px;
}
.mail-body::-webkit-scrollbar-track {
  background: #0f0422;
}

/* === MODAL ZA PRIKAZ OBAVEŠTENJA BEZ LINKA === */
.notif-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999;
}

.notif-modal-content {
  background: #1a1333;
  padding: 25px;
  border-radius: 12px;
  width: 420px;
  color: #fff;
  box-shadow: 0 0 15px rgba(138,43,226,0.5);
  text-align: center;
  position: relative;
  animation: popIn 0.3s ease;
}

@keyframes popIn {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.notif-modal-content h2 {
  color: #c6a0f6;
  margin-bottom: 15px;
  font-family: 'Josefin Sans', sans-serif;
}

.notif-text {
  font-size: 16px;
  line-height: 1.6;
  color: #eaeaea;
  margin: 15px 0;
}

.notif-date {
  font-size: 13px;
  color: #bbb;
  margin-top: 10px;
}

.notif-close {
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 26px;
  cursor: pointer;
  color: #fff;
  transition: color 0.3s ease;
}

.notif-close:hover {
  color: #c6a0f6;
}


/* 🔔 ANIMACIJA ZA ZVONCE KAD STIGNU NOVA OBAVEŠTENJA */

@keyframes shake {
  0%, 100% { transform: rotate(0deg); }
  10%, 30%, 50%, 70%, 90% { transform: rotate(-10deg); }
  20%, 40%, 60%, 80% { transform: rotate(10deg); }
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

@keyframes glow {
  0%, 100% { 
    filter: drop-shadow(0 0 2px #ffd25f);
  }
  50% { 
    filter: drop-shadow(0 0 10px #ffd25f) drop-shadow(0 0 20px #ff9f00);
  }
}

.notification-bell.shake {
  animation: 
    shake 0.6s ease-in-out,
    pulse 0.6s ease-in-out,
    glow 0.6s ease-in-out;
}

.notif-count {
  animation: countPop 0.3s ease-out;
}

@keyframes countPop {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.notif-dropdown {
  animation: dropdownSlide 0.3s ease-out;
}

@keyframes dropdownSlide {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulseDot {
  0%, 100% { 
    box-shadow: 0 0 0 0 rgba(255, 71, 71, 0.7);
  }
  50% { 
    box-shadow: 0 0 0 6px rgba(255, 71, 71, 0);
  }
}

.notif-count {
  animation: pulseDot 2s infinite;
}

.notification-bell:hover i {
  animation: swing 0.5s ease-in-out;
}

@keyframes swing {
  20% { transform: rotate(15deg); }
  40% { transform: rotate(-10deg); }
  60% { transform: rotate(5deg); }
  80% { transform: rotate(-5deg); }
  100% { transform: rotate(0deg); }
}

/* === SKROL ZA LISTU OBAVEŠTENJA === */
.mail-body {
  height: 70vh; /* visina glavnog dela — možeš menjati po želji (npr. 65vh) */
  display: flex;
  flex-direction: column;
  overflow: hidden; /* sprečava da skrol ide preko granica okvira */
}

.mail-list {
  flex: 1;
  overflow-y: auto; /* omogućava vertikalni skrol */
  padding-right: 10px;
  scrollbar-width: thin;
  scrollbar-color: #9b30ff #0f0422; /* Firefox */
}

/* 💅 Scrollbar stil za Chrome/Edge/Safari */
.mail-list::-webkit-scrollbar {
  width: 10px;
}

.mail-list::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #6a0dad, #9b30ff);
  border-radius: 5px;
}

.mail-list::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #9b30ff, #b86bff);
}

.mail-list::-webkit-scrollbar-track {
  background: #0f0422;
}

 #markAllBellBtn {
  background: none;
  border: none;
  color: #fff;
  cursor: pointer;
  float: right;
  margin-top: -2px;
  transition: 0.2s;
}
#markAllBellBtn:hover {
  color: #3ad86b;
}
.friend-request-actions {
  display: inline-flex;
  gap: 6px;
  margin-left: 10px;
}
.friend-request-actions button {
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 1rem;
  transition: transform 0.2s;
}
.friend-request-actions .accept-btn { color: #43b581; }
.friend-request-actions .decline-btn { color: #f04747; }
.friend-request-actions button:hover {
  transform: scale(1.2);
}

