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

:root {
  --bg-primary: #0a0e1a;
  --bg-secondary: #1a1f2e;
  --bg-tertiary: #252b3d;
  --bg-tertiary-transparent: #252b3d80 ;
  --blue-dark: #1e40af;
  --blue-medium: #3b82f6;
  --blue-light: #60a5fa;
  --grey-dark: #374151;
  --grey-medium: #6b7280;
  --grey-light: #9ca3af;
  --yellow-accent: #fbbf24;
  --light-grey-accent: #e5e7eb;
  --text-primary: #f9fafb;
  --text-secondary: #d1d5db;
  --text-muted: #9ca3af;
  --border-color: rgba(107, 114, 128, 0.3);
  --glow-blue: rgba(59, 130, 246, 0.4);
  --glow-yellow: rgba(251, 191, 36, 0.3);
  --ravenclaw-bronze: #946b2d;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  overflow-y: hidden;
  margin: 0;
  padding: 3%;
}


.left-bar {
  width: 30vw;
  float: left;
  height: 100vh;
}

.profile-card {
  width: 100%;
  height: 50.5%;
  margin: auto;
  margin-left: 2%;
  margin-top: auto;
  background-color: var(--bg-tertiary);
  border: 1px solid var(--ravenclaw-bronze);
  color: #dadfe1;
  border-radius: 15px;
  padding: 10% 0%;
  text-align: center;
}

.profile-image {
  position: relative;
  height: 30vh;
  margin:8%;
  aspect-ratio: 1;
  border-radius: 50%;
  border: 5px outset var(--ravenclaw-bronze);
  object-fit: cover;
  background: #f0f0f0;
  align-self: center;
  float: clear;
}

    /* Tab buttons styling */
.tab-btn {
  display: block;
  width: 100%;
  padding: 7px 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  font-weight: 500;
  text-align: center;
  object-fit: cover;
}

.tab-btn:hover {
  background: linear-gradient(to right, transparent 0%, var(--glow-blue) 50%, transparent 100%);
  color: var(--light-grey-accent);
  border-color: var(--ravenclaw-bronze);
}

.tab-btn:active {
  background: rgba(148, 107, 45, 0.15);
  color: var(--ravenclaw-bronze);
  border-color: var(--ravenclaw-bronze);
  font-weight: 600;
}

.right-bar {
  width:60vw; height:100vh; float:right;  
}


.tab-section {
  width: 95%;
  height: 90%;
  margin: auto;
  margin-left: 2%;
  margin-top: auto;
  background-color: var(--bg-tertiary-transparent);
  border: 1px solid var(--ravenclaw-bronze);
  color: #dadfe1;
  border-radius: 15px;
  padding: 2.5%;
  text-align: center;
}

.tab-section .tab-content {
  display: none;
  height:100%;
  width:100%;
  animation: fadeIn 0.4s ease-in-out;
}

.tab-section .tab-content.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}



.divider {
  width: 100%;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--ravenclaw-bronze) 20%, var(--ravenclaw-bronze) 80%, transparent);
}


/* ABOUT SECTION */
.about-collapsible {  
  margin-top: 2em;
  background: var(--bg-tertiary); 
  border: 2px solid var(--copper-accent); 
  border-top: none; 
  padding: 0 20px; /* Remove top/bottom padding initially */
  overflow: auto;
  max-height: 0;
  transition: max-height 0.4s ease, padding 0.4s ease;
}

.about-collapsible.open {
  max-height: 700px;
  padding: 20px;
}


.inner-collapsible {
  text-align: left;
  color: var(--text-secondary); 
  border-left: 4px solid var(--metallic-gold); 
  padding: 5%;
  padding-left: 15px;
  position: relative;
  z-index: 3;
}

.inner-collapsible strong {
  color: var(--metallic-gold);
}

.about-plaque-all {
  width: 43%;
  float:right;
}

.about-plaque-section {
  margin-bottom: 2%;
}

.about-plaque {
  font-family: "Glass Antiqua", cursive;
  width: 100%;
  font-weight: 800;
  font-size: 18pt;
  color: var(--bg-primary);
  height: 2em;
  padding: 0.25em;
  cursor: pointer;
  float: right;
  background: var(--metallic-gold);
  padding:auto;
  position: relative;
  z-index: 1; 
}



