/* ========================================
   STYLE.CSS (DAY 1)
   Hamonace Integrated Services
   ========================================
*/

/* === 1. GLOBAL STYLES & VARIABLES === */

/* We use variables to store our colors. 
   This way, you can change the brand's color in one place! 
*/
:root {
    --primary-color: #0d213f;   /* A strong, professional navy blue */
    --secondary-color: #007bff; /* A bright, modern blue for buttons */
    --light-bg: #f8f9fa;      /* A very light grey for section backgrounds */
    --text-color: #333;        /* Dark grey for text (easier to read than pure black) */
    --white: #ffffff;
    --border-color: #e9ecef;
}

/* A simple CSS reset to make browsers behave */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* This is your requirement: Set global font, color, and background */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: var(--white);
    color: var(--text-color);
    line-height: 1.6; /* Makes text more readable */
}

a {
    color: var(--secondary-color);
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

/* This is a helper class to center our content */
.container {
    width: 95%;
    max-width: 1100px;
    margin: 0 auto; /* This centers the container */
}


/* === 2. HEADER & NAVIGATION === */

/* This styles the entire header bar */
header {
    background: var(--white);
    border-bottom: 1px solid var(--border-color);
    padding: 0.25rem 0;
    position: sticky;
    top: 0;
    z-index: 10;
}

header .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    height: auto;
}

header h1 {
    font-size: 1.5rem;
    margin: 0;
}

header h1 a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 1rem;
}

header h1 img {
    height: 64px;
    width: auto;
    vertical-align: middle;
    margin-top: 6px;
}

header h1 {
    margin: 0;
}

header nav {
    width: 100%;
}

header nav ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    align-items: stretch;
    width: 100%;
    padding: 0.5rem 0;
}

header nav ul li {
    display: block;
    width: 100%;
}

header nav ul li a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: background 0.3s ease, color 0.3s ease;
    display: block;
    width: 100%;
    padding: 0.75rem 0.5rem;
    text-align: center;
    background: transparent;
    border-radius: 6px;
    font-size: 0.95rem;
}

header nav ul li a:hover {
    background: rgba(0,0,0,0.03);
    color: var(--secondary-color);
}


/* === 3. BUTTONS (Used on multiple pages) === */
.cta-button {
    display: inline-block;
    background: var(--secondary-color);
    color: var(--white);
    padding: 12px 24px;
    border-radius: 5px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.3s ease;
    border: none;
    cursor: pointer;
}

.cta-button:hover {
    background: var(--primary-color);
}


/* === 4. CONTACT FORM (contact.html) === */

/* Contact form layout using Flexbox */
.contact-form form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* This styles the individual form groups (label + input) */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.form-row .form-group {
    flex: 1;
}

.form-group label {
    font-weight: 600;
    color: var(--primary-color);
}

/* This styles all text boxes, email boxes, and text areas */
.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
}

/* Styles the "Send Message" button */
.form-group button {
    align-self: flex-start;
    margin-top: 1rem;
}


/* === 5. PROPERTY CARD (index.html & listings.html) === */

/* This is the main card container */
.property-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px; /* Nice rounded corners */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05); /* Subtle shadow */
    overflow: hidden; /* Keeps the image corners rounded */
    transition: box-shadow 0.3s ease;
    margin-bottom: 3rem; /* Increased space between cards */
    margin-top: 1.5rem; /* Increased space above cards */
}

.property-card:hover {
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1); /* Lifts the card on hover */
}

.property-card img {
    width: 100%;
    height: 200px;
    object-fit: cover; /* Prevents images from stretching */
}

/* Styles for the text content inside the card */
.property-card h3 {
    font-size: 1.25rem;
    color: var(--primary-color);
    padding: 1rem 1.25rem 0.5rem 1.25rem;
}

.property-card .price {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--secondary-color);
    padding: 0 1.25rem 0.5rem 1.25rem;
}

.property-card .details {
    font-size: 0.9rem;
    color: #6c757d;
    padding: 0 1.25rem 1rem 1.25rem;
}

