/* Base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: cursive;
    text-align: center;
}
/* Stil za email dugme */
a button {
    background-color: #94c5d8; /* Svijetloplava pozadina */
    color: #fff; /* Bijeli tekst */
    border: none; /* Bez obruba */
    border-radius: 20px; /* Zaobljeni kutovi */
    padding: 5px 10px; /* Prostor unutar dugmeta */
    font-size: 16px; /* Veliki font */
    cursor: pointer; /* Pokazivač miša kao ruka */
    transition: background-color 0.3s, transform 0.3s; /* Glatke animacije */
    text-align: center; /* Centriranje teksta */
}

/* Stil kada se hovera nad dugmetom */
a button:hover {
    background-color: #286d9b; /* Tamnija nijansa kad je hover */
    transform: scale(1.05); /* Lagano povećanje pri hoveru */
}

/* Stil kada se dugme klikne */
a button:active {
    background-color: #5A4B9B; /* Još tamnija nijansa pri kliku */
    transform: scale(0.98); /* Malo smanjivanje pri kliku */
}


/* Ikona dizajnera */
.designer-icon {
    width: 40px; /* Širina ikone */
    height: 40px; /* Visina ikone */
    background-color: #B0E0E6;
    border-radius: 20%; /* Zaobljeni kutovi (okrugla ikona) */
    position: absolute;
    top: 10px; /* Udaljenost od vrha */
    right: 30px; /* Udaljenost od desnog ruba */
    cursor: pointer;
    transition: transform 0.3s ease, opacity 0.3s ease;
}


.designer-icon:hover {
    transform: scale(1.2);
    opacity: 0.8;
}


/* Kartica s informacijama */
.designer-card 
{
    position: fixed;
    top: -200px; /* Početno sakriveno */
    right: 20px;
    width: 280px;
    background: #B0E0E6;
    border-radius: 12px;
    box-shadow: 0px 10px 30px rgba(0, 0, 0, 0.2);
    padding: 20px;
    text-align: center;
    transition: top 0.4s ease, opacity 0.3s ease;
    opacity: 0;
}

/* Prikaz kartice */
.designer-card.active {
    top: 80px; /* Pomakni karticu dolje */
    opacity: 1;
}

/* Zlatni naslov */
.designer-card h2 {
    color: #333;
    font-size: 20px;
    margin-bottom: 10px;
}

/* Tekst u kartici */
.designer-card p {
    margin: 5px 0;
    font-size: 14px;
    color: #333;
}

/* Link */
.designer-card a {
    color: #0073e6;
    text-decoration: none;
    font-weight: bold;
}

/* Dugme za zatvaranje */
.close-btn {
    background: none;
    border: none;
    font-size: 18px;
    color: #b89b6f;
    cursor: pointer;
    position: absolute;
    top: 10px;
    right: 15px;
    transition: color 0.3s ease;
}

.close-btn:hover {
    color: #8a6b43;
}
/* Fullscreen loading animation */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, #bfe3e5, #ffffff); /* Adjusted to blend with logo */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 1s ease-in-out;
}

.loading-logo {
    width: 150px;
    animation: pulse 1.5s infinite ease-in-out;
    filter: drop-shadow(0px 4px 6px rgba(0, 0, 0, 0.2)); /* Soft shadow for a luxury effect */
}

@keyframes pulse 
{
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.85; }
    100% { transform: scale(1); opacity: 1; }
}

.loaded .loading-screen 
{
    opacity: 0;
    pointer-events: none;
}


body {
    font-family: 'Arial', sans-serif;
    color: #333;
    background-color: #B0E0E6;
    line-height: 1.6;
}

header {
    background: #333;
    color: #B0E0E6;
    padding: 1.5em 0;
    text-align: center;
    font-size: 24px; /* Larger font size for desktop */
    transition: padding 0.3s ease;
}

header h1 {
    margin-bottom: 0.5rem;
    font-size: 2.5rem;
}

header p {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: #B0E0E6;
}

nav ul {
    list-style: none;
    padding: 0;
    display: flex;
    justify-content: center;
}

nav ul li {
    margin: 0 20px;
}

nav ul li a {
    color: #fff;
    text-decoration: none;
    font-size: 1.1rem;
}

nav ul li a:hover {
    color: #B0E0E6;
}

