/* General Reset & Base Styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f4f4f4;
  padding-top: 65px; /* Default padding for desktop fixed header */
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

/* Header Styles */
.site-header {
  background-color: #0A2342;
  color: #fff;
  padding: 15px 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  position: fixed; /* Make header sticky */
  top: 0;
  width: 100%;
  z-index: 1000; /* Ensure it's above other content */
}

.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-header .logo {
  font-size: 2.2em;
  font-weight: bold;
  color: #FFD700;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: color 0.3s ease;
}

.site-header .logo:hover {
  color: #fff;
}

.site-header .main-nav {
  flex-grow: 1; /* Allow nav to take available space */
  display: flex; /* To center its ul */
  justify-content: center; /* Center the nav links */
}

.site-header .main-nav ul {
  display: flex;
  gap: 25px;
}

.site-header .main-nav a {
  color: #fff;
  font-weight: 500;
  padding: 5px 0;
  position: relative;
  transition: color 0.3s ease;
}

.site-header .main-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0%;
  height: 2px;
  background-color: #FFD700;
  transition: width 0.3s ease;
}

.site-header .main-nav a:hover::after, 
.site-header .main-nav a.active::after {
  width: 100%;
}

.site-header .main-nav a:hover, 
.site-header .main-nav a.active {
  color: #FFD700;
}

/* Header Buttons */
.header-buttons {
  display: flex; /* Show on desktop */
  align-items: center;
  margin-left: 20px; /* Space between nav and buttons */
}

.btn {
  display: inline-block;
  padding: 8px 15px;
  border-radius: 5px;
  font-weight: bold;
  text-transform: uppercase;
  transition: all 0.3s ease;
  font-size: 0.9em;
  margin-left: 10px; /* Space between buttons */
}

.btn:first-child {
  margin-left: 0; /* No left margin for the first button in a group */
}

.btn-register {
  background-color: #FFD700; /* Gold */
  color: #0A2342; /* Dark blue */
  border: 2px solid #FFD700;
}

.btn-register:hover {
  background-color: #fff;
  color: #0A2342;
  border-color: #fff;
}

.btn-login {
  background-color: transparent;
  color: #FFD700; /* Gold */
  border: 2px solid #FFD700;
}

.btn-login:hover {
  background-color: #FFD700;
  color: #0A2342;
}

/* Hamburger Menu */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 25px;
  cursor: pointer;
  z-index: 1000;
}

.hamburger-menu span {
  display: block;
  width: 100%;
  height: 3px;
  background-color: #FFD700;
  border-radius: 2px;
  transition: all 0.3s ease-in-out;
}

.hamburger-menu.active span:nth-child(1) {
  transform: translateY(11px) rotate(45deg);
}

.hamburger-menu.active span:nth-child(2) {
  opacity: 0;
}

.hamburger-menu.active span:nth-child(3) {
  transform: translateY(-11px) rotate(-45deg);
}

/* Footer Styles */
.site-footer {
  background-color: #0A2342;
  color: #f0f0f0;
  padding: 40px 0 20px;
  font-size: 0.9em;
}

.site-footer .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 30px;
}

.site-footer .footer-column {
  flex: 1;
  min-width: 250px;
}

.site-footer h3 {
  color: #FFD700;
  font-size: 1.3em;
  margin-bottom: 15px;
  border-bottom: 1px solid rgba(255, 215, 0, 0.3);
  padding-bottom: 8px;
}

.site-footer p {
  margin-bottom: 10px;
  line-height: 1.8;
}

.site-footer a {
  color: #f0f0f0;
  transition: color 0.3s ease;
}

.site-footer a:hover {
  color: #FFD700;
}

.site-footer .footer-nav li {
  margin-bottom: 8px;
}

.site-footer .footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 20px;
  margin-top: 30px;
  text-align: center;
}

.site-footer .footer-bottom p {
  margin: 0;
  color: #bbb;
}

/* Responsive Styles */
@media (max-width: 992px) {
  .site-header .main-nav ul {
    gap: 15px;
  }
}

@media (max-width: 768px) {
  body {
    padding-top: 125px; /* Adjusted for mobile fixed header height */
  }

  .site-header .container {
    display: grid;
    grid-template-columns: auto 1fr auto; /* Hamburger | Logo (fills space) | Right-space */
    grid-template-rows: auto auto; /* Row 1: Logo/Hamburger; Row 2: Buttons */
    gap: 10px 0; /* Vertical gap between rows, no horizontal gap for columns */
    align-items: center;
    padding-top: 10px; /* Add some top padding for mobile header */
    padding-bottom: 10px; /* Add some bottom padding for mobile header */
  }

  .site-header .hamburger-menu {
    display: flex; /* Show hamburger on mobile */
    grid-column: 1; /* Place hamburger in the first column */
    grid-row: 1; /* Row 1 */
    justify-self: start; /* Align to the start (left) */
    margin-left: 15px; /* Ensure padding from edge */
  }

  .site-header .logo {
    grid-column: 2; /* Place logo in the second column (center) */
    grid-row: 1; /* Row 1 */
    justify-self: center; /* Center the logo */
    font-size: 1.8em; /* Adjust font size for mobile */
  }

  .site-header .header-buttons {
    grid-column: 1 / -1; /* Span all columns (1 to last) */
    grid-row: 2; /* Row 2 */
    display: flex; /* Show mobile buttons */
    justify-content: center; /* Center the buttons */
    width: 100%;
    gap: 10px; /* Space between buttons */
    margin-left: 0; /* Reset desktop margin */
  }
  .site-header .header-buttons .btn {
    margin-left: 0; /* Reset default margin from btn */
  }

  .site-header .main-nav {
    position: absolute;
    top: 110px; /* Calculated mobile fixed header height: 15px*2 (header padding) + 10px*2 (container padding) + 30px (logo/hamburger row height) + 10px (gap) + 35px (buttons row height) = 110px */
    left: 0;
    width: 100%;
    background-color: #0A2342; /* Same as header */
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease-in-out, padding 0.5s ease-in-out;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
    z-index: 999; /* Ensure it's above other content when open */
  }

  .site-header .main-nav.active {
    max-height: 500px; /* Max height to allow transition */
    padding: 10px 0;
  }

  .site-header .main-nav ul {
    flex-direction: column;
    text-align: center;
    padding: 10px 0;
  }

  .site-header .main-nav li {
    margin-bottom: 10px;
  }

  .site-header .main-nav a {
    display: block;
    padding: 10px 0;
    font-size: 1.1em;
  }

  .site-header .main-nav a::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .site-footer .container {
    flex-direction: column;
    align-items: center;
  }

  .site-footer .footer-column {
    text-align: center;
    margin-bottom: 20px;
    min-width: unset;
    width: 100%;
  }

  .site-footer h3 {
    text-align: center;
  }

  .site-footer .footer-nav {
    padding-left: 0;
  }

  .site-footer .footer-nav li {
    display: inline-block;
    margin: 0 10px 8px;
  }
}

@media (max-width: 480px) {
  .site-header .logo {
    font-size: 1.5em;
  }
  .site-footer .footer-nav li {
    display: block;
    margin: 0 auto 8px;
  }
}