:root {
    /* ThemeForest B&B Palette */
    --accent-gold: #978667;
    --accent-hover: #4b514d;
    --bg-main: #faf8f5;
    --bg-gray: #f4f4f4;
    --bg-card: rgba(151,134,103, 0.03);
    --bg-footer: #1f2127;
    --bg-footer-dark: #1a1b20;
    --text-main: #333333;
    --text-light: #777777;
    --text-white: #ffffff;
    --text-gold-light: #ebd7b2;
    
    --navbar-height: 80px;
    --border-radius: 0px;
    
    --shadow-soft: 0 0 30px 0 rgba(0,0,0,0.06);
    
    --transition: all 0.3s ease-in-out;
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 15px;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: 'Montserrat', Helvetica, sans-serif;
    line-height: 1.8;
    overflow-x: hidden;
}

.container {
    width: 90%;
    max-width: 1140px;
    margin: 0 auto;
}

.section-padding {
    padding: 100px 0;
}

.bg-main {
    background-color: var(--bg-main);
}

.bg-gray {
    background-color: var(--bg-gray);
}

.text-center {
    text-align: center;
}

/* Typography */
h1, h2, h3, h4 {
    color: var(--text-main);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.2;
}

.section-subtitle {
    color: var(--accent-gold);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 10px;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 50px;
}

.cursive-accent {
    font-family: 'Caveat', cursive;
    font-size: 3.5rem;
    color: var(--text-gold-light);
    margin-bottom: 10px;
    line-height: 1;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.5);
}

/* Buttons */
.btn-primary, .btn-large {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--accent-gold);
    color: var(--text-white);
    text-decoration: none;
    border-radius: 25px;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
}

.btn-primary {
    padding: 10px 25px;
}

.btn-large {
    padding: 14px 30px;
    font-size: 1rem;
}

.btn-primary:hover, .btn-large:hover {
    background-color: var(--accent-hover);
    color: var(--text-white);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    height: var(--navbar-height);
    background: transparent;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5%;
    z-index: 1000;
    transition: var(--transition);
    border-bottom: 1px solid transparent;
}

.navbar .logo a {
    color: var(--text-white);
}

.navbar .nav-links a:not(.btn-primary) {
    color: var(--text-white);
}

.navbar .mobile-menu-icon {
    color: var(--text-white);
}

.navbar.scrolled {
    height: 70px;
    background: #ffffff;
    border-bottom: 1px solid #d9e1e6;
}

.navbar.scrolled .logo a {
    color: var(--text-main);
}

.navbar.scrolled .nav-links a:not(.btn-primary) {
    color: var(--text-main);
}

.navbar.scrolled .mobile-menu-icon {
    color: var(--text-main);
}

.logo a {
    font-size: 1.5rem;
    font-weight: 700;
    text-decoration: none;
    letter-spacing: -1px;
}

.logo span {
    font-weight: 400;
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
    position: relative;
}

.nav-links a:not(.btn-primary)::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--accent-gold);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.nav-links a:not(.btn-primary):hover::after {
    transform: scaleX(1);
}

.nav-links a:hover:not(.btn-primary) {
    color: var(--accent-gold);
}

.mobile-menu-icon {
    display: none;
    font-size: 1.8rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    height: 100vh;
    min-height: 700px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    background-color: #000;
    /* Force GPU acceleration */
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

.hero::before {
    content: '';
    position: absolute;
    top: -5%;
    left: -5%;
    width: 110%;
    height: 110%;
    background: url('assets/Piscină sărată Saună uscatăumedă.jpeg') center/cover no-repeat;
    z-index: 0;
    /* Mobile rendering fixes */
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-perspective: 1000;
    perspective: 1000;
    transform-origin: center center;
    will-change: transform;
}

.hero.animate-zoom::before {
    -webkit-animation: zoomOutBg 15s ease-out forwards;
    animation: zoomOutBg 15s ease-out forwards;
}

@-webkit-keyframes zoomOutBg {
    0% {
        -webkit-transform: scale3d(1.15, 1.15, 1);
        transform: scale3d(1.15, 1.15, 1);
    }
    100% {
        -webkit-transform: scale3d(1, 1, 1);
        transform: scale3d(1, 1, 1);
    }
}

@keyframes zoomOutBg {
    0% {
        transform: scale3d(1.15, 1.15, 1);
    }
    100% {
        transform: scale3d(1, 1, 1);
    }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    color: var(--text-white);
    max-width: 800px;
    padding: 0 20px;
    margin-top: 60px;
}

.hero-content h1 {
    font-size: 4.5rem;
    color: var(--text-white);
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: -2px;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    font-weight: 400;
    opacity: 0.9;
}

/* Booking CTA */
.booking-cta {
    background-color: var(--accent-gold);
    color: var(--text-white);
    padding: 40px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    position: relative;
    z-index: 10;
}

.cta-container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
}

