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

body {
  font-family: "Georgia", "Times New Roman", serif;
  line-height: 1.6;
  color: #2c2c2c;
  background-color: #fbeec8;
}

/* Header Styles */
header {
  background-color: #fbeec8;
  border-bottom: 2px solid #2c2c2c;
  padding: 1.5rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

nav {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.8rem;
  font-weight: bold;
  color: #2c2c2c;
  text-decoration: none;
  font-family: "Georgia", serif;
}

.nav-links {
  display: flex;
  gap: 3rem;
  list-style: none;
}

.nav-links a {
  color: #4a4a4a;
  text-decoration: none;
  font-size: 1rem;
  transition: color 0.3s;
  font-weight: 500;
}

.nav-links a:hover {
  color: #2c2c2c;
}

/* Language Switch Styles */
.language-switch-container {
  position: relative;
}

#languageSwitch {
  padding: 0.5rem 1rem;
  border: 2px solid #2c2c2c;
  background-color: #fbeec8;
  color: #2c2c2c;
  font-family: "Georgia", serif;
  font-size: 0.9rem;
  border-radius: 4px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232c2c2c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.5rem center;
  background-size: 1rem;
  padding-right: 2rem;
}

#languageSwitch:focus {
  outline: 2px solid #8b0000;
  outline-offset: 2px;
}

/* Language Bar Styles */
.language-bar {
  margin-top: 3rem;
  padding: 1.5rem;
  background-color: #f0e6d2;
  border: 1px solid #d4c8a8;
  border-radius: 8px;
  text-align: center;
}

.language-bar-text {
  margin: 0;
  font-size: 1rem;
  color: #2c2c2c;
  font-weight: 500;
}

.language-links {
  display: inline-block;
  margin-left: 0.5rem;
}

.language-links a {
  color: #8b0000;
  text-decoration: none;
  margin: 0 0.3rem;
  font-weight: 600;
  border-bottom: 1px dotted #8b0000;
  transition: all 0.3s ease;
  display: inline-block;
}

/* Add separator using pseudo-element */
.language-links a:not(:last-child)::after {
  content: "|";
  color: #2c2c2c;
  margin-left: 0.6rem;
  position: absolute;
  pointer-events: none;
  font-weight: normal;
  text-decoration: none;
  border: none;
}

.language-links a {
  padding-right: 0.8rem; /* Space for separator */
  position: relative;
  border-bottom: none; /* Remove dotted underline for cleaner look with active state */
}
.language-links a:hover {
  color: #2c2c2c;
  text-decoration: underline;
}

/* Active language style */
.language-links a.active {
  color: #2c2c2c;
  font-weight: bold;
  cursor: default;
  pointer-events: none;
  text-decoration: none;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .language-switch-container {
    margin-top: 1rem;
  }

  #languageSwitch {
    width: 100%;
    padding: 0.8rem;
    font-size: 1rem;
  }

  .language-bar {
    margin-top: 2rem;
    padding: 1rem;
  }

  .language-links {
    display: block;
    margin-top: 0.5rem;
  }

  .language-links a {
    display: inline-block;
    margin: 0.2rem 0.3rem;
    padding-right: 0;
  }

  /* Hide separators on mobile as they might wrap weirdly */
  .language-links a:not(:last-child)::after {
    content: "";
    margin-left: 0;
  }
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #2c2c2c;
}

/* Hero Section */
.hero {
  background-color: #fbeec8;
  padding: 3rem 2rem 4rem;
  text-align: center;
}

.hero-content {
  max-width: 1200px;
  margin: 0 auto;
}

.hero-title-container {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 3rem;
  gap: 1rem;
  flex-wrap: wrap;
  position: relative;
}

.title-line {
  height: 3px;
  background-color: #2c2c2c;
  flex: 1;
  max-width: 250px;
  position: relative;
}

.title-line::before {
  content: "";
  position: absolute;
  top: -8px;
  left: 0;
  right: 0;
  height: 3px;
  background-color: #2c2c2c;
}

.title-line::after {
  content: "";
  position: absolute;
  top: 8px;
  left: 0;
  right: 0;
  height: 3px;
  background-color: #2c2c2c;
}

.hero-title-text {
  font-size: 3rem;
  font-weight: normal;
  color: #2c2c2c;
  font-family: "Georgia", serif;
  white-space: nowrap;
}

/* Hand icon styling */
.hand-icon {
  display: inline-block;
  font-size: 3rem;
  transform: rotate(-20deg);
}

.the-real {
  color: #8b0000;
  font-style: italic;
  font-size: 2.2rem;
  position: absolute;
  left: 25px;
  top: -18px;
  transform: rotate(-20deg);
  font-weight: bold;
  z-index: 10;
}

.main-heading {
  font-size: 2rem;
  margin-bottom: 1rem;
  line-height: 1.3;
  color: #2c2c2c;
  font-weight: normal;
}

.hero-description {
  font-size: 1rem;
  font-weight: normal;
  color: #4a4a4a;
  margin-bottom: 0;
  line-height: 1.7;
  max-width: 800px;
  margin: 0 auto;
}

/* Main Content */
main {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 2rem 3rem;
}

/* Score Display (shown first on result page) */
.score-display {
  padding: 1.5rem 2rem;
  text-align: center;
  margin-top: 0;
  margin-bottom: 2rem;
  display: none;
}

.score-display.show {
  display: block;
}

.score-title {
  font-size: 2rem;
  font-weight: normal;
  margin-bottom: 2rem;
  color: #2c2c2c;
}

.score-number {
  font-size: 8rem;
  font-weight: bold;
  color: #dc143c;
  margin: 1rem 0;
  line-height: 1;
}

