
/* Stylesheet written by Herman Malik <3 */

/* //////////////////////////////////////// PAGE LAYOUT /////////////////////////////////////////// */
#container {
  max-width:1200px;
  margin-top:40px;
  margin-left:auto;
  margin-right:auto;
  padding-left: 2%;
  padding-right:2%;
  width: 80%;
  min-height: 95vh;
  /* position: relative; */
  @media (max-width:430px) {
    width: 90%;
  }
}

section {
  margin-bottom:25px;
  margin-left: auto;
}

@media(min-width:600px) {
section {
  margin-bottom:25px;
}
}
@media(max-width:600px) {
section {
  margin-bottom:10px;
}
}

/* #content-wrap {
  padding-bottom: 12rem;  
}

/* work on fixing footer on short pages later
footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  height: 12rem;
} */ 
footer {
  max-width: 600px;
  margin: auto;
  text-align:center;
  color: gray;
}


/* /////////////////////////////////// FONTS, COLORS ////////////////////////////////////////////// */
/* Colors */
body {
  --theme-color: rgb(0, 50, 98);
  --text-color: #111;
  --bkg-color: #f4f3f2;
  --bkg-color-light: #eaeaea;
  --bkg-color-lighter: #ddd;
  --link-color: #219ab3 /* #19778A */;
  --link-hover-color: #193D86;
  --menu-item-color: #ddd; /* #FDB515; */

  --table-bkg-color: #f0f0f0;
  --table-side-one: var(--bkg-color-light);
  --table-side-two: rgba(255,255,255,0);

  --flexbox-bkg-color: #f0eeed; 
  --flexbox-side-one: var(--bkg-color);
  --flexbox-side-two: rgba(255,255,255,0);

  --mailform-border-color: #ABB032;
}
body.dark-theme {
  --theme-color: rgb(0, 63, 121);
  /* --theme-color: rgb(0, 39, 76); I'm actually stupid at design I think lighter is better but idk */
  --text-color: #eee;
  --bkg-color: rgb(24, 26, 28);
  --bkg-color-light: rgb(35,38,41);
  --bkg-color-lighter: rgb(40,43,46);
  --link-color: #219ab3;
  --link-hover-color: #11505d;
  --menu-item-color: #eee;

  --table-bkg-color: rgb(30,32,34);
  --table-side-one: var(--bkg-color);
  --table-side-two: var(--table-bkg-color);
  
  --flexbox-bkg-color: rgb(30,32,34);
  --flexbox-side-one: var(--bkg-color);
  --flexbox-side-two: var(--bkg-color);

  --mailform-border-color: #ABB032;
}

body {
  background: var(--bkg-color);
  color: var(--text-color);
}

/* Fonts */
body {
    font-family: "Poppins", "Avenir Next", "Open Sans", Helvetica, Arial, sans-serif;
    /* background: url(../img/new-background.jpg) 0 0 repeat; */
}
input {
  font-family: "Poppins", "Avenir Next", "Open Sans", Helvetica, Arial, sans-serif;
}


/* /////////////////////////////////// TEXT, LINKS //////////////////////////////////////////////// */
/* Headers */
h1, h2, h3, h4, h5, h6 {
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 1px;
}

h1 {
    font-size: 2em;
    margin-block-start: 0em;
    margin-block-end: 0.5em;
    padding: 0.5em 0 0 0;
    text-align: center;
    @media (max-width:600px) {
      font-size: 1.5em;
    }
}

h2 {
  font-size: 1.4em;
  margin-block-start: 0.8em;
  margin-block-end: 1.3em;
  padding: 0.5em 0 0 0;
  text-align: center; 
  @media (max-width:600px) {
    font-size: 1.25em;
  }
}

h3 {
  font-size: 1.2em;
  margin-block-start: 1.4em;
  margin-block-end: 1.4em;
  @media (max-width:600px) {
    font-size: 1.1em;
  }
}

h4, h5, h6 {
  font-size: 1em;
  margin-block-start: 1em;
  margin-block-end: 1em;
  @media (max-width:600px) {
    font-size: 0.9em;
  }
}


/* Body Text, List Text, Table Text */
p, li {
  font-size: 0.9em;
  line-height: 1.5;
  text-align: left;
}
th, td {
  font-size: 0.85em;
  line-height: 1.2;
}

@media(min-width:600px) {
  p, li {
      font-size: 1em;
      line-height: 1.8;
  }
  th, td {
    font-size: 0.9em;
    line-height: 1.5;
  }
}

/* Footer Text */
footer p {
  font-size: .8em;
  text-align: center;
}

