/* Base Styles */
:root {
    --primary: #cb151c;
    --primary-dark: #a11216;
    --secondary: #6c757d;
    --light: #f8f9fa;
    --dark: #212529;
    --success: #198754;
    --danger: #dc3545;
    --warning: #ffc107;
    --info: #0dcaf0;
    --body-bg: #ffffff;
    --text-color: #212529;
    --text-muted: #6c757d;
    --border-color: #dee2e6;
    --border-radius: 0.375rem;
    --box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.05);
    --transition: all 0.3s ease-in-out;
}

/* Typography */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--body-bg);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

h1, .h1 { font-size: 2.5rem; }
h2, .h2 { font-size: 2rem; }
h3, .h3 { font-size: 1.75rem; }
h4, .h4 { font-size: 1.5rem; }
h5, .h5 { font-size: 1.25rem; }
h6, .h6 { font-size: 1rem; }

p {
    margin-bottom: 1rem;
}

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

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

/* Buttons */
.btn {
    font-weight: 500;
    padding: 0.5rem 1.5rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    text-transform: uppercase;
    font-size: 0.875rem;
    letter-spacing: 0.5px;
}

.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover, .btn-primary:focus {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.2);
}

.btn-outline-primary {
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline-primary:hover {
    background-color: var(--primary);
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.2);
}

/* Forms */
.form-control, .form-select {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    transition: var(--transition);
    height: auto;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Cards */
.card {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.1);
}

.card-img-top {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.card-body {
    padding: 1.5rem;
}

.card-title {
    margin-bottom: 0.75rem;
    font-weight: 600;
}

/* Navigation */
.navbar {
    padding: 1rem 0;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
}

/* Ensure header/nav appear above hero overlay */
header.sticky-top { z-index: 1030; }
.navbar { z-index: 1031; }

/* Fix: Tailwind `.collapse` utility sets `visibility: collapse` which hides Bootstrap's navbar */
.collapse { visibility: visible !important; }

.navbar-brand {
    font-weight: 700;
    font-size: 1.75rem;
    color: var(--primary);
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem;
    color: var(--dark);
    position: relative;
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 1rem;
    background-color: var(--primary);
    transition: var(--transition);
}

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
    width: calc(100% - 2rem);
}

/* Hero Section */
.hero-split {
    display: flex;
    flex-wrap: wrap;
}
.hero-split .hero-left {
    background: var(--primary);
    color: #fff;
    flex: 1 1 40%;
    padding: 4rem 2rem;
    position: relative;
}
.hero-split .hero-left h1 {
    font-size: 3rem;
    line-height: 1.2;
    color: #fff;
}
.hero-split .hero-right {
    flex: 1 1 60%;
    position: relative;
    overflow: hidden;
}
.hero-split .hero-right img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero {
    padding: 8rem 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    color: white;
    text-align: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1;
}

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

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* Section Styling */
section {
    padding: 0rem 0;
    position: relative;
}

.section-title {
    position: relative;
    display: inline-block;
    margin-bottom: 3rem;
    text-align: center;
    width: 100%;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--primary);
    margin: 15px auto 0;
}

/* Feature Grid */
.feature-item {
    text-align: center;
    padding: 2rem 1.5rem;
    border-radius: var(--border-radius);
    background: #fff;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    height: 100%;
}
.feature-item i {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
}
.feature-item:hover {
    transform: translateY(-8px);
}

/* Features */
.feature-box {
    text-align: center;
    padding: 2rem 1.5rem;
    border-radius: var(--border-radius);
    background: white;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    height: 100%;
}

.feature-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    display: inline-block;
}

/* Testimonials */
.testimonial-card {
    padding: 2rem;
    border-radius: var(--border-radius);
    background: white;
    box-shadow: var(--box-shadow);
    position: relative;
    margin: 1rem 0;
}

.testimonial-text {
    font-style: italic;
    margin-bottom: 1.5rem;
    position: relative;
    padding-left: 1.5rem;
}

.testimonial-text::before {
    content: '\201C';
    font-size: 4rem;
    color: var(--primary);
    opacity: 0.2;
    position: absolute;
    left: -1rem;
    top: -1.5rem;
    font-family: Georgia, serif;
}

.testimonial-author {
    display: flex;
    align-items: center;
}

.testimonial-author img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    margin-right: 1rem;
    object-fit: cover;
}

.testimonial-rating {
    color: var(--warning);
    margin-bottom: 0.5rem;
}

/* Stats Bar */
.stats-bar {
    background: var(--primary);
    color: #fff;
    padding: 3rem 0;
}
.stats-bar .stat {
    text-align: center;
}
.stats-bar .stat h3 {
    font-size: 2rem;
    margin-bottom: .25rem;
}
.stats-bar .stat p {
    margin: 0;
    opacity: .8;
}

/* Footer */
footer {
    background-color: var(--dark);
    color: white;
    padding: 4rem 0 2rem;
}

.footer-widget h4 {
    color: white;
    margin-bottom: 1.5rem;
    font-weight: 600;
    position: relative;
    padding-bottom: 1rem;
}

.footer-widget h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background: var(--primary);
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

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

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary);
    padding-left: 5px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    margin-right: 10px;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    margin-top: 3rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
}

/* Responsive Adjustments */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: white;
        padding: 1rem;
        margin-top: 1rem;
        border-radius: var(--border-radius);
        box-shadow: var(--box-shadow);
    }
    
    .navbar-nav .nav-link::after {
        display: none;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    section {
        padding: 3rem 0;
    }
}

@media (max-width: 767.98px) {
    .hero {
        padding: 6rem 0;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fadeInUp {
    animation: fadeInUp 0.6s ease-out forwards;
}

/* Utilities */
.bg-light {
    background-color: #f8f9fa !important;
}

.text-primary {
    color: var(--primary) !important;
}

.bg-primary {
    background-color: var(--primary) !important;
}

.rounded {
    border-radius: var(--border-radius) !important;
}

.shadow-sm {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
}

.mb-6 {
    margin-bottom: 4rem !important;
}

.mt-6 {
    margin-top: 4rem !important;
}

.py-6 {
    padding-top: 4rem !important;
    padding-bottom: 4rem !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}
