/* General styles */
:root {
  --primary-color: #1A1A2E;
  --secondary-color: #FFD700;
  --text-color: #f0f0f0;
  --dark-text-color: #333;
  --link-hover-color: #ffe066;
  --button-bg-color: #FFD700;
  --button-text-color: #1A1A2E;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background-color: #0d0d1a;
}

a {
  color: var(--secondary-color);
  text-decoration: none;
}

a:hover {
  color: var(--link-hover-color);
}

ul {
  list-style: none;
}

/* Header styles */
.site-header {
  background-color: var(--primary-color);
  padding: 1rem 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 1.5rem;
}

.logo {
  font-size: 2.2rem;
  font-weight: bold;
  color: var(--secondary-color);
  text-transform: uppercase;
  letter-spacing: 1px;
  display: flex;
  align-items: center;
  gap: 5px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.logo .logo-text {
  background: linear-gradient(90deg, #FFD700, #FFA500);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 5px rgba(255, 215, 0, 0.6));
}

.main-nav ul {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.main-nav a {
  color: var(--text-color);
  font-weight: 500;
  font-size: 1.05rem;
  padding: 0.5rem 0;
  position: relative;
  transition: color 0.3s ease;
}

.main-nav a:hover {
  color: var(--secondary-color);
}

.main-nav a.active::after,
.main-nav a:hover::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background-color: var(--secondary-color);
  transform: scaleX(0);
  transform-origin: bottom right;
  transition: transform 0.3s ease-out;
}

.main-nav a.active::after,
.main-nav a:hover::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

.btn-primary {
  background-color: var(--button-bg-color);
  color: var(--button-text-color);
  padding: 0.7rem 1.2rem;
  border-radius: 5px;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.2s ease;
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  background-color: var(--link-hover-color);
  transform: translateY(-2px);
}

.auth-buttons {
  display: flex;
  gap: 1rem;
  margin-left: 1.5rem; /* Space between nav and auth buttons */
}

.hamburger-menu {
  display: none;
  width: 30px;
  height: 22px;
  background: none;
  border: none;
  cursor: pointer;
  position: relative;
  z-index: 1001;
}

.hamburger-menu::before, .hamburger-menu::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 3px;
  background-color: var(--secondary-color);
  left: 0;
  transition: all 0.3s ease;
}

.hamburger-menu::before {
  top: 0;
}

.hamburger-menu::after {
  bottom: 0;
}

.hamburger-menu.active::before {
  transform: rotate(45deg);
  top: 9px;
}

.hamburger-menu.active::after {
  transform: rotate(-45deg);
  bottom: 9px;
}

/* Footer styles */
.site-footer {
  background-color: var(--primary-color);
  color: var(--text-color);
  padding: 3rem 0 1rem;
  border-top: 1px solid rgba(255, 215, 0, 0.1);
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  padding: 0 1.5rem 2rem;
}

.footer-column h3 {
  color: var(--secondary-color);
  font-size: 1.2rem;
  margin-bottom: 1rem;
  text-transform: uppercase;
}

.footer-column p {
  font-size: 0.95rem;
  line-height: 1.8;
  color: #ccc;
}

.footer-column ul {
  padding: 0;
}

.footer-column ul li {
  margin-bottom: 0.7rem;
}

.footer-column ul li a {
  color: #ccc;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

.footer-column ul li a:hover {
  color: var(--secondary-color);
}

.footer-logo {
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--secondary-color);
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 1rem;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.footer-logo .logo-text {
  background: linear-gradient(90deg, #FFD700, #FFA500);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
}

.footer-bottom {
  text-align: center;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 215, 0, 0.05);
  font-size: 0.9rem;
  color: #aaa;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .header-container {
    padding: 0 1rem;
    display: flex;
    flex-wrap: wrap; /* Allow items to wrap to new lines */
    align-items: center;
    justify-content: flex-start; /* Start items from the left */
    position: relative; /* For absolute positioning of logo */
    min-height: 120px; /* Adjust minimum height to accommodate logo and buttons below */
  }

  .hamburger-menu {
    display: block; /* Show hamburger menu */
    order: 1; /* Place it first in the flex order */
    margin-right: 1rem; /* Add some space to its right */
    z-index: 1001; /* Ensure it's above other elements */
  }

  .logo {
    order: 2; /* Logical order, but absolute positioning will override flow */
    position: absolute; /* Take out of normal document flow */
    left: 50%; /* Center horizontally */
    transform: translateX(-50%); /* Adjust for its own width */
    top: 1rem; /* Position vertically, roughly aligned with hamburger */
    margin: 0; /* Reset any desktop margins */
    z-index: 10; /* Ensure it's above other elements if needed, but below hamburger */
    width: auto; /* Allow content to define width */
    max-width: calc(100% - 80px); /* Prevent logo from overlapping hamburger */
    text-align: center; /* Center the logo text itself */
  }

  .main-nav {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: var(--primary-color);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
    padding: 1rem 0;
    z-index: 999;
    transform: translateY(-100%);
    transition: transform 0.3s ease-out;
    order: 4; /* Conceptual order */
  }

  .main-nav.menu-open {
    display: flex;
    transform: translateY(0);
  }

  .main-nav ul {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }

  .main-nav li {
    width: 100%;
    text-align: center;
  }

  .main-nav a {
    display: block;
    padding: 0.8rem 1rem;
    width: 100%;
  }

  .main-nav a.active::after,
  .main-nav a:hover::after {
    display: none; /* Hide underline on mobile for cleaner look */
  }

  .auth-buttons {
    display: flex; /* Make buttons visible */
    gap: 1rem;
    order: 3; /* Place after the logo in the conceptual flow */
    flex-basis: 100%; /* Take full width, forcing it to a new line below the logo */
    justify-content: center; /* Center the buttons horizontally */
    margin-top: 3rem; /* Add space below the absolutely positioned logo */
    margin-left: 0; /* Reset desktop margin */
  }

  .btn-primary {
    /* Existing button styles */
    /* margin-top: 1rem; */ /* This might be overridden by auth-buttons margin-top */
    width: auto; /* Allow buttons to size naturally within the flex container */
    padding: 0.7rem 1rem; /* Adjust padding for mobile if needed */
  }

  .footer-container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-column {
    margin-bottom: 1.5rem;
  }

  .footer-column:last-child {
    margin-bottom: 0;
  }
}