.test-again-btn {
  margin-top: 2rem;
  padding: 1rem 3rem;
  font-size: 1.1rem;
  font-weight: normal;
  border: 2px solid #2c2c2c;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s;
  background-color: #c8e6c9;
  color: #2c2c2c;
  font-family: "Georgia", serif;
}

.test-again-btn:hover {
  background-color: #a5d6a7;
  transform: translateY(-2px);
}

/* Questions Container */
.questions-container {
  background-color: #fbeec8;
  padding: 1.5rem 0.5rem;
  margin-bottom: 2rem;
}

.question-item {
  display: flex;
  align-items: flex-start;
  padding: 0.35rem 0;
  margin-bottom: 0;
}

.question-number {
  font-weight: normal;
  color: #2c2c2c;
  margin-right: 0.5rem;
  min-width: 35px;
  font-size: 1rem;
}

.question-item input[type="checkbox"] {
  margin-right: 0.75rem;
  margin-top: 0.25rem;
  width: 17px;
  height: 17px;
  cursor: pointer;
  flex-shrink: 0;
  accent-color: #2c2c2c;
}

.question-item label {
  cursor: pointer;
  flex: 1;
  user-select: none;
  color: #2c2c2c;
  font-size: 1rem;
  line-height: 1.4;
}

/* Buttons */
.button-container {
  display: flex;
  gap: 2rem;
  justify-content: center;
  margin: 3rem 0;
  flex-wrap: wrap;
}

.btn {
  padding: 1.2rem 4rem;
  font-size: 1.2rem;
  font-weight: normal;
  border: 2px solid #2c2c2c;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s;
  font-family: "Georgia", serif;
}

.btn-calculate {
  background-color: #c8e6c9;
  color: #2c2c2c;
}

.btn-calculate:hover {
  background-color: #a5d6a7;
  transform: translateY(-2px);
}

.btn-clear {
  background-color: #c8e6c9;
  color: #2c2c2c;
}

.btn-clear:hover {
  background-color: #a5d6a7;
  transform: translateY(-2px);
}

/* Info Section */
.info-section {
  background-color: #fbeec8;
  padding: 2.5rem 2rem;
  margin: 3rem 0;
}

.info-section h2 {
  color: #2c2c2c;
  font-size: 2rem;
  margin-bottom: 1.5rem;
  font-weight: normal;
}

.info-section p {
  margin-bottom: 1rem;
  color: #4a4a4a;
  font-size: 1.05rem;
  line-height: 1.8;
}

/* Footer */
footer {
  background-color: #fbeec8;
  color: #2c2c2c;
  padding: 3rem 2rem;
  margin-top: 4rem;
  border-top: 2px solid #2c2c2c;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

.footer-section h3 {
  margin-bottom: 1rem;
  font-size: 1.3rem;
  font-weight: normal;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-links a {
  color: #4a4a4a;
  text-decoration: none;
  transition: color 0.3s;
  font-size: 1rem;
}

.footer-links a:hover {
  color: #2c2c2c;
}

/* Responsive Design */
@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fbeec8;
    flex-direction: column;
    padding: 1rem;
    border-bottom: 2px solid #2c2c2c;
  }

  .nav-links.active {
    display: flex;
  }

  .mobile-menu-btn {
    display: block;
  }

  /* Mobile Hero Section - Matching the reference design */
  .hero {
    padding: 2rem 1rem 3rem;
  }

  .hero-title-container {
    margin-bottom: 1rem;
    gap: 0.5rem;
    position: relative;
  }

  .hero-title-text {
    font-size: 1.4rem;
    white-space: normal;
    line-height: 1.3;
  }

  .title-line {
    max-width: 60px;
    min-width: 40px;
  }

  .hand-icon {
    font-size: 1.8rem;
  }

  .the-real {
    font-size: 1.3rem;
    position: absolute;
    left: 12px;
    top: -15px;
    margin-bottom: 0;
    display: inline-block;
    z-index: 10;
    transform: rotate(-20deg);
  }

  .main-heading {
    font-size: 1.4rem;
    line-height: 1.4;
    margin-bottom: 1rem;
    margin-top: 1rem;
  }

  .hero-description {
    font-size: 0.9rem;
    line-height: 1.7;
    padding: 0 0.5rem;
  }

  .score-number {
    font-size: 5rem;
  }

  .btn {
    padding: 1rem 2rem;
    font-size: 1rem;
  }

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

  .btn {
    width: 100%;
    max-width: 350px;
  }

  .questions-container {
    padding: 1rem 0.25rem;
  }

  .question-item {
    padding: 0.3rem 0;
  }

  .question-number {
    min-width: 30px;
    font-size: 0.95rem;
  }

  .question-item label {
    font-size: 0.95rem;
  }
}

/* Scroll to top button */
#scrollTop {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: #c8e6c9;
  color: #2c2c2c;
  border: 2px solid #2c2c2c;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 999;
  transition: all 0.3s;
}

#scrollTop:hover {
  background-color: #a5d6a7;
  transform: translateY(-3px);
}

#scrollTop.show {
  display: block;
}
/* Footer Sections */
.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.footer-section h3 {
  margin-bottom: 1rem;
  font-size: 1.3rem;
  font-weight: normal;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-links a {
  color: #4a4a4a;
  text-decoration: none;
  transition: color 0.3s;
  font-size: 1rem;
}

.footer-links a:hover {
  color: #2c2c2c;
}

.footer-section p {
  color: #4a4a4a;
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 0.5rem;
}

/* Responsive Footer */
@media (min-width: 768px) {
  .footer-content {
    flex-direction: row;
    justify-content: space-around;
    text-align: left;
  }

  .footer-section {
    flex: 1;
    padding: 0 1rem;
  }
}

@media (max-width: 767px) {
  .footer-content {
    gap: 1.5rem;
  }

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