/* ---------- Global Styles ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", Arial, sans-serif;
}

body {
  background-color: #f5f6fa; /* Light gray background */
  color: #333;
  margin: 0; 
  overflow-x: hidden; /* Prevents horizontal scroll bar */
}

/* ---------------------------------------------------- */
/* ---------- STICKY HEADER CONTAINER & SCROLL ---------- */
/* ---------------------------------------------------- */

#header-placeholder {
    margin-top: 0 !important; 
    padding-top: 0 !important;
    position: sticky; 
    top: 0;
    z-index: 100; 
}

/* Header Styles */
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  background-color: #0a2540;
  color: #fff;
  transition: padding 0.3s ease-in-out; 
  z-index: 100;
}

/* Shrinking Header Effect */
header.scrolled {
  padding: 0.05rem 2rem; 
}

.logo {
  display: flex;
  align-items: center;
  font-weight: bold;
  font-size: clamp(0.8rem, 4vw, 1.2rem); 
  white-space: nowrap;
}

.logo img {
  transition: all 0.3s ease-in-out;
}

header.scrolled .logo img {
  width: 60px; 
  height: 40px; 
}

/* ---------------------------------------------------- */
/* ---------- DESKTOP MENU (HOVER LOGIC) ---------- */
/* ---------------------------------------------------- */

nav#navbar {
  flex: 2;
  display: flex;
  justify-content: right;
}

nav ul.menu {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  align-items: right;
}

nav a {
  text-decoration: none;
  color: #fff;
  font-weight: 500;
  transition: color 0.3s ease;
}

nav a:hover {
  color: #00b4d8;
}

.dropdown {
  position: relative;
}

/* Desktop Submenu */
.submenu {
  display: none; 
  position: absolute;
  top: 100%;
  left: 50%; 
  transform: translateX(-50%); 
  background-color: #0a2540;
  border-radius: 0.5rem;
  overflow: hidden;
  min-width: 160px;
  z-index: 101;
}

.submenu li {
  padding: 0.5rem 1rem;
}

/* KEY: SHOW SUBMENU ON PARENT LI HOVER */
.dropdown:hover .submenu {
  display: block;
}

/* ---------- Hero, Testimonials, Footer (Standard Styles) ---------- */

.hero {
  position: relative;
  height: 75vh;
  background: url('images/IMG_0343.jpeg') center/cover no-repeat; 
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  color: #fff;
}

.overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.55);
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.hero p {
  font-size: 1.2rem;
}

.testimonials {
  padding: 4rem 2rem;
  text-align: center;
  background-color: #fff;
}

