/* Import Google fonts: Montserrat for titles, Roboto for body */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@700&family=Roboto:wght@400;500;700&display=swap');

html {
        position: relative;
        min-height: 100%;
}

/* https://colorhunt.co/palette/222831393e4600adb5eeeeee */
/*
#222831 : dark navy
#393E46 : navy
#00ADB5 : blue
#EEEEEE : beige
*/

body {
        color: #222831;
        background-color: #EEEEEE;
        font-family: "Roboto", sans-serif;
        font-size: 18px;
        font-stretch: normal;
        font-style: normal;
        font-variant: normal;
        font-weight: normal;
        letter-spacing: 0;
        line-height: 150%;
        margin-bottom: 30px;
        margin-left: 0px;
        margin-right: 0px;
        margin-top: 0px;
        opacity: 1.00;
        padding-bottom: 0px;
        padding-top: 0px;
        text-align: left;
        text-decoration: none;
        text-indent: 0px;
        text-transform: none;
        -webkit-text-size-adjust: none;
}

h1, h2, h3, h4 {
        font-family: "Montserrat", sans-serif;
        font-weight: 700;
        color: #393E46; 
        margin-top: 18px;
}

a {
        color: #00ADB5;
        text-decoration: none;
}

a:hover {
        color: #393E46;
        text-decoration: underline;
}

div {
        overflow: visible;
}

img {
        border: none;
}

footer {
        position: absolute;
        bottom: 0;
        width: 100%;
        height: 30px;
        background-color: #393E46;
}

.copyright {
        position: absolute;
        bottom: 0;
        width: 100%;
        font-size: 14px;
        color: #EEEEEE;
        text-align: center;
}

.navbar {
        background-color: #393E46;
        -webkit-transition: padding .3s;
        -moz-transition: padding .3s;
        transition: padding .3s;
        border: none;
}

.navbar .navbar-nav {
        float: right;
        padding-right: 30px;
        padding-top: 10px;
}

.navbar-default .navbar-nav>li>a {
        font-family: "Ubuntu", sans-serif;
        font-size: 18 px;
        font-weight: bold;
        color: #EEEEEE;
        background: #393E46;
        position: relative;
        display: block;
        padding: 10px 15px;
}

.navbar-default .navbar-nav>.active>a,
.navbar-default .navbar-nav>.active>a:focus,
.navbar-default .navbar-nav>.active>a:hover {
        color: #EEEEEE;
        background-color: #00ADB5;
}

.navbar-default .navbar-nav>li>a:focus,
.navbar-default .navbar-nav>li>a:hover {
        color: #393E46;
        background-color: #00ADB5;
}

footnote {
        font-family: "Ubuntu", sans-serif;
        color: #EF767A;
        font-size: 16px;
        font-style: italic;
}

#controls {
        /* Appearance */
        background-color: white;
        padding: 0 20px 20px 20px;
        cursor: move;
        /* Fade out while not hovering */
        opacity: 0.7;
        zoom: 0.9;
        transition: opacity 500ms 1s;
}

#controls:hover {
        /* Fade in while hovering */
        opacity: 0.95;
        transition-delay: 0;
}

.main {
        width: 90%;
        margin: auto;
        overflow: visible;
}

.quote {
        background: #FFFFFF;
        width: 100%;
        max-width: 500px;
        min-width: 450px;
        margin: 1em auto 0;
        padding: 1em;
        text-align: center;
        line-height: 30px;
}

blockquote {
        display: block;
        border-width: 2px 0;
        border-style: solid;
        border-color: #EF767A;
        padding: 1em 0 0.5em;
        margin: 1em 0;
        position: relative;
        font-size: 24px;
        color: #EF767A;
}

blockquote:before {
        content: attr(cite);
        position: absolute;
        top: 0em;
        left: 50%;
        transform: translate(-50%, -50%);
        background: #F8F3D4;
        width: 16rem;
        height: 2rem;
        font: 1em/0.95em "Ubuntu", sans-serif;;
        color: #EF767A;
        text-align: center;
        font-weight: bold;
}

