/* ============================================================
   BIG FIVE PERSONALITY MASTER STYLESHEET
   Consolidated from agreeableness.html, conscientiousness.html,
   extraversion.html, neuroticism.html, openness.html
   ============================================================ */

/* ---------- RESET & BASE ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: #1a1a1a;
  color: #1e1e2a;
  line-height: 1.5;
  scroll-behavior: smooth;
}

/* ---------- BACKGROUND VIDEO LAYER ---------- */
#video-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  overflow: hidden;
  pointer-events: none;
}

#bg-video {
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  object-fit: cover;
  background-color: #000;
}

/* ---------- MAIN CONTAINER ---------- */
.container {
  position: relative;
  z-index: 1;
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
}

/* ---------- PAGE HEADER ---------- */
.page-header {
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid rgba(226, 217, 206, 0.5);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
}

.page-header h1 {
  font-size: 1.8rem;
  font-weight: 700;
  background: linear-gradient(135deg, #e0f0ff, #cbd5e1);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

.back-link {
  background: rgba(240, 235, 226, 0.8);
  backdrop-filter: blur(4px);
  padding: 0.4rem 1rem;
  border-radius: 2rem;
  font-size: 0.85rem;
  text-decoration: none;
  color: #5b4b34;
  font-weight: 500;
  transition: background 0.2s;
}

.back-link:hover {
  background: rgba(226, 213, 194, 0.9);
}

/* ---------- SCORE CARD ---------- */
.score-card {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(8px);
  border-radius: 1.5rem;
  padding: 1.8rem;
  margin-bottom: 2rem;
  border: 1px solid rgba(238, 231, 223, 0.6);
  text-align: center;
}

.score-number {
  font-size: 4rem;
  font-weight: 800;
  color: #c6a15b;
  line-height: 1;
}

.score-label {
  font-size: 1.2rem;
  font-weight: 600;
  color: #1a2c3a;
  margin-top: 0.5rem;
}

.score-level {
  display: inline-block;
  background: rgba(198, 161, 91, 0.2);
  padding: 0.3rem 1.2rem;
  border-radius: 2rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #c6a15b;
  margin-top: 0.75rem;
}

.score-raw {
  font-size: 0.85rem;
  color: #7b6b54;
  margin-top: 0.5rem;
}

/* Score Bar (for Neuroticism page) */
.score-bar-container {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 1rem;
  height: 1rem;
  width: 100%;
  margin: 1rem 0;
  overflow: hidden;
}

.score-bar {
  background: #c6a15b;
  height: 100%;
  width: 0%;
  border-radius: 1rem;
}

/* ---------- SECTIONS ---------- */
.section {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(8px);
  border-radius: 1.5rem;
  padding: 1.8rem;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(238, 231, 223, 0.6);
  transition: background 0.2s;
}

.section:hover {
  background: rgba(255, 255, 255, 0.85);
}

.section h2 {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 1rem;
  border-left: 4px solid #c6a15b;
  padding-left: 1rem;
  color: #1a2c3a;
}

.section h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 1rem 0 0.5rem;
  color: #a8713a;
}

.section p {
  font-size: 0.95rem;
  margin-bottom: 0.8rem;
  color: #2e2d2c;
  text-align: left;
}

.section ul {
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}

.section li {
  font-size: 0.92rem;
  margin-bottom: 0.4rem;
  color: #2e2d2c;
}

/* ---------- SUB-SCORES GRID ---------- */
.subscores {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.subscore-item {
  background: rgba(248, 249, 250, 0.8);
  border-radius: 1rem;
  padding: 0.8rem 1rem;
}

.subscore-name {
  font-weight: 600;
  color: #1a2c3a;
  margin-bottom: 0.3rem;
}

.subscore-value {
  font-size: 0.85rem;
  color: #c6a15b;
  font-weight: 600;
}

.subscore-description {
  font-size: 0.8rem;
  margin-top: 0.5rem;
  color: #4b5563;
}

/* Sub-score Bar (for Neuroticism page) */
.subscore-bar {
  height: 0.5rem;
  background: rgba(0, 0, 0, 0.1);
  border-radius: 0.5rem;
  margin-top: 0.4rem;
  overflow: hidden;
}

.subscore-fill {
  height: 100%;
  background: #c6a15b;
  width: 0%;
  border-radius: 0.5rem;
}

/* ---------- TRAIT IMAGE ---------- */
.trait-image {
  margin: 1.5rem 0;
  text-align: center;
}

.trait-image img {
  max-width: 100%;
  height: auto;
  border-radius: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* ---------- ORIGINAL LINK ---------- */
.original-link {
  font-size: 0.7rem;
  word-break: break-all;
  margin-top: 0.5rem;
}

.original-link a {
  color: #c6a15b;
  text-decoration: none;
}

.original-link a:hover {
  text-decoration: underline;
}

/* ---------- FOOTER ---------- */
.footer {
  margin-top: 2rem;
  text-align: center;
  font-size: 0.75rem;
  color: #cfcdc0;
  border-top: 1px solid rgba(226, 217, 205, 0.5);
  padding-top: 2rem;
}

hr {
  margin: 1rem 0;
  border: none;
  border-top: 1px solid rgba(228, 219, 207, 0.5);
}

/* ---------- RESPONSIVE DESIGN ---------- */
@media (max-width: 640px) {
  .container {
    padding: 1rem;
  }
  
  .score-number {
    font-size: 2.5rem;
  }
  
  .subscores {
    grid-template-columns: 1fr;
  }
  
  .page-header h1 {
    font-size: 1.3rem;
  }
}

/* ---------- PRINT STYLES ---------- */
@media print {
  #video-container {
    display: none;
  }
  
  body {
    background: white;
  }
  
  .section,
  .score-card {
    background: white;
    backdrop-filter: none;
    border: 1px solid #ccc;
  }
  
  .back-link {
    display: none;
  }
}