/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header styles */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    height: 100px; /* Fixed height for consistency */
}

.header.hidden {
    transform: translateY(-100%);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 20px;
}

.logo-image {
    height: 80px;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-list a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    font-size: 14px;
    text-transform: uppercase;
    transition: color 0.3s ease;
    position: relative;
    padding-bottom: 5px;
}

.nav-list a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: #4a90e2;
    transition: width 0.3s ease;
}

.nav-list a:hover, .nav-list a.active {
    color: #4a90e2;
}

.nav-list a:hover::after, .nav-list a.active::after {
    width: 100%;
}

/* Set CSS variables for consistent colors */
:root {
    --primary-color: #4a90e2;
    --accent-color: #357abd;
    --text-color: #333;
    --text-light: #666;
    --white: #ffffff;
    --transition: all 0.3s ease;
}

/* Update reserve button style to match other pages */
.reserve-btn {
    background: #4a90e2;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.reserve-btn:hover {
    background-color: #357abd;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Hero section */
.hero {
    height: 100vh;
    background-image: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('../imagens/banner arroz carolino.jpg');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 80px;
    color: var(--white);
    position: relative;
    background-color: #000;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: 0 20px;
    margin: 0 auto;
    color: white;
    text-align: center;
}

.subtitle {
    font-size: 18px;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 20px;
    display: block;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-title {
    font-family: 'Playfair Display', serif;
    font-size: 48px;
    line-height: 1.2;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-description {
    font-size: 18px;
    margin-bottom: 30px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

/* Loading animation */
.loading .hero-content {
    animation: fadeIn 1s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Welcome section */
.welcome-section {
    padding: 60px 0;
    background-color: #f8f9fa;
}

.welcome-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.welcome-text h2 {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    color: #333;
    margin-bottom: 20px;
}

.welcome-text p {
    font-size: 18px;
    color: #666;
    line-height: 1.6;
}

/* Events Calendar Section */
.events-calendar {
    padding: 60px 0;
    background-color: #fff;
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    color: #333;
    text-align: center;
    margin-bottom: 30px;
}

.calendar-filters {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.month-selector select,
.year-selector select,
.category-selector select {
    padding: 10px 20px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    background-color: #fff;
    color: #333;
    cursor: pointer;
    min-width: 150px;
}

.calendar-view-toggle {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
}

.view-btn {
    padding: 8px 16px;
    border: 1px solid #4a90e2;
    background-color: transparent;
    color: #4a90e2;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.view-btn.active,
.view-btn:hover {
    background-color: #4a90e2;
    color: #fff;
}

.events-container {
    margin-top: 30px;
    min-height: 400px;
    position: relative;
}

.loading-events {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.loading-events i {
    font-size: 40px;
    color: #4a90e2;
    margin-bottom: 15px;
}

.loading-events p {
    font-size: 16px;
    color: #666;
}

/* Monthly Calendar View */
.monthly-calendar {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
}

.calendar-day {
    min-height: 120px;
    border: 1px solid #eee;
    padding: 10px;
    border-radius: 4px;
    background-color: #f9f9f9;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.calendar-day.today {
    background-color: #e9f5ff;
    border-color: #4a90e2;
}

.calendar-day-header {
    font-weight: 600;
    color: #333;
    text-align: center;
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid #eee;
}

.calendar-day.empty {
    background-color: #f5f5f5;
    opacity: 0.5;
}

.day-events {
    font-size: 12px;
    overflow-y: auto;
    flex-grow: 1;
    max-height: 80px; /* Permite rolagem se tiver muitos eventos */
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.day-event {
    padding: 4px 6px;
    background-color: #4a90e2;
    color: white;
    border-radius: 3px;
    margin-bottom: 2px;
    font-size: 11px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.day-event:hover {
    background-color: #357abd;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

.day-event.arte { background-color: #9c27b0; }
.day-event.cinema { background-color: #e91e63; }
.day-event.danca { background-color: #ff5722; }
.day-event.desporto { background-color: #4caf50; }
.day-event.exposicao { background-color: #ff9800; }
.day-event.gastronomia { background-color: #795548; }
.day-event.musica { background-color: #2196f3; }
.day-event.teatro { background-color: #673ab7; }
.day-event.cultura { background-color: #009688; }

/* Weekly View */
.weekly-calendar {
    display: flex;
    flex-direction: column;
}

.week-day {
    display: flex;
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.week-day-header {
    width: 120px;
    font-weight: 600;
}

.week-day-events {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.week-event {
    background-color: #4a90e2;
    color: white;
    padding: 5px 10px;
    border-radius: 3px;
    font-size: 14px;
    cursor: pointer;
}

/* List View */
.events-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.list-event {
    background-color: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.list-event:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.list-event-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
}

.list-event-date {
    font-weight: 600;
    color: #4a90e2;
}

.list-event-category {
    font-size: 14px;
    color: #777;
}

.list-event h3 {
    font-size: 18px;
    color: #333;
    margin-bottom: 10px;
}

.list-event-location {
    color: #666;
    font-size: 14px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.list-event-description {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

/* Featured Events Section */
.featured-events {
    padding: 60px 0;
    background-color: #f8f9fa;
}

.featured-events-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 30px;
}

.event-card {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.event-card:hover {
    transform: translateY(-10px);
}

.event-image {
    height: 200px;
    overflow: hidden;
}

.event-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.event-card:hover .event-image img {
    transform: scale(1.05);
}

.event-details {
    padding: 20px;
}

.event-date {
    display: block;
    color: #4a90e2;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
}

.event-details h3 {
    font-size: 20px;
    color: #333;
    margin-bottom: 15px;
}

.event-location {
    color: #666;
    font-size: 14px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.event-description {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

/* Footer */
.footer {
    background: var(--primary-color);
    color: var(--white);
    padding: 80px 0 40px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 60px;
}

.footer-logo {
    height: 100px;
    margin-bottom: 20px;
}

.footer-info {
    text-align: center;
    grid-column: 2;
    grid-row: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.footer-logo {
    height: 100px;
    margin-bottom: 15px;
    transform: translateY(-15px);
}

.footer-info p {
    color: rgba(255,255,255,0.7);
    margin-bottom: 15px;
}

.footer h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: var(--white);
}

.footer-links {
    grid-column: 3;
    grid-row: 1;
}

.footer-contact {
    grid-column: 1;
    grid-row: 1;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--white);
}

.footer-contact p {
    margin-bottom: 10px;
    color: rgba(255,255,255,0.7);
}

.footer .reserve-btn {
    background: white;
    color: var(--primary-color);
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.9rem;
    margin-top: 0;
    transform: translateY(-10px);
}

.footer-info .social-links {
    display: flex;
    gap: 15px;
    margin-top: 15px;
    justify-content: center;
}

.footer-info .social-links a {
    color: var(--white);
    font-size: 1.2rem;
    transition: var(--transition);
}

.footer-info .social-links a:hover {
    color: var(--accent-color);
}

/* Benavente Logo */
.benavente-logo {
    max-width: 150px;
    margin: 0 auto 20px;
}

.benavente-logo-img {
    width: 100%;
    height: auto;
    filter: brightness(0) invert(1); /* Make logo white */
}

/* Reservation Form */
.reserva-form-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.reserva-form-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.reserva-form {
    background-color: #fff;
    border-radius: 8px;
    padding: 30px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    max-height: 90vh;
    overflow-y: auto;
}

.reserva-form h2 {
    font-family: 'Playfair Display', serif;
    margin-bottom: 20px;
    font-size: 24px;
    color: #333;
}

.reserva-form .form-group {
    margin-bottom: 15px;
}

.reserva-form .form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #555;
}

.reserva-form .form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.reserva-form .submit-btn {
    background-color: #4a90e2;
    color: white;
    border: none;
    padding: 12px 0;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
    margin-top: 10px;
    font-size: 16px;
}

.reserva-form .submit-btn:hover {
    background-color: #357abd;
}

.reserva-form .close-btn {
    background-color: #f5f5f5;
    color: #333;
    border: 1px solid #ddd;
    padding: 12px 0;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
    margin-top: 10px;
    font-size: 16px;
}

.reserva-form .close-btn:hover {
    background-color: #e5e5e5;
}

/* Event Modal */
.event-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.event-modal-content {
    background: white;
    padding: 30px;
    border-radius: 8px;
    max-width: 600px;
    width: 100%;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
    position: relative;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}

.event-modal-header {
    margin-bottom: 20px;
}

.event-modal-title {
    font-size: 24px;
    color: #333;
    margin-bottom: 10px;
}

.event-modal-date {
    color: #4a90e2;
    font-weight: 600;
}

.event-modal-location {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #666;
    margin-bottom: 15px;
}

.event-modal-description {
    color: #555;
    line-height: 1.6;
    margin-bottom: 20px;
}

.event-modal-image {
    width: 100%;
    height: 250px;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
}

.event-modal-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Responsive design */
@media (max-width: 1024px) {
    .nav-list {
        display: none;
    }
    
    .featured-events-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .hero {
        height: 60vh;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .events-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    .event-card {
        max-width: 100%;
    }
    
    .event-image {
        height: 200px;
    }
    
    .section-title {
        font-size: 28px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .footer-info, .footer-links, .footer-contact {
        grid-column: 1;
    }
    
    .footer-contact {
        grid-row: 1;
    }
    
    .footer-info {
        grid-row: 2;
    }
    
    .footer-links {
        grid-row: 3;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 28px;
    }
    
    .subtitle {
        font-size: 14px;
    }
    
    .month-selector select,
    .year-selector select,
    .category-selector select {
        width: 100%;
    }
    
    .event-details h3 {
        font-size: 18px;
    }
}

/* Mobile menu */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: #333;
    font-size: 24px;
    cursor: pointer;
}

@media (max-width: 1024px) {
    .mobile-menu-btn {
        display: block;
    }
    
    .nav {
        position: fixed;
        top: 90px;
        left: 0;
        right: 0;
        background: white;
        height: 0;
        overflow: hidden;
        transition: height 0.3s ease;
        box-shadow: 0 5px 10px rgba(0,0,0,0.1);
    }
    
    .nav.active {
        height: 300px;
    }
    
    .nav-list {
        display: flex;
        flex-direction: column;
        padding: 20px;
        gap: 20px;
    }
    
    .nav-list a {
        font-size: 16px;
    }
}

/* Agenda Iframe Container */
.agenda-iframe-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 0;
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.agenda-iframe-container.full-page {
    min-height: calc(100vh - 450px);
    margin: 0 auto 60px;
}

.agenda-iframe-container iframe {
    width: 100%;
    min-height: 800px;
    border: none;
    transition: height 0.3s ease;
}

.agenda-iframe-container.full-page iframe {
    min-height: 1000px;
    overflow: hidden;
}

@media (max-width: 768px) {
    .agenda-iframe-container {
        padding: 10px 0;
    }
    
    .agenda-iframe-container iframe {
        min-height: 600px;
    }
    
    .agenda-iframe-container.full-page iframe {
        min-height: 800px;
    }
}

@media (max-width: 480px) {
    .agenda-iframe-container iframe {
        min-height: 500px;
    }
    
    .agenda-iframe-container.full-page iframe {
        min-height: 600px;
    }
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    height: 100px; /* Fixed height for consistency */
}

.header.hidden {
    transform: translateY(-100%);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 20px;
}
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        align-items: center;
        padding-top: 20px;
        padding-bottom: 20px;
    }
    
    .nav {
        margin-top: 20px;
    }
    
    .nav-list {
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
    }
    
    .hero {
        height: 60vh;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-description {
        font-size: 1.2rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .testimonial-content {
        padding: 40px 20px;
    }
    
    .testimonial-author {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .author-info {
        margin-left: 0;
        margin-top: 15px;
    }
    
    .testimonial-text {
        font-size: 18px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .footer-info, .footer-links, .footer-contact {
        grid-column: 1;
    }
    
    .footer-contact {
        grid-row: 1;
    }
    
    .footer-info {
        grid-row: 2;
    }
    
    .footer-links {
        grid-row: 3;
    }
}