section {
    padding: 4rem 1.5rem;
    text-align: center;
}
.hero {
    background-image: url('pepeljuga.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    position: relative;
    text-align: center;
    padding: 100px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #94c5d8; /* Dark overlay */
}

.hero h2, .hero h3 {
    position: relative;
    z-index: 1;
    margin-bottom: 10px;
}

.hero h2 {
    font-size: 3rem;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero h3 {
    font-size: 1.8rem;
    font-weight: lighter;
}

.hero .cta-btn {
    position: relative;
    z-index: 1;
    background-color: #286d9b;
    color: white;
    font-size: 1.2rem;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: background 0.4s ease-in-out, transform 0.3s ease-in-out;
}

.hero .cta-btn:hover {
    background-color: #1c5e8a;
    transform: scale(1.08);
}

.hero .cta-btn:active {
    transition: opacity 0.5s ease, transform 0.4s ease;
}

#myBtn {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 99;
    border: none;
    outline: none;
    background-color: #94c5d8;
    color: #fff;
    cursor: pointer;
    padding: 15px;
    border-radius: 50%;
    transition: opacity 0.5s ease, transform 0.4s ease;
}

#myBtn:hover {
    background-color: #333;
    transform: scale(1.1);
}


.hero h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.5rem;
}

.slideshow {
    position: relative;
    overflow: hidden;
    height: 500px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slideshow img {
    position: absolute;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.slideshow img.active {
    opacity: 1;
}

.timer-container {
    position: relative;
    width: 100%;
    height: 5px;
    background: #ddd;
    overflow: hidden;
    border-radius: 5px;
    margin-top: 10px;
}

.timer-bar {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: #286d9b;
    width: 0;
    transition: width 4s linear;
}

.about, .services, .gallery, .contact {
    padding: 5rem 1.5rem;
}

.about h2, .services h2, .gallery h2, .contact h2 {
    margin-bottom: 2rem;
    font-size: 2rem;
}

.about p, .services p, .contact p {
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.8;
    color: #000;
}

/* 📌 Service List - Centers Services */
.service-list {
    display: flex;
    flex-direction: column;
    align-items: center;  /* Center the services horizontally */
    margin: 20px;
    width: 80%;  /* Set width to 80% instead of using display: 80% */
    margin-left: auto;  /* Center the service-list container */
    margin-right: auto; /* Center the service-list container */
}

/* 📌 Service Box Styling */
.service {
    background-color: #94c5d8;
    padding: 15px;
    margin: 5px 0;
    border-radius: 8px;
    max-width: 70%;
    cursor: pointer;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    width: 100%;  /* Ensure the service box takes full width up to its max-width */
    display: flex;
    justify-content: center;  /* Horizontally center content */
    align-items: center;  /* Vertically center content */
}

/* 📌 Service Heading */
.service h3 {
    margin: 0;
    color: rgb(0, 0, 0);
    font-family: cursive;
}

/* 📌 Service Menu (Hidden by Default) */
.service-menu {
    display: block;
    background-color: white;
    padding: 15px;
    margin: 0;  /* No extra margin */
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    text-align: center;
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: max-height 0.5s ease, opacity 0.4s ease-in-out, transform 0.4s ease-in-out;
    transform: translateY(-10px);
}

/* 📌 Open Service Menu */
.service-menu.open {
    opacity: 1;
    width: auto;
    max-height: 500px; /* Adjust to fit content */
    transform: translateY(0);
    margin: 0;
    overflow: hidden; /* Add this */
}

/* 📌 Image Container */
.service-menu-image-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* Centers images */
    gap: 10px; /* Space between images */
    margin-top: 15px;
    align-items: flex-start; /* Prevent stretching */
}

/* 📌 Service Images */
.service-menu-image {
    width: 100%; /* Default full width on small screens */
    max-width: 300px; /* Ensures images don't get too big */
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.3s ease;
    flex-shrink: 0;
    object-fit: cover; /* Keeps aspect ratio */
}

/* 📌 Hover Effect */
.service-menu-image:hover {
    transform: scale(1.05);
}

/* 📌 Service Menu Buttons */
.service-menu button {
    background-color: #B0E0E6;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    color: white;
    cursor: pointer;
}

/* 📌 Button Hover */
.service-menu button:hover {
    background-color: #94c5d8;
}

/* 📌 Button Active (Click Effect) */
.service-menu button:hover:active {
    background-color: #005bb5;
}

.center-image {
    max-width: 80%;      /* Set maximum width to 80% of the parent container */
    height: auto;        /* Maintain aspect ratio */
    display: block;      /* Make the image a block-level element */
    margin: 20px auto;   /* Center the image horizontally with automatic margins */
}

.lightbox-content {
    max-width: 90%;
    max-height: 90%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); /* Responsive grid */
    gap: 8px;
    padding: 10px;
    justify-content: center;
}

