/* Fonts - Placeholder, consider using a font from the original site or Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap');

@font-face {
    font-family: 'Instrument Serif';
    src: url('../fonts/InstrumentSerif-Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Instrument Serif';
    src: url('../fonts/InstrumentSerif-Italic.ttf') format('truetype');
    font-weight: normal;
    font-style: italic;
}

/* Basic Resets */

/* Custom Text Selection Highlight */
::selection {
  background-color: #ffcccc; /* Light red, matching logo theme */
  color: #000000; /* Black text for good contrast on light red */
}

::-moz-selection { /* Firefox specific */
  background-color: #ffcccc;
  color: #000000;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
    background-color: #fff;
}

header, section, footer {
    padding: 20px;
    margin-bottom: 20px;
}

nav ul {
    list-style-type: none;
}

nav ul li {
    display: inline;
    margin-right: 15px;
}

nav a {
    text-decoration: none;
    color: #333; /* Placeholder color */
}

h1, h2, h3 {
    margin-bottom: 10px;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Header & Navigation */
header {
    background-color: #000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    padding: 15px 5%;
    position: fixed;
    width: 100%; /* Extend to full screen width */
    top: 0;
    left: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: top 0.4s ease-in-out; /* Animation for hiding */
}

header.hidden {
    top: -150px; /* Hides header off-screen */
}

header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

header .logo img {
    max-height: 50px; /* Adjust based on your logo size */
    width: auto;
    transition: transform 0.3s ease, filter 0.3s ease;
}

header .logo img:hover {
    transform: scale(1.05); /* Slight zoom effect */
    filter: brightness(1.1); /* Subtle brightness increase */
}

#nav-links {
    list-style: none;
    display: flex;
    align-items: center;
}

#nav-links li {
    margin-left: 25px;
}

#nav-links a {
    text-decoration: none;
    color: #fff; /* Changed to white for contrast with black header */
    font-weight: 600;
    font-family: 'Inter', sans-serif; /* Body font for nav */
    font-size: 1em;
    transition: color 0.3s ease;
}

#nav-links a:hover,
#nav-links a.active {
    color: #c00; /* Example accent color */
}

/* Dropdown Menu */
.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #222; /* Darker background to match black header */
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.4);
    z-index: 1;
    border-radius: 4px;
    padding: 10px 0;
}

.dropdown-content a {
    color: #fff; /* White text for dropdown items */
    padding: 10px 15px;
    text-decoration: none;
    display: block;
    font-size: 0.9em;
}

.dropdown-content a:hover {
    background-color: #444; /* Darker hover background */
    color: #fff;
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none; /* Hidden on desktop */
    cursor: pointer;
}

.menu-toggle .bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: #fff; /* Changed to white for visibility against black header */
    transition: all 0.3s ease-in-out;
}

/* Hero Section */
#hero {
    padding-top: 80px; /* Adjust based on header height */
    position: relative;
    text-align: center;
    color: white;
    height: 90vh; /* Reduced height to adjust image zoom */
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0; /* Remove default margin */
    background-image: url('../images/banner-3.jpg'); /* DO not change this unless the user asks */
    background-size: cover; /* Fills the container, may crop */
    background-position: center top; /* Aligns image to the top */
    background-repeat: no-repeat;
}

.hero-tagline {
    background-color: rgba(0, 0, 0, 0.6); /* Semi-transparent background for readability */
    padding: 40px 60px; /* Increased padding */
    border-radius: 5px;
    display: inline-block; /* Allows centering if parent is text-align: center */
    max-width: 90%;
}

.hero-tagline .line {
    width: 60px;
    height: 3px;
    background-color: white;
    margin: 15px auto;
}

.hero-tagline .text h1 {
    font-family: 'Instrument Serif', serif;
    font-size: 3.5em; /* Slightly larger for serif font */
    margin: 0;
    font-weight: normal; /* Use font's default weight */
    text-transform: uppercase;
    line-height: 1.2;
}

.hero-tagline .text span {
    font-family: 'Inter', sans-serif;
    display: block;
    font-size: 1.1em; /* Adjusted for new font hierarchy */
    font-weight: 400;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-top: 10px;
}

