/* Custom overrides and additional styles for Situational Judgment Test and layout fixes */

/* Interview Simulator Navigation Button Hover Effect */
.interview-nav-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.5) !important;
}

/*
  Footer grid fix: ensure four columns on larger screens and responsive
  stacking on mobile. The parent ``.footer-grid`` uses CSS grid to
  distribute columns evenly with a gap. Each column inherits flex
  behaviour on smaller viewports.
*/
.site-footer .footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 3rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

.site-footer .footer-col {
  margin-bottom: 0;
}

.site-footer .container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Footer text and links */
.site-footer,
.site-footer h4,
.site-footer ul,
.site-footer li,
.site-footer a,
.site-footer a:link,
.site-footer a:visited {
  color: #e5e7eb;
}

.site-footer a:hover,
.site-footer a:active {
  color: #8B5CF6;
}

.site-footer h4 {
  color: #ffffff;
}

/* Remove bullet points from footer lists */
.site-footer ul {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

.site-footer li {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 0 0.75rem 0 !important;
}

/* Situational Judgment Test enhancements */
.sjt-question {
  background-color: #f9fbfd;
  padding: 1rem;
  border-radius: 4px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  margin-bottom: 1rem;
  font-size: 1.05rem;
}
.sjt-options {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1rem;
  font-size: 1rem;
}
.sjt-select-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.25rem;
}
.sjt-select-group select {
  padding: 0.4rem 0.6rem;
  border-radius: 4px;
  border: 1px solid #b3c2d1;
  font-size: 0.95rem;
}
#sjt-test-container {
  max-width: 800px;
  margin: 0 auto;
}
.sjt-controls {
  display: flex;
  justify-content: space-between;
  margin-top: 1rem;
}

/* Enhance the SJT header styling */
.test-section h2 {
  font-size: 1.6rem;
  margin-bottom: 0.5rem;
  color: #0f4c81;
}

.test-section p {
  font-size: 1rem;
  margin-bottom: 1rem;
}

/* SJT buttons */
#prev-btn, #next-btn, #submit-btn {
  padding: 0.5rem 1rem;
  border-radius: 4px;
  border: none;
  font-weight: 600;
  cursor: pointer;
  font-size: 0.95rem;
}
#prev-btn {
  background-color: #e0e6ed;
  color: #0f4c81;
}
#next-btn {
  background-color: #0f4c81;
  color: #ffffff;
}
#submit-btn {
  background-color: #27ae60;
  color: #ffffff;
}
#prev-btn:hover {
  background-color: #d3dbe4;
}
#next-btn:hover {
  background-color: #0c3c64;
}
#submit-btn:hover {
  background-color: #1e8a4d;
}

/* ============================================
   Occupational Category - Nested Subcategories
   ============================================ */

/* Container for subcategory items */
.nav-subcategory-list {
  list-style: none;
  margin: 0;
  padding: 0.5rem 0 0.75rem 0;
  background: rgba(248, 250, 252, 0.5);
}

.nav-subcategory {
  margin: 0;
}

/* Nested details element for subcategories */
.nav-subcategory-details {
  border: none;
  margin: 0;
  background: transparent;
}

.nav-subcategory-details summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1rem 0.625rem 2.5rem;
  color: #475569;
  font-weight: 600;
  font-size: 0.875rem;
  transition: all 0.15s ease;
  position: relative;
}

.nav-subcategory-details summary::-webkit-details-marker {
  display: none;
}

.nav-subcategory-details summary::after {
  content: '';
  position: absolute;
  right: 1rem;
  width: 6px;
  height: 6px;
  border-right: 2px solid #94a3b8;
  border-bottom: 2px solid #94a3b8;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.nav-subcategory-details[open] summary::after {
  transform: rotate(-135deg);
}

.nav-subcategory-details summary:hover {
  color: #059669;
  background: rgba(255, 255, 255, 0.6);
}

.nav-subcategory-details summary svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  opacity: 0.7;
}

.nav-subcategory-details summary:hover svg {
  opacity: 1;
}

/* Third-level items inside subcategories */
.nav-subcategory-details ul {
  list-style: none;
  margin: 0;
  padding: 0.25rem 0 0.5rem 0;
  background: rgba(240, 245, 250, 0.4);
}

.nav-subcategory-details ul li {
  margin: 0;
}

.nav-subcategory-details ul li a {
  display: block;
  padding: 0.5rem 1rem 0.5rem 4rem;
  color: #64748b;
  text-decoration: none;
  font-size: 0.8125rem;
  font-weight: 500;
  transition: all 0.15s ease;
  position: relative;
}

.nav-subcategory-details ul li a::before {
  content: '';
  position: absolute;
  left: 3.5rem;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 3px;
  background: #cbd5e1;
  border-radius: 50%;
  transition: all 0.15s ease;
}

.nav-subcategory-details ul li a:hover {
  color: #059669;
  background: rgba(255, 255, 255, 0.7);
}

.nav-subcategory-details ul li a:hover::before {
  background: #059669;
  box-shadow: 0 0 4px rgba(5, 150, 105, 0.4);
}

/* Coming Soon placeholder styling */
.coming-soon-item {
  display: block;
  padding: 0.5rem 1rem 0.5rem 4rem;
  color: #9ca3af;
  font-size: 0.8125rem;
  font-weight: 500;
  font-style: italic;
  position: relative;
}

.coming-soon-item::before {
  content: '○';
  position: absolute;
  left: 3.35rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.5rem;
  color: #d1d5db;
}

/* Smart Search Results */
.search-results {
    max-height: 400px;
    overflow-y: auto;
    background: white;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    border-radius: 12px;
    border: 1px solid #eee;
    padding: 0.5rem;
}

/* Dark mode for search results */
html[data-theme="dark"] .search-results {
    background: #1e1e32;
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

html[data-theme="dark"] .search-badge {
    background: #1f1f35;
    color: #94a3b8;
}

html[data-theme="dark"] .search-link:hover,
html[data-theme="dark"] .search-link:focus {
    background-color: #2a2a45;
}

html[data-theme="dark"] .search-status,
html[data-theme="dark"] .search-error,
html[data-theme="dark"] .no-results {
    color: #94a3b8;
}
.search-item {
    padding: 0;
    margin-bottom: 2px;
}
.search-link {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    color: #333;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s;
}
.search-link:hover, .search-link:focus {
    background-color: #f3f4f6;
    transform: translateX(2px);
}
.search-icon {
    font-size: 1.25rem;
    margin-right: 0.75rem;
    width: 24px;
    text-align: center;
}
.search-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}
.search-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: #1f2937;
}
.search-category {
    font-size: 0.75rem;
    font-weight: 500;
    margin-top: 2px;
}
.search-badge {
    font-size: 0.7rem;
    padding: 2px 6px;
    background: #f3f4f6;
    border-radius: 4px;
    color: #6b7280;
    margin-left: 8px;
    text-transform: uppercase;
}
.search-status, .search-error, .no-results {
    padding: 1rem;
    text-align: center;
    color: #6b7280;
    font-style: italic;
}
.search-more {
    text-align: center;
    padding: 0.5rem;
    border-top: 1px solid #f3f4f6;
    margin-top: 0.5rem;
}
.search-more a {
    color: #3b82f6;
    font-size: 0.85rem;
    font-weight: 500;
}
