body {
  font-family: 'Montserrat', Arial, sans-serif;
  margin: 0;
  background: #fff;
  color: #222;
}
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 40px 16px 40px;
  border-bottom: 1px solid #eee;
  max-width: 60vw;
  margin-left: auto;
  margin-right: auto;
}
.logo {
  display: flex;
  align-items: center;
  font-size: 2rem;
  font-weight: 700;
  color: #1a73e8;
  letter-spacing: 1px;
}
.logo-icon {
  width: 38px;
  height: 38px;
  margin-right: 10px;
  background: #1a73e8;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.logo-icon svg {
  width: 24px;
  height: 24px;
  fill: #fff;
}
nav {
  display: flex;
  gap: 32px;
  font-size: 1rem;
}
nav a {
  color: #222;
  text-decoration: none;
  font-weight: 700;
  transition: color 0.2s;
  letter-spacing: 0.5px;
}
nav a:hover {
  color: #1a73e8;
  text-shadow: 0 2px 8px rgba(26,115,232,0.08);
}
.cta-btn {
  background: #1a73e8;
  color: #fff;
  border: none;
  padding: 12px 28px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s;
}
.cta-btn:hover {
  background: #155ab6;
}
.hero {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 60px 40px 40px 40px;
  background: #f7fafc;
  max-width: 60vw;
  margin-left: auto;
  margin-right: auto;
}
.hero-content {
  max-width: 520px;
}
.hero-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 18px;
  color: #222;
}
.hero-slogan {
  font-size: 1.2rem;
  margin-bottom: 24px;
  color: #444;
}
.hero-info {
  font-size: 1rem;
  color: #666;
  margin-bottom: 8px;
}
.hero-contact {
  font-size: 1rem;
  color: #1a73e8;
  margin-bottom: 24px;
}
.hero-illustration {
  flex: 1;
  min-width: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-illustration svg {
  width: 320px;
  height: 220px;
}
.services-section {
  padding: 60px 40px 40px 40px;
  background: #fff;
  max-width: 60vw;
  margin-left: auto;
  margin-right: auto;
}
.services-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 40px;
  text-align: center;
  color: #222;
}
.services-list {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  justify-content: center;
}
.service-card {
  background: #f7fafc;
  border-radius: 18px;
  box-shadow: 0 2px 12px rgba(30, 64, 175, 0.06);
  padding: 36px 28px 28px 28px;
  max-width: 320px;
  min-width: 260px;
  flex: 1 1 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: box-shadow 0.2s;
}
.service-card:hover {
  box-shadow: 0 4px 24px rgba(30, 64, 175, 0.13);
}
.service-icon {
  width: 64px;
  height: 64px;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e3f0ff;
  border-radius: 50%;
}
.service-icon svg {
  width: 36px;
  height: 36px;
  fill: #1a73e8;
}
.service-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: #1a73e8;
}
.service-desc {
  font-size: 1rem;
  color: #444;
}
footer {
  text-align: center;
  padding: 32px 0 16px 0;
  color: #888;
  font-size: 1rem;
  background: #f7fafc;
  margin-top: 40px;
  max-width: 60vw;
  margin-left: auto;
  margin-right: auto;
}
@media (max-width: 900px) {
  .hero {
    flex-direction: column;
    padding: 40px 16px 24px 16px;
  }
  .services-section {
    padding: 40px 16px 24px 16px;
  }
}
@media (max-width: 600px) {
  .services-list {
    flex-direction: column;
    gap: 24px;
  }
  .hero-illustration svg {
    width: 220px;
    height: 140px;
  }
}
.ads-section {
  margin: 40px 0 0 0;
  max-width: 100vw;
  width: 100vw;
  text-align: center;
  padding: 0;
}
.ads-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 32px;
}
.ads-list {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  margin-bottom: 32px;
  padding: 0 8px;
}
.ad-card {
  background: #f7fafc;
  border-radius: 18px;
  box-shadow: 0 2px 12px rgba(30, 64, 175, 0.06);
  padding: 24px 18px 18px 18px;
  width: 260px;
  cursor: pointer;
  transition: box-shadow 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.ad-card:hover {
  box-shadow: 0 4px 24px rgba(30, 64, 175, 0.13);
  transform: translateY(-4px) scale(1.03);
}
.ad-thumb {
  width: 220px !important;
  height: 150px !important;
  max-width: 220px !important;
  max-height: 150px !important;
  min-width: 220px !important;
  min-height: 150px !important;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 16px;
  box-shadow: 0 1px 6px rgba(30, 64, 175, 0.08);
  display: block;
  background: #f7fafc;
}
.ad-label {
  font-size: 1.1rem;
  font-weight: 600;
  color: #1a73e8;
}
.ad-modal {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.55);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ad-modal-content {
  padding: 0 !important;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
}
.ad-modal-content iframe {
  width: 100%;
  height: 120vh;
  min-height: 630px;
  border: none;
  display: block;
  background: transparent;
  border-radius: 18px;
}
.ad-modal-close {
  position: absolute;
  top: 12px;
  right: 18px;
  font-size: 2rem;
  color: #1a73e8;
  cursor: pointer;
  font-weight: bold;
  z-index: 2;
}
@media (max-width: 900px) {
  .ads-section {
    max-width: 100vw;
    width: 100vw;
    padding: 0;
  }
  .ads-list {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
    padding: 0 2vw;
  }
  .ad-card {
    width: 44vw;
    max-width: 180px;
    min-width: 120px;
  }
  .ad-thumb {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 4/3;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: 100% !important;
    max-height: 100% !important;
  }
  .ad-modal-content {
    min-width: 0;
    padding: 8px;
  }
}
@media (max-width: 600px) {
  .ads-list {
    gap: 6px;
    padding: 0 1vw;
  }
  .ad-card {
    width: 48vw;
    max-width: 140px;
    min-width: 80px;
    padding: 8px 2px 8px 2px;
  }
  .ad-thumb {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 4/3;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: 100% !important;
    max-height: 100% !important;
  }
}

/* --- FIX: Responsive header, logo, popup, prevent horizontal scroll, always show NoahAI text --- */
html, body {
  width: 100vw;
  max-width: 100vw;
  overflow-x: hidden;
}

@media (max-width: 600px) {
  header {
    flex-direction: column;
    align-items: flex-start;
    padding: 12px 8px 8px 8px;
    max-width: 100vw;
    width: 100vw;
  }
  .logo {
    font-size: 1.5rem;
    margin-bottom: 8px;
    width: 100vw;
    justify-content: flex-start;
    white-space: nowrap;
  }
  .logo-icon {
    width: 32px;
    height: 32px;
    margin-right: 8px;
  }
  nav {
    gap: 16px;
    font-size: 0.95rem;
    width: 100vw;
    flex-wrap: wrap;
  }
  .cta-btn {
    width: 100%;
    margin-top: 8px;
    padding: 10px 0;
    font-size: 1rem;
  }
  .hero, .services-section, footer {
    max-width: 100vw;
    width: 100vw;
    padding-left: 4vw;
    padding-right: 4vw;
  }
  .hero-illustration {
    min-width: 0;
  }
  .ad-modal-content {
    padding: 0 !important;
    max-width: 100vw;
    width: 100vw;
    border-radius: 0;
  }
  .ad-modal-content iframe {
    height: 105vw;
    min-height: 390px;
    border-radius: 0;
  }
}

/* Luôn hiển thị text NoahAI trên mobile */
.logo a {
  display: inline !important;
  color: inherit;
  text-decoration: none;
  font-weight: 700;
  margin-left: 0;
}

/* Ngăn popup/modal bị lệch phải trên mobile */
.ad-modal-content {
  box-sizing: border-box;
  margin: 0 auto;
}

/* Ngăn mọi thành phần chính bị overflow ngang */
.hero, .services-section, .ads-section, footer {
  box-sizing: border-box;
  overflow-x: hidden;
} 