/* ---------- GLOBAL ---------- */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    color: #333;
    background-color: #fff;
    line-height: 1.6;
}

/* ---------- HEADER ---------- */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 40px;
    background-color: #003366;
    color: white;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.logo {
    font-size: 1.4rem;
    font-weight: 700;
}

nav ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 20px;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

nav ul li a:hover {
    color: #008000;
}

/* ---------- HERO / ABOUT ---------- */
#about {
    text-align: center;
    padding: 60px 20px;
    background-color: #f8f8f8;
}

#about h1, #about h2 {
    color: #003366;
    margin-bottom: 15px;
}

#about p {
    color: #333;
    margin-bottom: 10px;
}

.about-logo img {
    width: 180px;
    margin-bottom: 20px;
}

/* ---------- SERVICES ---------- */
#services, #Safety {
    padding: 60px 20px;
    background-color: #fff;
}

.services-grid, .safety-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.service {
    background-color: white;
    border-radius: 12px;
    text-align: center;
    padding: 15px;
    border: 2px solid #008000;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service:hover {
    transform: translateY(-6px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
}

.service img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
}

.service p {
    font-weight: 600;
    color: #003366;
}

#contact {
    display: flex;
    flex-direction: column; /* stack items vertically */
    align-items: center;
    text-align: center;
    padding: 40px 20px;
    background-color: #f0f0f0;
    gap: 20px; /* spacing between address and showcase */
}

.address, .showcase {
    width: 100%;
    max-width: 500px;
}

.address h2 {
    margin-bottom: 15px;
    color: #008000;
}

.showcase {
    font-weight: bold;
    color: #003366;
    font-size: 1.2em;
}

.address {
    max-width: 400px;
}

.address h2 {
    color: #008000;
}

.address h3 {
    color: #003366;
    margin-bottom: 5px;
}

.showcase {
    font-weight: bold;
    color: #008000;
    margin-top: 20px;
}

/* ---------- CONTACT FORM ---------- */
#contact-form {
    display: flex;
    justify-content: center;
    padding: 60px 20px;
    background-color: #fafafa;
}

.contactForm {
    width: 100%;
    max-width: 600px;
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}

.contactForm h2 {
    text-align: center;
    color: #008000;
    margin-bottom: 25px;
}

.contactForm form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contactForm input,
.contactForm select,
.contactForm textarea {
    padding: 12px 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 16px;
    width: 100%;
    box-sizing: border-box;
}

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

#submit {
    background-color: #008000;
    color: white;
    padding: 14px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#submit:hover {
    background-color: #006400;
}

/* ---------- FOOTER ---------- */
footer {
    background-color: #003366;
    color: white;
    text-align: center;
    padding: 25px;
    font-size: 0.9em;
    line-height: 1.6;
}

footer p {
    margin: 5px 0;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        text-align: center;
        padding: 15px;
    }

    nav ul {
        flex-direction: column;
        gap: 10px;
        margin-top: 10px;
    }

    #contact {
        flex-direction: column;
        gap: 20px;
    }
}

/* Chatbot container */
#chatbot {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 300px;
    max-height: 400px;
    background: white;
    border: 2px solid #003366;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    display: none;
    flex-direction: column;
    font-family: 'Poppins', sans-serif;
    overflow: hidden;
    z-index: 1000;
  }
  
  /* Header */
  #chat-header {
    background: #003366;
    color: white;
    padding: 10px;
    text-align: center;
    font-weight: bold;
  }
  
  /* Body */
  #chat-body {
    flex: 1;
    padding: 10px;
    overflow-y: auto;
    font-size: 14px;
  }
  
  /* Input */
  #chat-input {
    display: flex;
    border-top: 1px solid #ddd;
  }
  #chat-input input {
    flex: 1;
    border: none;
    padding: 10px;
    font-size: 14px;
  }
  #chat-input button {
    background: #008000;
    border: none;
    color: white;
    padding: 10px 15px;
    cursor: pointer;
  }
  #chat-input button:hover {
    background: #006400;
  }
  
  /* Floating button */
  #chat-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #008000;
    color: white;
    border: none;
    border-radius: 50%;
    width: 55px;
    height: 55px;
    font-size: 22px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    z-index: 1000;
  }
  
  /* Fade-in effect */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeIn 1s ease-out forwards;
  }
  
  @keyframes fadeIn {
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .service {
    background-color: white;
    border-radius: 12px;
    text-align: center;
    padding: 15px;
    border: 2px solid #008000;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.service:hover {
    transform: translateY(-8px) scale(1.03);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s ease;
  }
  
  .reveal.active {
    opacity: 1;
    transform: translateY(0);
  }
  
  #chat-toggle {
    animation: bounce 2s infinite;
  }

  /* Chatbot container (hidden by default) */
#chatbot {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 300px;
    height: 400px;
    background: #fff;
    border: 2px solid #008000;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    opacity: 0;
    transform: scale(0.9);
    pointer-events: none;
    transition: all 0.3s ease-in-out;
    z-index: 1000;
  }
  
  /* Show state */
  #chatbot.show {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
  }
  
  /* Chat header */
  #chatbot-header {
    background: #008000;
    color: white;
    padding: 10px;
    text-align: center;
    font-weight: bold;
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
  }
  
  /* Chat body */
  #chat-body {
    flex: 1;
    padding: 10px;
    overflow-y: auto;
    font-size: 14px;
  }
  
  /* Chat input */
  #chat-input {
    display: flex;
    border-top: 1px solid #ccc;
  }
  #chat-input input {
    flex: 1;
    border: none;
    padding: 8px;
    outline: none;
  }
  #chat-input button {
    background: #008000;
    color: white;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
  }
  #chat-input button:hover {
    background: #006400;
  }
  
  
  @keyframes bounce {
    0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
    40% {transform: translateY(-10px);}
    60% {transform: translateY(-5px);}
  }

  .typing {
    overflow: hidden;
    border-right: 3px solid #008000;
    white-space: nowrap;
    width: 0;
    animation: typing 4s steps(30, end) forwards, blink 0.7s step-end infinite;
  }
  
  @keyframes typing {
    from { width: 0 }
    to { width: 100% }
  }
  
  @keyframes blink {
    50% { border-color: transparent }
  }
  
  /* Default (desktop) */
.menu-toggle {
    display: none;
    font-size: 28px;
    cursor: pointer;
    color: white;
  }
  
  /* Mobile styles */
  @media (max-width: 768px) {
    nav ul {
      display: none; /* hide nav by default */
      flex-direction: column;
      width: 100%;
      background: #003366;
      text-align: center;
      padding: 10px 0;
    }
  
    nav ul li {
      margin: 10px 0;
    }
  
    .menu-toggle {
      display: block;
    }
  
    nav ul.active {
      display: flex; /* show when active */
    }
  }
  