/* ========================================
   Villa Zaragosa - Main Stylesheet
   Modern Property Management System
   ======================================== */

/* ---- Base Styles ---- */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--body-font);
    color: var(--text-color);
    line-height: 1.7;
    overflow-x: hidden;
    margin: 0;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--heading-font);
    font-weight: 700;
    color: var(--secondary-color);
}

a { color: var(--primary-color); text-decoration: none; transition: all 0.3s ease; }
a:hover { color: var(--accent-color); }

.letter-spacing-2 { letter-spacing: 2px; }

/* ---- Navbar ---- */
#mainNav {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.08);
    padding: 0.75rem 0;
    transition: all 0.3s ease;
    z-index: 1050;
}

#mainNav.scrolled {
    padding: 0.5rem 0;
    box-shadow: 0 4px 30px rgba(0,0,0,0.12);
}

.brand-lockup {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none !important;
}

.brand-mark {
    height: 60px;
    width: 60px;
    object-fit: contain;
    flex-shrink: 0;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(26, 26, 46, 0.08);
}

.brand-text {
    font-family: var(--heading-font);
    font-weight: 800;
    font-size: 1.6rem;
    line-height: 1.1;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    white-space: nowrap;
}

.brand-lockup-footer .brand-mark {
    height: 52px;
    width: 52px;
}

.brand-text-footer {
    color: #fff !important;
    background: none !important;
    -webkit-text-fill-color: #fff !important;
    font-size: 1.45rem;
}

#mainNav .nav-link.active {
    color: var(--primary-color);
    font-weight: 600;
}

/* Toast host (avoids fixed-nav collision) */
.toast-host {
    position: fixed;
    top: 88px;
    right: 1.25rem;
    z-index: 1080;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-width: min(420px, calc(100vw - 2rem));
}

.toast-host .toast {
    box-shadow: 0 8px 28px rgba(26, 26, 46, 0.16);
    border: none;
    border-radius: 12px;
}

/* Auth / login premium card */
.auth-card .auth-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.auth-card .auth-brand .brand-mark {
    height: 72px;
    width: 72px;
}

.auth-card .password-toggle-wrap {
    position: relative;
}

.auth-card .password-toggle-wrap .form-control {
    padding-right: 2.75rem;
}

.auth-card .password-toggle {
    position: absolute;
    right: 0.65rem;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    color: #6c757d;
    padding: 0.25rem;
    line-height: 1;
}

.auth-card .password-toggle:hover {
    color: var(--primary-color);
}

.auth-demo-creds {
    background: var(--light-bg);
    border-radius: 10px;
    padding: 0.85rem 1rem;
    text-align: left;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
    background: #fff;
    border: 1px dashed #d8dde6;
    border-radius: 14px;
}

.empty-state-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(77, 101, 255, 0.12), rgba(26, 26, 46, 0.08));
    color: var(--primary-color);
    font-size: 1.75rem;
}

.empty-state-title {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 1.15rem;
    margin-bottom: 0.35rem;
}

.empty-state-message {
    color: #6c757d;
    margin-bottom: 1.25rem;
    max-width: 360px;
    margin-left: auto;
    margin-right: auto;
}

.nav-logo,
.footer-logo {
    height: 52px;
    width: auto;
    max-width: 280px;
    object-fit: contain;
}

#mainNav .nav-link {
    color: var(--secondary-color);
    font-weight: 500;
    padding: 0.5rem 1rem;
    transition: color 0.3s ease;
    font-size: 0.95rem;
}

#mainNav .nav-link:hover {
    color: var(--primary-color);
}

.nav-cta-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border: none;
    color: #fff !important;
    padding: 0.5rem 1.5rem !important;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.nav-cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(77,101,255,0.4);
    color: #fff !important;
}

.user-menu-toggle {
    font-size: 1.3rem;
}

