/* Global Styles */
:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --dark-color: #212529;
    --light-color: #f8f9fa;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    padding-top: 60px; /* Navbar (60px) */
}

/* Navigation Bar */
.navbar {
    height: 60px; /* Fixed navbar height */
    z-index: 1030; /* Ensure navbar stays on top */
}

.navbar.fixed-top {
    position: fixed !important;
    top: 0 !important; /* Position at very top */
    left: 0 !important;
    right: 0 !important;
}

/* Ensure content starts right after navbar with no gaps */
.page-header,
.hero-section,
main,
section:first-of-type {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Remove any extra spacing from first sections */
body > section:first-of-type,
body > main:first-of-type,
.hero-section,
section.py-5:first-of-type,
section.py-4:first-of-type,
section.py-3:first-of-type {
    margin-top: 0 !important;
    padding-top: 0 !important;
}
.contact-bar {
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    z-index: 1029;
    font-size: 0.9rem;
    border-bottom: 1px solid #495057;
}

.contact-info {
    gap: 0;
}

.contact-item {
    display: flex;
    align-items: center;
    white-space: nowrap;
}

.contact-item a {
    transition: color 0.3s ease;
}

.contact-item a:hover {
    color: var(--primary-color) !important;
}

.contact-item i {
    font-size: 0.85rem;
    width: 16px;
    text-align: center;
}

.tagline {
    font-size: 0.85rem;
    font-weight: 500;
}

/* Navigation */
.navbar {
    background-color: #343a40 !important;
    box-shadow: 0 2px 4px rgba(0,0,0,.1);
    top: 0 !important; /* Position at very top */
    height: 60px; /* Fixed navbar height */
    z-index: 1030; /* Above contact bar */
}

/* Mobile navbar adjustments */
@media (max-width: 991.98px) {
    .navbar {
        position: relative !important; /* Allow mobile menu to expand naturally */
    }
    
    .navbar-toggler {
        border: 1px solid rgba(255,255,255,0.3);
        padding: 4px 8px;
    }
    
    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.2rem rgba(255,255,255,0.25);
    }
    
    .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
    }
}

.navbar-brand {
    font-size: 1.5rem;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-image: url('https://images.unsplash.com/photo-1567767292278-a4f21aa2d36e?w=1920');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    margin-top: -40px !important; /* Pull up to eliminate white space gap */
    padding-top: 40px !important; /* Add padding to compensate for negative margin */
}

.hero-overlay {
    background: rgba(0, 0, 0, 0.6);
    min-height: 45vh;
}

.search-container {
    max-width: 750px;
    margin: 0 auto;
}

.search-container .form-control,
.search-container .form-select {
    height: 35px;
    border: 1px solid #dee2e6;
}

.search-container .btn {
    height: 35px;
    font-weight: 600;
}

/* Property Navigation */
.property-nav-container {
    max-width: 900px;
    margin: 0 auto;
}

.btn-nav-category {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.3s ease;
    font-weight: 500;
    text-decoration: none;
    display: inline-block;
    backdrop-filter: blur(10px);
    font-size: 0.9rem;
}

.btn-nav-category:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,.15);
    text-decoration: none;
}

.btn-nav-category:focus {
    color: white;
    text-decoration: none;
}

.btn-nav-category:active {
    background: white;
    color: var(--primary-color);
    border-color: white;
}

/* Category Cards */
.category-card {
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid #e9ecef;
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0,0,0,.15) !important;
}

.category-icon i {
    transition: transform 0.3s ease;
}

.category-card:hover .category-icon i {
    transform: scale(1.1);
}

/* Property Cards */
.property-card {
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
}

.property-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,.15) !important;
}

.property-image {
    overflow: hidden;
}

.property-image img {
    transition: transform 0.3s ease;
}

.property-card:hover .property-image img {
    transform: scale(1.05);
}

.property-badge .badge {
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
}

.property-price .badge {
    font-size: 1.1rem;
    padding: 0.5rem 1rem;
    font-weight: 600;
}

.property-features .badge {
    font-size: 0.85rem;
    padding: 0.5rem 0.75rem;
    border: 1px solid #dee2e6;
}