/* Links */
a {
  color: var(--link-color);
  -webkit-transition: all .2s ease-in-out;
  -moz-transition: all .2s ease-in-out;
  transition: all .2s ease-in-out;
      text-decoration: none;
}

a:hover, a:focus, a:active {
  color: var(--link-hover-color);
  /* text-decoration: underline; */
}

/* Manual changes */
.important {
  font-size: 1.1em;
}

.text-bold {
  font-weight: bold;
}

.text-justify {
  text-align: justify;
}

.text-center {
  text-align: center;
}
.block-center {
  margin-left: auto;
  margin-right: auto;
  display: block;
}
.hidden {
  display: none !important; /* hides visually and from screen readers  */
}
.visuallyhidden { /* hides visually but not from screen readers */
  border: 0;
  clip: rect(0 0 0 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  white-space: nowrap; /* For long content since newlines not interpreted as spaces */
}
.visuallyhidden.focusable:active,
.visuallyhidden.focusable:focus { /* extends .visuallyhidden to become visible on focus*/
  clip: auto;
  height: auto;
  margin: 0;
  overflow: visible;
  position: static;
  width: auto;
  white-space: inherit;
}
.invisible {
  visibility: hidden; /* hides visually and from screen readers while maintaining layout */
}



/* //////////////////////////////////////// IMAGES //////////////////////////////////////////////// */
img {
  max-width: 100%;
}

.dark-theme img {
  filter: brightness(.8) contrast(1.2);
}

.banner {
  display: block;
  margin-left: auto;
  margin-right: auto;
  width: 80%;
  /* padding-bottom:  20px; */
  @media (min-width: 900px) {
    max-width: 60%;
  }
}

.semibanner {
  margin-left: auto;
  margin-right: auto;
  width: 40%;
  padding: 10px;
  @media (max-width: 736px) {
    width: 65%;
  }
}

/* Officers and Former Officers pages */
#officers img {
  width:200px;
  /* max-height: 360px; // implement later without stretching */
}
#officers td {
  min-width: 150px;
  max-width: 200px;
}
#officers table {
  @media (min-width:430px) {
    min-height: 200px;
  }
}
.officerimg img:last-child{display:none}
.officerimg:hover img:first-child{display:none}
.officerimg:hover img:last-child{display:inline-block}

footer img {
  width: 120px;
  vertical-align: middle;
  padding: 0 10px
}


/* //////////////////////////////////////// TABLES //////////////////////////////////////////////// */

/* Fixed-layout tables */
.fixed-table {
  table-layout: fixed;
  text-align: center;
}

/* Scrollable tables styled like the one for office hours */
.styled-table {
  border-collapse: collapse;
  /* min-width: 400px; */
  width: 80%;
  margin: auto;


  /* does the below need to be removed? */
  .col-3 {
  border-left: 2px dotted;
  }
  
  .col-1 .col-3 {
    text-align: right;
  }   
}

.styled-table thead tr {
  background-color: var(--theme-color);
}

.styled-table th, .styled-table td {
    padding: 12px 15px;
}

@media(max-width:600px) {
  .styled-table th, .styled-table td {
    padding: 8px 10px;
}
}

.styled-table tbody th {
  white-space: nowrap;
}

.styled-table tbody tr {
  border-bottom: thin solid var(--bkg-color-light);
}

/* .styled-table tbody tr:nth-of-type(even) {
  background-color: #f0f0f0;
}
.styled-table tbody tr:nth-of-type(odd) {
  background-color: #f4f3f2;
} */

.styled-table tbody tr:last-of-type {
  border-bottom: 2px solid var(--theme-color);
}

.styled-table tbody tr:first-of-type {
  border-bottom: 2px solid var(--theme-color);
}

/* Shadows for mobile scrolling tables */
.table-wrapper {
  overflow: auto;
  max-width: 100%;
  border-radius: 10px;
  @media (max-width: 736px) {
    background:
    linear-gradient(to right, var(--table-side-one), var(--table-side-two)),
    linear-gradient(to right, var(--table-side-two), var(--table-side-one)) 0 100%,
    radial-gradient(farthest-side at 0% 50%, rgba(0,0,0,.2), rgba(0,0,0,0)),
    radial-gradient(farthest-side at 100% 50%, rgba(0,0,0,.2), rgba(0,0,0,0)) 0 100%;
    background-repeat: no-repeat;
    background-color: var(--table-bkg-color);
    background-size: 40px 100%, 40px 100%, 14px 100%, 14px 100%;
    background-position: 0 0, 100%, 0 0, 100%;
    background-attachment: local, local, scroll, scroll;
  }
  @media (min-width: 736px) {
    background-color: var(--table-bkg-color);
  }
}

