@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&display=swap');

:root {
  color-scheme: dark;
  --md-sys-color-primary: rgb(155 212 160);
  --md-sys-color-surface-tint: rgb(155 212 160);
  --md-sys-color-on-primary: rgb(0 57 21);
  --md-sys-color-primary-container: rgb(27 81 41);
  --md-sys-color-on-primary-container: rgb(182 241 187);
  --md-sys-color-secondary: rgb(157 212 158);
  --md-sys-color-on-secondary: rgb(2 57 19);
  --md-sys-color-secondary-container: rgb(30 81 39);
  --md-sys-color-on-secondary-container: rgb(184 241 185);
  --md-sys-color-tertiary: rgb(154 212 162);
  --md-sys-color-on-tertiary: rgb(0 57 23);
  --md-sys-color-tertiary-container: rgb(25 81 42);
  --md-sys-color-on-tertiary-container: rgb(181 241 189);
  --md-sys-color-error: rgb(255 179 178);
  --md-sys-color-on-error: rgb(86 29 32);
  --md-sys-color-error-container: rgb(115 51 53);
  --md-sys-color-on-error-container: rgb(255 218 217);
  --md-sys-color-background: rgb(16 21 16);
  --md-sys-color-on-background: rgb(224 228 220);
  --md-sys-color-surface: rgb(16 21 16);
  --md-sys-color-on-surface: rgb(224 228 220);
  --md-sys-color-surface-variant: rgb(65 73 65);
  --md-sys-color-on-surface-variant: rgb(193 201 190);
  --md-sys-color-outline: rgb(139 147 137);
  --md-sys-color-outline-variant: rgb(65 73 65);
  --md-sys-color-shadow: rgb(0 0 0);
  --md-sys-color-scrim: rgb(0 0 0);
  --md-sys-color-inverse-surface: rgb(224 228 220);
  --md-sys-color-inverse-on-surface: rgb(45 50 44);
  --md-sys-color-inverse-primary: rgb(53 105 63);
  --md-sys-color-primary-fixed: rgb(182 241 187);
  --md-sys-color-on-primary-fixed: rgb(0 33 9);
  --md-sys-color-primary-fixed-dim: rgb(155 212 160);
  --md-sys-color-on-primary-fixed-variant: rgb(27 81 41);
  --md-sys-color-secondary-fixed: rgb(184 241 185);
  --md-sys-color-on-secondary-fixed: rgb(0 33 8);
  --md-sys-color-secondary-fixed-dim: rgb(157 212 158);
  --md-sys-color-on-secondary-fixed-variant: rgb(30 81 39);
  --md-sys-color-tertiary-fixed: rgb(181 241 189);
  --md-sys-color-on-tertiary-fixed: rgb(0 33 11);
  --md-sys-color-tertiary-fixed-dim: rgb(154 212 162);
  --md-sys-color-on-tertiary-fixed-variant: rgb(25 81 42);
  --md-sys-color-surface-dim: rgb(16 21 16);
  --md-sys-color-surface-bright: rgb(54 58 53);
  --md-sys-color-surface-container-lowest: rgb(11 15 11);
  --md-sys-color-surface-container-low: rgb(24 29 24);
  --md-sys-color-surface-container: rgb(28 33 28);
  --md-sys-color-surface-container-high: rgb(38 43 38);
  --md-sys-color-surface-container-highest: rgb(49 54 49);
  --sidebar-bg: #101510;
  --main-bg: #0b0f0b;
  --surface-bg: #101510;
  --card-bg: #232823;
  --red: #272B26;
  --green-btn: #2d3a2d;
  --green-btn-arrow: #b6c6b6;
  --blue-btn: #06494B;
  --blue-btn-arrow: #8CD5DC;
  --text-main: #e3e3e3;
  --text-secondary: #a0a0a0;
  --border-radius: 32px;
  --card-radius: 32px;
  --news-radius: 20px;
  --sidebar-width: 76px;
  --sidebar-width-open: 198px;
  --transition: 0.2s cubic-bezier(.4, 0, .2, 1);
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  background: var(--surface-bg);
  color: var(--text-main);
  font-family: 'Roboto', Arial, sans-serif;
  min-height: 100vh;
  width: 100vw;
  overflow-x: hidden;
  overflow-y: hidden;
}