/* Footer */
footer a:hover {
    color: var(--primary-color) !important;
    transition: color 0.3s ease;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding-top: 140px; /* Increased for mobile - contact bar + navbar take more space */
    }
    
    .contact-bar {
        font-size: 0.8rem;
        padding: 8px 0 !important;
    }
    
    .contact-info {
        justify-content: center;
        text-align: center;
    }
    
    .contact-item {
        margin-bottom: 4px !important;
        margin-right: 16px !important;
    }
    
    .tagline {
        text-align: center !important;
        font-size: 0.8rem;
        margin-top: 4px;
    }
    
    .hero-section {
        background-attachment: scroll;
    }
    
    .search-container {
        padding: 1.5rem !important;
    }
    
    .search-container .form-control,
    .search-container .form-select,
    .search-container .btn {
        height: 45px;
    }
    
    .btn-nav-category {
        margin: 2px;
        padding: 10px 18px;
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .contact-bar .row {
        text-align: center;
    }
    
    .contact-bar .col-lg-4 {
        margin-top: 4px;
    }
    
    .contact-item {
        margin-right: 12px !important;
        font-size: 0.75rem;
    }
    
    .tagline {
        font-size: 0.75rem;
    }
    
    .property-nav-container .row {
        justify-content: center !important;
    }
    
    .btn-nav-category {
        margin: 2px;
        padding: 8px 15px;
        font-size: 0.85rem;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.property-card,
.category-card,
.category-mini-card {
    animation: fadeInUp 0.6s ease-out;
}

/* Utility Classes */
.text-primary {
    color: var(--primary-color) !important;
}

.bg-primary {
    background-color: var(--primary-color) !important;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
}

/* Property Details Page Fixes */
.property-details-section {
    padding: 2rem 0;
    min-height: auto;
}

.property-image-container img {
    max-height: 400px;
    width: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.card {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 0.5rem;
}

.card-body {
    padding: 1.5rem;
}

.sticky-top {
    position: sticky;
    top: 120px !important; /* Adjusted for contact bar + navbar */
    z-index: 10;
}

/* Prevent excessive spacing */
section {
    margin: 0;
    padding: 0rem 0;
}

/* Property Details Page - Compact Layout */
.property-details-section {
    padding: 1rem 0;
    min-height: auto;
}

.property-details-section .card {
    border: 1px solid #e9ecef;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 1rem;
}

.property-details-section .card-body {
    padding: 1rem;
}

.property-details-section h1,
.property-details-section .h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.property-details-section h3,
.property-details-section h4 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.property-details-section .btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

.property-details-section .form-control-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

.property-details-section .badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
}

/* Compact sticky sidebar */
.sticky-top {
    position: sticky;
    top: 110px !important;
    z-index: 10;
}

/* Why Choose Us Section - Reduce by 30% text/icons, 35% vertical spacing */
.bg-light {
    padding-top: 0rem !important; /* Reduced by 35% from 3rem (py-5) */
    padding-bottom: 0rem !important;
}

.bg-light h2 {
    font-size: 1.68rem !important; /* Reduced by 30% from ~2.4rem */
}

.bg-light .text-muted {
    font-size: 0.84rem !important; /* Reduced by 30% from 1.2rem */
}

.bg-light h5 {
    font-size: 0.875rem !important; /* Reduced by 30% from 1.25rem */
}

.bg-light p {
    font-size: 0.7rem !important; /* Reduced by 30% from 1rem */
}

.bg-light .feature-icon {
    width: 56px !important; /* Reduced by 30% from 80px */
    height: 56px !important;
    margin-bottom: 1.3rem !important; /* Reduced by 35% from 2rem */
}

/* Home page override - higher specificity */
body.home-page .bg-light .feature-icon {
    width: 50px !important;
    height: 50px !important;
    margin-bottom: 0.75rem !important;
}

.bg-light .feature-icon i {
    font-size: 1.4rem !important; /* Reduced by 30% from 2rem (fa-2x) */
}

.bg-light .mb-5 {
    margin-bottom: 1.95rem !important; /* Reduced by 35% from 3rem */
    margin-top: 2rem;
}

.bg-light .col-lg-3 {
    margin-bottom: 1.3rem !important; /* Reduced by 35% from 2rem */
}

.bg-light .mb-3 {
    margin-bottom: 1.3rem !important; /* Reduced by 35% from 2rem */
}

/* Home page specific optimizations for Why Choose Us section */
body.home-page .bg-light {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}

body.home-page .bg-light h5 {
    font-size: 0.95rem !important;
    margin-bottom: 0.5rem !important;
}

body.home-page .bg-light p {
    font-size: 0.8rem !important;
    margin-bottom: 0.5rem !important;
}

/* Fix for stretched icons - more specific selector */
body.home-page .bg-light .feature-icon,
body.home-page .bg-light div.feature-icon {
    width: 50px !important;
    height: 50px !important;
    margin-bottom: 0.75rem !important;
    min-width: 50px !important;
    min-height: 50px !important;
    max-width: 50px !important;
    max-height: 50px !important;
    border-radius: 50% !important;
    flex-shrink: 0 !important;
    aspect-ratio: 1 / 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}

body.home-page .bg-light .feature-icon i,
body.home-page .bg-light div.feature-icon i {
    font-size: 1.2rem !important;
    line-height: 1 !important;
    display: block !important;
    text-align: center !important;
}

body.home-page .bg-light .mb-3 {
    margin-bottom: 1rem !important;
}

body.home-page .bg-light .text-center {
    padding: 0.5rem 0 !important;
}

/* Ensure CTA section is more prominent */
body.home-page .bg-primary {
    padding-top: 2.5rem !important;
    padding-bottom: 2.5rem !important;
}

/* Hero section optimization for home page */
body.home-page .hero-section {
    margin-bottom: 0 !important;
}

/* Responsive adjustments for home page */
@media (max-width: 768px) {
    body.home-page .hero-overlay {
        min-height: 30vh !important;
    }
    
    body.home-page .row.align-items-center {
        min-height: 30vh !important;
    }
    
    body.home-page .bg-light {
        padding-top: 1.5rem !important;
        padding-bottom: 1rem !important;
    }
    
    body.home-page .bg-light .feature-icon {
        width: 45px !important;
        height: 45px !important;
        margin-bottom: 0.5rem !important;
        min-width: 45px !important;
        min-height: 45px !important;
        max-width: 45px !important;
        max-height: 45px !important;
        border-radius: 50% !important;
        flex-shrink: 0 !important;
        aspect-ratio: 1 / 1 !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    body.home-page .bg-light .feature-icon i {
        font-size: 1rem !important;
        line-height: 1 !important;
    }
    
    body.home-page .bg-light h5 {
        font-size: 0.85rem !important;
    }
    
    body.home-page .bg-light p {
        font-size: 0.75rem !important;
    }
}

/* Override any problematic professional-card styles for property details */
.property-details-section .professional-card {
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    min-height: auto;
}

/* Ensure proper container spacing */
.container {
    max-width: 1200px;
}

/* Fix any layout stretching issues */
.row {
    margin: 0;
}

.col-lg-8, .col-lg-4 {
    padding: 0 15px;
}

/* Property overview icons spacing */
.property-overview .text-center {
    padding: 1rem;
}

.property-overview i {
    margin-bottom: 0.5rem;
}

/* Form styling */
.form-control {
    margin-bottom: 0.5rem;
}

/* Button styling */
.btn {
    margin-bottom: 0.5rem;
}

/* Table styling */
.table td {
    padding: 0.5rem 0;
    border: none;
}

/* Share buttons */
.d-flex.gap-2 button {
    margin: 0;
}

/* Contact Form Field Styling */
.mandatory-field {
    border-left: 4px solid var(--primary-color);
    background-color: #f8f9ff;
}

.mandatory-field:focus {
    border-left: 4px solid var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.15);
}

.optional-field {
    border-left: 4px solid #6c757d;
    background-color: #f8f9fa;
}

.optional-field:focus {
    border-left: 4px solid #6c757d;
    box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.15);
}

/* Form section separator */
.form-section-separator {
    border-top: 2px solid #e9ecef;
    margin: 1.5rem 0;
    padding-top: 1rem;
}

.form-section-separator h6 {
    color: #6c757d;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Professional card styling */
.professional-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.professional-card:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

/* Button professional styling */
.btn-professional {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0b5ed7 100%);
    border: none;
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(13, 110, 253, 0.3);
}

.btn-professional:hover {
    background: linear-gradient(135deg, #0b5ed7 0%, #0a58ca 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(13, 110, 253, 0.4);
    color: white;
}

/* Section title styling */
.section-title {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title h2 {
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 1rem;
}

.section-title p {
    color: #6c757d;
    font-size: 1.1rem;
}

/* Services section background */
.services-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 4rem 0;
}

/* Rolling Text Animation */
.rolling-text-container {
    height: 20px;
    overflow: hidden;
    position: relative;
    font-size: 0.8rem;
    color: #ffc107;
    font-weight: 500;
    width: auto;
    min-width: 150px;
}

.rolling-text {
    animation: roll 6s infinite;
    line-height: 20px;
    display: flex;
    flex-direction: column;
}

.rolling-item {
    display: block;
    height: 20px;
    white-space: nowrap;
    flex-shrink: 0;
}

@keyframes roll {
    0%, 30% { transform: translateY(0); }
    33%, 63% { transform: translateY(-20px); }
    66%, 96% { transform: translateY(-40px); }
    100% { transform: translateY(0); }
}

/* Blog Content Formatting */
.blog-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
    margin-bottom: 2rem;
}

.blog-content > div {
    text-align: justify;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.blog-content p {
    margin-bottom: 1.5rem;
    text-align: justify;
}

.blog-content h1,
.blog-content h2,
.blog-content h3,
.blog-content h4,
.blog-content h5,
.blog-content h6 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
    color: #212529;
}

.blog-content h1 { font-size: 2.5rem; }
.blog-content h2 { font-size: 2rem; }
.blog-content h3 { font-size: 1.75rem; }
.blog-content h4 { font-size: 1.5rem; }
.blog-content h5 { font-size: 1.25rem; }
.blog-content h6 { font-size: 1.1rem; }

.blog-content ul,
.blog-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.blog-content li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.blog-content blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0.375rem;
}

