/* ========================== */
/*        BASE STYLES        */
/* ========================== */
html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.15rem;
  font-feature-settings: "lnum", "tnum";
  line-height: 1.9;
  overflow: hidden;
  scroll-behavior: auto;
  text-align: center;
}

body {
  scroll-snap-type: y mandatory;
  overflow-y: scroll;
}

/* Responsive Font Sizes */
@media (min-width: 768px) {

  html,
  body,
  li,
  table {
    font-size: 1.25rem;
  }
}

/* ========================== */
/*         FONTS             */
/* ========================== */
@font-face {
  font-family: 'Cormorant Garamond';
  src: url('/static/fonts/CormorantGaramond-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Cormorant Garamond';
  src: url('/static/fonts/CormorantGaramond-Bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Cormorant Garamond';
  src: url('/static/fonts/CormorantGaramond-Italic.woff2') format('woff2');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

/* ========================== */
/*      NAVIGATION RAIL      */
/* ========================== */
#scrollNav {
  position: fixed;
  top: 50%;
  right: -200px;
  z-index: 1000;
  background-color: rgba(0, 0, 0, 0.7);
  border-radius: 1.5rem 0 0 1.5rem;
  backdrop-filter: blur(3px);
  transform: translateY(-50%);
  animation: slideIn 2.45s forwards;
}

@keyframes slideIn {
  to {
    right: 0;
  }
}

@media (max-width: 768px) {
  #scrollNav {
    display: none;
  }
}

/* Navigation Links */
.nav-link {
  position: relative;
  width: 3rem;
  height: 3rem;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0 !important;
  color: #ccc;
  transition: color 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
  color: dodgerblue;
  font-weight: bold;
}

.nav-link i {
  font-size: 1.5rem;
}

.nav-link span {
  position: absolute;
  right: 100%;
  margin-right: 0.75rem;
  font-size: 1.1rem;
  font-weight: 500;
  color: white;
  white-space: nowrap;
  opacity: 0;
  transform: translateX(10px);
  pointer-events: none;
  transition: all 0.3s ease;
}

.nav-link:hover span {
  opacity: 1;
  transform: translateX(0);
}

@media (max-width: 768px) {
  .nav-link {
    width: 100%;
    font-size: 2rem;
  }
}

/* ========================== */
/*    MOBILE NAVIGATION      */
/* ========================== */
.hamburger-wrapper {
  position: fixed;
  bottom: 0;
  right: 0;
  width: 60px;
  height: 60px;
  padding: 5px;
  background-color: #003366;
  border-top-left-radius: 80%;
  z-index: 1051;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: -4px -4px 12px rgba(0, 0, 0, 0.2);
}

.hamburger {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
}

.hamburger .bar {
  width: 24px;
  height: 2.5px;
  margin: 3px 0;
  background-color: #007bff;
  border-radius: 2px;
  transition: transform 0.4s ease, opacity 0.3s ease;
}

.hamburger.open .bar:nth-child(1) {
  transform: rotate(45deg) translate(4px, 4px);
}

.hamburger.open .bar:nth-child(2) {
  opacity: 0;
}

.hamburger.open .bar:nth-child(3) {
  transform: rotate(-45deg) translate(4px, -4px);
}

/* Overlay */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1050;
  height: 100%;
  width: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  opacity: 0;
  pointer-events: none;
  padding-top: 100px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  transition: opacity 0.4s ease;
}

.overlay.show {
  opacity: 1;
  pointer-events: auto;
}

.overlay .logo {
  position: absolute;
  top: 30px;
  font-weight: bold;
  color: white;
}

@media (min-width: 768px) {

  .hamburger-wrapper,
  .overlay {
    display: none !important;
  }
}

/* ========================== */
/*         SECTIONS          */
/* ========================== */
section {
  position: relative;
  height: 100vh;
  color: white;
  display: flex;
  justify-content: center;
  align-items: center;
  scroll-snap-align: start;
}

section>.content {
  z-index: 2;
  width: 100%;
  max-height: 100vh;
  overflow-y: auto;
  scroll-snap-type: y mandatory;
  outline: none;
}

section::before,
section::after {
  content: "";
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

/* Dark Overlays */
section.dark-overlay::before,
section.dark-overlay::after {
  background-blend-mode: overlay;
  background-repeat: no-repeat;
  filter: brightness(var(--dynamic-brightness, 0.7)) blur(var(--dynamic-blur, 0));
  transition: filter 0.2s ease-out;
}

section.darker-overlay::before,
section.darker-overlay::after {
  background-blend-mode: overlay;
  background-repeat: no-repeat;
  filter: brightness(0.2);
}

/* Individual Section Backgrounds */
section#sobe-za-iznajmljivanje::before {
  background-image: linear-gradient(rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.1)), url('/assets/stari-dom/hodnik-stepenice.webp');
  clip-path: polygon(0 0, 70% 0, 50% 100%, 0% 100%);
  box-shadow: 10px 0 0 rgba(255, 255, 255, 0.3);
}

section#sobe-za-iznajmljivanje::after {
  background-image: linear-gradient(rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.1)), url('/assets/stari-dom/dvokrevetna-soba-krevet.webp');
  clip-path: polygon(70% 0, 100% 0, 100% 100%, 50% 100%);
}

section#hostel::before {
  background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('/assets/novi-dom/art.webp');
  clip-path: polygon(30% 0, 0 0, 0 100%, 50% 100%);
}

section#hostel::after {
  background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('/assets/novi-dom/dvokrevetna-soba-krevet.webp');
  clip-path: polygon(100% 0, 30% 0, 50% 100%, 100% 100%);
}

section#restoran::before {
  background-image: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.3)), url("/assets/restoran.webp");
}

section#pristupacnost::before {
  background-image: url("/assets/stari-dom/invalidska-staza.webp");
}

section#parking::before {
  background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('/assets/parking-bicikli.webp');
  clip-path: polygon(0 0, 53% 0, 47% 100%, 0% 100%);
}

section#parking::after {
  background-image: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('/assets/garaza.webp');
  clip-path: polygon(53% 0, 100% 0, 100% 100%, 47% 100%);
}

section#kucni-red::before {
  background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('/assets/novi-dom/hala.webp');
}

section#kontakt::before {
  background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('/assets/novi-dom/recepcija.webp');
}

/* ========================== */
/*        ANIMATIONS         */
/* ========================== */
#heroTitle span {
  display: inline-block;
  opacity: 0;
  transform: scale(2) translateY(15px);
  animation: zoomFadeIn 0.5s forwards ease-out;
  animation-delay: calc(var(--i) * 0.05s);
}

@keyframes zoomFadeIn {
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

#heroSubtitle {
  opacity: 0;
  transform: translateY(10px);
  animation: softFadeIn 1.2s ease-out 1s forwards;
}

@keyframes softFadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Section Element Animation */
section h1,
section h2,
section p,
section a {
  filter: brightness(70%);
  transition: filter 1.25s ease;
}

section.visible h1,
section.visible h2,
section.visible p,
section.visible a {
  filter: brightness(100%);
}

/* ========================== */
/*           MISC            */
/* ========================== */
video.bg-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

body,
.content {
  overflow: auto;
  scrollbar-width: none;
  /* Firefox */
  -ms-overflow-style: none;
  /* IE10+ */
}

.table {
  --bs-table-bg: transparent !important;
  --bs-table-color: white;
}

.roomImage {
  border-radius: 8%;
}