.property-card .details-button {
    display: block;
    background: var(--light-bg);
    color: var(--primary-color);
    text-align: center;
    padding: 0.75rem;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.property-card .details-button:hover {
    background: #e2e6ea;
}


/* === 6. PAGE-SPECIFIC STYLES === */

/* Styles the header on top of the About, Listings, and Contact pages */
.page-header {
    background: var(--primary-color);
    color: var(--white);
    padding: 2.5rem 0;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
}

/* Styles the hero section on the homepage */
.hero {
    background: var(--primary-color);
    position: relative;
    overflow: hidden;
    color: var(--white);
    padding: 2rem 0;
    text-align: center;
    display: flex;
    align-items: center;
    min-height: 30vh;
}

.hero-bg-slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-bg-slideshow img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    animation: hero-bg-fade 12s infinite ease-in-out;
}

.hero-bg-slideshow img:nth-child(1) { animation-delay: 0s; }
.hero-bg-slideshow img:nth-child(2) { animation-delay: 4s; }
.hero-bg-slideshow img:nth-child(3) { animation-delay: 8s; }

@keyframes hero-bg-fade {
    0%, 100% { opacity: 0; }
    10%, 33% { opacity: 1; }
    43% { opacity: 0; }
}

.hero-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65); /* Dark overlay to keep text readable */
    z-index: 2;
}

/* === OFFICE TOUR BACKGROUND (about.html) === */
.office-tour {
    padding: 40px 0;
}
.office-bg-card {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}
.office-bg-slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}
.office-bg-slideshow img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    animation: bg-fade 12s infinite ease-in-out;
}
.office-bg-slideshow img:nth-child(1) { animation-delay: 0s; }
.office-bg-slideshow img:nth-child(2) { animation-delay: 4s; }
.office-bg-slideshow img:nth-child(3) { animation-delay: 8s; }

@keyframes bg-fade {
    0%, 100% { opacity: 0; }
    10%, 33% { opacity: 1; }
    43% { opacity: 0; }
}

.office-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 2;
}
.office-bg-content {
    position: relative;
    z-index: 3;
    text-align: center;
    padding: 40px;
}
.office-bg-content h2 {
    color: #fff;
    margin-bottom: 15px;
    font-size: 2.5rem;
}
.office-bg-content p {
    font-size: 1.1rem;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
    color: #f1f1f1;
}

.hero .container {
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    max-width: 800px;
}

.hero h2 {
    font-size: 1.5rem;
    margin: 0;
    line-height: 1.2;
}

.hero p {
    font-size: 1rem;
    margin: 0;
    max-width: 600px;
    opacity: 0.9;
}

/* About Page: Mission, Vision, and Team sections */
.mission,
.vision,
.meet-the-team,
.team-section {
    padding: 3rem 1.5rem;
}

/* Mission and Vision Box Styling */
.mission-box,
.vision-box {
    padding: 2rem;
    background-color: #e6f2ff; /* Soft light blue. Change this if you had a specific color in mind! */
    border-left: 5px solid var(--secondary-color); /* Adds a nice blue accent line on the left */
    border-radius: 8px;
    margin-bottom: 2rem;
}

/* Team grid for About page */
.team-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.section-title {
    text-align: center;
    color: var(--primary-color);
    margin-bottom: 2rem;
}

.team-member {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
}

.team-photo {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 0.75rem;
}

.team-member h3 {
    margin: 0.5rem 0 0.25rem;
    font-size: 1.05rem;
    color: var(--primary-color);
}

.team-member .role {
    margin: 0;
    font-weight: 600;
    color: #555;
}

.team-member .bio {
    color: #666;
    font-size: 0.95rem;
    margin-top: 0.5rem;
}


/* Adds spacing to all main sections */
section {
    padding: 3rem 0;
}

/* Styles the two-column layout on the contact page */
.contact-content .container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: flex-start;
    padding: 2rem 0;
}

.contact-info, .contact-form {
    width: 100%;
}

.contact-info h2,
.contact-form h2 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.contact-info p {
    margin-bottom: 1rem;
    font-size: 1.05rem;
    line-height: 1.8;
}

/* === 7. FOOTER STYLES === */
.main-footer {
    background: var(--primary-color);
    color: var(--white);
    padding: 3rem 0 2rem;
    margin-top: 2rem;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    line-height: 1.6;
}

.footer-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-col {
    padding: 0;
    margin-bottom: 2rem;
}

.footer-col h4 {
    color: var(--white);
    font-size: 1.1rem;
    margin-bottom: 1.2rem;
    font-weight: 600;
}

