/* style.css */
:root {
    --primary: #026246;
    --primary-dark: #014632;
    --secondary: #333;
    --bg-light: #f0f5f9;
    --white: #ffffff;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --font-main: 'Montserrat', sans-serif;
}

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

body {
    font-family: var(--font-main);
    color: var(--secondary);
    background-color: var(--bg-light);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* =========================
   Navigation / Header
   ========================= */
header {
    background: var(--white);
    box-shadow: var(--shadow);
    padding: 0.8rem 2rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 70px;
}

/* Logo Styling */
.logo {
    display: flex;
    align-items: center;
}

.logo img {
    max-height: 60px; 
    width: auto;
    display: block;
    transition: transform 0.3s ease;
}

.logo a:hover img {
    transform: scale(1.02);
}

/* Desktop Navigation */
nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    align-items: center;
    margin: 0;
}

nav a {
    text-decoration: none;
    color: var(--secondary);
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s;
    position: relative;
}

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

nav a:not(.btn):hover {
    color: var(--primary);
}

nav a:not(.btn):hover::after {
    width: 100%;
}

/* Hamburger Menu Icon */
.hamburger {
    display: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: var(--secondary);
    padding: 5px;
    transition: color 0.3s;
}

.hamburger:hover {
    color: var(--primary);
}

/* Layout Utilities */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem;
}

.container-narrow {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
}

.text-center { text-align: center; }
.highlight { color: var(--primary); font-weight: bold; }

.section-spacer {
    margin-top: 3rem;
    margin-bottom: 3rem;
}

/* Hero Section */
.hero {
    /* Default fallback gradient */
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    padding: 6rem 2rem; /* Increased padding for better image display */
    text-align: center;
    border-radius: 0 0 20px 20px;
    
    /* Properties to handle background images */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}

.hero h1 { font-size: 2.5rem; margin-bottom: 1rem; text-shadow: 0 2px 4px rgba(0,0,0,0.3); }
.hero p { max-width: 700px; margin: 0 auto 2rem auto; font-size: 1.1rem; text-shadow: 0 1px 2px rgba(0,0,0,0.3); }

/* Split Section (Image + Text) */
.split-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    margin: 4rem 0;
}