.blog-content strong,
.blog-content b {
    font-weight: 600;
    color: #212529;
}

.blog-content em,
.blog-content i {
    font-style: italic;
}

/* Auto-format numbered lists and bullet points from plain text */
.blog-content div[style*="white-space: pre-line"] {
    font-family: inherit;
}

/* Style for emojis and special characters */
.blog-content div[style*="white-space: pre-line"] {
    font-size: 1.1rem;
    line-height: 1.8;
}

/* Better spacing for paragraphs in pre-line content */
.blog-content div[style*="white-space: pre-line"] {
    margin-bottom: 1rem;
}

/* Enhanced formatting for auto-generated content */
.blog-content h4.text-primary {
    color: var(--primary-color) !important;
    font-weight: 600;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 0.5rem;
    margin-top: 2rem;
    margin-bottom: 1.5rem;
}

.blog-content p {
    margin-bottom: 1.5rem;
    text-align: justify;
    line-height: 1.7;
}

.blog-content strong {
    color: #212529;
    font-weight: 600;
}

/* Special styling for numbered points */
.blog-content p strong:first-child {
    color: var(--primary-color);
    font-size: 1.1em;
}

/* Better spacing for content sections */
.blog-content > div > h4:first-child {
    margin-top: 0;
}

/* Responsive text sizing */
@media (max-width: 768px) {
    .blog-content {
        font-size: 1rem;
    }
    
    .blog-content h4.text-primary {
        font-size: 1.3rem;
    }
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
    .rolling-text-container {
        display: none !important;
    }
    
    .blog-content {
        font-size: 1rem;
    }
    
    .blog-content h1 { font-size: 2rem; }
    .blog-content h2 { font-size: 1.75rem; }
    .blog-content h3 { font-size: 1.5rem; }
    .blog-content h4 { font-size: 1.25rem; }
}
/* Newsletter Subscription Styles */
.newsletter-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0056b3 100%);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(13, 110, 253, 0.3);
}

