* {
  margin: 0;
  padding: 0;
}

body {
  /*background: #c0c0c0;*/
  background-image: url(bg-resized.jpg);
  image-resolution: inherit;
  line-height: 1.6;
  background-color: #f9fafb;
  color: #1a1a1a;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

header {
  background: #77b1cc;
  justify-content: center;
  color: darkblue;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  padding: 15px 20px;
  align-items: center;
  flex-wrap: wrap;
  position: sticky;
  top: 0;
  z-index: 1000;
}

header h1 {
  justify-self: center;
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: 1px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

nav {
  justify-content: space-evenly;
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

nav a,
header a {
  text-decoration: none;
  transition: all 0.3s ease;
  padding: 8px 12px;
  font-weight: 600;
  border-radius: 4px;
}

#menu {
  display: none;
}

a:hover,
a:focus {
  color: darkblue;
  transform: translateY(-1px);
}

@media (max-width: 768px) {
  body {
    width: auto;
  }

  nav {
    display: none;
    width: 100%;
    flex-direction: column;
    background-color: #003366;
    margin-top: 10px;
    border-radius: 4px;
  }

  nav a {
    padding: 12px 20px;
    border-top: 1px solid #002244;
  }

  #menu {
    display: flex;
  }

  .nav-toggle:checked + .nav-toggle-label + nav {
    display: flex;
  }

  .nav-toggle-label {
    display: flex;
  }
}

.main {
  margin: 5px 2px;
  /*background-color: #c4c7f8;
    padding: 7px 5px;
    opacity: 0.9;*/
  /*margin-left: 2px;
    margin-right: 3px;*/
  box-sizing: border-box;
  border-radius: 5px;
  flex: 1;
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.main-body h1,
.main-body h2,
.main-body h3 {
  margin-bottom: 10px;
}

.main-body h2 {
  color: #1428d8;
}

p {
  margin-bottom: 15px;
  font-size: 1.1rem;
}

.main-body h1 {
  color: #050458;
  font-size: 2.5rem;
  margin-bottom: 1.1rem;
}

.containers {
  box-sizing: border-box;
  box-shadow: 4px 8px rgba(0, 0, 0, 0.1);
  background: #e0e0e0;
  border-radius: 10px;
  border-bottom: 20px;
  margin-bottom: 15px;
  transition: all 0.3s ease;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.3s ease;
}

.containers h2 {
  justify-self: center;
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 10px;
  /*color: #004080;*/
}

.containers p {
  justify-self: center;
}

.containers:hover {
  transform: translateY(-1px);
  box-shadow: 4px 8px rgba(0, 0, 0, 0.4);
}

.btn-primary {
  background-color: #004080;
  color: #c0c0c0;
  padding: 12px 18px;
  border: 2px solid #c0c0c0;
  border-radius: 5px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

.btn-primary:hover,
.btn-primary:focus {
  background-color: #c0c0c0;
  color: #004080;
  border-color: #004080;
  outline: none;
}

#projects {
  font-family: Arial, sans-serif;
  color: #eee;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  user-select: none;
}

.container {
  position: relative;
  width: 90vw;
  max-width: 1000px;
  overflow: hidden;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.7);
  background: #222;
}

.image-strip {
  display: flex;
  transition: transform 0.4s ease;
  will-change: transform;
  cursor: grab;
}

.image-strip:active {
  cursor: grabbing;
}

.image-strip img {
  flex-shrink: 0;
  width: 200px;
  height: 140px;
  object-fit: cover;
  margin-right: 10px;
  border-radius: 6px;
  transition: transform 0.3s ease;
}

.image-strip img:hover {
  transform: scale(1.1);
  z-index: 10;
  box-shadow: 0 0 15px #ff6600;
}

/* Navigation buttons */
.nav-buttons {
  margin-top: 15px;
  display: flex;
  justify-content: center;
  gap: 20px;
}

button {
  background: #ff6600;
  border: none;
  padding: 10px 20px;
  color: #fff;
  font-weight: bold;
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background 0.3s ease;
}

button:disabled {
  background: #555;
  cursor: not-allowed;
}

button:hover:not(:disabled) {
  background: #ff8533;
}

footer {
  background-color: #003366;
  color: white;
  text-align: center;
  padding: 15px 20px;
  font-size: 0.9rem;
  margin-top: 40px;
}

@media (max-width: 500px) {
  header h1 {
    font-size: 1.1rem;
  }

  body {
    background-image: url(bg.jpg);
  }

  /*header nav a {

    }*/
}
