/* ===== Reset ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  overflow-y: scroll;
  /* Always show vertical scrollbar to prevent layout jump */
}

body {
  font-family: ui-sans-serif, system-ui, sans-serif;
  line-height: 1.6;
  background: #f9fafb;
  color: #333;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  /* Prevent horizontal scroll */
  transition: padding-top 0.3s ease;
}

/* ===== Navbar ===== */
.navbar {
  background: #ffffff;
  color: #161718;
  padding: 16px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  height: 70px;
  padding: 0 32px;
}

body.scrolled .navbar {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.logo {
  font-size: 28px;
  font-weight: bold;
  letter-spacing: 1px;
  color: #161718;
  text-decoration: none;
  line-height: 70px;
}

nav ul {
  list-style: none;
  display: flex;
}

nav a,
.nav-btn-link,
.nav-btn {
  display: inline-block;
  padding: 12px 20px;
  background: #ffffff;
  color: #161718;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.3s, box-shadow 0.3s, border-radius 0.3s, color 0.3s;
  border: none;
  outline: none;
  line-height: normal;
}

nav a:hover,
.nav-btn-link:hover,
.nav-btn:hover {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.15);
  border-radius: 16px;
}

/* ===== Hamburger ===== */
.hamburger {
  display: none;
  cursor: pointer;
}

/* ===== Layout Wrapper ===== */
.wrapper {
  display: flex;
  flex: 1;
  min-height: calc(100vh - 70px);
}



/* ========== Registration Container ========== */
.reg-container {
  display: flex;
  background: white;
  width: 100%;
  max-width: 600px;
  min-height: 60vh;
  margin: 30px auto 30px auto;
  padding: 32px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  text-align: center;
  flex-direction: column;
  justify-content: center;
}

.reg-container h2 {
  font-size: 32px;
  color: #1e3a8a;
  margin-bottom: 24px;
}

/* ========== Form Inputs ========== */
.input-group {
  margin-bottom: 20px;
  text-align: left;
}

label {
  display: block;
  margin-bottom: 8px;
  color: #1e3a8a;
  font-weight: 600;
}

input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 16px;
  margin-bottom: 8px;
  outline: none;
  transition: border-color 0.3s;
}

input:focus {
  border-color: #2563eb;
}

/* ========== Buttons ========== */
button,
a.login-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 48px;
  /* Fixed consistent height */
  padding: 0 20px;
  background: #3b82f6;
  color: white;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  border: none;
  cursor: pointer;
  transition: background 0.3s, box-shadow 0.3s, border-radius 0.3s, color 0.3s;
  text-align: center;
}

button:hover,
a.login-button:hover {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.15);
  border-radius: 16px;
}

/* ===== Options ===== */
.options {
  margin-top: 20px;
  margin-bottom: 20px;
  text-align: center;
}

.options a {
  color: #3b82f6;
  text-decoration: none;
  font-weight: 600;
  margin: 0 8px;
  transition: color 0.3s;
}

.options a:hover {
  color: #2563eb;
  text-decoration: underline;
}

/* ========== Notes ========== */
.login-note p {
  margin-top: 20px;
  margin-bottom: 20px;
  color: #555;
  font-size: 14px;
}

/* ===== Responsive Styling ===== */
@media (max-width: 1024px) {
  .navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    width: 100%;
  }

  body {
    padding-top: 50px;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: #1e3a8a;
    text-align: left;
    padding: 16px 25px 16px 25px;
    border-radius: 0 0 8px 8px;
    z-index: 101;
    transition: max-height 0.4s cubic-bezier(.4, 0, .2, 1), opacity 0.4s;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
  }

  .nav-links.active {
    display: block;
    max-height: 300px;
    opacity: 1;
  }

  .nav-links ul {
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: left;
    width: 100%;
    padding: 0;
    margin: 0;
  }

  .nav-links ul li {
    flex: 1;
    text-align: left;
  }

  .nav-links ul li a {
    display: block;
    width: 100%;
    padding: 8px 0;
    background-color: #1e3a8a;
    color: white;
    font-weight: 600;
    text-align: left;
    border-radius: 8px;
    transition: background 0.3s, box-shadow 0.3s, border-radius 0.3s, color 0.3s;
  }

  nav a:hover,
  .nav-btn-link:hover,
  .nav-btn:hover {
    display: block;
    width: 100%;
    padding: 8px 0;
    background-color: #1e3a8a;
    color: white;
    font-weight: 600;
    text-align: left;
    border-radius: none;
    box-shadow: none;
    transition: none;
    cursor: pointer;
  }



  .hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 32px;
    height: 32px;
    cursor: pointer;
    gap: 6px;
  }

  .hamburger span {
    display: block;
    height: 4px;
    width: 100%;
    background: #000000;
    border-radius: 2px;
    transition: all 0.3s ease;
  }

  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
  }

  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }

  /* Hide all content except navbar when hamburger menu is active with fade animation */
  body.nav-open .reg-container {
    opacity: 0;
    visibility: hidden;
    transform: translateY(-20px);
    transition: opacity 0.4s cubic-bezier(.4, 0, .2, 1),
      visibility 0.4s cubic-bezier(.4, 0, .2, 1),
      transform 0.4s cubic-bezier(.4, 0, .2, 1);
  }

  body.nav-open .hero {
    padding-top: 130px !important;
    transition: padding-top 0.4s cubic-bezier(.4, 0, .2, 1);
  }

  .reg-container {
    padding: 20px;
    margin: 60px auto 20px;
    width: min(600px, calc(100% - 40px));
    min-height: 60vh;
    /* Ensures enough height for vertical centering */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-self: center;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.4s cubic-bezier(.4, 0, .2, 1),
      visibility 0.4s cubic-bezier(.4, 0, .2, 1),
      transform 0.4s cubic-bezier(.4, 0, .2, 1);
  }

  .reg-container h2 {
    font-size: 28px;
  }

  body.nav-open .reg-container {
    margin-top: 130px !important;
    /* Same as .hero in style.css */
    transition: margin-top 0.4s cubic-bezier(.4, 0, .2, 1);
  }
}