/* 
   Astera Housing Home Care Elite Core Styles 
   Version 2.0 - Ultra Premium Luxury Aesthetic
*/

:root {
    /* Ultra-Premium Color Palette */
    --color-primary-dark: #0A192F;
    /* Deep rich navy */
    --color-primary-light: #1A365D;
    --color-accent-gold: #D4AF37;
    /* Elegant metallic gold */
    --color-accent-gold-hover: #F3E5AB;
    --color-accent-maroon: #800000;
    /* Sophisticated burgundy/maroon */

    /* Neutral & Backgrounds */
    --color-bg-light: #F8F9FA;
    --color-bg-white: #FFFFFF;
    --color-text-dark: #2D3748;
    --color-text-muted: #718096;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--color-primary-dark) 0%, #112240 100%);
    --gradient-gold: linear-gradient(135deg, #BF953F, #FCF6BA, #B38728, #FBF5B7, #AA771C);

    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Lato', sans-serif;

    /* Shadows & Glassmorphism */
    --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.12);
    --glass-bg: rgba(255, 255, 255, 0.92);
    --glass-border: 1px solid rgba(255, 255, 255, 0.4);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.05);

    /* Transitions */
    --transition-fast: 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    --transition-base: 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    --transition-slow: 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--color-text-dark);
    line-height: 1.8;
    background-color: var(--color-bg-white);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    line-height: 1.25;
    margin-bottom: 1.5rem;
    color: var(--color-primary-dark);
    letter-spacing: -0.02em;
}

h1 {
    font-size: 4rem;
}

h2 {
    font-size: 3rem;
}

h3 {
    font-size: 2rem;
}

h4 {
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-family: var(--font-body);
    font-weight: 700;
}

a {
    color: var(--color-primary-dark);
    text-decoration: none;
    transition: var(--transition-fast);
}

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

/* SVG Icon Styling */
.svg-icon {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    display: inline-block;
}

.container {
    width: 100%;
    max-width: 1400px;
    /* Wider container for luxury feel */
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 8rem 0;
    /* More breathing room */
    position: relative;
}

.text-center {
    text-align: center;
}

.mt-1 {
    margin-top: 1rem;
}

.mt-2 {
    margin-top: 2rem;
}

.mt-3 {
    margin-top: 3rem;
}

.mt-4 {
    margin-top: 4rem;
}

.mb-1 {
    margin-bottom: 1rem;
}

.mb-2 {
    margin-bottom: 2rem;
}

.mb-3 {
    margin-bottom: 3rem;
}

.mb-4 {
    margin-bottom: 4rem;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.max-w-800 {
    max-width: 800px;
}

/* Typography Utility */
.lead-text {
    font-size: 1.35rem;
    color: var(--color-text-muted);
    font-weight: 300;
    line-height: 1.8;
}

.highlight-gold {
    color: var(--color-accent-gold);
}

/* Luxury Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.25rem 2.5rem;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border-radius: 0;
    /* Sharp corners for high-end look */
    cursor: pointer;
    transition: var(--transition-base);
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary {
    background: var(--color-accent-gold);
    color: var(--color-primary-dark);
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    color: var(--color-accent-gold);
    border-color: var(--color-primary-dark);
}

.btn-outline {
    background: transparent;
    color: var(--color-primary-dark);
    border: 1px solid var(--color-primary-dark);
}

.btn-outline:hover {
    background: var(--color-primary-dark);
    color: var(--color-bg-white);
}

.btn-outline-white {
    background: transparent;
    color: var(--color-bg-white);
    border: 1px solid var(--color-bg-white);
}

.btn-outline-white:hover {
    background: var(--color-bg-white);
    color: var(--color-primary-dark);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: transparent;
    transition: var(--transition-base);
    padding: 1.5rem 0;
}

.header.scrolled {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: var(--glass-shadow);
    padding: 0.75rem 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
}

/* Increased logo size */
.logo-img {
    height: 85px;
    transition: var(--transition-base);
}

.header.scrolled .logo-img {
    height: 65px;
}

.nav-links {
    display: flex;
    gap: 3rem;
    list-style: none;
    align-items: center;
}

.nav-links li a {
    font-weight: 500;
    color: var(--color-primary-dark);
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    position: relative;
    padding-bottom: 0.5rem;
}

.header:not(.scrolled) .nav-links li a.light-text {
    color: var(--color-bg-white);
}

.nav-links li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: 0;
    left: 0;
    background-color: var(--color-accent-gold);
    transition: var(--transition-base);
}

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

.contact-phone-nav {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.contact-phone-nav span {
    font-size: 0.75rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-muted);
}

