@import url('https://fonts.googleapis.com/css2?family=Chantelli+Antiqua&display=swap');

:root {
  --primary-color: rgb(0, 139, 139);
  --primary-dark: #05641a;
  --background-dark: #111;
  --nav-bg: #222;
  --text-light: #eee;
  --max-width: 1200px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Chantelli Antiqua', serif;
  background-color: var(--background-dark);
  color: var(--primary-color);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

header {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: #fff;
  padding: 20px 10px;
  box-shadow: 0 6px 15px rgba(0, 139, 139, 0.4);
  position: relative;
  z-index: 2;
  border-bottom: 2px solid var(--primary-dark);
  display: flex;
  align-items: center;
  justify-content: center;
}

header h1 {
  margin: 0;
  font-size: 3rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  flex-grow: 1;
  text-align: center;
}

header #logo {
  height: 190px;
  width: 200px;
  position: absolute;
  left: 20px;
  top: 60%;
  transform: translateY(-50%);
}

@media (max-width: 768px) {
  header #logo {
    display: none;
  }
}

header p {
  margin: 5px 0 10px;
}

nav {
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: white;
  padding: 10px 0;
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: 0 2px 8px rgba(0, 139, 139, 0.2);
  border-radius: 13px;
  width: 390px;
  margin: 0 auto;
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  gap: 30px;
}

.nav-list li {
  display: inline;
}

.nav-link {
  color: white;
  font-size: 1.2rem;
  text-decoration: none;
  font-weight: 600;
  position: relative;
  display: inline-block;
  transition: transform 0.3s ease, color 0.3s ease;
  cursor: pointer;
  will-change: transform, color;
  padding: 6px 0;
}

.nav-link:hover,
.nav-link:focus-visible {
  color: #fff;
  transform: translateY(-2px);
  outline-offset: 4px;
}

.nav-link:focus-visible {
  outline: 2px solid var(--primary-color);
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -3px;
  width: 0;
  height: 2px;
  background: var(--primary-color);
  transition: width 0.3s ease, left 0.3s ease;
  transform-origin: center;
}

.nav-link:hover::after,
.nav-link:focus-visible::after {
  width: 100%;
  left: 0;
}

.hero {
  position: relative;
  background-image: 
    linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.9)),
    url('../img/background.jpg');
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  height: 60vh;
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  text-align: center;
  overflow: hidden;
  opacity: 0;
  animation: fadeIn 1.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  padding: 0 20px;
}

.hero-content {
  max-width: 320px;
  width: 100%;
  line-height: 1.2;
  word-wrap: break-word;
  user-select: none;
}

.hero h2 {
  font-size: 3rem;
  margin: 0;
  text-shadow: 0 4px 12px rgba(0, 139, 139, 0.5);
  font-weight: 600;
}

.hero p {
  font-size: 1.5rem;
  margin-top: 10px;
  line-height: 1.4;
}

.hero button {
  background: var(--primary-color);
  border: none;
  padding: 14px 28px;
  color: #111;
  font-size: 1.1rem;
  margin-top: 30px;
  cursor: pointer;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 139, 139, 0.5);
  transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
  will-change: transform, background;
}

.hero button:hover,
.hero button:focus-visible {
  background: #087f23;
  transform: scale(1.07);
  box-shadow: 0 7px 20px rgba(8, 127, 35, 0.8);
  outline-offset: 4px;
  outline: 2px solid var(--primary-color);
}

.hero button:focus-visible {
  outline-offset: 4px;
}

.section {
  padding: 60px 20px;
  text-align: center;
  background: var(--background-dark);
}

.section h3 {
  font-size: 2.8rem;
  margin-bottom: 30px;
  color: var(--primary-color);
  font-weight: 600;
  text-shadow: 0 2px 8px rgba(0, 139, 139, 0.4);
}

.services {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 25px;
}

.service {
  flex: 1 1 260px;
  max-width: 320px;
  margin: 10px;
  padding: 20px;
  background: linear-gradient(145deg, #222, #333);
  border-radius: 16px;
  box-shadow: 0 5px 18px rgba(0, 139, 139, 0.3);
  transition: transform 0.35s ease, box-shadow 0.35s ease, opacity 0.3s ease;
  opacity: 0;
  animation: fadeIn 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  position: relative;
  cursor: default;
  user-select: none;
  outline-offset: 4px;
}

.service:focus-visible {
  outline: 3px solid var(--primary-color);
  outline-offset: 4px;
}

.service:hover {
  box-shadow: 0 12px 28px rgba(0, 139, 139, 0.55);
  transform: translateY(-8px);
}

.service h4 {
  font-size: 1.6rem;
  margin-bottom: 12px;
  color: var(--primary-color);
  font-weight: 600;
  text-shadow: 0 2px 5px rgba(0, 139, 139, 0.4);
}

.service p {
  font-size: 1.05rem;
  color: #ddd;
  line-height: 1.4;
}

.service::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 139, 139, 0.1);
  pointer-events: none;
  opacity: 0;
  transform: translateX(0) translateY(0);
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.service:hover::after {
  opacity: 1;
}

.service:hover[data-hover-direction="top"]::after {
  transform: translateY(-100%);
}

.service:hover[data-hover-direction="right"]::after {
  transform: translateX(100%);
}

.service:hover[data-hover-direction="bottom"]::after {
  transform: translateY(100%);
}

.service:hover[data-hover-direction="left"]::after {
  transform: translateX(-100%);
}

.footer {
  background: var(--background-dark);
  color: var(--text-light);
  padding: 25px 20px;
  text-align: center;
  border-top: 2px solid #087f23;
  font-size: 1rem;
}

.footer a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
  cursor: pointer;
}

.footer a:hover,
.footer a:focus-visible {
  color: #fff;
  text-shadow: 0 2px 4px rgba(0, 139, 139, 0.4);
}

.footer a:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 3px;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal.visible {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: #222;
  border-radius: 12px;
  padding: 30px 40px;
  max-width: 420px;
  width: 100%;
  color: var(--text-light);
  box-shadow: 0 8px 30px rgba(0, 139, 139, 0.7);
  position: relative;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: transparent;
  border: none;
  font-size: 2rem;
  color: var(--primary-color);
  cursor: pointer;
  transition: color 0.25s ease;
}

.modal-close:hover,
.modal-close:focus-visible {
  color: #087f23;
  outline-offset: 3px;
  outline: 2px solid var(--primary-color);
}

.modal h3 {
  margin-top: 0;
  margin-bottom: 20px;
  font-size: 2rem;
  font-weight: 600;
  color: var(--primary-color);
  text-align: center;
}

.modal p {
  font-size: 1.1rem;
  line-height: 1.5;
}

:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 3px;
  transition: outline-color 0.3s ease;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

@media (max-width: 768px) {
  header h1 {
    font-size: 2.2rem;
  }

  .nav-list {
    gap: 18px;
  }

  .hero h2 {
    font-size: 2rem;
  }

  .services {
    flex-direction: column;
    align-items: center;
  }

  .service {
    max-width: 100%;
  }
}

.service-list {
  font-size: 1.7rem;
}

.benefit-information p {
  font-size: 1.5rem;
}

.benefit-information h4 {
  font-size: 2.5rem;
}