.app-bg {
  position: relative;
  min-height: 100vh;
  min-width: 100vw;
  width: 100%;
  height: 100vh;
  background: var(--surface-bg);
  display: flex;
  flex-direction: row;
}

.sidebar {
  background: #101510;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 32px 0;
  border-radius: 32px 0 0 32px;
  min-width: var(--sidebar-width);
  width: var(--sidebar-width);
  height: calc(100vh - 44px);
  margin-top: 22px;
  margin-bottom: 22px;
  z-index: 2;
  position: relative;
}

.sidebar.open {
  width: var(--sidebar-width-open);
  min-width: var(--sidebar-width-open);
}

.main-area {
  flex: 1; /* kitölti a sidebar melletti helyet */
  min-width: 0; /* fontos, hogy a flexbox engedje zsugorodni */
  display: flex;
  flex-direction: column;
  position: relative;
  min-height: 0;
}

.main-content {
  background: var(--main-bg);
  border-radius: 32px;
  margin: 22px 22px 0px 0;
  padding: 0 22px 0px 32px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: 0 0 0 2px rgba(0,0,0,0.12);
  max-width: calc(100% - 22px);
  min-height: calc(100dvh - 104px); /* mobilbarát */
  height: calc(100dvh - 104px);
  overflow-y: scroll;
  scroll-behavior: smooth
}

.header {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  margin-bottom: 22px;
  min-height: 80px;
  position: sticky;
  top: 0;
  z-index: 10;
  background: #0B0F0B;
  backdrop-filter: blur(12px);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.welcome-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin-top: 40px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.header.hide .welcome-container {
  transform: translateY(-50%);
  opacity: 0;
}

.header-icons {
  position: absolute;
  top: 8px;
  right: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-icon-link {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--green-btn);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  transition: var(--transition);
}

.header-icon-link:hover {
  background-color: var(--card-bg);
}

.header-icon {
  width: 24px;
  height: 24px;
}

.terms-icon {
  width: 40px;
  height: 40px;
}

.terms-text {
  font-size: 1.7rem;
  font-weight: 500;
  color: var(--text-main);
}

.terms-desc {
  font-size: 1rem;
  color: var(--text-main);
  margin: 2px 0 0 0;
  text-align: left;
}

.nav-menu {
  display: flex;
  flex-direction: column;
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
  gap: 24px;
}
.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.75rem;
  width: 64px;
  padding: 0;
  border-radius: 16px;
  transition: var(--transition);
  position: relative;
}

.nav-item-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.75rem;
  width: 64px;
  height: 64px;
  padding: 0;
  border-radius: 16px;
  transition: var(--transition);
  position: relative;
  border: none;
  background: none;
  outline: none;
}

.nav-item:not(.active):hover .nav-icon-container {
  background-color: #232823;
}

.nav-item-list:hover {
  background-color: #ffffff2b;
}

.nav-item-list span {
  pointer-events: none;
}


.nav-item.active .nav-icon-container {
  background-color: var(--green-btn);
}

.nav-item span {
  color: #C1C9BE;
}

.nav-item.active span {
  color: #D4E8D1;
}

.nav-icon {
  filter: brightness(0) saturate(100%) invert(85%) sepia(6%) saturate(466%) hue-rotate(60deg) brightness(95%) contrast(86%); /* #C1C9BE */
}

.nav-item.active .nav-icon {
  filter: brightness(0) saturate(100%) invert(94%) sepia(11%) saturate(309%) hue-rotate(61deg) brightness(94%) contrast(90%); /* #D4E8D1 */
}
.nav-icon-container {
  width: 56px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  transition: var(--transition);
}

.nav-icon {
  width: 24px;
  height: 24px;
}

/* ---------- open navbar  ---------- */

