/* style.css */

/* --- VARIABILE CULOARE (Versiune Curățată) --- */
/* Am păstrat setul de variabile care pare a fi cel final și l-am mutat în partea de sus. */
:root {
    --color-primary: #1c2f4a; 
    --color-secondary: #03a9f4;
    --color-accent-main: #ff6b35; 
    --color-accent-dark: #ff4757;
    --color-background-light: #f5f5f5;
    --color-text-dark: #333;
    --color-success: #28a745; 
    --color-warning: #ffc107;
    --color-info: #17a2b8; 
}

/* --- RESET GLOBAL --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--color-background-light);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    flex: 1;
}

/* --- NAVBAR --- */
.navbar {
    background-color: white;
    border-bottom: 3px solid var(--color-secondary);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 1.8rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--color-primary);
}

.nav-menu {
    list-style: none;
    display: flex;
    align-items: center;
    transition: max-height 0.3s ease-out;
}

.nav-menu li {
    margin-left: 20px;
}

.nav-menu a {
    text-decoration: none;
    color: var(--color-text-dark);
    font-weight: 500;
    padding: 8px 10px;
    border-radius: 5px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
}

.nav-menu a i {
    margin-right: 5px;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--color-accent-main);
}

.nav-menu .cta a {
    background-color: var(--color-accent-main);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 600;
    box-shadow: 0 2px 5px rgba(255, 107, 53, 0.4);
}

.nav-menu .cta a:hover {
    background-color: var(--color-accent-dark);
    color: white;
}

/* --- Meniu Hamburger (Mobile) --- */
.hamburger {
    display: none;
    cursor: pointer;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--color-primary);
    margin: 4px 0;
    transition: all 0.3s ease-in-out;
}

