/* Basic Resets & Typography */
:root {
    --primary-color: #004080; /* Dark Blue */
    --secondary-color: #007bff; /* Brighter Blue */
    --accent-color: #28a745; /* Green for CTAs, etc. */
    --light-bg: #f8f9fa; /* Light Grey Background */
    --text-color: #343a40; /* Dark Grey Text */
    --light-text: #6c757d; /* Lighter Grey Text */
    --white: #ffffff;
    --border-color: #dee2e6;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

h1 { font-size: 2.8em; }
h2 { font-size: 2.2em; }
h3 { font-size: 1.8em; }

p {
    margin-bottom: 15px;
}

a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-color);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 25px;
    font-size: 1em;
    font-weight: 600;
    text-align: center;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    border: 2px solid transparent;
}

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

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

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

.btn-secondary:hover {
    background-color: var(--secondary-color);
    color: var(--white);
}

/* New style for full-width button */
.button-wrapper {
    margin-top: 50px; /* Space above the button */
    text-align: center; /* Center the button container */
}

.btn-full-width {
    display: block;
    width: 100%;
    max-width: 400px; /* Optional: limit max width for aesthetic */
    margin: 0 auto; /* Center button if max-width is applied */
    padding: 15px 25px; /* Slightly larger padding for prominence */
    font-size: 1.1em;
}

/* Header */
.main-header {
    background-color: var(--white);
    padding: 20px 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1); /* Subtle shadow for flat design */
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.main-header .logo img {
    height: 50px; /* Adjust logo size */
}

.main-nav ul {
    list-style: none;
    display: flex;
}

.main-nav ul li {
    margin-left: 30px;
}

.main-nav ul li a {
    color: var(--text-color);
    font-weight: 500;
    font-size: 1.1em;
    padding: 5px 0;
    position: relative;
}

.main-nav ul li a.active,
.main-nav ul li a:hover {
    color: var(--primary-color);
}

.main-nav ul li a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.main-nav ul li a.active::after,
.main-nav ul li a:hover::after {
    width: 100%;
}


/* Hero Section */
.hero-section {
    background-size: cover;
    background-position: center;
    color: var(--white);
    text-align: center;
    padding: 100px 0;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 450px;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4); /* Dark overlay */
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.hero-content h1 {
    color: var(--white);
    font-size: 3.5em;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.4em;
    margin-bottom: 30px;
    color: rgba(255, 255, 255, 0.9);
}

.hero-content .btn {
    font-size: 1.1em;
    padding: 15px 35px;
    background-color: var(--accent-color);
    border-color: var(--accent-color);
}

.hero-content .btn:hover {
    background-color: #218838; /* Darker green */
    border-color: #218838;
}

/* Page Specific Hero (e.g., Contact, Loans, About) */
.page-hero-section {
    background-color: var(--light-bg);
    padding: 80px 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.page-hero-section h1 {
    font-size: 3em;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.page-hero-section p {
    font-size: 1.2em;
    color: var(--light-text);
    max-width: 800px;
    margin: 0 auto;
}

/* Add padding between the text and the Learn More button in the hero section */
.page-hero-section p:last-of-type {
    margin-bottom: 30px; /* Adjust as needed */
}


/* Sections */
section {
    padding: 60px 0;
}

.bg-light {
    background-color: var(--light-bg);
}

.intro-section {
    text-align: center;
}

.intro-section h2 {
    margin-bottom: 30px;
}

.intro-section p {
    max-width: 800px;
    margin: 0 auto 15px auto;
    font-size: 1.1em;
    color: var(--light-text);
}

/* General introductory text for sections */
.section-intro {
    max-width: 800px;
    margin: 0 auto 30px auto; /* Center it and add bottom margin */
    font-size: 1.1em;
    color: var(--light-text);
    text-align: center;
}

.services-overview-section,
.product-category-section { /* Added .product-category-section for consistency */
    text-align: center;
}

.services-overview-section h2,
.product-category-section h2 {
    margin-bottom: 40px;
}

.service-cards,
.product-cards { /* Combined for similar grid layouts */
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.card {
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08); /* Reduced shadow for flat design */
    padding: 30px;
    text-align: center;
    transition: box-shadow 0.3s ease; /* Removed transform for flat design */
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1); /* Slightly stronger shadow on hover */
}

.card h3 {
    margin-bottom: 15px;
    color: var(--primary-color);
}

.card p {
    color: var(--light-text);
    margin-bottom: 25px;
}

/* Specific styling for product category intros and lists */
.category-intro {
    max-width: 800px;
    margin: 0 auto 30px auto;
    font-size: 1.1em;
    color: var(--light-text);
    text-align: center;
}

.card ul {
    list-style: none; /* Remove default bullet points */
    padding: 0;
    margin-bottom: 20px;
    text-align: left; /* Align list items to left within card */
    color: var(--text-color);
}

.card ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 10px;
    font-size: 0.95em;
}