.footer-col p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 1rem;
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-col ul {
    list-style: none;
    padding: 0;
}

.footer-col ul li {
    margin-bottom: 0.8rem;
}

.footer-col ul li a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer-col ul li a:hover {
    color: var(--secondary-color);
}

.col-social-icons {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.col-social-icons a {
    color: var(--white);
    font-size: 1.5rem;
    transition: color 0.3s ease;
}

.col-social-icons a:hover {
    color: var(--secondary-color);
}

.voffset-30 {
    margin-top: 30px;
}

.voffset-40 {
    margin-top: 40px;
}

.footer-hr {
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin: 2rem 0;
}

.footer-copyright {
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}
/* 1. This container holds the slideshow */
.slideshow-container {
    width: 100%;
    height: 200px;
    overflow: hidden;
    position: relative;
}
/* 2. This is the wrapper for the moving images */
.slideshow {
    width: 100%;
    height: 100%;
    display: flex;
    animation: slide 12s infinite ease-in-out;
}
/* 3. This styles each image in the slideshow */
.slideshow img {
    min-width: 100%;
    height: 100%;
    object-fit: cover;
    flex-shrink: 0; /* Prevents squishing so images are perfectly full-width */
}
/* 4. This is the animation keyframe using smooth hardware-accelerated transforms */
@keyframes slide {
    0%, 25% { transform: translateX(0%); }
    33%, 58% { transform: translateX(-100%); }
    66%, 91% { transform: translateX(-200%); }
    100% { transform: translateX(0%); }
}
/* 5. Fallback rule for property cards without slideshows */
.property-card img, .slideshow img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}
.property-card:hover{
    position: relative;
    top:-4px;
}
.team-member:hover{
    position: relative;
    top:-4px;
}
.form-group input:valid{
    border: 1px solid rgb(0, 192, 0);
}

/* -----------------------------
   RESPONSIVE: Progressive Enhancement (Mobile First)
   ----------------------------- */
/* Small Tablets (480px and up) */
@media (min-width: 480px) {
    header h1 img { height: 80px; }
    header nav ul li a { padding: 0.6rem 1rem; font-size: 1rem; }
    
    .hero h2 { font-size: 1.8rem; }
    
    .team-photo { height: 180px; }
    
    .slideshow-container,
    .slideshow img,
    .property-card img,
    .property-card .slideshow img {
        height: 260px;
    }

    .footer-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .footer-col {
        margin-bottom: 0;
    }
}

/* Medium Devices / Tablets (600px and up) */
@media (min-width: 600px) {
    .team-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Large Tablets / Small Desktops (768px and up) */
@media (min-width: 768px) {
    .container { width: 90%; }
    
    header { padding: 0.1rem 0; }
    header .container {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    header nav { width: auto; }
    header nav ul {
        flex-direction: row;
        gap: 2rem;
        width: auto;
        padding: 0;
        justify-content: flex-end;
    }
    header nav ul li {
        display: flex;
        width: auto;
    }
    header nav ul li a {
        display: inline;
        width: auto;
        padding: 0;
        background: transparent;
        font-size: 1rem;
        text-align: left;
    }
    header nav ul li a:hover {
        background: transparent;
    }
    header h1 img {
        height: 140px;
        margin-top: 10px;
    }

    .hero { padding: 1rem 0; }
    .hero h2 { font-size: 2.25rem; }
    .hero p { font-size: 1.05rem; }

    .team-photo { height: 220px; }

    .contact-content .container {
        flex-direction: row;
        gap: 4rem;
    }
    .contact-info { flex: 1; }
    .contact-form { flex: 2; }

    .footer-row {
        grid-template-columns: repeat(4, 1fr);
    }
    .footer-col {
        padding: 0 1rem;
    }
}

/* Desktops (900px and up) */
@media (min-width: 900px) {
    header .container { height: 12vh; }
    header h1 img {
        height: 250px;
        margin-top: 19px;
    }
    
    .hero h2 { font-size: 3rem; }
    .hero p { font-size: 1.25rem; }
    
    .team-grid { grid-template-columns: repeat(3, 1fr); }
    .team-photo { height: 260px; }
    
    .slideshow-container,
    .slideshow img,
    .property-card img,
    .property-card .slideshow img {
        height: 400px;
    }
}
