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

html {
  font-size: 9px;
}

/* For small screens */
@media only screen and (max-width: 600px) {
  html {
    font-size: 3.78px;
  }
}
  
body {
  /*font-family: "Helvetica Neue", Arial, sans-serif;*/
  line-height: 1.6;
  margin: 4rem;
  background-color: #f5f5f5; /* light gray or off-white */
  font-family: Arial, sans-serif;
  color: #333;
}

/* Button (could be an <a>, <button>, etc.) */
.button {
  float: right;
  background: transparent;
  border: 0.25rem solid #000000;
  color: #000000;
  text-decoration: none;
  padding: 0.2rem 0.8rem;
  border-radius: 4px;
  font-size: 2rem;
  cursor: pointer;
  transition: background 0.2s;
  margin-right: 0.4rem;
  position: relative;
  top: -3.6rem;
}

.button.tags {
  font-size: 2.4rem;
  padding: 0.2rem 0.4rem;
}
.button.tags.active {
  background-color: #888888;
}

.button-text {
  border: none;
  float: right;
  background: transparent;
  color: #000000;
  padding: 0.8rem 1.6rem;
  border-radius: 4px;
  font-size: 2rem;
  margin-right: 0.4rem;
  position: relative;
  top: -3.6rem;
}

/* Go back button on the left */
.goback {
  float: left;
  font-size: 2.9rem;
  padding: 0.05rem 0.8rem;
  top: -4.4rem;
}

/* Hover effect for the button */
.button:hover {
  background: #dfdfdf;
}

.transposition-controls {
  margin: 0em 0;
}
.transposition-controls .button {
  padding: 0.2rem 0.8rem;
  margin: 0 0.6rem;
  cursor: pointer;
  font-size: 3rem;
  top: -4.2rem;
}
/* Highlight the active accidental */
.transposition-controls .active {
  background-color: #888888;
}

.logo {
  height: 6.2rem;
  float: left;
  background: transparent;
  top: -6.6rem;
  position: relative;
  margin-right: 0.6rem;
}

/* Title */
h1 {
  margin: 0;        /* remove default h1 margin */
  font-size: 2.6rem;
  flex: 1;          /* take up remaining space */
  text-align: center;
  margin-bottom: 4.8rem;
  display: flex;
  align-items: center;
}

h2 {
    margin: 0;        /* remove default h1 margin */
    font-size: 2rem;
    flex: 1;          /* take up remaining space */
    text-align: center;
    display: flex;
    align-items: center;
    margin-top: 4rem;   /* space before author heading */
    margin-bottom: 0px; /* small gap after heading */
    font-weight: normal;
    padding-bottom: 0px;        /* space between text and line */
  }

/* The list for songs under each author */
ul {
    list-style: none;      /* remove bullets */
    padding-left: 0;       /* remove default indent */
    margin-bottom: 3rem; /* space after the list */
    text-align: left;
}

/* Each list item - small vertical space */
li {
  margin: 0.6rem 0;
}

/* Links for each song */
li a {
  text-decoration: none;
  color: #007acc; /* nice link color */
  font-size: 1.75rem;
}

li a:hover {
  text-decoration: underline;
}

/* Divide the listing into 2 columns */
#listContainer {
  gap: 4rem4;
  column-count: 2;
  column-gap: 3.4rem;
}

/* Divide display into 2 columns */
#songDoubleColumn {
  column-count: 2;
  column-gap: 3.4rem;
}

#songCount {
  float: right;
  color: #000000;
  padding: 0.8rem 1.6rem;
  font-size: 1.8rem;
  margin-right: 0.4rem;
  position: relative;
  top: -3.6rem;
}

/* Prevent groups from being split between columns */
.author-group {
  break-inside: avoid;
  margin-bottom: 2rem;
}

/* Main container that centers the "sheet" on the page */
.container {
  max-width: 700px;   /* how wide you want your "sheet" */
  margin: auto;  /* auto left/right => centered, 2rem top/bottom gap */
  background-color: #fff;   /* white "sheet" background */
  border-radius: 8px;       /* soften corners if you like */
  box-shadow: 0 0 10px rgba(0,0,0,0.1); /* subtle shadow */
  padding-top: 4.2rem;
  padding-right: 2.5rem;
  padding-bottom: 3.5rem;
  padding-left: 2.5rem;
}

/* A little spacing for paragraphs inside the container */
.container p {
  margin: 2rem 0;
  line-height: 1.6;
  font-size: 1.75rem;
}

.emptyContainer {
  max-width: 700px;   /* how wide you want your "sheet" */
  margin: auto;  /* auto left/right => centered, 2rem top/bottom gap */
  padding-top: 4rem;
  padding-right: 3rem;
  padding-bottom: 2rem;
  padding-left: 3rem;

}

.emptyContainer.small {
  padding-top: 2rem;
  padding-right: 3rem;
  padding-bottom: 1rem;
  padding-left: 3rem;
}

/* PARTS (verses, choruses, etc.) */
/* This class applies a margin after each part */
.part {
  margin-bottom: 4rem; /* space between parts */
  break-inside: avoid; /* for columns */
}
/* Verse styling */
.part.verse p {
  color: #000; /* black text */
  margin: 7px 0;
}
/* Chorus styling */
.part.chorus p {
  color: #9e1766;
  margin: 0.875rem 0;
}

.chord-block {
    display: inline-flex;   /* Let it flow inline with surrounding text */
    flex-direction: column-reverse;
    vertical-align: baseline; /* Align the table’s baseline with surrounding text */
    position: relative;
    top: -1.95rem;
    align-items: center;
    color: inherit;
    border-collapse: collapse; /* Remove extra cell spacing */
    margin-right: 0.6rem;     /* spacing after the pair */
    gap: 0.2rem; /* separate chord and lyric */
  }
.chord-block > * {
  margin: 0; 
  padding: 0; 
  line-height: 1; 
}
.chord-inline {
  display: inline-flex;
  flex-direction: row; /* horizontal layout */
  align-items: center;
  gap: 0.8rem; /* small gap between chords */
}

/* The chord goes in the first (top) row */
.chord {
  color: #1f78b4;
  font-weight: bold;
  line-height: 1;  /* so it doesn’t push the row’s height too large */
  font-size: 1.56rem;
}

.complement {
  color: #1f78b4;
  font-weight: bold;
  line-height: 1;  /* so it doesn’t push the row’s height too large */
  font-size: 1.28rem;
  position: relative;
  top: -0.6rem;  /* adjust this value as needed */
  /*
  vertical-align: super; /* or adjust as needed */
}

.bass{
  color: #30b34d;
  font-size: 1.38rem;
}

/* The lyric goes in the second (bottom) row */
.lyric {
  /* Usually inherits color (black or red) from the verse/chorus container */
  font-size: 1.75rem;
}

/* For parenthesized chords (C) */
.chord-block.optional .chord {
  /*color: gray; /* or a lighter weight, etc. */
  font-style: italic;
  font-size: 1.2rem;
}

/* Grey when italic */
igrey {
    font-style: italic;
    color: #6b6b6b
}
gpurple {
  color: #9e1766;
}

/* Loading spinner */
#loadingMsg::after {
  content: "";
  display: inline-block;
  width: 2rem;
  height: 2rem;
  border: 0.25rem solid #333;
  border-top: 0.25rem solid transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-left: 1rem;
}
@keyframes spin {
  100% { transform: rotate(360deg); }
}