.card ul li::before {
    content: '✔'; /* Custom bullet point */
    color: var(--accent-color);
    position: absolute;
    left: 0;
    top: 0;
}

.content-list {
    max-width: 800px;
    margin: 0 auto 30px auto;
    text-align: left;
}

.content-list ul {
    list-style: none;
    padding: 0;
}

.content-list ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 10px;
    font-size: 1.1em;
    color: var(--text-color);
}

.content-list ul li::before {
    content: '•'; /* Simple bullet for general lists */
    color: var(--primary-color);
    position: absolute;
    left: 0;
    top: 0;
    font-size: 1.2em;
    line-height: 1;
}

/* Contact Form Specific Styles */
.contact-form {
    max-width: 600px;
    margin: 0 auto;
    padding: 30px;
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.contact-form-section h2 {
    text-align: center; /* Center the heading text */
}

.contact-form .form-group {
    margin-bottom: 20px;
    text-align: left;
}

.contact-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--primary-color);
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="subject"],
.contact-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1em;
    color: var(--text-color);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25); /* Subtle focus highlight */
    outline: none;
}

.contact-form textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-form .btn-primary {
    width: auto;
    padding: 12px 30px;
}

/* Contact Info Section */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 30px;
    text-align: left;
}

.contact-item {
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    padding: 30px;
    transition: box-shadow 0.3s ease;
}

.contact-item:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.contact-item h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.contact-item p {
    margin-bottom: 10px;
    color: var(--light-text);
}


/* Footer */
.main-footer {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 50px 0 20px 0;
    font-size: 0.95em;
}

.main-footer a {
    color: rgba(255, 255, 255, 0.8);
}

.main-footer a:hover {
    color: var(--white);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-section h3 {
    color: var(--white);
    margin-bottom: 20px;
    font-size: 1.3em;
}

.footer-section p, .footer-section ul {
    margin-bottom: 10px;
    color: rgba(255, 255, 255, 0.7);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 8px;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    color: rgba(255, 255, 255, 0.6);
}

/* Responsive adjustments */
/* Hamburger icon for mobile */
.hamburger {
    display: none; /* Hidden by default on desktop */
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001; /* Above navigation */
}

.hamburger .bar {
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
    transition: all 0.3s ease-in-out;
    border-radius: 2px;
}

/* Hamburger to X animation */
.hamburger.active .bar:nth-child(2) {
    opacity: 0;
}

.hamburger.active .bar:nth-child(1) {
    transform: translateY(11px) rotate(45deg);
    background-color: var(--white); /* Change color when active */
}

.hamburger.active .bar:nth-child(3) {
    transform: translateY(-11px) rotate(-45deg);
    background-color: var(--white); /* Change color when active */
}


@media (max-width: 768px) {
    .main-header .container {
        flex-direction: row; /* Keep logo and hamburger on same row */
        justify-content: space-between;
        align-items: center;
    }

    .hamburger {
        display: flex; /* Show hamburger on mobile */
    }

    .main-nav {
        display: flex; /* Always display flex but control visibility with max-height */
        position: absolute;
        top: 90px; /* Below header */
        left: 0;
        width: 100%;
        background-color: var(--primary-color); /* Full width dropdown */
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
        z-index: 1000;
        flex-direction: column;
        text-align: center;
        padding-bottom: 20px;
        max-height: 0; /* Hidden by default */
        overflow: hidden;
        transition: max-height 0.3s ease-in-out, padding 0.3s ease-in-out;
    }

    .main-nav.active {
        max-height: 500px; /* Sufficient height for menu items */
        padding-bottom: 20px;
    }

    .main-nav ul {
        flex-direction: column;
        width: 100%;
        margin-top: 0;
    }

    .main-nav ul li {
        margin: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    .main-nav ul li:last-child {
        border-bottom: none;
    }

    .main-nav ul li a {
        padding: 15px 20px;
        display: block;
        color: var(--white);
        font-size: 1.2em;
        text-align: center;
    }

    .main-nav ul li a:hover,
    .main-nav ul li a.active {
        background-color: var(--secondary-color);
        color: var(--white);
    }
    .main-nav ul li a::after { /* Remove active line for mobile dropdown */
        display: none;
    }

    .hero-content h1 {
        font-size: 2.5em;
    }
    .hero-content p {
        font-size: 1.1em;
    }

    h1 { font-size: 2.2em; }
    h2 { font-size: 1.8em; }
    h3 { font-size: 1.5em; }

    .page-hero-section h1 {
        font-size: 2.2em;
    }
    .page-hero-section p {
        font-size: 1em;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .footer-section ul {
        padding: 0;
    }

    .content-list {
        padding: 0 15px; /* Add some padding on smaller screens */
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .button-wrapper {
        margin-top: 30px;
    }

    .btn-full-width {
        max-width: 100%; /* Ensure it's full width on mobile */
    }
}