.newsletter-form .form-control,
.detailed-newsletter-form .form-control,
.detailed-newsletter-form .form-select {
    border: 2px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.newsletter-form .form-control:focus,
.detailed-newsletter-form .form-control:focus,
.detailed-newsletter-form .form-select:focus {
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 0 0.2rem rgba(255, 255, 255, 0.25);
    color: white;
}

.newsletter-form .form-control::placeholder,
.detailed-newsletter-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.detailed-newsletter-form .form-select option {
    background: var(--dark-color);
    color: white;
}

.newsletter-form .btn,
.detailed-newsletter-form .btn {
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.newsletter-form .btn:hover,
.detailed-newsletter-form .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Newsletter Messages */
.newsletter-form .text-success,
.detailed-newsletter-form .text-success {
    color: #d4edda !important;
    background: rgba(212, 237, 218, 0.2);
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid rgba(212, 237, 218, 0.3);
}

.newsletter-form .text-danger,
.detailed-newsletter-form .text-danger {
    color: #f8d7da !important;
    background: rgba(248, 215, 218, 0.2);
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid rgba(248, 215, 218, 0.3);
}

/* Footer Newsletter Quick Subscribe */
.newsletter-form .input-group .btn {
    border-left: none;
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.2);
    color: white;
}

.newsletter-form .input-group .btn:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.3);
}