.testimonials h2 {
  margin-bottom: 2rem;
  font-size: 2rem;
  color: #0a2540;
}

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.testimonial {
  background-color: #f1f3f6;
  padding: 1.5rem;
  border-radius: 1rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.testimonial p {
  font-style: italic;
  margin-bottom: 1rem;
}

footer {
  background-color: #0a2540;
  color: #fff;
  text-align: center;
  padding: 1rem;
}

footer a {
  color: #00b4d8;
  text-decoration: none;
}

/* ---------------------------------------------------- */
/* ---------- MOBILE MENU SPECIFIC STYLES  ---------- */
/* ---------------------------------------------------- */

.mobile-navbar {
    display: none; 
}

@media (max-width: 767px) {
    /* Mobile-specific logo and hero text sizes */
    .logo {
        white-space: nowrap !important; 
        font-size: clamp(0.75rem, 3.5vw, 1.1rem); 
    }
    .hero h1 {
        font-size: 1.8rem;
    }
    
    /* Hide Desktop Nav */
    header nav#navbar {
        display: none;
    }

    /* Show Mobile Nav Container and Toggle Button */
    .mobile-navbar {
        display: block;
        flex-grow: 0;
        position: relative;
        z-index: 102; 
        padding: 0; 
        background-color: #0a2540; 
        width: 100%;
    }
    
    .mobile-navbar .menu-toggle {
        font-size: 1.5rem;
        cursor: pointer;
        user-select: none;
        padding: 1rem 2rem;
        width: 100%; 
        color: #fff;
        display: flex;
        justify-content: flex-end;
        align-items: center;
        gap: 0.5rem;
        transition: padding 0.3s ease-in-out; 
    }
    
    /* Mobile Shrinking Header Rule */
    header.scrolled .mobile-navbar .menu-toggle {
        padding: 0.5rem 2rem; 
    }
    
    /* Mobile Menu Container (Slide-out panel) */
    .mobile-menu {
        list-style: none !important;
        padding: 0 !important;
        margin: 0 !important;
        background-color: #0a2540;
        
        position: fixed;
        top: 0;
        right: 0; 
        height: 100vh; 
        width: 70%; 
        max-width: 300px;
        
        z-index: 99; 
        box-shadow: -5px 0 10px rgba(0, 0, 0, 0.4);
        
        display: flex; 
        flex-direction: column;
        
        transform: translateX(100%); /* Start off-screen */
        transition: transform 0.3s ease-in-out; 
    }

    /* Activation State: Slide the menu into view */
    .mobile-menu.active {
        transform: translateX(0); 
    }

    /* Menu Item and Link Styling */
    .mobile-menu li {
        border-top: 1px solid #1a3a5a;
        padding: 0 !important;
        margin: 0 !important;
    }

    .mobile-menu .has-submenu {
        overflow: hidden !important; 
        position: relative; 
    }

    .mobile-menu a {
        color: #fff;
        text-decoration: none;
        display: block;
        padding: 12px 2rem 12px 2.0rem; 
        transition: background-color 0.3s ease;
    }

    .mobile-menu a:hover {
        background-color: #1a3a5a;
    }

    /* Mobile Submenu Hiding/Styling */
    .mobile-menu li > .Mobile_submenu {
        display: block; 
        position: static; 
        list-style: none !important;
        
        padding: 0 0 0 2.0rem !important; /* Indentation */
        margin: 0 !important;
        
        background: #1a3a5a;
        transition: max-height 0.3s ease-in-out; 
        overflow: hidden;
        max-height: 0; /* Hidden by default */
    }
    
    /* Reveal the submenu when JavaScript adds the .active class */
    .mobile-menu li > .Mobile_submenu.active {
        max-height: 1000px !important; 
    }

    
    .Mobile_submenu li {
        list-style-type: none !important;
        margin: 0 !important;
        padding: 0 !important;
        border-top: none; 
    }
    
    .Mobile_submenu li a {
        padding: 8px 2rem 8px 0 !important; 
        font-size: 1rem;
        color: #fff; 
        display: block;
    }
    
    .mobile-menu .has-submenu > a {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .mobile-menu .has-submenu > a::after {
        content: " ▾";
        transition: transform 0.3s ease;
    }

    /* Rotate caret when the submenu is open */
    .mobile-menu .has-submenu.open > a::after {
        transform: rotate(180deg);
    }
}


/* -------------------- Desktop Layout (768px and up) -------------------- */
@media (min-width: 768px) {
  header nav#navbar {
    display: flex !important;
  }

  .mobile-navbar {
    display: none !important;
  }
}

/* ---------------------------------------------------- */
/* ---------- AUTO PAGE STYLES (3 Rows, 2 Cols) ---------- */
/* ---------------------------------------------------- */

/* 1. Auto Page Hero Image */
.auto-hero {
    height: 50vh; 
    background: url('images/IMG_0319.jpeg') center/cover no-repeat;
}

.auto-hero .hero-content h1 {
    font-size: 2rem; 
}

/* 2. Grid Container for 3 Rows, 2 Columns */
.auto-content-grid {
    display: grid;
    /* Forces the 2-column layout */
    grid-template-columns: 1fr 1fr; 
    gap: 2rem;
    padding: 4rem 3rem; 
    max-width: 1200px; 
    margin: 0 auto; 
    /* This rule ensures the background color is correctly applied */
    background-color: #fff; 
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.05);
}

/* 3. Style for Grid Items - MATCHING TESTIMONIALS */
.auto-content-grid .grid-item {
    /* Use the parent selector to increase specificity */
    background-color: #f1f3f6; 
    padding: 1.5rem;
    border-radius: 1rem; 
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); 
    text-align: left; 
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Optional: Subtle Hover effect for desktop */
.auto-content-grid .grid-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.auto-content-grid .grid-item h2 {
    color: #0a2540;
    margin-bottom: 0.75rem; 
    font-size: 1.4rem; 
    border-bottom: 2px solid #00b4d8; 
    padding-bottom: 0.25rem;
}

.auto-content-grid .grid-item p {
    line-height: 1.6;
    color: #555;
}

/* 4. Mobile Responsiveness (Stack columns) */
@media (max-width: 767px) {
    .auto-hero {
        height: 40vh;
    }
    
    .auto-content-grid {
        grid-template-columns: 1fr; /* 1 column for mobile */
        gap: 1.5rem;
        padding: 2rem 1rem; 
    }
}