#identity-arrow #appearance-arrow #personality-arrow #family-arrow #magic-arrow {
  float: right;
  transition: transform 0.3s ease;
  display: inline-block; /* Needed for transform to work */
}

#identity-content #appearance-content #personality-content #family-content #magic-content {
  position: relative;
}


    /* Responsive design */
@media (max-width: 768px) {
  body {
      padding: 1rem;
      overflow: auto;
  }
  
  .left-bar {
      width: 100%;
      float: none;
      height: auto;
      margin: auto;
      margin-bottom: 2rem;
  }
  
  .right-bar {
    width: 95%;
      float: none;
      height: auto;
      margin-bottom: 2rem;
      margin: auto;
    }
  
  .tab-section {
      width: 95%;
      float: none;
      margin: auto;
      height: auto;
  }
  
  .tab-nav {
      flex-wrap: wrap;
  }
  
  .tab-button {
      flex: none;
  }
}

.content-section {
  position:relative;
  height: 100%;
  width: 100%;
  overflow-x: hidden;
  overflow-y: hidden;
  padding: 0;
  }

.section-title {
  font-size: 2em;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 1rem;
  text-align: center;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  letter-spacing: 2px;
  position: relative;
}


/**************** TIMELINE SECTION ***************/
.timeline-wrapper {
  position: relative;
  height: 100%;
  width: 100%;
  overflow-y: auto;
  overflow-x: hidden;
}

#timeline-section::before {
  content: '';
  position: absolute;
  left: 1%;
  top: 5%;
  bottom: -2px;
  transform: translateX(-50%);
  width: 5px;
  height: 100%;
  background: var(--metallic-gold);
  margin-left: 0;
}

.timeline-item {
  position: relative;
  width: 100%;
  display: flex;
  align-items: flex-start;
}

.timeline-marker {
  text-align:center;
  font-size: 16pt;
  position: absolute;
  left: 1%;
  top: 20%;
  transform: translateX(-50%);
  color: var(--metallic-gold);
  background: var(--faux-transparent);
}

.timeline-happening {
  border: 3px outset var(--bg-primary);
  background: linear-gradient(135deg, var(--bg-primary) 60%, var(--bg-secondary) 80%, var(--bg-primary) 82%);
  padding: 1% 2%;
  width: 85%;
  position: relative;
  left: 3%;
  text-align: center;
  margin-bottom: 1rem;
}

.age-marker {
  position: absolute;
  display: inline-block;
  padding: 5px 12px;
  color: var(--bg-primary);
  top: 2px;
  left: 3px;
  font-size: 0.9em;
  font-weight: bold;
  background: linear-gradient(135deg, var(--copper-accent) 50%, #d29152 60%, var(--copper-accent) 80%);
  line-height: 1.8em;
}

.wos-marker {
  position: absolute;
  right: 3px;
  top: 2px;
  float:right;
  text-align: right;
  margin-right: 3px;
  color: var(--copper-accent);
  }

.timeline-happening-content {
  border: 3px groove var(--bg-primary);
  position:relative;
  padding: 2%;
  padding-bottom: 1em;
  padding-top: 2em;
  }
  
.timeline-happening-content  h3 {
  font-weight: bold;
  color: var(--text-secondary);
  }


.relations-wrapper {
  position: relative;
  height: 80%;
  width: 100%;
  padding: 2%;
  overflow-y: auto;
  }

.relations-decoration-divider {
  height: 5%;
  }

.relations-single h3 {
font-family: "Glass Antiqua";
font-size: 18pt;
color: var(--border-gold);
text-align: center;
}

.relations-single {
font-size: 11pt;
color: var(--text-muted);
text-align: justify;
}

.relations-single strong {
font-size: 11pt;
color: var(--metallic-gold);
}

.achievements-wrapper {
  display: grid;
  overflow-y: auto;
  height: 90%;
  width: 100%;
  gap: 15px;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: auto auto auto;
  }

.achievement {
  background: var(--bg-primary);
  border: 2px outset var(--metallic-gold);
  padding: 4%
  }


@media (max-width: 768px) {
  .achievements-wrapper {
      grid-template-columns: repeat(2, 1fr);
      
  }