.cta-item {
    text-align: center;
}

.cta-item h3 {
    color: var(--text-white);
    font-size: 1.2rem;
    margin-bottom: 10px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.cta-phone {
    font-size: 2rem;
    font-weight: 700;
}

.cta-phone a {
    color: var(--text-white);
    text-decoration: none;
    transition: var(--transition);
}

.cta-phone a:hover {
    color: var(--text-gold-light);
}

.cta-cards {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 10px;
}

.card-badge {
    background-color: #fff;
    color: #333;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 5px;
}

.card-badge::before {
    content: '💳';
}

.card-badge.edenred {
    border-left: 4px solid #e2000f;
}

.card-badge.sodexo {
    border-left: 4px solid #005697;
}

.card-badge.up {
    border-left: 4px solid #f6891f;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.about-subtitle {
    font-size: 1.1rem;
    color: var(--accent-gold);
    margin-bottom: 25px;
    font-weight: 500;
}

.about-text p {
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 20px;
}

.about-image img {
    width: 100%;
    box-shadow: var(--shadow-soft);
}

/* Facilities Section */
.facilities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 0; /* Removing gap to use borders for separation */
    background-color: #fff;
    box-shadow: var(--shadow-soft);
}

.facility-card {
    padding: 50px 40px;
    text-align: center;
    transition: var(--transition);
    position: relative;
    border-right: 1px solid #ededed;
    border-bottom: 1px solid #ededed;
}

.facility-card:hover {
    background-color: var(--bg-card);
}

.card-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--accent-gold);
}

.facility-card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
}

.facility-card p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* Flat Marquee Carousel Section */
.carousel-container {
    width: 100%;
    overflow: hidden;
    padding: 30px 0;
    margin-top: 20px;
    position: relative;
}

.carousel-container::before,
.carousel-container::after {
    content: "";
    position: absolute;
    top: 0;
    width: 120px;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.carousel-container::before {
    left: 0;
    background: linear-gradient(to right, var(--bg-main), transparent);
}

.carousel-container::after {
    right: 0;
    background: linear-gradient(to left, var(--bg-main), transparent);
}

.carousel-track {
    display: flex;
    gap: 40px;
    width: max-content;
    animation: scrollTrack 30s linear infinite;
}

.carousel-container:hover .carousel-track {
    animation-play-state: paused;
}

.carousel-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: 500px;
    scroll-snap-align: center;
    transition: transform 0.4s ease;
}

.carousel-item:hover {
    transform: translateY(-10px);
}

.carousel-track img {
    width: 100%;
    height: 350px;
    object-fit: cover;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.4s ease;
}

.carousel-item:hover img {
    transform: scale(1.02);
}

.carousel-caption {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-main);
    letter-spacing: -0.01em;
}

@keyframes scrollTrack {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-50% - 20px)); } /* Half track + half gap */
}

/* Bento Gallery */
.bento-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 320px;
    gap: 20px;
    padding: 60px 0 20px;
}
.bento-item {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    display: flex;
    flex-direction: column;
    background: #fff;
}
.bento-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}
.bento-item img {
    flex: 1;
    min-height: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s ease;
}
.bento-item:hover img {
    transform: scale(1.05);
}
.bento-caption {
    background: #fff;
    color: var(--text-main);
    padding: 15px;
    font-weight: 600;
    font-size: 0.9rem;
    text-align: center;
    z-index: 2;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.02);
}

/* Bento Grid Spans */
.bento-item:nth-child(1) { grid-column: span 2; grid-row: span 2; }
.bento-item:nth-child(2) { grid-column: span 1; grid-row: span 1; }
.bento-item:nth-child(3) { grid-column: span 1; grid-row: span 1; }
.bento-item:nth-child(4) { grid-column: span 2; grid-row: span 1; }
.bento-item:nth-child(5) { grid-column: span 1; grid-row: span 2; }
.bento-item:nth-child(6) { grid-column: span 1; grid-row: span 1; }
.bento-item:nth-child(7) { grid-column: span 2; grid-row: span 1; }
.bento-item:nth-child(8) { grid-column: span 3; grid-row: span 1; }