/* //////////////////////////////////////// FLEX CONTAINERS /////////////////////////////////////// */
/* E.g. the bottom of the front page */
.flex-container {
  display: flex;
  flex-flow: row wrap;
  justify-content: center;
  text-align: center;
  
  overflow: scroll;
  /* Hide scrollbar for IE, Edge and Firefox */
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
  
  /* @media (max-width: 430px) {
    background-color: var(--flexbox-bkg-color);
  } */
}

/* Hide scrollbar for Chrome, Safari and Opera */
.flex-container::-webkit-scrollbar {
  display: none;
}

.flex-item {
  padding: 1em;
  flex-grow: 1;
  table-layout: fixed;
  border-radius: 10px;
  max-width: 528px;
  /* should the hover effect be for min-width 430px or nah? */
  &:hover {
    background-color: var(--bkg-color-light);
  } 
  /* @media (max-width:430px){
    display: block;
    width: 100%;
  } */
}


/* //////////////////////////////////////// COLLAPSIBLES ////////////////////////////////////////// */
/* Full collapsibles (mobile and desktop), eg the ones on the resources page */
.collapsible {
  background-color: var(--bkg-color-light);
  cursor: pointer;
  padding: 18px;
  margin-bottom: 15px;
  width: 100%;
  border-radius: 10px;
}

.collapsible.active {
  background-color: var(--bkg-color-lighter);
  border-radius: 10px 10px 0px 0px;
}
.collapsible:hover {
  @media(min-width: 430px) {
    background-color: var(--bkg-color-lighter);
  }
}

.content {
  padding: 0em 1em 0em 1em; /* changed by JS */
  background-color: var(--bkg-color-light);
  max-height: 0em; /* changed by JS */
  overflow: hidden;
  transition: max-height 0.2s ease-out;
  border-radius: 0px 0px 10px 10px;
  margin-top: -15px;
}

ul.content {
  padding-left: 40px;
}

@media (min-width: 400px) { /* hide +/- it before it gets ugly */
  .collapsible::before {
    content: '+';
    /* font-family: monospace; */
    font-size: 1em;
    color: var(--text-color);
    float: left;
    margin-left: 5px;
    margin-top: auto;
  }

  .collapsible.active::before {
    content: '-';
    /* font-family: monospace; */
    font-size: 1em;
    color: var(--text-color);
  }
}


/* Mobile collapsibles (only looks collapsible on mobile and tablet) */
@media (max-width: 736px) {
  
.mobile-collapsible {
  background-color: var(--bkg-color-light);
  cursor: pointer;
  padding: 18px;
  margin-bottom: 15px;
  width: 100%;
  border-radius: 10px;
}

.mobile-active {
  background-color: var(--bkg-color-lighter);
  border-radius: 10px 10px 0px 0px;
}

.mobile-content {
  padding: 0 0.75em 0 0.75em; /* changed by JS */
  background-color: var(--bkg-color-light);
  max-height: 0em; /* changed by JS */
  overflow: hidden;
  transition: max-height 0.2s ease-out;
  border-radius: 0px 0px 10px 10px;
  margin-top: -15px;
}

ul.mobile-content {
  padding-left: 40px;
}

@media (min-width: 400px) { /* hide it before it gets ugly */
  .mobile-collapsible::before {
    content: '+';
    /* font-family: monospace; */
    font-size: 1em;
    color: var(--text-color);
    float: left;
    margin-left: 5px;
    margin-top: auto;
  }

  .mobile-active::before {
    content: '-';
    /* font-family: monospace; */
    font-size: 1em;
    color: var(--text-color);
  }
}

}

/* //////////////////////////////////////// MISC ////////////////////////////////////////////////// */

/* Announcement Panes */
.announcement {
  margin: auto;
  padding: 2% 6%;
  background-color: var(--bkg-color-light);
  border: #111;
  border-style:solid;
  border-width: 0px;
  border-radius: 25px;
  width: 95%;
  @media (min-width: 736px) {
    width: 80%;
  }
  @media (min-width: 1500px) {
    width: 70%;
  }
}
/* Feature Panes (same as announcement but less shrinking) */
.feature {
  margin: auto;
  padding: 2% 6%;
  background-color: var(--bkg-color-light);
  border: #111;
  border-style:solid;
  border-width: 0px;
  border-radius: 25px;
  width: 95%;
  @media (min-width: 736px) {
    width: 80%;
  }
}


