body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  color: #1c1c1c;
  font-size: 18px; /* larger base size */
}
.cf-spinner {
    width: 28px;
    height: 28px;
    border: 3px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-left-color: rgb(253, 141, 13);
    animation: spin 1s ease-in-out infinite;
    display: none; /* Initially hidden */
}

.cf-spinner.visible {
    display: block;
}

#cf-turnstile-checkbox.hidden + .cf-turnstile-label::before {
    display: none;
}

/* Preloader Styles */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    transition: opacity 0.5s ease;
    flex-direction: column;
}

.preloader.hidden {
    opacity: 0;
    pointer-events: none;
}

.logo {
    display: flex;
    align-items: center;
    width: 100px;
    height: 100px;
    margin-bottom: 24px;
}

.preloader-logo {
    width: 80px;
    margin-bottom: 24px;
    animation: float 2s ease-in-out infinite;
}

.preloader-text {
    font-size: 1.2rem;
    color: #333;
    position: relative;
    height: 30px;
    width: 250px;
    text-align: center;
}

.preloader-text .text-item {
    position: absolute;
    left: 0;
    right: 0;
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.preloader-text .text-item.active {
    opacity: 1;
    transform: translateY(0);
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Sidebar */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 170px; /* slightly wider */
  background: #f8f9fa;
  border-right: 1px solid #e0e0e0;
  padding: 32px 16px;
  box-sizing: border-box;
}

.nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav li {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 16px;
  padding: 14px 10px;
  border-radius: 6px;
  cursor: pointer;
  color: #212529;
}

.nav li i {
  font-size: 18px; /* larger icons */
}

.nav li.active,
.nav li:hover {
  background: #e9ecef;
}

/* Content */
.content-wrapper {
  margin-left: 170px; /* align with new sidebar width */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  text-align: center;
  transition: margin-left 0.3s ease;
}

.form-step {
  display: none;
  flex-direction: column;
  align-items: center;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.form-step.active {
  display: flex;
  opacity: 1;
  transform: translateY(0);
}

.form-step.reverse-animation {
    transform: translateY(-20px);
}

.content h1 {
  font-size: 32px;
  margin-bottom: 40px;
}

.form {
  width: 100%;
  max-width: 600px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form input,
.form select {
  padding: 16px 18px;
  font-size: 16px;
  border: 1px solid #d2d4d6;
  border-radius: 4px;
  width: 100%;
  box-sizing: border-box;
}

/* Custom select styling */
.form select {
  background: #f1f2f4 url("data:image/svg+xml,%3Csvg width='22' height='22' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 8L10 13L15 8' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 14px center;
  appearance: none;
  -webkit-appearance: none;
}

.form select:focus {
  outline: none;
  border-color: #bdbfc2;
}

.form select option {
  padding: 8px 16px;
  background: #fff;
}

.form select option:hover {
  background-color: #f1f2f4;
}

.form select option:checked {
  background-color: #e9ecef;
  font-weight: 500;
}

.form button {
  align-self: center;
  padding: 14px 40px;
  font-size: 16px;
  background: #d4a017;
  color: #ffffff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.form button:hover {
  opacity: 0.9;
}

.collapse-btn {
  position: absolute;
  top: 14px;
  right: -12px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid #d2d4d6;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.sidebar.collapsed .collapse-btn {
  transform: rotate(180deg);
}

.sidebar.collapsed {
  width: 70px;
}

.sidebar.collapsed .nav li {
  justify-content: center;
}

.sidebar.collapsed .nav li i {
  margin: 0;
}

.sidebar.collapsed .logo {
  display: none;
}


.sidebar.collapsed + .content-wrapper {
  margin-left: 70px;
}

.logo-link {
    text-decoration: none;
}

.mobile-menu-btn,
.close-sidebar-btn {
    display: none;
    position: absolute;
    top: 20px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
}

.mobile-menu-btn {
    left: 20px;
}

.close-sidebar-btn {
    right: 20px;
    color: #333;
}

.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 99;
}

.overlay.active {
    display: block;
}

@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        left: -280px;
        width: 280px;
        z-index: 100;
        transition: left 0.3s ease;
        height: 100%;
        box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    }

    .sidebar.open {
        left: 0;
    }

    .content-wrapper {
        margin-left: 0;
        padding: 60px 20px 20px;
    }

    .collapse-btn {
        display: none;
    }

    .mobile-menu-btn,
    .close-sidebar-btn {
        display: block;
    }

    #step2 h2,
    #step3 h2,
    #step4 h2,
    .content h1 {
        font-size: 1.8rem;
        margin-bottom: 24px;
    }

    .essay-options {
        flex-direction: column;
    }

    .option-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .content h1,
    #step2 h2,
    #step3 h2,
    #step4 h2 {
        font-size: 1.5rem;
    }

    .form input,
    .form select,
    .option-btn,
    .prev-btn,
    .continue-btn {
        font-size: 14px;
        padding: 12px 16px;
    }
}

/* 404 Page Styles */
.error-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    text-align: center;
    padding: 20px;
}

.error-container h1 {
    font-size: 8rem;
    font-weight: 700;
    margin: 0;
    color: #0d6efd;
}

.error-container h2 {
    font-size: 2rem;
    margin: 10px 0;
}

.error-container p {
    font-size: 1.2rem;
    color: #555;
    margin-bottom: 30px;
}

.error-container .continue-btn {
    text-decoration: none;
}

/* Tooltip language dropdown (simulate) */
.form select::-ms-expand {
  display: none;
}

/* Loading Spinner */
.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border-left-color: #0d6efd;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.loading-text {
    margin-bottom: 24px;
}

/* Step 2 Styles */
#step2 h2,
#step3 h2,
#step4 h2 {
  font-size: 28px;
  font-weight: 600;
  margin-bottom: 32px;
}

.essay-options {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.option-btn {
  padding: 10px 20px;
  font-size: 16px;
  border: 1px solid #d2d4d6;
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  transition: all 0.2s ease;
}

.option-btn.active,
.option-btn:hover {
  border-color: #0d6efd;
  background: #f1f5ff;
  color: #0d6efd;
}

.option-btn.active {
  box-shadow: 0 0 0 1px #0d6efd;
}

.word-count {
  font-size: 16px;
  color: #555;
  margin-bottom: 32px;
}

.navigation-buttons {
  display: flex;
  gap: 16px;
}

.prev-btn,
.continue-btn {
  padding: 12px 32px;
  font-size: 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.prev-btn {
  border: 1px solid #d2d4d6;
  background: #fff;
  color: #333;
}

.continue-btn {
  border: none;
  background: #d4a017;
  color: #fff;
}

.continue-btn:hover {
  opacity: 0.9;
} 