/* ---- Hero Section ---- */
.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background-color: #0b1220;
    background-image:
        linear-gradient(135deg, rgba(10, 16, 32, 0.72) 0%, rgba(15, 23, 42, 0.55) 45%, rgba(26, 35, 74, 0.68) 100%),
        url('/images/backgrounds/hero-skyline.jpg');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.hero-section.has-custom-bg {
    background-image:
        linear-gradient(135deg, rgba(10, 16, 32, 0.72) 0%, rgba(15, 23, 42, 0.55) 45%, rgba(26, 35, 74, 0.68) 100%),
        var(--hero-bg-image);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background:
        radial-gradient(ellipse 80% 60% at 50% 40%, rgba(255,255,255,0.08) 0%, transparent 60%),
        linear-gradient(180deg, rgba(0,0,0,0.15) 0%, transparent 35%, rgba(0,0,0,0.35) 100%);
    z-index: 0;
    pointer-events: none;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(180deg, rgba(8,12,24,0.25) 0%, rgba(8,12,24,0.45) 100%);
    z-index: 0;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    padding-top: 80px;
}

.hero-title {
    color: #fff;
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
    text-shadow: 0 4px 24px rgba(0,0,0,0.35);
}

.hero-subtitle {
    color: rgba(255,255,255,0.9);
    font-size: 1.25rem;
    max-width: 640px;
    margin: 0 auto 2rem;
    line-height: 1.8;
    text-shadow: 0 2px 12px rgba(0,0,0,0.25);
}

.hero-cta {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border: none;
    color: #fff;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(77,101,255,0.35);
}

.hero-cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 36px rgba(77,101,255,0.5);
    color: #fff;
}

.hero-wave {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    z-index: 1;
}

.hero-wave svg {
    display: block;
    width: 100%;
    height: 80px;
}

/* ---- Clients Section ---- */
.clients-section {
    background: #fff;
}

.client-logos-track {
    overflow: hidden;
    position: relative;
}

.client-logos-slider {
    display: flex;
    gap: 3rem;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.client-logo-item {
    flex: 0 0 auto;
    opacity: 0.5;
    transition: opacity 0.3s ease;
    filter: grayscale(100%);
}

.client-logo-item:hover {
    opacity: 1;
    filter: grayscale(0%);
}

.client-logo-item img {
    height: 50px;
    width: auto;
    object-fit: contain;
}

.client-placeholder {
    padding: 0.75rem 1.5rem;
    background: var(--light-bg);
    border-radius: 8px;
    font-weight: 600;
    color: #999;
    font-size: 0.85rem;
    white-space: nowrap;
}

/* ---- Stats Section ---- */
.stats-section {
    background: var(--light-bg);
}

.stat-card {
    padding: 2rem 1rem;
}

.stat-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.75rem;
    display: block;
}

.stat-value {
    font-family: var(--heading-font);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--secondary-color);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.9rem;
    color: #777;
    margin-top: 0.25rem;
    font-weight: 500;
}

/* ---- Section Common ---- */
.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
}

.section-subtitle {
    color: #777;
    font-size: 1.1rem;
    max-width: 500px;
    margin: 0 auto;
}

/* ---- Features Section ---- */
.features-section {
    padding: 5rem 0;
    background: #fff;
}

.feature-tabs {
    margin-bottom: 2rem;
}

.feature-tab {
    background: transparent !important;
    color: var(--text-color) !important;
    border: 2px solid #e0e0e0 !important;
    border-radius: 50px !important;
    padding: 0.6rem 1.5rem !important;
    margin: 0.25rem;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease !important;
}

.feature-tab:hover {
    border-color: var(--primary-color) !important;
    color: var(--primary-color) !important;
}

.feature-tab.active {
    background: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: #fff !important;
}