/* Mailforms and Text Boxes */
#mailform .email { 
  border:1px solid var(--mailform-border-color); 
  width: 300px; 
  font-size:1.25em; 
  border-radius: 3px; 
  box-sizing: border-box; 
  padding: 0px 8px;
  @media (max-width: 550px) {
    width: 200px;  
  }
}
#mailform .button { 
  margin-left:15px; 
  border:1px solid var(--mailform-border-color); 
  font-size:1.25em; width:120px; 
  border-radius:3px; 
  box-sizing:border-box;
   padding: 0px 4px;}
#mailform label {
  padding-bottom:10px;
  display:block;
}
textarea {
  resize: vertical; /* only vertical resizing */
}

/* Buttons */
button {
	margin: 10px;
  color: var(--text-color);
	background-color: var(--bkg-color-light);
	padding: 10px;
	font-size: 1.3em;
  border-width: 1px;
  border-radius: 8px;
}

/* iframes (none currently in use) */
iframe {
  border: none;
  display: block;
  margin:auto;
  width: 80%;
  height: 80vh;
}
/* "better looking" horizontal rule */
hr {
  display: block;
  height: 1px;
  border: 0;
  border-top: 1px solid #ccc;
  margin: 1em 0;
  padding: 0;
}


/* Fancy underline effect on hover */
.underline {
  border: 1px solid transparent;
}
.underline::after {
  width: 0%;
  height: 1px;
  display: block;
  background-color: #eee;
  content: " ";
  /* position: absolute; */
  top: 34px;
  left: 50%;
  -webkit-transition: left 0.2s cubic-bezier(0.215, 0.61, 0.355, 1), width 0.2s cubic-bezier(0.215, 0.61, 0.355, 1);
  transition: left 0.2s cubic-bezier(0.215, 0.61, 0.355, 1), width 0.2s cubic-bezier(0.215, 0.61, 0.355, 1);
}
.underline:hover::after {
  width: 100%;
  height: 1px;
  display: block;
  background-color: #eee;
  content: " ";
  /* position: absolute; */
  top: 34px;
  left: 0;
}

/*
 * Clearfix: contain floats
 *
 * For modern browsers
 * 1. The space content is one way to avoid an Opera bug when the
 *    `contenteditable` attribute is included anywhere else in the document.
 *    Otherwise it causes space to appear at the top and bottom of elements
 *    that receive the `clearfix` class.
 * 2. The use of `table` rather than `block` is only necessary if using
 *    `:before` to contain the top-margins of child elements.
 */
 .clearfix:before,
 .clearfix:after {
     content: " "; /* 1 */
     display: table; /* 2 */
 }
 .clearfix:after {
     clear: both;
 } 
/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Vendor-prefixed and regular ::selection selectors cannot be combined:
 * https://stackoverflow.com/a/16982510/7133471
 *
 * Customize the background color to match your design.
 */

 ::-moz-selection {
  background: #b3d4fc;
  text-shadow: none;
}
::selection {
  background: #b3d4fc;
  text-shadow: none;
}


/* //////////////////////////////////////// DARK MODE ////////////////////////////////////////////////// */
/* this must be kept below other styles */
body:not(.dark-theme) .light-hide {
  display: none;
}
body.dark-theme .dark-hide {
  display: none;
}


/* //////////////////////////////////////// PRINT STYLES ///////////////////////////////////////////////// */
/* Inlined to avoid the additional HTTP request */
/* https://www.phpied.com/delay-loading-your-print-css/ */

@media print {
  *,
  *:before,
  *:after {
      background: transparent !important;
      color: #000 !important; /* Black prints faster */
      -webkit-box-shadow: none !important;
      box-shadow: none !important;
      text-shadow: none !important;
  }

  a,
  a:visited {
      text-decoration: underline;
  }

  a[href]:after {
      content: " (" attr(href) ")";
  }

  abbr[title]:after {
      content: " (" attr(title) ")";
  }

  /*
    * Don't show links that are fragment identifiers,
    * or use the `javascript:` pseudo protocol
    */

  a[href^="#"]:after,
  a[href^="javascript:"]:after {
      content: "";
  }

  pre {
      white-space: pre-wrap !important;
  }
  pre,
  blockquote {
      border: 1px solid #999;
      page-break-inside: avoid;
  }

  /*
    * Printing Tables:
    * http://css-discuss.incutio.com/wiki/Printing_Tables
    */

  thead {
      display: table-header-group;
  }

  tr,
  img {
      page-break-inside: avoid;
  }

  p,
  h2,
  h3 {
      orphans: 3;
      widows: 3;
  }

  h2,
  h3 {
      page-break-after: avoid;
  }
}