/*
 * Global Stylesheet for VIỆT BẮC MỸ website
 *
 * This stylesheet defines the core layout, typography and colour palette
 * for the entire site. Colours have been chosen to provide strong
 * contrast and readability while reflecting the professionalism of a
 * corporate accounting and marketing firm. Media queries ensure the
 * layout adapts gracefully to different screen sizes. Accessible
 * interactions (such as larger hit‑areas and focus outlines) are
 * provided to support users navigating with keyboards or assistive
 * devices.
 */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css');

/* CSS variables make it easy to adjust the palette and maintain
 * consistent spacing throughout the site. Feel free to tweak these
 * values to adjust the mood of the design.
 */
:root {
  --primary-colour: #004d7a;       /* deep blue for brand elements */
  --secondary-colour: #0073b7;     /* medium blue for highlights */
  --accent-colour: #e6f0f9;        /* very light blue for backgrounds */
  --text-colour: #2d2d2d;          /* dark grey for body text */
  --light-text: #ffffff;           /* white for text on dark backgrounds */
  --max-width: 1200px;             /* maximum content width */
  --border-radius: 6px;            /* subtle rounding for cards */
  --transition-speed: 0.3s;        /* global transition speed */
}

html {
  box-sizing: border-box;
  scroll-behavior: smooth;
}

*, *:before, *:after {
  box-sizing: inherit;
}

body {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  color: var(--text-colour);
  background-color: var(--accent-colour);
  line-height: 1.6;
}

a {
  color: var(--secondary-colour);
  text-decoration: none;
  transition: color var(--transition-speed);
}

a:hover,
a:focus {
  color: var(--primary-colour);
  text-decoration: underline;
}

/* Navigation bar */
nav {
  background-color: var(--primary-colour);
  color: var(--light-text);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 1rem;
  gap: 1rem;
}

/* Language switcher styles */
.lang-switch {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin-left: 1rem;
}

.lang-switch a {
  color: var(--light-text);
  font-size: 0.9rem;
  font-weight: 500;
}

.lang-switch a:hover,
.lang-switch a:focus {
  text-decoration: underline;
}

.nav-brand {
  font-weight: 700;
  font-size: 1.4rem;
  letter-spacing: 1px;
  color: var(--light-text);
}

.nav-menu {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin: 0;
  padding: 0;
  margin-left: auto; /* push navigation to the right when language switch is present */
}

.nav-menu li {
  position: relative;
}

.nav-menu li a {
  display: block;
  padding: 0.5rem 0.75rem;
  border-radius: var(--border-radius);
  color: var(--light-text);
  font-weight: 500;
}

.nav-menu li a:hover,
.nav-menu li a:focus {
  background-color: var(--secondary-colour);
}

/* Hero section */
.hero {
  /* Container for hero image and overlay */
  position: relative;
  overflow: hidden;
  color: var(--light-text);
  /* Increase hero height so the full team photo is visible on a range of screen sizes */
  min-height: 75vh;
  display: flex;
  align-items: center;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4); /* dark overlay for readability */
  z-index: 1;
}

.hero-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  width: 100%;
  max-width: var(--max-width);
  padding: 2rem 1rem;
  text-align: center;
}

/* Ensure the hero image fills the hero container and scales appropriately */
.hero-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Align the focus area of the image towards the right so more faces are visible on wider screens */
  object-position: right center;
  z-index: 0;
}

.hero h1 {
  font-size: 2.5rem;
  margin: 0 0 1rem;
  font-weight: 700;
}

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

.btn {
  display: inline-block;
  background-color: var(--secondary-colour);
  color: var(--light-text);
  padding: 0.75rem 1.5rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  transition: background-color var(--transition-speed);
}

.btn:hover,
.btn:focus {
  background-color: var(--primary-colour);
}

/* Section styles */
.section {
  padding: 3rem 1rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.section h2 {
  font-size: 2rem;
  margin-bottom: 1.5rem;
  text-align: center;
  color: var(--primary-colour);
}

.section p {
  max-width: 800px;
  margin: 0 auto 1.5rem;
  text-align: center;
}

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

.service-card {
  background-color: #ffffff;
  border-radius: var(--border-radius);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  padding: 2rem 1.5rem;
  text-align: center;
  transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.service-card:hover,
.service-card:focus-within {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.service-card i {
  font-size: 2.5rem;
  color: var(--secondary-colour);
  margin-bottom: 1rem;
}

.service-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--primary-colour);
}

.service-card p {
  font-size: 0.95rem;
  color: var(--text-colour);
}

/* About page styling */
.team-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.team-card {
  background-color: #ffffff;
  border-radius: var(--border-radius);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  padding: 2rem 1.5rem;
  text-align: center;
}

.team-card h3 {
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
  color: var(--primary-colour);
}

.team-card p {
  font-size: 0.9rem;
}

/* Contact page */
.contact-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.contact-info div {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
}

.contact-info i {
  color: var(--secondary-colour);
  font-size: 1.2rem;
}

.contact-form {
  background-color: #ffffff;
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  max-width: 600px;
  margin: 0 auto;
}

.contact-form form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-form label {
  font-weight: 600;
}

.contact-form input,
.contact-form textarea {
  padding: 0.75rem;
  border: 1px solid #cccccc;
  border-radius: var(--border-radius);
  font-size: 1rem;
  width: 100%;
}

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

.contact-form button {
  align-self: flex-start;
  background-color: var(--secondary-colour);
  color: var(--light-text);
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  cursor: pointer;
  transition: background-color var(--transition-speed);
}

.contact-form button:hover,
.contact-form button:focus {
  background-color: var(--primary-colour);
}

/* Footer */
footer {
  background-color: var(--primary-colour);
  color: var(--light-text);
  padding: 2rem 1rem;
  margin-top: 3rem;
}

.footer-container {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  text-align: center;
}

.footer-container .social {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.footer-container .social a {
  color: var(--light-text);
  font-size: 1.3rem;
  transition: color var(--transition-speed);
}

.footer-container .social a:hover,
.footer-container .social a:focus {
  color: var(--secondary-colour);
}

.footer-container p {
  margin: 0.25rem 0;
  font-size: 0.9rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }
  .hero p {
    font-size: 1rem;
  }
  .nav-menu {
    gap: 0.5rem;
  }
}