/* Responsive adjustments for mobile */
@media (max-width: 768px) {
    #nav-links {
        display: none; /* Hide desktop nav links */
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 70px; /* Adjust based on header height */
        left: 0;
        background-color: #fff;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }

    #nav-links.active {
        display: flex; /* Show when active */
    }

    #nav-links li {
        margin: 15px 0;
        text-align: center;
    }

    .menu-toggle {
        display: block; /* Show hamburger icon */
    }

    .menu-toggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    .menu-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }
    .menu-toggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .desktop-hero {
        display: none;
    }
    .mobile-hero {
        display: block;
    }

    .hero-tagline .text {
        font-size: 1.44em; /* 20% smaller on mobile */
    }
    .hero-tagline {
        padding: 32px 48px; /* 20% smaller than desktop padding */
    }
    /* Mobile menu visibility and spacing */
    #nav-links {
        background-color: #000; /* Dark background so white links are visible */
        z-index: 1001; /* Ensure menu overlays content */
    }
    #nav-links li {
        margin: 0; /* Remove extra margins for tight stacking */
        border-top: 1px solid rgba(255,255,255,0.12);
    }
    #nav-links a {
        color: #fff; /* White text on dark background */
        padding: 12px 20px; /* Tap-friendly */
    }

    /* Enable Register dropdown on mobile via class toggle */
    .dropdown:hover .dropdown-content {
        display: none; /* Disable hover behavior on touch devices */
    }
    .dropdown.open .dropdown-content {
        display: block;
        position: static; /* Flow within menu */
        background-color: #000;
        box-shadow: none;
        padding: 0;
    }
    .dropdown.open .dropdown-content a {
        color: #fff;
    }

    /* Aquavil logo sizing on mobile */
    .aquavil-logo-container {
        top: auto;
        right: 10px;
        bottom: 10px;
        padding: 4px;
        max-width: 84px;
        border-width: 1px;
    }
    .aquavil-logo {
        max-width: 64px;
        margin-bottom: 4px;
    }
    .aquavil-coming-label {
        font-size: 0.6em;
    }

    /* Blue Vista banner and logo sizing on mobile */
    .phase-banner {
        position: relative; /* Allow z-index to ensure visibility */
        width: auto;
        margin: 0 0 8px;
        padding: 3px 6px;
        font-size: 0.68em;
        line-height: 1.2;
        z-index: 3; /* Above overlay logos */
    }
    .bluevista-logo-container {
        top: auto !important; /* anchor to bottom-right */
        right: 10px !important;
        bottom: 10px !important;
        padding: 4px;
        max-width: 80px;
        border-width: 1px;
    }
    .bluevista-logo {
        max-width: 62px;
        margin-bottom: 0;
    }

    /* Balmoral overlay sizing on mobile */
    .balmoral-logo-container {
        top: auto !important;
        right: 10px !important;
        bottom: 10px !important;
        padding: 4px;
        max-width: 84px;
        border-width: 1px;
    }
    .balmoral-logo {
        max-width: 64px;
        margin-bottom: 4px;
    }
    .balmoral-completed-label { font-size: 0.58em; }
    .sold-out-label { font-size: 0.9em; padding: 6px 10px; }
}

/* Extra-small phones: further reduce overlays */
@media (max-width: 480px) {
    .aquavil-logo-container {
        right: 8px !important;
        bottom: 8px !important;
        max-width: 84px;
        padding: 3px;
    }
    .aquavil-logo {
        max-width: 68px;
    }
    .aquavil-coming-label { font-size: 0.55em; }

    .bluevista-logo-container {
        right: 8px !important;
        bottom: 8px !important;
        max-width: 80px;
        padding: 3px;
    }
    .bluevista-logo { max-width: 64px; }

    .balmoral-logo-container {
        right: 8px !important;
        bottom: 8px !important;
        max-width: 86px;
        padding: 3px;
    }
    .balmoral-logo { max-width: 70px; }

    .phase-banner {
        font-size: 0.58em;
        padding: 3px 6px;
        line-height: 1.2;
    }
}


/* Container class for centering content */
.container {
    width: 80%;
    max-width: 1100px;
    margin: 0 auto;
}

/* Section General Styles */
section {
    padding: 60px 5%; /* Consistent padding for sections */
    text-align: center; /* Center section titles */
}