/* Stări Active pentru Hamburger */
.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* --- HEADER / HERO --- */
.header {
    background-color: var(--color-primary);
    color: white;
    padding: 60px 20px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.header p {
    font-size: 1.2rem;
    opacity: 0.8;
}

/* --- FORMULAR CĂUTARE --- */
.search-form {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    padding: 20px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin-top: -30px; /* Ridică formularul deasupra header-ului */
    position: relative;
    z-index: 10;
}

.search-form input[type="text"],
.search-form select {
    flex: 1;
    min-width: 150px;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.search-form input[type="text"]:focus,
.search-form select:focus {
    border-color: var(--color-secondary);
    outline: none;
}

.search-button {
    background-color: var(--color-accent-main);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 150px;
}

.search-button i {
    margin-right: 8px;
}

.search-button:hover {
    background-color: var(--color-accent-dark);
}

.search-button:active {
    transform: scale(0.98);
}

/* --- GRID REZULTATE --- */
.results-info {
    text-align: center;
    margin: 40px 0 20px;
    font-size: 1.1rem;
    color: var(--color-text-dark);
}

.results-info strong {
    color: var(--color-accent-main);
    font-weight: 700;
}

.accommodation-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.accommodation-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

.accommodation-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.card-content {
    padding: 20px;
}

.card-type {
    display: inline-block;
    background-color: var(--color-secondary);
    color: white;
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.card-type i {
    margin-right: 5px;
}

.card-title {
    font-size: 1.4rem;
    color: var(--color-primary);
    margin-bottom: 5px;
}

.card-location {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.card-location i {
    color: var(--color-accent-main);
    margin-right: 5px;
}

.card-description {
    color: #555;
    font-size: 0.95rem;
    line-height: 1.4;
    margin-bottom: 20px;
}

.card-link {
    display: block;
    width: 100%;
    text-align: center;
    padding: 10px;
    background-color: var(--color-accent-main);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: background-color 0.2s;
}

.card-link:hover {
    background-color: var(--color-accent-dark);
}

.card-link i {
    margin-right: 8px;
}

/* --- Mesaj Fără Rezultate --- */
.no-results-message {
    grid-column: 1 / -1;
    text-align: center;
    padding: 50px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    color: var(--color-primary);
    font-size: 1.2rem;
    font-weight: 500;
}

/* --- FOOTER --- */
footer {
    background: var(--color-primary);
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 3rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    margin-bottom: 1rem;
    color: var(--color-accent-main);
    font-size: 1.2rem;
}

.footer-section p {
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-section a {
    color: white;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: var(--color-accent-main);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1rem;
    text-align: center;
    font-size: 0.85rem;
    opacity: 0.8;
}

.footer-bottom p {
    margin-top: 5px;
}

.footer-bottom .policy-link {
    color: white;
    text-decoration: none;
}

.footer-bottom .policy-link:hover {
    text-decoration: underline;
}

/* --- MODAL (Politica de Confidențialitate) --- */
.modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 2000; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgba(0,0,0,0.6); /* Black w/ opacity */
}

.modal-content {
    background-color: #fefefe;
    margin: 5% auto; /* 5% from the top and centered */
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    max-width: 800px; 
    position: relative;
    max-height: 90vh; /* Limitează înălțimea */
    overflow-y: auto; /* Permite scroll în modală */
}

.modal-content h2, .modal-content h3 {
    color: var(--color-primary);
    margin-top: 15px;
    margin-bottom: 10px;
}

.close-button {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    top: 10px;
    right: 20px;
}

.close-button:hover,
.close-button:focus {
    color: var(--color-accent-main);
    text-decoration: none;
}

#modal-accept-btn {
    margin-top: 20px;
    display: block;
    width: 100%;
}

/* --- COOKIE BANNER --- */
.cookie-banner {
    display: none; /* Hidden by default by JS */
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--color-primary);
    color: white;
    padding: 15px 20px;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.2);
    z-index: 1500;
    align-items: center;
    justify-content: space-between;
}

.cookie-banner p {
    margin: 0;
    font-size: 0.95rem;
    flex-grow: 1;
}

.cookie-banner a {
    color: var(--color-accent-main);
    text-decoration: underline;
}

.cookie-buttons {
    display: flex;
    gap: 10px;
    margin-left: 20px;
}

.cookie-banner .reject-button {
    background-color: transparent;
    border: 2px solid white;
    color: white;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.2s, border-color 0.2s;
}

.cookie-banner .reject-button:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: var(--color-accent-main);
    color: var(--color-accent-main);
}

.cookie-banner .search-button {
    padding: 8px 15px;
    border-radius: 5px;
    font-size: 0.95rem;
    min-width: unset;
}

/* --- MEDIA QUERIES (Responsivitate) --- */

/* Tablete și Dispozitive Mici */
@media (max-width: 1024px) {
    .search-form {
        flex-direction: column;
    }
    
    .search-form input[type="text"],
    .search-form select,
    .search-button {
        width: 100%;
        min-width: unset;
    }
}

/* Telefoane Mobile */
@media (max-width: 768px) {
    .nav-content {
        padding: 10px 20px;
    }

    .nav-menu {
        position: absolute;
        top: 60px; /* Înălțimea navbar-ului */
        left: 0;
        width: 100%;
        max-height: 0;
        overflow: hidden;
        flex-direction: column;
        background-color: white;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
        z-index: 999;
    }

    .nav-menu.active {
        max-height: 500px; /* Valoare suficient de mare */
        padding: 10px 0;
    }

    .nav-menu li {
        margin: 0;
        width: 100%;
        text-align: center;
        border-bottom: 1px solid #eee;
    }

    .nav-menu li:last-child {
        border-bottom: none;
    }

    .nav-menu a {
        display: block;
        padding: 15px;
        color: var(--color-primary);
    }
    
    .nav-menu .cta a {
        border-radius: 0;
        box-shadow: none;
    }

    .hamburger {
        display: block;
    }

    .header h1 {
        font-size: 2rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-section p span {
        padding-left: 0 !important;
        display: block;
    }

    .cookie-banner {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-buttons {
        margin-top: 10px;
        margin-left: 0;
        width: 100%;
        justify-content: center;
    }
}