body {
  margin: 0;
  padding: 0;
  background: var(--bg-color);
  color: var(--text-color);
  font-family: helvetica, sans-serif;
  line-height: 1.5rem;
}
body:has(#nudity:checked) .box:not(.nudity),
body:has(#notnudity:checked) .nudity,

body:has(#fatart:checked) .box:not(.fatart),
body:has(#notfatart:checked) .fatart,

body:has(#queerart:checked) .box:not(.queerart),
body:has(#notqueerart:checked) .queerart,

body:has(#witchyart:checked) .box:not(.witchyart),
body:has(#notfanart:checked) .witchyart,

body:has(#fantasy:checked) .box:not(.fantasy),
body:has(#notfantasy:checked) .fantasy,

body:has(#originalart:checked) .box:not(.originalart),
body:has(#notoriginalart:checked) .originalart,

body:has(#trinity:checked) .box:not(.trinity),
body:has(#nottrinity:checked) .trinity,

body:has(#sunny:checked) .box:not(.sunnylee),
body:has(#notsunny:checked) .sunnylee,

body:has(#diamond:checked) .box:not(.diamond),
body:has(#notdiamond:checked) .diamond,

body:has(#pearl:checked) .box:not(.pearl),
body:has(#notpearl:checked) .pearl,

body:has(#fanart:checked) .box:not(.fanart),
body:has(#notfanart:checked) .fanart,

body:has(#qt:checked) .box:not(.queensthief),
body:has(#notqt:checked) .queensthief,

body:has(#tp:checked) .box:not(.treasureplanet),
body:has(#nottp:checked) .treasureplanet,

body:has(#hmc:checked) .box:not(.howlsmc),
body:has(#nothmc:checked) .howlsmc

 {display: none;}


/*Custom styling for headers.*/
h1, h2, h3 {
  font-family: helvetica, sans-serif;
  line-height: 2rem;
}

h3, h4 {
  margin-top: 2rem;
}

h1, h2 {
  color: var(--header-color);
}

h3, h4 {
  color: var(--header-color2);
}

h4 {
  text-decoration:double;
  text-decoration-line: underline;
}

/*Custom styling for links (not stylized elsewhere like in title and sidebar).*/
a {
  color: var(--link-color);
}

a:hover, a:focus {
  color: var(--link-select-color);
  transition: ease-in 0.2s, ease-out 0.2s;
}

a:visited {
color: var(--text-color);
  transition: ease-in 0.2s, ease-out 0.2s;
}
  
/*Miscellanous custom styling for various elements.*/
blockquote {
  border-left: var(--blockqline-color) 3px solid;
  background: var(--post-bg-color);
  padding: 0.1px 0.75rem;
  margin: 0 1.5rem;
}

hr {
  width: 75%;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}

/* changes the color of bolded text - I mostly add this to help with scannability for adhd folk */
b {
color: var(--link-color);
}

/* element used for tags - default highlights text in yellow */
mark {
  font-size: .9rem;
  background-color: var(--bg-color);
  color: var(--post-text-color);
  padding: 4px;
  
}

.nobottom {
  border-bottom: 0px solid var(--blockqline-color);
}
fieldset {
  margin: 0px;
  padding-right: 0;
  padding-left: 0;
  padding-top: 0px;
  border-bottom: 2px solid var(--blockqline-color);
  border-top: 0 solid var(--blockqline-color);
  border-right: 0 solid var(--blockqline-color);
  border-left: 0 solid var(--blockqline-color);
}

details {
  background-color: var(--post-bg-color);
}
input[type="radio"] {
  accent-color: var(--blockqline-color);
}

/*Header image.*/
.header, .title, .main {
  margin-right: 72px;
  margin-left: 422px; /* sidebar width + right margin */
  width: calc(100% - 494px); /* second number is left margin + right margin*/
}

.header {
  margin-top: 16px;
  margin-bottom: 0px;
  height: 344px;
  text-align: center;
  overflow: hidden;
  border-top-left-radius: 5px;
  border-top-right-radius: 5px;
}

.header img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}


/*Title bar with icon, title, description, and all caps links.*/
.title {
  margin-top: 0px;
  min-height: 64px;
  margin-bottom: 0px;
  text-align: center;
  color: var(--text-color);
}

.title h1, .title h2 {
  color: var(--text-color);
}

.title-links a {
  text-transform: uppercase;
  font-size: .85rem;
  text-decoration: none;
  color: var(--link-color)
}

.title a:hover, .title a:focus {
  text-decoration:underline;
  color: var(--link-color)
    
}

.title a:visited {
  color: var(--link-color);
}
  
.title-pic {
  padding:0;
  margin: 0;
  display: inline-block;
  vertical-align: top;
  height: 96px;
  margin-top: -72px;
  border: 5px solid var(--bg-color);
  border-radius: 10px;
}
  
.title-pic img {
  height: 100%;
  overflow: hidden;
}
  

/*Contains the main content and sidebar.*/
.page-wrapper {
  padding: 0;
  margin: 0;
}


/*Contains the sidebar box named side-box.*/
.sidebar {
  margin: 0px;
  width: 350px;
  position:fixed;
  top: 0px;
  
}
  
.sidebar h2 {
  background: var(--bg-color);
  color: var(--text-color);
  padding: 16px 8px 8px 8px;
  margin: auto;
  text-align: center;
  position: sticky;
  top: 0;
}
  
/*Button styling. A touch target (ie anything that you try to click on mobile) needs to be at least 36px to be accessibile.*/

.main .accent-button a {
 width: fit-content;
 padding: 8px 32px;
}

.button a, .button a:visited, .accent-button a, .accent-button a:visited {
  display: block;
  padding: 8px;
  margin: 8px 0;
  text-decoration: none;
  text-align: center;
  border-radius: 25px;
}

.button a {
  background: var(--post-bg-color);
}

.button a:hover, .button a:focus {
  background: var(--bg-color);
  transition: ease-in 0.2s, ease-out 0.2s;
}

.accent-button a {
  background: var(--link-color); 
}

.accent-button a {
 color: var(--bg-color);
}

.accent-button a:hover, .accent-button a:focus {
 background: var(--text-color); 
 color: var(--bg-color);
}

.accent-button b {
 color: var(--bg-color);
}

/*Contains main content boxes.*/
.main {
  margin-top: 48px;
  margin-bottom: 48px;
}
.main, .sidebar {
  display: inline-block;
}
  
/*Basic container type for subsections of main and sidebar divs*/
.box, .side-box {
  margin-bottom: 16px;
}
  
/*Inner content div for boxes. Padding goes here so sidebar headers etc can keep their no-margin look.*/
.inner {
  padding: 8px 24px;
  background: var(--post-bg-color);
  color: var(--post-text-color);
}

.side-inner {
  padding: 0px 24px 16px 24px;
  background: var(--bg-color);
  color: var(--text-color);
  height: calc(100% - 16px);
  overflow-y: scroll;
  scrollbar-color:  var(--blockqline-color) var(--bg-color);
}

.side-box {
  height: 100vh;
}

.img {
  width: 100%;
  padding: 16px;
  display: flex;
  justify-content: space-around;
img {width: 45%; box-sizing: border-box;}
}

.inner img, .side-inner img {
  max-width: 100%; /*Prevent image overflow.*/
  height: auto;
  border-radius: 5px; /*Give images in content rounded corners.*/
}
  
.box, .side-box, .title-pic img {
  border-radius: 5px;
  overflow: hidden; /*Force inner divs to conform to rounded corners.*/
}
  


/* styling of the tags area at the top of the post */
.tags {
border-bottom: 3px solid var(--blockqline-color);
margin: 0 -24px;
padding: 0 24px;
}
  
/*Footer section.*/
.footer {
  background: var(--bg-color);
  color: var(--text-color);
  padding: 16px 64px 16px 32px;
  font-size: 1rem;
  padding-bottom: 10px;
  text-align: left;
}
  
.footer a {
  color: var(--link-color);
}

.footer a:hover, .footer a:focus {
  color: var(--link-select-color);
  transition: ease-in 0.2s, ease-out 0.2s;
}

/*Topicon wraps the svg code that becomes the 'back to top' icon sitting at the bottom right of the screen. I converted it to code so it will always be the link color*/
.topicon {
 position:fixed;
 bottom: 16px;
 right: 16px;
}

/*Adapt to narrower screens.*/
@media(max-width: 850px) {  

 .header {
    margin-top: 16px;
    margin-bottom: 0px;
    height: 250px;
  }

  .header, .title {
    margin-right: 72px;
    margin-left: 72px;
    width: calc(100% - 144px);
  }

  .page-wrapper {
    padding: .1px 0;
    margin: 0 72px; /* same right and left margin as .header */
  }
  
  .sidebar, .main {
    display: block;
    position: static;
    margin-right:auto;
    margin-left:auto;
    width: 100%;    
  }
    
  .sidebar {
    position:auto;
    margin-top: 16px;
  }
  
  .sidebar h2 {
    background: var(--bg-color);
    color: var(--text-color);
    padding: 8px;
    margin: 8px;
    text-align: center;
    position: auto;
  }
    
  .side-inner {
    overflow-y: auto;
    scrollbar-color:  var(--blockqline-color) var(--bg-color);
    height: auto;
    padding-top: 0px;
    background:  var(--bg-color);
    color: var(--text-color);
  }

  .side-box {
    height: auto;
  }

  .main {
    margin-top: 32px;
    margin-bottom: 32px;
  }
    
}



/*Adapt to even narrower screens and mobile*/
@media(orientation: portrait) {  
  .header {
    margin: 0;
    width: 100%;
    height: 200px;
    border-radius: 0px;
  }

  .title {
    margin-left: 0px;
    width: calc(100% - 48px);
    padding: 0 24px;
  }

  .title-pic {
    height: 72px;
    margin-top: -52px;
    border-radius: 10px;
  }

  .page-wrapper {
    padding: .1px 0px;
    margin: 0px;
  }
  
  .sidebar, .main {
    display: block;
    margin-right: 8px;
    margin-left: 8px;
    position: auto;
    width: calc(100% - 16px);    
  }

  .sidebar {
  margin-top: 0px;
  }
    
  .sidebar h2 {
    background: var(--bg-color);
    color: var(--text-color);
    padding: 8px;
    margin: 8px;
    text-align: center;
    position: auto;
  }

  .side-box {
    height: auto;
  }
  
  .side-inner {
    overflow-y: auto;
    height: auto;
    padding-top: 0px;
  }

  .main {
    margin-top: 32px;
    margin-bottom: 32px;
  }
    
  }
  