/* Rules Section */
.rules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.rule-card {
    background: #ffffff;
    padding: 40px 35px;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    border-top: 3px solid transparent;
    transition: all 0.4s ease;
    overflow: hidden;
}

.rule-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(151,134,103, 0.15);
    border-top: 3px solid var(--accent-gold);
}

.rule-number {
    font-family: 'Montserrat', sans-serif;
    font-size: 5rem;
    font-weight: 800;
    color: rgba(151,134,103, 0.05);
    position: absolute;
    top: -10px;
    right: 15px;
    line-height: 1;
    z-index: 0;
    transition: color 0.4s ease;
}

.rule-card:hover .rule-number {
    color: rgba(151,134,103, 0.15);
}

.rule-card h4 {
    font-size: 1.25rem;
    margin-bottom: 15px;
    color: var(--text-main);
    position: relative;
    z-index: 1;
}

.rule-card p, .rule-list {
    font-size: 0.95rem;
    color: var(--text-light);
    position: relative;
    z-index: 1;
}

.rule-list {
    list-style-type: disc;
    padding-left: 20px;
}

.rule-list li {
    margin-bottom: 8px;
}

.rule-card-full {
    grid-column: 1 / -1;
    text-align: center;
    padding: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.rule-card-full p {
    font-size: 1.1rem;
    color: var(--text-main);
}

/* Footer */
.footer {
    background-color: var(--bg-footer);
    color: #a8a8a8;
    padding: 80px 0 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.footer-brand h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: var(--text-white);
}

.footer-contact h3, .footer-social h3 {
    font-size: 1.1rem;
    margin-bottom: 25px;
    color: var(--text-gold-light);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.footer-contact p {
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 50%;
    color: var(--text-white);
    text-decoration: none;
    transition: var(--transition);
}

.social-links a:hover {
    background-color: var(--accent-gold);
    border-color: var(--accent-gold);
}

.footer-bottom {
    background-color: var(--bg-footer-dark);
    text-align: center;
    padding: 25px 0;
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 1024px) {
    .about-grid {
        gap: 40px;
    }
    
    .hero-content h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    .navbar {
        background: #ffffff;
        border-bottom: 1px solid #d9e1e6;
    }

    .navbar .logo a, .navbar .mobile-menu-icon {
        color: var(--text-main);
    }

    .nav-links {
        display: none;
        position: absolute;
        top: var(--navbar-height);
        left: 0;
        width: 100%;
        background: #ffffff;
        flex-direction: column;
        padding: 20px 0;
        box-shadow: 0 10px 15px rgba(0,0,0,0.05);
    }
    
    .nav-links.active {
        display: flex;
    }

    .nav-links a:not(.btn-primary) {
        color: var(--text-main) !important;
    }
    
    .mobile-menu-icon {
        display: block;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .about-text {
        text-align: center;
    }

    .carousel-container::before,
    .carousel-container::after {
        width: 30px;
    }

    .carousel-item {
        width: 85vw;
    }

    .carousel-track img {
        height: 250px;
    }

    .bento-gallery {
        grid-template-columns: 1fr;
        grid-auto-rows: 320px;
    }

    .bento-item {
        grid-column: span 1 !important;
        grid-row: span 1 !important;
    }
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(5px);
    opacity: 0;
    transition: opacity 0.3s ease;
    justify-content: center;
    align-items: center;
}

.lightbox.show {
    opacity: 1;
}

.lightbox-content {
    max-width: 90%;
    max-height: 90%;
    border-radius: 12px;
    box-shadow: 0 0 40px rgba(0,0,0,0.6);
    transform: scale(0.8);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.lightbox.show .lightbox-content {
    transform: scale(1);
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: #fff;
    font-size: 50px;
    font-weight: 300;
    cursor: pointer;
    transition: color 0.3s;
    line-height: 1;
}

.lightbox-close:hover {
    color: var(--accent-gold);
}

/* Reviews Section */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.review-card {
    background-color: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
}

.stars {
    color: var(--accent-gold);
    font-size: 1.2rem;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

.review-text {
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    line-height: 1.6;
}

.review-author {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 0.9rem;
}

@media (max-width: 900px) {
    .reviews-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .reviews-grid {
        grid-template-columns: 1fr;
    }

    .rules-show-more-container {
        display: block !important;
    }

    .rules-grid .rule-card:nth-child(n+4) {
        display: none;
    }

    .rules-grid.show-all .rule-card:nth-child(n+4) {
        display: block;
    }
}