/* ---------------------------------------------------- */
/* ---------- IT PAGE HERO STYLES ---------- */
/* ---------------------------------------------------- */
.it-hero {
    /* IT Hero image. Replace with your actual image path (e.g., a server, keyboard, or circuit board) */
    background: url('images/IMG_0336.jpeg') center/cover no-repeat;
}
/* ---------------------------------------------------- */
/* ---------- GENERAL REPAIRS PAGE HERO STYLES ---------- */
/* ---------------------------------------------------- */
.other-hero {
    /* General Repair Hero image. Replace with your actual image path (e.g., tools, a workshop, or various repair tasks) */
    background: url('images/IMG_0386.jpeg') center/cover no-repeat;
}
/* ---------------------------------------------------- */
/* ---------- SERVICES INDEX PAGE STYLES ---------- */
/* ---------------------------------------------------- */

/* Services Hero Image */
.services-hero {
    /* Services Hero image. Replace with a relevant image (e.g., a toolbox, mixed tools) */
    background: url('images/IMG_0336.jpeg') center/cover no-repeat;
}

/* 3-Item Grid Layout */
.services-index-grid {
    /* Use 3 columns for desktop (max-width of 1200px) */
    grid-template-columns: repeat(3, 1fr) !important; 
    gap: 2rem;
    padding: 4rem 3rem;
}

/* Style the service items as clickable links */
.services-index-grid .services-card {
    /* Ensure the clickable area fills the card */
    display: block; 
    text-decoration: none;
    color: inherit;
    height: 100%; /* Ensure all cards are the same height */
}

.services-index-grid .services-card h2 {
    /* Ensure link text contrast on hover */
    transition: color 0.3s ease; 
}

.services-index-grid .services-card:hover h2 {
    color: #00b4d8; /* Highlight title on hover */
}

/* Mobile Adjustments for 3-Item Grid */
@media (max-width: 767px) {
    .services-index-grid {
        /* On mobile, stack them for better readability */
        grid-template-columns: 1fr !important;
        padding: 2rem 1rem; 
    }
}
/* ---------------------------------------------------- */
/* ---------- REVIEW PAGE STYLES ---------- */
/* ---------------------------------------------------- */
.review-hero {
    /* Review Hero image. Use a relevant image (e.g., someone typing, a star rating). */
    background: url('images/review-hero.jpeg') center/cover no-repeat;
}

.review-form-container {
    padding: 4rem 2rem;
    max-width: 600px;
    margin: 0 auto;
    background-color: #fff;
    border-radius: 1rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

#review-form {
    display: flex;
    flex-direction: column;
}

#review-form h2 {
    color: #0a2540;
    margin-bottom: 1.5rem;
    text-align: center;
    border-bottom: 2px solid #00b4d8;
    padding-bottom: 0.5rem;
}

#review-form label {
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    font-weight: bold;
    color: #0a2540;
}

#review-form input[type="text"],
#review-form textarea {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 0.5rem;
    font-size: 1rem;
}

#review-form button[type="submit"] {
    background-color: #00b4d8;
    color: #fff;
    border: none;
    padding: 12px 20px;
    margin-top: 2rem;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 1.1rem;
    transition: background-color 0.3s;
}

#review-form button[type="submit"]:hover {
    background-color: #0a2540;
}

#form-message {
    margin-top: 1rem;
    padding: 0.5rem;
    text-align: center;
    color: green;
}

.hidden {
    display: none;
}
/* ---------------------------------------------------- */
/* ---------- SERVICE REQUEST FORM STYLES ---------- */
/* ---------------------------------------------------- */
.contact-hero {
    /* Contact Hero image. Use a relevant image (e.g., phone, calendar, or a desk with papers). */
    background: url('images/IMG_0343.jpeg') center/cover no-repeat;
}

.request-form-container {
    padding: 4rem 2rem;
    max-width: 700px;
    margin: 0 auto;
    background-color: #fff;
    border-radius: 1rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

#service-request-form {
    display: flex;
    flex-direction: column;
}

#service-request-form h2 {
    color: #0a2540;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    text-align: left;
    border-bottom: 2px solid #00b4d8;
    padding-bottom: 0.3rem;
}

#service-request-form label {
    margin-top: 1rem;
    margin-bottom: 0.3rem;
    font-weight: bold;
    color: #0a2540;
}

#service-request-form input[type="text"],
#service-request-form input[type="tel"],
#service-request-form input[type="email"],
#service-request-form textarea,
#service-request-form select {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 0.5rem;
    font-size: 1rem;
    width: 100%; /* Ensure all form controls are full width */
}

