/* ==========================================================
   CondoSuite PRO — Modern Mobile-First Rebirth (v2.0)
   Design Language: Premium, Fast, Inter-based
   ========================================================== */

/* --- Variables (Token System) --- */
:root {
    /* Colors */
    --primary:       #2563EB;
    --primary-dark:  #1D4ED8;
    --primary-light: #EFF6FF;
    --secondary:     #64748B;
    --dark:          #111827;
    --darker:        #030712;
    --surface:       #FFFFFF;
    --background:    #F8FAFC;
    --border:        #E2E8F0;
    --success:       #10B981;
    --warning:       #F59E0B;
    --danger:        #EF4444;

    /* Spacing & Sizing */
    --p-mobile:      24px;
    --p-desktop:     10%;
    --radius-sm:     0.5rem;
    --radius-md:     0.75rem;
    --radius-lg:     1.5rem;
    --radius-full:   9999px;

    /* Effects */
    --shadow-sm:     0 1px 3px 0 rgb(0 0 0 / 0.1);
    --shadow-md:     0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg:     0 10px 15px -3px rgb(0 0 0 / 0.1);
    --shadow-blue:   0 10px 30px -10px rgba(37, 99, 235, 0.35);
    --transition:    all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Global Base & Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
    width: 100%;
    overflow-x: hidden;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--dark);
    line-height: 1.6;
    background: var(--surface);
}

/* Typography Scale */
h1, h2, h3, h4, h5 { color: var(--darker); font-weight: 800; line-height: 1.2; letter-spacing: -0.025em; }
p { color: var(--secondary); word-wrap: break-word; overflow-wrap: break-word; }

img, video, iframe { max-width: 100%; height: auto; border: none; }

/* Utilities */
.container { width: 100%; padding: 0 var(--p-mobile); }
@media (min-width: 1200px) { .container { max-width: 1200px; margin: 0 auto; padding: 0; } }

.d-none { display: none !important; }
@media (min-width: 768px) { .d-md-none { display: none !important; } .d-md-flex { display: flex !important; } }

/* ============================================
   NAVIGATION (Mobile First)
   ============================================ */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    height: 72px;
    background: transparent;
    transition: var(--transition);
}

.navbar.scrolled, .navbar.navbar-solid {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding: 0 var(--p-mobile);
    max-width: 100% !important; /* Overrule container if used */
}

.nav-logo img {
    height: 38px;
    width: auto;
    transition: var(--transition);
}

.nav-links { display: none; }

.nav-toggle {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--darker);
    cursor: pointer;
    padding: 8px;
}

.navbar.navbar-transparent:not(.scrolled) .nav-toggle { color: #fff; }

/* Mobile Menu System */
.nav-mobile-overlay {
    position: fixed;
    inset: 0;
    background: var(--surface);
    z-index: 1100;
    padding: 24px;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
}

.nav-mobile-overlay.active { transform: translateX(0); }

.nav-mobile-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 40px; }
.nav-close { width: 44px; height: 44px; border-radius: 50%; background: var(--background); border: none; font-size: 1.25rem; cursor: pointer; }

.nav-mobile-links { list-style: none; display: flex; flex-direction: column; gap: 20px; }
.nav-mobile-links a { text-decoration: none; font-size: 1.75rem; font-weight: 800; color: var(--darker); }
.nav-mobile-links a.active { color: var(--primary); }

.nav-mobile-footer { margin-top: auto; padding-bottom: 24px; }

/* ============================================
   SECTIONS & HEROES (Mobile First)
   ============================================ */
.section { padding: 64px 0; }
.section-header { text-align: center; margin-bottom: 40px; }

.section-label {
    display: inline-block;
    padding: 4px 12px;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-radius: var(--radius-full);
    margin-bottom: 16px;
}

.section-title { font-size: 2rem; margin-bottom: 20px; }
.section-sub { font-size: 1.1rem; max-width: 650px; margin: 0 auto; line-height: 1.5; color: var(--secondary); }

/* Heroes */
.hero { padding: 120px 0 64px; text-align: center; position: relative; overflow: hidden; }
.hero-content { position: relative; z-index: 2; }
.hero h1 { font-size: clamp(2.25rem, 10vw, 3.75rem); margin-bottom: 24px; }
.hero-sub { margin-bottom: 32px; max-width: 600px; margin-left: auto; margin-right: auto; }
.hero-actions { display: flex; flex-direction: column; gap: 16px; }

.hero-visual { margin-top: 48px; width: 100%; }
.hero-mockup { border-radius: var(--radius-lg); padding: 8px; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.2); backdrop-filter: blur(4px); box-shadow: var(--shadow-lg); }

.page-hero { padding: 140px 0 64px; text-align: center; background: var(--background); }