.split-content h2 {
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.split-image img {
    width: 100%;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
    object-fit: cover;
}

@media (max-width: 768px) {
    .split-section {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    .split-image {
        order: -1; /* Puts image on top on mobile */
    }
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 25px;
    background-color: var(--primary);
    color: var(--white);
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s ease;
    border: 2px solid var(--primary);
    font-weight: bold;
    cursor: pointer;
}

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

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

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

.btn-full-width {
    width: 100%;
    margin-top: 1rem;
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.card {
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    border-top: 5px solid var(--primary);
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
}

.card:hover { transform: translateY(-5px); }
.card h3 { color: var(--primary); margin-bottom: 1rem; }
.card ul { list-style: none; margin: 1rem 0; flex-grow: 1; }
.card ul li::before { content: "✓"; color: var(--primary); margin-right: 8px; }

/* Portfolio Layout */
.portfolio-split {
    display: flex;
    align-items: center;
    gap: 3rem;
    background: var(--white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: var(--shadow);
}

.device-mockup {
    flex: 1;
    border: 12px solid #333;
    border-radius: 30px;
    overflow: hidden;
    height: 600px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.device-mockup iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.portfolio-text { flex: 1; }

/* Form Styling */
.form-card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    border-top: 5px solid var(--primary);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

@media (max-width: 600px) {
    .form-row { grid-template-columns: 1fr; }
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--secondary);
}

label span { color: #d9534f; } /* Red asterisk */

input[type="text"],
input[type="email"],
input[type="tel"],
textarea,
select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: var(--font-main);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
    background-color: #fdfdfd;
}

/* Custom File Input Styling */
input[type="file"] {
    padding: 8px;
    background: #f9f9f9;
}

input[type="file"]::file-selector-button {
    margin-right: 15px;
    border: none;
    background: var(--primary);
    padding: 8px 16px;
    border-radius: 4px;
    color: var(--white);
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
}

input[type="file"]::file-selector-button:hover {
    background: var(--primary-dark);
}

/* Custom Select Dropdown Arrow */
select:not([multiple]) {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23026246' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
}

select[multiple] {
    height: 120px; /* Replaces inline style */
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--primary);
    background-color: var(--white);
    box-shadow: 0 0 0 3px rgba(2, 98, 70, 0.1);
}

textarea {
    resize: vertical; /* Only allow vertical resizing */
    min-height: 120px;
}

/* Helper for hidden inputs that become visible */
.conditional-input {
    margin-top: 10px;
    display: none;
}

.form-divider {
    border: 0;
    height: 1px;
    background: #eee;
    margin: 2rem 0;
}

small {
    display: block;
    margin-top: 5px;
    color: #888;
    font-size: 0.85rem;
}

/* Footer Styles */
.main-footer {
    background-color: var(--secondary);
    color: var(--white);
    padding: 2rem 0;
    margin-top: auto;
    border-top: 4px solid var(--primary);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 0 1rem;
}

/* Social Icons */
.social-links a {
    display: inline-block;
    color: var(--white);
    transition: all 0.3s ease;
}

.social-links svg {
    fill: currentColor;
    width: 32px;
    height: 32px;
}

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

.copyright {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* --- Pricing Card Specifics --- */

.pricing-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    border-top: 5px solid var(--primary);
}

/* Highlight the popular card */
.pricing-card.popular {
    border-color: #ffd700;
    transform: scale(1.02);
    box-shadow: 0 8px 15px rgba(0,0,0,0.15);
    z-index: 1;
}

.badge {
    position: absolute;
    top: -15px;
    right: 20px;
    background-color: #ffd700;
    color: #333;
    padding: 5px 15px;
    font-size: 0.8rem;
    font-weight: bold;
    border-radius: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    text-transform: uppercase;
}

.card-header {
    text-align: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #eee;
}

.price {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
    margin: 10px 0;
}

.sub-price {
    font-size: 0.9rem;
    color: #666;
}

.card-body ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.card-body li {
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
}

/* Maintenance Section Styling */
.maintenance-block {
    background-color: #f9f9f9;
    padding: 1rem;
    border-radius: 8px;
    margin-top: 1.5rem;
    border-left: 3px solid var(--primary);
}

.maintenance-block strong {
    display: block;
    color: var(--primary-dark);
    margin-bottom: 5px;
}

.maintenance-block small {
    display: block;
    line-height: 1.4;
    color: #555;
}

.card-footer {
    margin-top: 2rem;
    text-align: center;
}

.card-footer .btn {
    width: 100%;
}

/* Responsive adjustments for pricing */
@media (max-width: 768px) {
    .pricing-card.popular {
        transform: none;
        margin: 1rem 0;
    }
}

/* Desktop layout */
@media (min-width: 768px) {
    .footer-content {
        flex-direction: row;
        justify-content: space-between;
    }
    
    .social-links {
        order: 2;
    }
    
    .copyright {
        order: 1;
    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    header {
        padding: 0.8rem 1.5rem;
    }

    .logo img {
        max-height: 50px;
    }

    .hamburger { 
        display: block;
    }
    
    nav {
        position: absolute;
        top: 100%; 
        left: 0;
        width: 100%;
        background: var(--white);
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
        border-top: 1px solid #eee;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease-in-out, padding 0.4s ease-in-out;
        display: block;
    }

    nav.show { 
        max-height: 500px;
    }

    nav ul {
        flex-direction: column;
        width: 100%;
        text-align: center;
        gap: 0;
        padding: 1rem 0;
    }

    nav ul li {
        width: 100%;
    }

    nav a {
        display: block;
        padding: 1rem;
        font-size: 1.1rem;
        border-bottom: 1px solid #f5f5f5;
    }

    nav a:not(.btn)::after {
        display: none;
    }

    nav li:last-child {
        padding: 1.5rem 1rem;
        border-bottom: none;
    }
    
    nav a.btn {
        display: inline-block;
        width: 80%;
    }

    .portfolio-split { flex-direction: column; }
    .device-mockup { width: 100%; height: 400px; }
}