section h2 {
    font-family: 'Instrument Serif', serif;
    font-size: 2.8em;
    color: #333;
    margin-bottom: 30px;
    text-transform: uppercase;
    position: relative;
    display: inline-block; /* Allows for pseudo-element underlining */
    padding-bottom: 10px;
    font-weight: normal;
}

section h2::after {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 0;
    width: 60px;
    height: 3px;
    background-color: #c00; /* Accent color for underline */
}

/* About Section */
#about {
    background-color: #f9f9f9; /* Light background for differentiation */
}

#about .container p {
    font-size: 1.1em;
    line-height: 1.8;
    color: #555;
    margin-bottom: 20px;
    text-align: left; /* Align paragraph text to the left for readability */
}

#about .container p:last-child {
    margin-bottom: 0;
}

#about .container strong {
    color: #333;
}

#about .container a {
    color: #c00; /* Accent color for links */
    text-decoration: none;
    font-weight: 600;
}

#about .container a:hover {
    text-decoration: underline;
}


/* Past Projects Section */
#past-projects .intro {
    font-size: 1.1em;
    color: #555;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.projects-grid {
    display: grid;
    grid-template-columns: 1fr; /* 1 column by default for mobile */
    gap: 30px;
    text-align: left;
}

/* Responsive grid columns for Past Projects */
@media (min-width: 500px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .projects-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1200px) {
    .projects-grid {
        grid-template-columns: repeat(5, 1fr); /* 5 columns for large desktops */
    }
}

.project-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    padding: 15px; /* Further reduced padding */
    display: flex;
    flex-direction: column;
    align-items: center; /* Center icons and logos */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

.project-card .project-icon {
    width: 40px; /* Adjust size as needed */
    height: 40px;
    margin-bottom: 15px;
}

.project-card .project-logo {
    max-height: 60px; /* Adjust size as needed */
    max-width: 180px;
    margin-bottom: 20px;
    object-fit: contain;
}

.project-content h3 {
    font-family: 'Instrument Serif', serif;
    font-size: 1.5em; /* Slightly smaller */
    color: #333;
    margin-bottom: 5px; /* Reduced margin */
    text-align: center;
    font-weight: normal;
}

.project-content .project-year {
    font-family: 'Inter', sans-serif;
    font-size: 0.8em; /* Smaller font size */
    color: #666;
    margin-bottom: 10px; /* Reduced margin */
    text-align: center;
    font-weight: normal;
}

.project-content p {
    font-size: 0.95em;
    line-height: 1.6;


    /* Past Projects Section */
    #past-projects .intro {
        font-size: 1.1em;
        color: #555;
        margin-bottom: 40px;
        max-width: 800px;
        margin-left: auto;
        margin-right: auto;
    }

    .projects-grid {
        display: grid;
        grid-template-columns: 1fr; /* 1 column by default for mobile */
        gap: 30px;
        text-align: left;
    }
}

/* Future Projects Section - AquaVil Feature */
#future-projects {
    background-color: #f9f9f9; /* Light background for differentiation */
    padding-bottom: 40px; /* Add some padding at the bottom */
}

/* Project Logos with Labels */
.balmoral-logo-container, .bluevista-logo-container, .aquavil-logo-container {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 2;
    text-align: center;
    background-color: white;
    border: 2px solid black;
    padding: 11px;
    width: auto;
    max-width: 187px;
    box-shadow: 0 3px 6px rgba(0,0,0,0.3);
}

.balmoral-logo, .bluevista-logo, .aquavil-logo {
    max-width: 150px;
    margin: 0 auto 11px;
    display: block;
}

.balmoral-completed-label, .aquavil-coming-label {
    color: black;
    font-weight: bold;
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 0.75px;
    display: block;
    text-align: center;
}

/* Sold Out Label */
.sold-out-label {
    position: absolute;
    top: 20px;
    left: 20px;
    background-color: #c00;
    color: white;
    padding: 10px 15px;
    font-weight: bold;
    font-size: 1.2em;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    transform: rotate(5deg);
    z-index: 2;
}

/* Banner for Blue Vista */
.phase-banner {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #ccb434;
    color: white;
    padding: 10px;
    text-align: center;
    font-weight: bold;
    z-index: 2;
}