/* Acknowledgement: https://github.com/statnmap/RshinyApps/tree/master/On-Off_SwitchButton */
/*                                                                                         */
/* ON-OFF switch button */
/* Sébastien Rochette */
/* http://sebrock.fr/en/ */
/* CSS modified from : https://proto.io/freebies/onoff/ */
/* All switch */
.onoffswitch {
        width: 130px;
        position: relative;
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        font-family: "Ubuntu", sans-serif;
}

.onoffswitch-checkbox {
        display: none;
}

.onoffswitch-label {
        display: block;
        overflow: hidden;
        cursor: pointer;
        border: 2px solid #999999;
        border-radius: 30px;
}

.onoffswitch-inner {
        display: block;
        width: 200%;
        margin-left: -100%;
        transition: margin 0.2s ease-in 0s;
}

.onoffswitch-inner:before,
.onoffswitch-inner:after {
        display: block;
        float: left;
        width: 50%;
        height: 40px;
        padding: 0;
        line-height: 40px;
        font-size: 16px;
        color: white;
        font-family: "Ubuntu", sans-serif;
        font-weight: bold;
        box-sizing: border-box;
}

/* All switch - default div class */
.onoffswitch-inner:before {
        content: " ";
        padding-left: 10px;
}

.onoffswitch-inner:after {
        content: " ";
        padding-right: 10px;
        text-align: right;
}

.onoffswitch-switch {
        display: block;
        width: 30px;
        height: 30px;
        margin: 6.5px;
        position: absolute;
        top: 0;
        bottom: 0;
        border-radius: 30px;
        right: 87px;
        transition: all 0.3s ease-in 0s;
}

.onoffswitch-checkbox:checked+.onoffswitch-label .onoffswitch-switch {
        right: 0px;
}

.onoffswitch-checkbox:checked+.onoffswitch-label .onoffswitch-inner {
        margin-left: 0;
}

/* Color change */
/* RedGreen */
.RedGreen .onoffswitch-inner:before {
        background-color: #008A0C;
        color: #FFFFFF;
}

.RedGreen .onoffswitch-inner:after {
        background-color: #D10000;
        color: #FFFFFF;
}

.RedGreen .onoffswitch-switch {
        background: #FFFFFF;
        border: 2px solid #FFFFFF;
}

/* GreyBlue */
.GreyBlue .onoffswitch-inner:before {
        background-color: #FFFFFF;
        color: #428bca;
}

.GreyBlue .onoffswitch-inner:after {
        background-color: #FFFFFF;
        color: #AAA;
}

.GreyBlue .onoffswitch-switch {
        background: #AAA;
        border: 2px solid #AAA;
}

.GreyBlue .onoffswitch-checkbox:checked+.onoffswitch-label .onoffswitch-switch {
        background-color: #428bca;
}

/* Text change */
/* On / Off */
.OnOff .onoffswitch-inner:before {
        content: "ON";
}

.OnOff .onoffswitch-inner:after {
        content: "OFF";
}

/* Yes / No */
.YesNo .onoffswitch-inner:before {
        content: "YES";
}

.YesNo .onoffswitch-inner:after {
        content: "NO";
}

/* True / False */
.TrueFalse .onoffswitch-inner:before {
        content: "Pearson";
}

.TrueFalse .onoffswitch-inner:after {
        content: "Spearman";
}

/* Panel figures */
/* Square plot wrapper: width constrained by parent column and viewport */
.sq-plot-wrap {
  width: min(100%, 92vw, 92vh);
  margin-left: auto;
  margin-right: auto;
  overflow: hidden; /* prevents accidental horizontal scrollbars */
}

/* Any Shiny plot output inside the square wrapper */
.sq-plot-wrap .shiny-plot-output {
  width: 100% !important;
  max-width: 100% !important;
  display: block;
}

/* Ensure rendered plot surface fills the output container */
.sq-plot-wrap .shiny-plot-output > img,
.sq-plot-wrap .shiny-plot-output > canvas {
  width: 100% !important;
  height: auto !important; /* keep aspect until JS forces square height */
  display: block;
}

.page-content {
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px 18px;
}

.page-content h2, .page-content h3 {
  margin-top: 18px;
}