/* Responsive Newsletter */
@media (max-width: 768px) {
    .newsletter-section {
        margin-top: 2rem;
        padding: 2rem 1rem !important;
    }
    
    .detailed-newsletter-form .row.g-2 {
        gap: 0.5rem;
    }
    
    .detailed-newsletter-form .col-12 {
        margin-bottom: 0.5rem;
    }
}

/* Newsletter Animation */
.newsletter-section {
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading States */
.newsletter-form .btn:disabled,
.detailed-newsletter-form .btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.newsletter-form .btn .fa-spinner,
.detailed-newsletter-form .btn .fa-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Unsubscribe Page Styles */
.unsubscribe-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.unsubscribe-card {
    border: none;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.unsubscribe-card .card-body {
    padding: 3rem;
}

.unsubscribe-icon {
    color: #6c757d;
    margin-bottom: 2rem;
}

.unsubscribe-reasons {
    text-align: left;
    display: inline-block;
}

.unsubscribe-reasons li {
    margin-bottom: 0.5rem;
    padding: 0.25rem 0;
}

/* Admin Subscriber Styles */
.admin-subscriber-card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.admin-subscriber-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.subscriber-status-badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
}

.subscriber-actions .btn {
    margin: 0.125rem;
}

/* Subscriber Timeline */
.subscriber-timeline {
    position: relative;
    padding-left: 2rem;
}

.subscriber-timeline::before {
    content: '';
    position: absolute;
    left: 1rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
}

.timeline-item {
    position: relative;
    margin-bottom: 1.5rem;
}

.timeline-marker {
    position: absolute;
    left: -1.75rem;
    top: 0.25rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 0 0 2px var(--primary-color);
}

.timeline-marker.success {
    background: #28a745;
}

.timeline-marker.warning {
    background: #ffc107;
}

.timeline-marker.danger {
    background: #dc3545;
}

/* Newsletter Success Popup */
.newsletter-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease-out;
}

.newsletter-popup {
    background: white;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideInUp 0.4s ease-out;
}

.newsletter-popup-content {
    padding: 2.5rem;
    text-align: center;
}

.newsletter-popup-icon {
    font-size: 4rem;
    color: #28a745;
    margin-bottom: 1.5rem;
}

.newsletter-popup h3 {
    color: #333;
    margin-bottom: 1rem;
    font-weight: 700;
}

.newsletter-popup p {
    color: #666;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.newsletter-popup ul {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
    text-align: left;
    display: inline-block;
}

.newsletter-popup li {
    color: #555;
    margin-bottom: 0.75rem;
    font-size: 1rem;
}

.newsletter-popup li i {
    color: #28a745;
    margin-right: 0.5rem;
}

.newsletter-popup-close {
    margin-top: 1.5rem;
    padding: 0.75rem 2rem;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.newsletter-popup-close:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(13, 110, 253, 0.3);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Responsive popup */
@media (max-width: 768px) {
    .newsletter-popup-content {
        padding: 2rem 1.5rem;
    }
    
    .newsletter-popup-icon {
        font-size: 3rem;
    }
    
    .newsletter-popup h3 {
        font-size: 1.5rem;
    }
}
.is-invalid {
    border-color: #dc3545 !important;
}

.invalid-feedback {
    display: block;
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.is-valid {
    border-color: #28a745 !important;
}

.valid-feedback {
    display: block;
    color: #28a745;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Custom Navbar Styling */
.navbar-nav .nav-link {
    color: white !important;
    transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover {
    color: #f8f9fa !important;
    transform: translateY(-1px);
}

/* Calculators Dropdown Hover Expand Effect */
.calculators-dropdown {
    transition: all 0.3s ease;
}

.calculators-dropdown:hover {
    transform: scale(1.05);
}

.calculators-dropdown .dropdown-menu {
    border: none;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-radius: 8px;
    margin-top: 8px;
    animation: dropdownFadeIn 0.3s ease;
}

@keyframes dropdownFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.calculators-dropdown .dropdown-item {
    padding: 10px 20px;
    transition: all 0.2s ease;
}

.calculators-dropdown .dropdown-item:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateX(5px);
}

/* Sign Up Button Styling */
.nav-item .btn-primary {
    border-radius: 20px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.nav-item .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(13, 110, 253, 0.4);
}

/* Navbar Brand Styling */
.navbar-brand {
    color: white !important;
}

/* User Dropdown Styling */
.navbar-nav .dropdown-toggle {
    color: white !important;
}

.navbar-nav .dropdown-menu {
    border: none;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-radius: 8px;
    margin-top: 8px;
}

.navbar-nav .dropdown-item {
    transition: all 0.2s ease;
}

.navbar-nav .dropdown-item:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateX(5px);
}

/* Mobile Menu Styling */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background-color: #343a40 !important; /* Dark solid background */
        border-radius: 8px;
        margin-top: 10px;
        padding: 15px;
        box-shadow: 0 4px 15px rgba(0,0,0,0.3);
        border: 1px solid #495057;
    }
    
    .navbar-collapse .nav-link {
        color: white !important;
        padding: 12px 15px;
        border-bottom: 1px solid #495057;
        display: block;
        width: 100%;
    }
    
    .navbar-collapse .nav-link:last-child {
        border-bottom: none;
    }
    
    .navbar-collapse .nav-link:hover {
        background-color: #495057 !important;
        border-radius: 4px;
        color: #f8f9fa !important;
    }
    
    .navbar-collapse .dropdown-menu {
        background-color: #495057 !important;
        border: none;
        margin-left: 15px;
        box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
    }
    
    .navbar-collapse .dropdown-item {
        color: white !important;
        padding: 8px 15px;
    }
    
    .navbar-collapse .dropdown-item:hover {
        background-color: #6c757d !important;
        color: white !important;
    }
    
    .calculators-dropdown:hover {
        transform: none; /* Disable hover effect on mobile */
    }
}