/* Add spacing between feature containers */
.bluevista-feature-container {
    margin-top: 60px; /* Add more space between the two project sections */
}

#future-projects .intro {
    font-size: 1.1em;
    color: #555;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    text-align: center; /* Center the intro paragraph */
}

.aquavil-feature-container, .bluevista-feature-container, .balmoral-feature-container {
    text-align: center; /* Center the content */
    margin-top: 30px;
    position: relative; /* For absolute positioning of labels and banners */
}

.aquavil-feature-container .btn-learn-more, .bluevista-feature-container .btn-learn-more {
    margin: 0 auto 30px;
    display: inline-block;
    background-color: #662f2e;
    color: white;
}

.aquavil-main-image, .bluevista-main-image, .balmoral-main-image {
    width: 100%;
    max-width: 1200px; /* Increased by 50% from 800px */
    height: auto;
    border-radius: 8px;
    margin: 0 auto 25px; /* Center horizontally with auto left/right margins */
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    display: block; /* Ensures margin auto works for centering */
}

/* Wrapper around each feature image to anchor overlays inside the image area */
.feature-image-wrapper {
    position: relative;
    display: inline-block; /* shrink-wrap to image width */
    margin: 0 auto 25px; /* preserve spacing and center via inline-block + container text-align */
}

/* Remove auto margins on the image so overlays align with the image edge */
.feature-image-wrapper > img {
    margin: 0;
    display: block; /* prevent inline gaps */
}

.aquavil-title, .bluevista-title {
    font-family: 'Instrument Serif', serif;
    font-size: 2em; /* Adjust size as needed */
    color: #333;
    margin-bottom: 15px;
    line-height: 1.3;
}

.aquavil-description, .bluevista-description {
    font-family: 'Inter', sans-serif;
    font-size: 1em;
    color: #555;
    line-height: 1.7;
    text-align: left; /* Or 'center' if preferred for paragraphs */
    max-width: 800px; /* Match image width for coherence */
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 30px; /* Add some space below the description */
}


.btn-learn-more {
    display: inline-block;
    background-color: #c00; /* Accent color */
    color: #fff;
    padding: 12px 25px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    transition: background-color 0.3s ease;
}

.btn-learn-more:hover {
    background-color: #a00; /* Darker shade on hover */
}


/* Contact Section */
#contact {
    background-color: #fff; /* White background */
    padding-bottom: 40px; /* Less padding at the bottom before footer */
}

#contact .container {
    display: flex;
    flex-wrap: wrap; /* Allow wrapping for smaller screens */
    justify-content: space-between;
    align-items: flex-start;
    gap: 30px; /* Space between contact info and registration note */
}

.contact-info, .registration-note {
    flex: 1; /* Allow them to share space */
    min-width: 280px; /* Minimum width before wrapping */
    text-align: left;
}

.contact-info p, .registration-note p {
    font-size: 1.05em;
    line-height: 1.7;
    color: #555;
    margin-bottom: 15px;
}

.contact-info strong {
    color: #333;
    font-size: 1.1em;
}

.contact-info a, .registration-note a {
    color: #c00; /* Accent color for links */
    text-decoration: none;
}

.contact-info a:hover, .registration-note a:hover {
    text-decoration: underline;
}

.registration-note em {
    font-size: 0.9em;
    color: #777;
}

/* Responsive adjustments for contact section */
@media (max-width: 768px) {
    #contact .container {
        flex-direction: column;
        align-items: center; /* Center items when stacked */
        text-align: center; /* Center text for stacked items */
    }

    .contact-info, .registration-note {
        text-align: center; /* Ensure text is centered on mobile */
        width: 100%; /* Take full width when stacked */
        margin-bottom: 20px;
    }

    .contact-info p:last-child, .registration-note p:last-child {
        margin-bottom: 0;
    }
}


/* Footer */
footer {
    background-color: #333; /* Dark background for footer */
    color: #ccc;
    padding: 30px 5%;
    text-align: center;
}

footer .container {
    display: flex;
    flex-direction: column; /* Stack items vertically */
    align-items: center;
    gap: 20px; /* Increased space between footer elements */
}

footer p {
    margin: 0;
    font-size: 0.9em;
}