.header:not(.scrolled) .contact-phone-nav span.light-text {
    color: rgba(255, 255, 255, 0.7);
}

.contact-phone-nav a {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.25rem;
    color: var(--color-accent-gold);
}

.header:not(.scrolled) .contact-phone-nav a.light-text {
    color: var(--color-bg-white);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--color-primary-dark);
    cursor: pointer;
}

.header:not(.scrolled) .mobile-menu-btn.light-text {
    color: var(--color-bg-white);
}

/* Hero Section (Home) */
.home-hero {
    height: 100vh;
    min-height: 800px;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.5s ease-in-out, transform 10s ease-in-out;
    transform: scale(1.05);
    /* Subtle zoom effect */
}

.hero-slide.active {
    opacity: 1;
    transform: scale(1);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(10, 25, 47, 0.8) 0%, rgba(10, 25, 47, 0.4) 100%);
    z-index: 1;
}

.hero-content {
    max-width: 900px;
    position: relative;
    z-index: 2;
    padding-top: 100px;
}

.hero-content h1 {
    color: var(--color-bg-white);
    font-size: 5rem;
    margin-bottom: 2rem;
    line-height: 1.1;
    animation: slideUp 1.2s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

.hero-content p {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 3rem;
    animation: slideUp 1.2s cubic-bezier(0.25, 1, 0.5, 1) 0.2s forwards;
    opacity: 0;
    font-weight: 300;
    max-width: 700px;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    animation: slideUp 1.2s cubic-bezier(0.25, 1, 0.5, 1) 0.4s forwards;
    opacity: 0;
}

/* Page Hero Header (for internal pages) */
.page-hero {
    padding: 12rem 0 6rem;
    background-size: cover;
    background-position: center;
    color: var(--color-bg-white);
    text-align: center;
    position: relative;
}

.page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(10, 25, 47, 0.8) 0%, rgba(10, 25, 47, 0.6) 100%);
    z-index: 0;
}

.page-hero .container {
    position: relative;
    z-index: 1;
}

.page-hero h1 {
    color: var(--color-bg-white);
    font-size: 4rem;
    margin-bottom: 1rem;
}

/* Trust Bar */
.trust-bar {
    background-color: var(--color-bg-white);
    padding: 2.5rem 0;
    box-shadow: var(--shadow-sm);
    position: relative;
    z-index: 10;
    margin-top: -50px;
    /* Overlap hero slightly */
}

.trust-flex {
    display: flex;
    justify-content: center;
    gap: 4rem;
    flex-wrap: wrap;
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-weight: 500;
    color: var(--color-text-dark);
    font-size: 1.1rem;
}

.trust-item svg {
    color: var(--color-accent-gold);
    width: 32px;
    height: 32px;
}

/* About Section */
.about-preview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
    align-items: center;
}

.img-stack {
    position: relative;
}

.img-stack img {
    box-shadow: var(--shadow-lg);
    position: relative;
    z-index: 2;
}

.img-stack::after {
    content: '';
    position: absolute;
    bottom: -30px;
    right: -30px;
    width: 100%;
    height: 100%;
    border: 1px solid var(--color-accent-gold);
    z-index: 1;
}

/* Services */
.services-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2.5rem;
    margin-top: 4rem;
}

.service-card {
    background: var(--color-bg-white);
    padding: 3rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition-slow);
    border: 1px solid rgba(0, 0, 0, 0.03);
    position: relative;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--gradient-gold);
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition-base);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-icon-wrap {
    margin-bottom: 2rem;
    color: var(--color-accent-gold);
}

.service-icon-wrap svg {
    width: 48px;
    height: 48px;
}

.service-content h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

/* Timeline */
.timeline {
    position: relative;
    max-width: 900px;
    margin: 5rem auto 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: 0;
    height: 100%;
    width: 1px;
    background: rgba(10, 25, 47, 0.1);
}

.timeline-item {
    position: relative;
    padding-bottom: 4rem;
    width: 50%;
    padding-right: 4rem;
}

.timeline-item:nth-child(even) {
    margin-left: auto;
    padding-right: 0;
    padding-left: 4rem;
}

.timeline-item::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 0;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--color-bg-white);
    border: 3px solid var(--color-accent-gold);
}

.timeline-item:nth-child(even)::after {
    left: -8px;
}

/* Stats */
.stats-section {
    background: var(--color-primary-dark);
    position: relative;
}

/* Background image overlay for stats to add texture */
.stats-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://am8.nyc3.digitaloceanspaces.com/vasilyev.michael97@gmail.com-texture.webp') center/cover;
    opacity: 0.1;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 4rem;
    position: relative;
    z-index: 2;
}