.gallery-grid img {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.2s ease-in-out;
}

.gallery-grid img:hover {
    transform: scale(1.05);
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

/* Lightbox Image with Zoom */
.lightbox img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
    transition: transform 0.3s ease-in-out;
    cursor: zoom-in;
}

/* Cursor when dragging */
.lightbox img:active {
    cursor: grabbing;
}


.lightbox .close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 30px;
    cursor: pointer;
}

.lightbox .prev,
.lightbox .next {
    position: absolute;
    top: 50%;
    color: white;
    font-size: 28px;
    cursor: pointer;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.6); /* Darker background for contrast */
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.4); /* Subtle border */
}

.lightbox .prev {
    left: 20px;
}

.lightbox .next {
    right: 20px;
}

.lightbox .prev::before,
.lightbox .next::before {
    content: '❮'; /* Unicode arrow icon */
    font-size: 26px;
    font-weight: bold;
    transition: transform 0.2s ease-in-out;
}

.lightbox .next::before {
    content: '❯'; /* Adjust arrow for next button */
}

.lightbox .prev:hover,
.lightbox .next:hover {
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid rgba(255, 255, 255, 0.6);
    transform: translateY(-50%) scale(1.1);
}

.lightbox .prev:active,
.lightbox .next:active {
    transform: translateY(-50%) scale(0.95);
}


.gallery-item {
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    position: relative;
}


footer {
    background: #333;
    color: #fff;
    padding: 2rem 1.5rem;
    text-align: center;
}

footer p {
    margin: 0;
}

p {
    font-size: 1.2em;
    font-family: cursive;;
}


#myBtn img {
    width: 30px;
    height: 30px;
}

.review-btn 
{
    margin-top: 40px;
    background-color: #94c5d8;
    color: white;
    font-size: 18px;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s ease, 0.3s ease;
    box-shadow: 2px 4px 10px rgba(0, 0, 0, 0.15);
}

.review-btn:hover {
    background-color: #79bcd6;
    transform: translateY(-5px);
}

.review-btn:active {
    transform: scale(0.9);
}

.flip-gallery {
    display: flex;
    justify-content: center;
    gap: 8px; /* Optimized spacing for better alignment */
    flex-wrap: wrap;
}

.flip-container {
    width: 320px; /* Larger images for better visibility */
    height: 480px; /* Adjusted height to fit longer images */
    perspective: 1000px;
    cursor: pointer;
}

.flip-box {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.5s ease-in-out;
}

.flip-container.active .flip-box {
    transform: rotateY(180deg);
}

.flip-front, .flip-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.flip-front img, .flip-back img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Ensures the full image is visible without cropping */
    transition: transform 0.3s ease-in-out;
}

.flip-front img:hover, .flip-back img:hover {
    transform: scale(1.05); /* Subtle zoom effect for better engagement */
}

.flip-back {
    transform: rotateY(180deg);
}