/* Rolling Text Animation (if exists) */
.rolling-text-container {
    overflow: hidden;
    height: 20px;
}

.rolling-text {
    animation: roll 6s infinite;
}

@keyframes roll {
    0%, 33% { transform: translateY(0); }
    34%, 66% { transform: translateY(-20px); }
    67%, 100% { transform: translateY(-40px); }
}

.rolling-item {
    display: block;
    height: 20px;
    line-height: 20px;
    font-size: 0.8rem;
    color: #ffc107;
    font-weight: 400;
}

/* Hero Subscribe Button Widget */
.subscribe-widget {
    z-index: 10;
}

.subscribe-widget .btn {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: var(--primary-color);
    font-weight: 600;
    transition: all 0.3s ease;
    border-radius: 25px;
    padding: 8px 16px;
    font-size: 0.9rem;
}

.subscribe-widget .btn:hover {
    background: rgba(255, 255, 255, 1);
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.subscribe-widget .btn i {
    font-size: 0.85rem;
}

/* Home Newsletter Modal Styling */
#homeSubscribeModal .modal-content {
    border: none;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

#homeSubscribeModal .modal-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 15px 15px 0 0;
}

#homeSubscribeModal .modal-body {
    padding: 2rem;
}

#homeSubscribeModal .form-control {
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 12px 16px;
    transition: all 0.3s ease;
}

#homeSubscribeModal .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.15);
}

#homeSubscribeModal .btn-primary {
    border-radius: 8px;
    padding: 12px 24px;
    font-weight: 600;
    transition: all 0.3s ease;
}

#homeSubscribeModal .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(13, 110, 253, 0.3);
}

/* Responsive adjustments for subscribe widget */
@media (max-width: 768px) {
    .subscribe-widget {
        position: absolute !important;
        bottom: 10px !important;
        right: 10px !important;
        margin: 0 !important;
    }
    
    .subscribe-widget .btn {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    #homeSubscribeModal .modal-body {
        padding: 1.5rem 1rem;
    }
}

@media (max-width: 576px) {
    .subscribe-widget .btn {
        padding: 5px 10px;
        font-size: 0.75rem;
    }
    
    .subscribe-widget .btn i {
        font-size: 0.75rem;
    }
}

/* Critical fix for icon stretching - highest specificity - v2 */
body.home-page section.bg-light .feature-icon,
body.home-page .bg-light div.feature-icon.bg-primary,
.home-page .bg-light .feature-icon {
    width: 50px !important;
    height: 50px !important;
    border-radius: 50% !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
    flex-grow: 0 !important;
    min-width: 50px !important;
    min-height: 50px !important;
    max-width: 50px !important;
    max-height: 50px !important;
    aspect-ratio: 1 !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}

/* Force circular shape with transform if needed - v2 */
body.home-page section.bg-light .feature-icon.bg-primary,
body.home-page .bg-light div.feature-icon.bg-primary,
.home-page .bg-light .feature-icon.bg-primary {
    transform: scale(1, 1) !important;
    border-radius: 50% !important;
}
/* Final override for home page icons - highest priority */
body.home-page section.py-4.bg-light .feature-icon {
    width: 50px !important;
    height: 50px !important;
    border-radius: 50% !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}