.nav-menu-open {
  display: flex;
  flex-direction: column;
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
  gap: 24px;
}
.nav-item-open {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.75rem;
  width: calc(100% - 28px);
  padding: 0;
  border-radius: 16px;
  transition: var(--transition);
  position: relative;
}

.nav-item-open-list {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.75rem;
  width: calc(100% - 28px);
  height: calc(100% - 28px);
  padding: 0;
  border-radius: 16px;
  transition: var(--transition);
  position: relative;
  border: none;
  background: none;
  outline: none;
}

.nav-item-open:not(.active):hover {
  background-color: #232823;
  height: 50px;
  border-radius: 32px;
}

.nav-item-list:hover {
  background-color: #ffffff2b;
}

.nav-item-list span {
  pointer-events: none;
}


.nav-item.active {
  /* background-color: var(--green-btn); */
  height: 50px;
  border-radius: 32px;
}

.nav-item-open span {
  color: #C1C9BE;
}

.nav-item-open.active span {
  color: #D4E8D1;
}

.nav-icon-open {
  filter: brightness(0) saturate(100%) invert(85%) sepia(6%) saturate(466%) hue-rotate(60deg) brightness(95%) contrast(86%); /* #C1C9BE */
}

.nav-item-open.active .nav-icon-open {
  filter: brightness(0) saturate(100%) invert(94%) sepia(11%) saturate(309%) hue-rotate(61deg) brightness(94%) contrast(90%); /* #D4E8D1 */
}
.nav-icon-open-container {
  width: 56px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  transition: var(--transition);
}

/* Alapból elrejtjük a szöveget */
.nav-item-list span {
  display: none;
}

/* Csak ha a gombnak van a "-open" osztálya, mutatjuk */
.nav-item-list.nav-item-open-list span {
  display: flex; /* vagy flex, ha flex konténer */
}


.nav-icon-open {
  width: 24px;
  height: 24px;
}

.category-items {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: calc(90dvh - 320px);
  overflow-y: auto;
  border-radius: 32px;
}

.category-item {
  background: #101510;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  align-items: left;
  transition: all 0.2s ease;
}

/* Lekerekítések */
.category-item.first {
  border-radius: 32px 32px 8px 8px;
}

.category-item.middle {
  border-radius: 8px;
}

.category-item.last {
  border-radius: 8px 8px 32px 32px;
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-thumb {
  background: transparent;
  border-radius: 4px;
  transition: background 0.3s ease;
}

::-webkit-scrollbar-track {
  background: transparent;
}

.main-content:hover::-webkit-scrollbar-thumb {
  background: #232823;
}

.main-content.scrolling::-webkit-scrollbar-thumb {
  background: #232823;
}

@media (max-width: 900px) {
  .main-content {
    padding: 0 8px 32px 32px;
  }

  .sidebar {
    margin-left: 8px;
  }

  .main-content {
    margin-left: 0;
  }
}

@media (max-width: 700px) {
  .sidebar {
    display: none;
  }

  .main-content {
    border-radius: 32px;
    margin: 8px;
    box-shadow: inset -8px 0 0 var(--md-extended-color-system-regular-color-container), inset 0 -8px 0 var(--md-extended-color-system-regular-color-container);
  }

  .main-area {
    margin-left: 0;
  }
}

.footer { 
  margin-top: 8px; 
  position: relative; 
}

.footer-terms { 
  justify-content: center;
  align-items: center;
}

#site-footer .footer-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-radius: 12px;
  background: #0E1512;
}
#site-footer .footer-left img,
#site-footer .footer-right img {
  height: 65px;
  object-fit: contain;
}

#site-footer .footer-right {
  padding-right: 48px;
}

#site-footer .footer-center {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
#site-footer .footer-terms {
  color: #C4C8C3;
  text-decoration: underline;
  cursor: pointer;
  font-size: 14px;
}
@media (max-width: 900px) {
  #site-footer .footer-container {
    flex-direction: column;
    gap: 8px;
    padding: 10px 12px;
  }
}