.label {
    position: absolute;
    top: 8px;
    left: 8px;
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 5px 10px;
    font-size: 18px;
    font-family: 'Helvetica Neue', sans-serif;
    font-weight: bold;
    text-transform: uppercase;
    border-radius: 6px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.label:hover {
    background-color: rgba(0, 0, 0, 0.8);
    box-shadow: 0px 6px 12px rgba(0, 0, 0, 0.4);
}

.auto-flip-gallery 
{
    display: flex;
    justify-content: center;
    gap: 4px;
    flex-wrap: wrap;
}

.flip-card {
    width: 150px; /* Optimized for mobile */
    height: 220px;
    perspective: 1000px;
    position: relative;
}

.flip-inner {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.5s ease-in-out;
}

.flip-card.active .flip-inner {
    transform: rotateY(180deg);
}

.flip-front-face, .flip-back-face {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.flip-front-face img, .flip-back-face img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.flip-back-face {
    transform: rotateY(180deg);
}

.flip-label {
    position: absolute;
    top: 5px;
    left: 5px;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 3px 6px;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    border-radius: 4px;
}

/* Modal Styling */
.reviews-modal {
display: none;
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.8);
justify-content: center;
align-items: center;
z-index: 1000;
overflow: hidden; /* Prevents scrolling the background */
}

.modal-content {
background-color: #94c5d8;
padding: 2rem;
border-radius: 8px;
width: 80%;
max-width: 600px;
max-height: 80%; /* Ensure modal doesn't exceed viewport height */
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
text-align: center;
overflow-y: auto; /* Enables scrolling inside the modal */
}

.close-modal 
{
position: absolute;
top: 15px;
color: rgb(255, 106, 106);
right: 40px;
font-size: 36px;
font-weight: bold;
cursor: pointer;
transition: color 0.3s ease, transform 0.2s ease;
}

.close-modal:hover {
color: #ff0000; /* Red color on hover for better visibility */
transform: scale(1.3); /* Slight zoom effect on hover */
}
.review-list {
display: flex;
flex-direction: column;
gap: 1rem;
margin-top: 1.5rem;
}

.review {
background: #79bcd6;
padding: 1rem;
border-radius: 8px;
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
font-size: 1rem;
line-height: 1.5;
}


/* Responsive styles */
@media (max-width: 700px) 
{
    .auto-flip-gallery 
    {
        flex-wrap: wrap;
        justify-content: space-between;
    }
    
    /* Each card will take up roughly 50% of the width minus gap adjustments */
    .flip-card {
        width: calc(50% - 8px); /* Adjust '8px' if needed based on your gap */
        height: auto; /* Remove fixed height for responsive scaling */
    }
    
    /* Maintain aspect ratio using the padding-top trick */
    .flip-inner {
        position: relative;
        width: 100%;
        padding-top: 146.67%; /* (220 / 150 * 100%) for a 150x220 ratio */
    }
    
    /* Ensure the front and back faces fill the flip card */
    .flip-front-face,
    .flip-back-face {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
    }
    .flip-gallery {
        gap: 4px;
    }
    .flip-container {
        width: 95%;
        height: auto; /* Ensures proportional scaling on mobile */
    }
    .flip-box {
        height: 420px; /* Slightly reduced height for smaller screens */
    }

    .label {
        font-size: 14px; /* Slightly smaller text on mobile */
        padding: 3px 6px; /* Smaller padding */
    }
    .designer-icon 
    {
        width: 25px; /* Širina ikone */
        height: 25px; /* Visina ikone */
    }

    .designer-card 
    {
        width: 90%;  /* Širina skoro cijelog ekrana */
        right: 5%;
        left: 5%;
        top: -250px; /* Malo više da ne smeta */
        padding: 15px;
    }

    .designer-card.active {
        top: 50px; /* Pomak dolje */
    }

    .designer-card h2 {
        font-size: 18px; /* Smanjen font za telefon */
    }

    .designer-card p {
        font-size: 13px; /* Bolja čitljivost */
    }

    .close-btn {
        font-size: 16px; /* Manje dugme za zatvaranje */
        top: 5px;
        right: 10px;
    }
    .about {
        color: black;
    }

    .slideshow {
        height: 300px;
    }

    .slideshow img {
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: 100%;
    }

    header h1 {
        font-size: 2rem;
    }

    header p {
        font-size: 1rem;
    }

    nav ul {
        flex-direction: column;
    }

    nav ul li {
        margin: 10px 0;
    }

    .hero h2 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1.2rem;
    }

    .service {
        max-width: 100%; /* Allow services to be wider on smaller screens */
    }

    .service-menu-image {
        max-width: 100%; /* Make images full width on small screens */
    }
    .services-list {
        flex-direction: column;
        align-items: center;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(80px, 1fr)); /* Smaller images for mobile */
    }

    .gallery-grid img {
        height: 80px;
    }

    .lightbox img {
        max-width: 95%;
    }

    p {
        font-size: 0.8em;
        color: black;
    }

    #location iframe {
        width: 100%;
        height: 300px;
    }
    #myBtn
    {
        padding: 14px;
        bottom:20px;
        right:20px;
    }
    #myBtn img 
    {
        width: 20px;
        height: 20px;
    }
}