.feature-headline {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.feature-desc {
    font-size: 1.05rem;
    line-height: 1.8;
}

.feature-bullets {
    list-style: none;
    padding: 0;
    margin-top: 1.5rem;
}

.feature-bullets li {
    padding: 0.4rem 0;
    font-size: 1rem;
}

.feature-image-wrapper {
    background: linear-gradient(135deg, #f0f2ff 0%, #e8ebff 100%);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-image {
    max-width: 100%;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.feature-placeholder {
    text-align: center;
    color: var(--primary-color);
    opacity: 0.5;
}

.feature-placeholder i {
    font-size: 5rem;
    display: block;
    margin-bottom: 1rem;
}

.feature-placeholder span {
    font-size: 1.1rem;
    font-weight: 600;
}

/* ---- Solutions Section ---- */
.solutions-section {
    padding: 5rem 0;
    background: var(--light-bg);
}

.solution-card {
    background: #fff;
    border-radius: 16px;
    padding: 2.5rem 2rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    border: 1px solid #eee;
}

.solution-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.1);
    border-color: var(--primary-color);
}

.solution-icon {
    width: 70px;
    height: 70px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(77,101,255,0.1), rgba(77,101,255,0.05));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.solution-name {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.solution-tagline {
    color: var(--primary-color);
    font-weight: 500;
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.solution-desc {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.solution-features {
    list-style: none;
    padding: 0;
    margin-bottom: 1.5rem;
}

.solution-features li {
    padding: 0.3rem 0;
    font-size: 0.9rem;
    color: #555;
}

.solution-features li i { color: var(--primary-color); }

/* ---- Testimonials Section ---- */
.testimonials-section {
    padding: 5rem 0;
    background: #fff;
}

.testimonial-card {
    background: var(--light-bg);
    border-radius: 16px;
    padding: 2rem;
    height: 100%;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.testimonial-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.testimonial-quote {
    color: var(--primary-color);
    font-size: 2.5rem;
    line-height: 1;
    margin-bottom: 0.5rem;
    opacity: 0.5;
}

.testimonial-text {
    font-size: 1rem;
    line-height: 1.8;
    color: #555;
    font-style: italic;
    margin-bottom: 1.5rem;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.testimonial-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.avatar-placeholder {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
}

/* ---- Awards Section ---- */
.awards-section {
    padding: 5rem 0;
    background: var(--light-bg);
}

.award-card {
    padding: 2rem 1rem;
    transition: transform 0.3s ease;
}

.award-card:hover { transform: translateY(-5px); }

.award-badge {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ffd700, #ffaa00);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 2rem;
    color: #fff;
    box-shadow: 0 4px 15px rgba(255,170,0,0.3);
}

.award-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.award-year {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
}

/* ---- CTA Section ---- */
.cta-section {
    position: relative;
    padding: 6rem 0;
    background-color: #0b1220;
    background-image:
        linear-gradient(135deg, rgba(15, 23, 42, 0.78) 0%, rgba(30, 41, 90, 0.72) 50%, rgba(77, 101, 255, 0.55) 100%),
        url('/images/backgrounds/cta-city-dusk.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    color: #fff;
    overflow: hidden;
}

.cta-section.has-custom-bg {
    background-image:
        linear-gradient(135deg, rgba(15, 23, 42, 0.78) 0%, rgba(30, 41, 90, 0.72) 50%, rgba(77, 101, 255, 0.55) 100%),
        var(--cta-bg-image);
}

.cta-title {
    color: #fff;
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-subtitle {
    color: rgba(255,255,255,0.85);
    font-size: 1.15rem;
    max-width: 600px;
    margin: 0 auto 2rem;
}

.cta-button {
    background: #fff;
    color: var(--primary-color);
    border: none;
    padding: 0.85rem 2.5rem;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
    color: var(--secondary-color);
}

/* ---- Page Header ---- */
.page-header-section {
    position: relative;
    background-color: #0b1220;
    background-image:
        linear-gradient(135deg, rgba(10, 16, 32, 0.78) 0%, rgba(26, 35, 74, 0.65) 55%, rgba(77, 101, 255, 0.45) 100%),
        url('/images/backgrounds/page-architecture.jpg');
    background-size: cover;
    background-position: center 40%;
    background-repeat: no-repeat;
    padding: 9rem 0 3.5rem;
    text-align: center;
    color: #fff;
}

.page-header-section.page-header-login {
    background-image:
        linear-gradient(135deg, rgba(10, 16, 32, 0.8) 0%, rgba(15, 23, 42, 0.7) 100%),
        url('/images/backgrounds/login-lobby.jpg');
    background-position: center;
    min-height: 42vh;
    display: flex;
    align-items: flex-end;
    padding-bottom: 3rem;
}

.page-title {
    color: #fff;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.page-subtitle {
    color: rgba(255,255,255,0.8);
    font-size: 1.1rem;
}

/* ---- Contact Page ---- */
.contact-info-card {
    background-color: #0b1220;
    background-image:
        linear-gradient(135deg, rgba(15, 23, 42, 0.92) 0%, rgba(26, 35, 74, 0.88) 100%),
        url('/images/backgrounds/brochure-towers.jpg');
    background-size: cover;
    background-position: center;
    color: #fff;
    border-radius: 16px;
    padding: 2.5rem;
    height: 100%;
}

.contact-info-card h4 { color: #fff; }

.contact-info-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.contact-info-item i {
    font-size: 1.25rem;
    color: var(--accent-color);
    margin-top: 0.2rem;
}

.contact-info-item p {
    color: rgba(255,255,255,0.8);
    margin: 0.25rem 0 0;
}

.contact-info-item a { color: rgba(255,255,255,0.8); }
.contact-info-item a:hover { color: #fff; }

/* ---- Footer ---- */
.site-footer {
    background: var(--secondary-color);
    color: rgba(255,255,255,0.7);
    padding: 4rem 0 2rem;
}

.footer-logo { height: 52px; width: auto; }

.footer-desc {
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
    line-height: 1.7;
}

.footer-heading {
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.25rem;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li { margin-bottom: 0.5rem; }

.footer-links a {
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer-links a:hover { color: #fff; }

.footer-contact {
    list-style: none;
    padding: 0;
}

.footer-contact li {
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
    display: flex;
    align-items: flex-start;
}

.footer-contact a {
    color: rgba(255,255,255,0.6);
}

.footer-contact a:hover { color: #fff; }

.social-links {
    display: flex;
    gap: 0.75rem;
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    transition: all 0.3s ease;
    font-size: 1.1rem;
}

.social-link:hover {
    background: var(--primary-color);
    color: #fff;
    transform: translateY(-2px);
}

.footer-divider {
    border-color: rgba(255,255,255,0.1);
    margin: 2rem 0 1.5rem;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-bottom p {
    margin: 0;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.5);
}

.footer-legal {
    display: flex;
    gap: 1.5rem;
}

.footer-legal a {
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
}

.footer-legal a:hover { color: #fff; }

/* ---- Buttons ---- */
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* ---- Animation on Scroll ---- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---- Blog Cards ---- */
.blog-card {
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid #eee;
    height: 100%;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.blog-card-img {
    height: 200px;
    background: linear-gradient(135deg, #f0f2ff, #e8ebff);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 3rem;
}

.blog-card-body { padding: 1.5rem; }

/* ---- FAQ Items ---- */
.faq-item {
    background: var(--light-bg);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.faq-item h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

/* ---- Cards ---- */
.card {
    border-radius: 12px;
}

.auth-section {
    background:
        linear-gradient(180deg, rgba(248,250,252,0.96) 0%, rgba(241,245,249,1) 100%),
        url('/images/backgrounds/features-interior.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: scroll;
}

.auth-card {
    border-radius: 18px !important;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.12) !important;
    backdrop-filter: blur(8px);
    background: rgba(255,255,255,0.96);
}

.solution-card-media {
    height: 200px;
    background-color: #0b1220;
    background-image:
        linear-gradient(135deg, rgba(77,101,255,0.55) 0%, rgba(26,35,74,0.7) 100%),
        url('/images/backgrounds/features-interior.jpg');
    background-size: cover;
    background-position: center;
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
    .hero-title { font-size: 2.25rem; }
    .hero-subtitle { font-size: 1rem; }
    .section-title { font-size: 1.75rem; }
    .stat-value { font-size: 1.75rem; }
    .footer-bottom { flex-direction: column; text-align: center; }
    .cta-title { font-size: 1.75rem; }
    .hero-section,
    .cta-section,
    .page-header-section {
        background-attachment: scroll;
    }
}

@media (max-width: 576px) {
    .hero-title { font-size: 1.75rem; }
    .feature-tab { font-size: 0.8rem; padding: 0.5rem 1rem !important; }
}
