/* ==========================================================================
   CJ Consultancy Services Ltd — Modern Stylesheet
   ========================================================================== */

:root {
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --brand-dark: #0f172a;
  --brand-navy: #1e3a8a;
  --brand-blue: #0284c7;
  --brand-blue-hover: #0369a1;
  --border-color: #e2e8f0;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px -2px rgba(0, 0, 0, 0.08);
  --radius: 8px;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.65;
  touch-action: auto;
}

/* LOGO BAND */
.logo-band {
  background: var(--brand-dark);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 24px 20px;
  text-align: center;
}

.logo-band img {
  max-height: 150px;
  width: auto;
  display: block;
  margin: 0 auto;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

/* NAVIGATION BAR */
.main-nav {
  width: 100%;
  background: #111827;
  border-bottom: 3px solid var(--brand-blue);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-md);
}

.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 6px 12px;
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.main-nav a {
  color: #94a3b8;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 10px 16px;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.main-nav a:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.main-nav a.active {
  color: #ffffff;
  background: var(--brand-blue);
}

/* MAIN CONTENT CONTAINER */
main {
  max-width: 960px;
  margin: 40px auto;
  padding: 32px;
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-md);
  margin-bottom: 140px; /* Prevents overlap with fixed footer */
}

/* TYPOGRAPHY */
h1 {
  font-size: 2.1rem;
  color: var(--brand-dark);
  margin-top: 0;
  margin-bottom: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 12px;
}

h2 {
  font-size: 1.4rem;
  color: var(--brand-navy);
  margin-top: 36px;
  margin-bottom: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

p {
  margin-bottom: 16px;
  color: var(--text-main);
  font-size: 1.05rem;
}

p strong {
  color: var(--brand-dark);
}

a {
  color: var(--brand-blue);
  text-decoration: none;
  font-weight: 500;
}

a:hover {
  text-decoration: underline;
}

/* BULLET LISTS & FEATURED SERVICES */
ul {
  padding-left: 20px;
  margin-bottom: 24px;
}

li {
  margin-bottom: 8px;
  color: var(--text-main);
  font-size: 1.02rem;
}

/* INDEX & SERVICES PARAGRAPH BLOCKS */
main > p > strong {
  display: inline-block;
  font-size: 1.1rem;
  color: var(--brand-dark);
}

/* UN THEORY INDEX CONTROLS */
.search-box {
  width: 100%;
  padding: 12px 16px;
  font-size: 0.95rem;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  background-color: #f1f5f9;
  color: var(--text-main);
  margin-bottom: 16px;
}

.dropdown-box {
  width: 100%;
  padding: 8px;
  font-size: 0.95rem;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  background: #ffffff;
  color: var(--text-main);
  margin-bottom: 24px;
}

.dropdown-box option {
  padding: 6px 10px;
}

.button-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
}

.button-row a,
.button-row button {
  background: var(--brand-dark);
  color: #ffffff !important;
  padding: 10px 18px;
  font-size: 0.92rem;
  font-weight: 600;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.1s ease;
  display: inline-flex;
  align-items: center;
}

.button-row a:hover,
.button-row button:hover {
  background: var(--brand-navy);
  text-decoration: none;
}

#openZenodo {
  background: var(--brand-blue) !important;
}

#openZenodo:hover {
  background: var(--brand-blue-hover) !important;
}

/* FOOTER - FIXED BOTTOM */
.site-footer {
  text-align: center;
  padding: 18px 20px;
  background: var(--brand-dark);
  color: #94a3b8;
  font-size: 0.9rem;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 90;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 -2px 10px rgba(0,0,0,0.15);
}

/* RESPONSIVE DESIGN */
@media (max-width: 768px) {
  .logo-band img {
    max-height: 100px;
  }

  .main-nav ul {
    gap: 6px;
    padding: 8px;
  }

  .main-nav a {
    font-size: 0.85rem;
    padding: 8px 10px;
  }

  main {
    margin: 16px 12px 140px 12px;
    padding: 20px 16px;
  }

  h1 {
    font-size: 1.6rem;
  }

  h2 {
    font-size: 1.25rem;
  }

  .button-row {
    flex-direction: column;
  }

  .button-row a,
  .button-row button {
    width: 100%;
    justify-content: center;
  }
}