/* ============================================
   GRID LOADS (Mobile First)
   ============================================ */
/* Flex/Stack for mobile, Grid for desktop */
.grid-stack { display: flex; flex-direction: column; gap: 24px; }

.card {
    padding: 32px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    transition: var(--transition);
}

.card-icon {
    width: 54px; height: 54px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; margin-bottom: 24px;
}

/* ============================================
   INTERIOR PAGES & COMPONENTS (Mobile First)
   ============================================ */
.section-light { background: var(--surface); }
.section-muted { background: var(--background); }

/* Pricing Cards */
.price-card {
    padding: 32px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    position: relative;
    display: flex;
    flex-direction: column;
}
.price-card.featured {
    border-color: var(--primary);
    box-shadow: var(--shadow-blue);
    transform: scale(1.02);
}
.price-badge {
    position: absolute;
    top: -12px; right: 24px;
    background: var(--primary);
    color: white;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 800;
}
.price-name { font-size: 1.25rem; font-weight: 800; color: var(--darker); }
.price-divider { margin: 24px 0; border: none; border-top: 1px dashed var(--border); }
.price-features { list-style: none; margin-bottom: 32px; flex-grow: 1; }
.price-features li { display: flex; align-items: start; gap: 12px; font-size: 0.9rem; margin-bottom: 12px; color: var(--secondary); }
.price-features li i { color: var(--success); margin-top: 4px; }

/* Contact Form & Info */
.contact-info-item { display: flex; gap: 20px; margin-bottom: 32px; }
.contact-info-icon {
    width: 44px; height: 44px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.contact-info-item h4 { font-size: 1rem; margin-bottom: 4px; }

.contact-form-card {
    background: var(--surface);
    padding: 32px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md);
}

.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 0.85rem; font-weight: 700; margin-bottom: 8px; color: var(--darker); }
.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}
.form-row { display: flex; flex-direction: column; gap: 0; }

/* Functional Capabilities (Features Page) */
.capability-group {
    background: var(--surface);
    padding: 32px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
}
.capability-header { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; padding-bottom: 16px; border-bottom: 1px dashed var(--border); }
.capability-header i { font-size: 1.5rem; color: var(--primary); }
.capability-list { list-style: none; }
.capability-list li { display: flex; align-items: start; gap: 10px; font-size: 0.9rem; margin-bottom: 12px; color: var(--secondary); }
.capability-list li i { color: var(--success); margin-top: 4px; }

/* CTA Section */
.cta-section {
    background: var(--primary);
    color: white;
    padding: 80px 0;
    text-align: center;
}
.cta-section h2 { color: white; font-size: 2rem; margin-bottom: 24px; }
.cta-actions { display: flex; flex-direction: column; gap: 16px; margin-top: 32px; }

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 12px 28px; border-radius: var(--radius-md); font-weight: 700;
    text-decoration: none; transition: var(--transition); border: 2px solid transparent;
    cursor: pointer; font-family: inherit;
}

.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-blue); }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); }

.btn-ghost { border-color: var(--border); color: var(--dark); }
.btn-white { background: #fff; color: var(--primary); }

.btn-lg { padding: 16px 36px; font-size: 1.125rem; }

/* Animation Classes */
.animate-in { opacity: 0; transform: translateY(20px); animation: fadeInUp 0.6s forwards; }
@keyframes fadeInUp { to { opacity: 1; transform: translateY(0); } }

/* ============================================
   DESKTOP ADAPTATIONS (min-width: 768px)
   ============================================ */
@media (min-width: 768px) {
    .nav-inner { padding: 0 5%; }
    .nav-links { display: flex; list-style: none; gap: 32px; }
    .nav-links a { text-decoration: none; color: var(--darker); font-weight: 600; font-size: 0.95rem; position: relative; }
    .nav-links a.active::after { content: ''; position: absolute; bottom: -8px; left: 0; right: 0; height: 2px; background: var(--primary); }
    .navbar.navbar-transparent:not(.scrolled) .nav-links a { color: #fff; }
    .nav-toggle { display: none; }

    .hero { text-align: left; padding: 180px 0 100px; min-height: 80vh; display: flex; align-items: center; }
    .hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 64px; align-items: center; }
    .hero-sub { margin-left: 0; }
    .hero-actions { flex-direction: row; }
    .hero-visual { margin-top: 0; }

    .section { padding: 96px 0; }
    .section-title { font-size: 2.75rem; }

    .grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }

    .form-row { flex-direction: row; gap: 20px; }
    .form-row .form-group { flex: 1; }
    
    .cta-section h2 { font-size: 3rem; }
    .cta-actions { flex-direction: row; justify-content: center; }
}
