:root {
    --brown: #6B4423;
    --gold: #B38B59;
    --cream: #F5EFE6;
}

html {
    scroll-behavior: smooth;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes smoothBounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-20px);
    }

    60% {
        transform: translateY(-10px);
    }
}

.animate-fadeIn {
    animation: fadeIn 1.5s ease forwards;
}

.animate-smoothBounce {
    animation: smoothBounce 2s infinite;
}

.dish-card {
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.dish-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.12);
}

.btn-gradient {
    background: linear-gradient(45deg, var(--brown), var(--gold));
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.btn-gradient:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(107, 68, 35, 0.4);
}

.wine-pattern {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><path d="M20,50 Q50,20 80,50" stroke="%23B38B59" fill="none" opacity="0.05" stroke-width="2"/></svg>');
    background-size: 100px 100px;
}

section {
    transition: transform 0.6s ease, opacity 0.6s ease;
    min-height: 100vh;
    padding: 4rem 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--cream);
}

::-webkit-scrollbar-thumb {
    background: var(--gold);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--brown);
}

#menuModal,
#galleryModal {
    transition: opacity 0.3s ease;
    opacity: 0;
    pointer-events: none;
}

#menuModal:not(.hidden),
#galleryModal:not(.hidden) {
    opacity: 1;
    pointer-events: auto;
}

#menuModalImage,
#galleryModalImage {
    animation: zoomIn 0.3s ease forwards;
    max-height: 90vh;
}

@keyframes zoomIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.nav-link.active {
    color: #B38B59 !important;
    font-weight: 600;
}

.nav-link.active::after {
    content: '';
    display: block;
    width: 100%;
    height: 2px;
    background-color: #B38B59;
    margin-top: 4px;
    animation: fadeIn 0.3s ease-out;
}

#mobile-menu .nav-link.active {
    color: #B38B59 !important;
    font-weight: 600;
    padding-left: 8px;
    border-left: 3px solid #B38B59;
}

body.preload {
    opacity: 0;
    overflow: hidden;
}

body.loaded {
    opacity: 1;
    transition: opacity 0.8s ease-out;
}

#home {
    padding-top: 8rem;
    padding-bottom: 4rem;
}

#home h2,
#home p {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeIn 1s ease 0.1s forwards;
}

#home .btn-gradient {
    opacity: 0;
    animation: fadeIn 1s ease 0.1s forwards,
        pulse 2s ease 0.9s infinite;
}

@keyframes pulse {
    0% {
        transform: translateY(0) scale(1);
    }

    50% {
        transform: translateY(-5px) scale(1.05);
    }

    100% {
        transform: translateY(0) scale(1);
    }
}

.section-title,
.section-content {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.section-content {
    transition-delay: 0.2s;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.modal-arrow {
    width: 50px;
    height: 50px;
    background: rgba(107, 68, 35, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

@media (max-width: 767px) {
    .modal-arrow {
        width: 50px;
        height: 50px;
        background: rgba(107, 68, 35, 0.9);
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        color: white;
        border: none;
        cursor: pointer;
        transition: none;
        transform: none !important;
    }

    #menuModalImage {
        max-height: 60vh;
    }

    #menuLeftArrow,
    #menuRightArrow {
        display: none !important;
    }
}

@media (hover: hover) {
    .modal-arrow:hover {
        background: rgba(107, 68, 35, 0.9);
    }
}

@media (min-width: 768px) {

    #menuLeftArrow,
    #menuRightArrow {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
    }

    #menuLeftArrow {
        left: -3rem;
    }

    #menuRightArrow {
        right: -3rem;
    }
}

/* Disabled arrows: darker + no hover + no click feel */
.modal-arrow:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  filter: grayscale(100%);
}

/* Remove hover effect when disabled (så den inte "lyser upp") */
.modal-arrow:disabled:hover {
  transform: none;
  box-shadow: none;
}

/* Mobile arrow optimization */
@media (max-width: 767px) {

  .modal-arrow {
    width: 60px;
    height: 60px;
    font-size: 20px;
  }

  .gallery-arrow-left {
    left: 10px;
  }

  .gallery-arrow-right {
    right: 10px;
  }

}

.modal-arrow {
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
}

#galleryModalImage {
  transition: transform 0.25s ease;
  touch-action: pan-y;
}

#galleryModalImage {
  transition: transform 0.3s ease;
  will-change: transform;
}