.name-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.name-group label {
    grid-column: span 1; /* Keep labels with their inputs */
    margin-top: 0; /* Adjust spacing */
}

/* Ensure inputs within name-group also have proper top margin alignment */
.name-group input {
    margin-top: 0; 
}

#service-request-form button[type="submit"] {
    background-color: #00b4d8;
    color: #fff;
    border: none;
    padding: 12px 20px;
    margin-top: 2rem;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 1.1rem;
    transition: background-color 0.3s;
}

#service-request-form button[type="submit"]:hover {
    background-color: #0a2540;
}

.callback-note {
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.5rem;
    font-style: italic;
}

hr {
    border: 0;
    height: 1px;
    background-color: #ccc;
    margin: 2rem 0;
}

/* Adjust for small screens */
@media (max-width: 500px) {
    .name-group {
        grid-template-columns: 1fr;
    }
}

/* ---------------------------------------------------- */
/* ---------- SERVICES SECTION STYLES ---------- */
/* ---------------------------------------------------- */

.services {
    padding: 4rem 2rem;
    text-align: center;
    background-color: #f1f3f6; /* Light gray background to separate from hero/testimonials */
}

.services h2 {
    font-size: 2rem;
    color: #0a2540;
    margin-bottom: 0.5rem;
}

.service-intro {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 3rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.service-grid {
    display: grid;
    /* Create three columns on large screens, one column on small screens */
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.service-card {
    display: flex;
    flex-direction: column;
    text-align: left;
    background-color: #fff;
    border-radius: 1rem;
    overflow: hidden; /* Contains the image */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none; /* Remove underline from card link */
    color: #333; /* Default text color */
}

.service-card:hover {
    transform: translateY(-5px); /* Lift card slightly on hover */
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}

.card-image {
    width: 100%;
    height: 200px; /* Fixed height for image consistency */
    object-fit: cover; /* Ensures image covers the area without distortion */
    transition: transform 0.5s ease;
}

.service-card:hover .card-image {
    transform: scale(1.05); /* Slight zoom effect on image hover */
}

.service-card h3 {
    color: #0a2540;
    padding: 1rem 1.5rem 0.5rem 1.5rem;
}

.service-card p {
    padding: 0 1.5rem 1rem 1.5rem;
    font-size: 0.95rem;
    flex-grow: 1; /* Pushes the CTA link to the bottom */
}

.cta-link {
    display: block;
    background-color: #00b4d8;
    color: #fff;
    padding: 1rem 1.5rem;
    font-weight: bold;
    text-align: center;
    transition: background-color 0.3s ease;
}

.service-card:hover .cta-link {
    background-color: #0a2540;
}
/* --- Styling for the Booking Section --- */

#book-service {
    /* Create a distinct visual break */
    background-color: #f8f8f8; /* Light gray background */
    padding: 60px 20px; /* Generous top and bottom padding */
    text-align: center; /* Center all block content inside */
}

#book-service h2 {
    /* Style the main heading */
    color: #333; /* Dark text color */
    margin-bottom: 25px;
    font-size: 2.2em; /* Slightly larger text */
}

#book-service p {
    color: #555;
    max-width: 800px;
    margin: 0 auto 30px auto; /* Center paragraph and add space below */
    line-height: 1.6;
}

#book-service ol {
    /* Style the ordered list for the steps */
    text-align: left; /* Align list items to the left */
    max-width: 600px;
    margin: 20px auto 40px auto; /* Center the list and add space */
    padding-left: 0; /* Remove default padding */
    list-style-position: inside; /* Keep numbers inside the text block */
}

#book-service ol li {
    padding: 10px 0;
    border-bottom: 1px dashed #eee; /* Subtle separator between steps */
    color: #444;
}

#book-service ol li:last-child {
    border-bottom: none; /* No separator on the last item */
}

/* --- Styling for the Button (Call-to-Action) --- */

.btn-primary {
    display: inline-block; /* Allows padding and width to be set */
    background-color: #007bff; /* Primary brand color (Blue) */
    color: white;
    text-decoration: none; /* Remove underline from link */
    padding: 15px 30px;
    border-radius: 5px; /* Rounded corners */
    font-size: 1.1em;
    font-weight: bold;
    letter-spacing: 0.5px;
    transition: background-color 0.3s ease; /* Smooth hover effect */
    margin-top: 20px;
}

.btn-primary:hover {
    background-color: #0056b3; /* Darken on hover for feedback */
}

/* --- Container Utility (if you used the optional div) --- */

.container {
    /* Assuming a standard max-width container for centering content */
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 15px;
}