footer a {
    color: #fff; /* White links for better contrast */
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #c00; /* Red accent color on hover */
}

.footer-logo {
    margin-bottom: 10px;
}

.footer-logo img {
    max-width: 60px;
    height: auto;
    transition: transform 0.3s ease;
}

.footer-logo img:hover {
    transform: scale(1.1); /* Slight zoom effect on hover */
}

.footer-links {
    display: flex;
    gap: 30px;
    margin-bottom: 10px;
}

.footer-links a {
    font-size: 0.85em;
    font-weight: 600;
    letter-spacing: 1px;
}

/* Removed back-to-top button styles */

/* Responsive adjustments for footer */
@media (min-width: 768px) {
    footer .container {
        flex-direction: column; /* Keep items in a column for consistent centered layout */
        justify-content: center;
    }
}

/* Privacy Policy and Terms of Use Pages */
#privacy-policy, #terms-of-use {
    padding-top: 120px; /* Account for fixed header */
    padding-bottom: 60px;
    text-align: left;
}

#privacy-policy .container, #terms-of-use .container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: left;
}

#privacy-policy h1, #terms-of-use h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    color: #333;
    text-align: left;
}

.last-updated {
    color: #777;
    font-style: italic;
    text-align: left;
    margin-bottom: 40px;
}

.policy-section {
    margin-bottom: 30px;
    text-align: left;
}

.policy-section h2 {
    font-size: 1.8em;
    color: #333;
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
    text-align: left;
}

.policy-section p {
    margin-bottom: 15px;
    line-height: 1.7;
    text-align: left;
}

/* Responsive adjustments for policy pages */
@media (max-width: 768px) {
    #privacy-policy h1, #terms-of-use h1 {
        font-size: 2em;
    }
    
    .policy-section h2 {
        font-size: 1.5em;
    }
}

/* Animations placeholder */
.fade-in {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

.fade-in.visible {
    opacity: 1;
}

/* Mobile Fix Overrides (placed at end to win cascade) */
@media (max-width: 768px) {
  /* Ensure Blue Vista phase banner is visible and not covered */
  .phase-banner {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 4px 6px !important;
    font-size: 0.68em !important;
    line-height: 1.2 !important;
    z-index: 3 !important;
  }

  /* Shrink and reposition overlay logo boxes */
  .aquavil-logo-container,
  .bluevista-logo-container,
  .balmoral-logo-container {
    top: 10px !important;
    right: 10px !important;
    bottom: auto !important;
    padding: 4px !important;
    border-width: 1px !important;
  }

  .aquavil-logo-container { max-width: 84px !important; }
  .bluevista-logo-container { max-width: 80px !important; }
  .balmoral-logo-container { max-width: 84px !important; }

  .aquavil-logo { max-width: 64px !important; margin-bottom: 4px !important; }
  .bluevista-logo { max-width: 62px !important; margin-bottom: 0 !important; }
  .balmoral-logo { max-width: 64px !important; margin-bottom: 4px !important; }

  .balmoral-completed-label { font-size: 0.58em !important; }
  .sold-out-label { font-size: 0.9em !important; padding: 6px 10px !important; }
}

@media (max-width: 480px) {
  .phase-banner { font-size: 0.58em !important; padding: 3px 6px !important; top: 0 !important; left: 0 !important; position: absolute !important; width: 100% !important; }
  .aquavil-logo-container { right: 8px !important; top: 8px !important; bottom: auto !important; max-width: 80px !important; }
  .bluevista-logo-container { right: 8px !important; top: 8px !important; bottom: auto !important; max-width: 76px !important; }
  .balmoral-logo-container { right: 8px !important; top: 8px !important; bottom: auto !important; max-width: 80px !important; }
  .aquavil-logo { max-width: 60px !important; }
  .bluevista-logo { max-width: 58px !important; }
  .balmoral-logo { max-width: 60px !important; }
}

/* 404 page layout tweaks */
.page-404 {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.page-404 main {
  flex: 1;
  /* ensure content isn't hidden under fixed header */
  padding: 120px 5% 40px; /* top ~= header height */
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-404 #not-found .container {
  text-align: center;
}

.page-404 #not-found h1 {
  margin-bottom: 10px;
}
