/* RentWise India Custom Premium CSS */

:root {
    --primary-color: #2563eb; /* Modern Indigo/Blue */
    --primary-light: #eff6ff;
    --primary-dark: #1d4ed8;
    --secondary-color: #64748b;
    --dark-color: #0f172a;
    --light-color: #f8fafc;
    --bg-color: #f1f5f9;
    --font-family: 'Outfit', sans-serif;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-color);
    color: var(--dark-color);
    -webkit-font-smoothing: antialiased;
}

/* Premium Rounded Cards with Soft Shadows */
.card-premium {
    border: none;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: #ffffff;
    overflow: hidden;
}

.card-premium:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.card-premium .card-header {
    background-color: transparent;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    padding: 1.5rem;
    font-weight: 600;
}

.card-premium .card-body {
    padding: 1.5rem;
}

/* Glass Effect & Modern Navbar */
.glass-effect {
    background: rgba(255, 255, 255, 0.92) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.modern-navbar {
    padding-top: 0.65rem;
    padding-bottom: 0.65rem;
    transition: all 0.2s ease-in-out;
}

.brand-icon-box {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: #ffffff;
    border-radius: 10px;
    font-size: 1.15rem;
}

.nav-link-custom {
    color: #475569 !important;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 0.9rem !important;
    border-radius: 8px;
    transition: all 0.18s ease-in-out;
}

.nav-link-custom:hover {
    color: var(--primary-color) !important;
    background-color: #f1f5f9;
}

.nav-link-custom.active {
    color: var(--primary-color) !important;
    background-color: var(--primary-light);
    font-weight: 600;
}

/* Mega Dropdown */
.dropdown-mega-menu {
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 0 !important;
    background: #ffffff;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.08) !important;
}

@media (min-width: 992px) {
    /* Mega menu stays open while hovering the trigger OR the menu itself */
    .dropdown-mega:hover > .dropdown-mega-menu,
    .dropdown-mega-menu:hover {
        display: block;
        animation: fadeInMega 0.15s ease-out;
    }
    /* Bridge the gap between the nav link and dropdown so mouse doesn't slip out */
    .dropdown-mega-menu {
        padding-top: 12px !important;
        margin-top: -8px !important;
    }
    /* Invisible hover bridge so moving mouse downward doesn't lose hover state */
    .dropdown-mega::before {
        content: '';
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        height: 12px;
        z-index: 9999;
    }
}

@keyframes fadeInMega {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.mega-category-title {
    font-size: 0.75rem;
    letter-spacing: 0.06em;
}

.mega-link-list li {
    margin-bottom: 0.55rem;
}

.mega-link-list li a {
    color: #334155;
    text-decoration: none;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    transition: color 0.15s ease;
}

.mega-link-list li a:hover {
    color: var(--primary-color);
}

.btn-search-icon {
    width: 38px;
    height: 38px;
    padding: 0;
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    transition: all 0.2s ease;
}

.btn-search-icon:hover {
    background-color: #e2e8f0;
    color: var(--primary-color);
}

.btn-nav-cta {
    font-size: 0.9rem;
    padding: 0.5rem 1.25rem !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

/* Typography Enhancements */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #1e293b;
}

/* Buttons */
.btn {
    border-radius: 12px;
    padding: 0.75rem 1.75rem;
    font-weight: 600;
    transition: all 0.25s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border: none;
    color: #fff;
    box-shadow: 0 4px 14px 0 rgba(37, 99, 235, 0.39);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark), #1e40af);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

/* Form Controls */
.form-control, .form-select {
    border-radius: 12px;
    padding: 0.75rem 1rem;
    border: 1px solid #cbd5e1;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background-color: #f8fafc;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    background-color: #fff;
    box-shadow: 0 0 0 0.25rem rgba(37, 99, 235, 0.15);
}

/* Calculator Result Block */
.result-block {
    background-color: var(--primary-light);
    border-left: 4px solid var(--primary-color);
    padding: 1.5rem;
    border-radius: 0 12px 12px 0;
    margin-top: 1.5rem;
}

.result-block .value {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--primary-color);
}

/* Breadcrumb Styling */
.breadcrumb-container {
    background-color: #fff;
    padding: 1rem 1.25rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
}

.breadcrumb-item a {
    text-decoration: none;
    color: var(--secondary-color);
    font-weight: 500;
}

.breadcrumb-item.active {
    color: var(--primary-color);
    font-weight: 600;
}

/* Sidebar Utilities */
.sticky-sidebar {
    position: sticky;
    top: 100px;
}

/* Interactive Hover Lifts */
.hover-lift {
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08) !important;
}

/* Custom Gradient Backgrounds */
.bg-gradient-primary {
    background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
}

/* ==========================================================================
   Clean Print Optimization Stylesheet
   Hides navigation, footers, action buttons, sidebars, ads, and UI controls,
   and optimizes report readability on physical print / browser print.
   ========================================================================== */
@media print {
    /* Hide non-printable navigation, footers, share buttons, sidebar */
    nav, 
    footer, 
    .navbar, 
    .site-footer, 
    .breadcrumb-container, 
    .d-print-none, 
    .btn, 
    .sticky-sidebar, 
    .faq-section, 
    .related-calculators,
    .no-print {
        display: none !important;
    }

    body {
        background: #ffffff !important;
        color: #000000 !important;
        font-size: 11pt;
        line-height: 1.4;
    }

    .main-content {
        margin: 0 !important;
        padding: 0 !important;
    }

    .container, .container-fluid {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    .card, .card-premium {
        border: 1px solid #cbd5e1 !important;
        box-shadow: none !important;
        margin-bottom: 20px !important;
        page-break-inside: avoid;
    }

    .result-block {
        border: 2px solid #2563eb !important;
        background-color: #f8fafc !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        padding: 1rem !important;
        margin-bottom: 1.5rem !important;
    }

    .table {
        border-collapse: collapse !important;
        width: 100% !important;
    }

    .table td, .table th {
        background-color: transparent !important;
        border: 1px solid #cbd5e1 !important;
        padding: 6px 10px !important;
    }

    @page {
        margin: 1.5cm;
        size: A4 portrait;
    }
}