.stat-item {
    text-align: center;
}

.stat-item h3 {
    color: var(--color-accent-gold);
    font-size: 4.5rem;
    margin-bottom: 0;
    font-weight: 400;
}

.stat-item p {
    font-size: 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-bg-white);
}

/* Forms */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    margin-top: 4rem;
}

.contact-info-card {
    padding-right: 2rem;
}

.contact-detail {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.contact-detail svg {
    color: var(--color-accent-gold);
    width: 32px;
    height: 32px;
    flex-shrink: 0;
}

.contact-detail h4 {
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.contact-form-wrap {
    background: var(--color-bg-white);
    padding: 4rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.form-group {
    margin-bottom: 2rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.75rem;
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-muted);
}

.form-control {
    width: 100%;
    padding: 1rem;
    border: none;
    border-bottom: 1px solid #E2E8F0;
    background: transparent;
    font-family: var(--font-body);
    font-size: 1.1rem;
    transition: var(--transition-base);
}

.form-control:focus {
    outline: none;
    border-color: var(--color-accent-gold);
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* FAQ Accordion */
.accordion-item {
    border-bottom: 1px solid #E2E8F0;
    margin-bottom: 0;
}

.accordion-header {
    width: 100%;
    padding: 2rem 0;
    background: none;
    border: none;
    text-align: left;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--color-primary-dark);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.accordion-header svg {
    transition: transform 0.4s ease;
    width: 24px;
    height: 24px;
    color: var(--color-accent-gold);
}

.accordion-header[aria-expanded="true"] svg {
    transform: rotate(180deg);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
}

.accordion-content p {
    padding-bottom: 2rem;
    color: var(--color-text-muted);
    font-size: 1.1rem;
}

/* Footer Focus */
.site-footer {
    background-color: var(--color-primary-dark);
    color: rgba(255, 255, 255, 0.7);
    padding: 6rem 0 2rem;
    position: relative;
}

/* We don't invert the logo now as requested, we just show it normally unless it needs styling.
   If the background is dark, and the logo is dark text, it might need brightness/invert. 
   The user said "Logo in footer is all white fix it." - So I will remove the filter and let it display naturally.
   If it's dark text on dark bg, I will add a subtle light backing to it. */
.footer-logo {
    max-width: 250px;
    margin-bottom: 2rem;
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.1));
}

.footer-grid {
    display: grid;
    grid-template-columns: 2.5fr 1fr 1.5fr 2fr;
    gap: 3rem;
    margin-bottom: 4rem;
}

.footer-col h4 {
    color: var(--color-bg-white);
    font-size: 1rem;
    margin-bottom: 2rem;
}

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

.footer-links li {
    margin-bottom: 1rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
}

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

.footer-contact p {
    margin-bottom: 1rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.footer-contact svg {
    color: var(--color-accent-gold);
    margin-top: 4px;
    width: 18px;
    height: 18px;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Animations */
@keyframes slideUp {
    from {
        transform: translateY(40px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.animate-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1s cubic-bezier(0.25, 1, 0.5, 1), transform 1s cubic-bezier(0.25, 1, 0.5, 1);
}

.animate-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.delay-1 {
    transition-delay: 0.1s;
}

.delay-2 {
    transition-delay: 0.2s;
}

.delay-3 {
    transition-delay: 0.3s;
}

/* Mobile Responsiveness */
@media (max-width: 1024px) {
    .hero-content h1 {
        font-size: 4rem;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .about-preview,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 4rem;
    }

    .timeline::before {
        left: 40px;
        transform: none;
    }

    .timeline-item {
        width: 100%;
        padding-left: 100px;
        padding-right: 0;
    }

    .timeline-item:nth-child(even) {
        padding-left: 100px;
    }

    .timeline-item::after {
        left: 32px !important;
        right: auto;
    }
}

@media (max-width: 768px) {

    .nav-links,
    .contact-phone-nav {
        display: none;
        width: 100%;
        text-align: center;
    }

    .nav-links.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        background: var(--color-bg-white);
        padding: 3rem;
        box-shadow: var(--shadow-md);
        gap: 2rem;
    }

    .header:not(.scrolled) .nav-links.active li a.light-text {
        color: var(--color-primary-dark);
    }

    .mobile-menu-btn {
        display: block;
    }

    .hero-content h1 {
        font-size: 3rem;
    }

    .hero-content p {
        font-size: 1.25rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .trust-flex {
        flex-direction: column;
        gap: 2rem;
        align-items: flex-start;
        padding: 0 2rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}