/* Generate web font packages (with css) in http://www.fontsquirrel.com */
@font-face {
	font-family: 'didact_gothicregular';
	src: url('didactgothic-regular-webfont.woff2') format('woff2'), url('didactgothic-regular-webfont.woff') format('woff');
	font-weight: normal;
	font-style: normal;
}

/* @import url('https://fonts.googleapis.com/css?family=Quicksand|Jura&subset=latin,cyrillic'); */

:root {
	--top-margin: 107px;
	--left-margin: 280px;
	--right-margin: 36px;
	--theme-color1: #eee;
	--theme-color2: #aaa;
}
@media only screen and (max-width: 610px) {
  :root {
    --left-margin: 244px;
  }
}

* {
	margin: 0;
	padding: 0;
	font-family: 'didact_gothicregular'; /* Verdana, sans-serif / 'Quicksand' / 'Jura' */
	font-size: 16px; /* 13 with Verdana */
	font-weight: normal;
	font-style: normal;
	text-align: left;
	text-shadow: 0 0 3px #eee;
	vertical-align: top;
	color: rgb(32,32,32);
	text-decoration: none;
	/* may introduce bugs, but does not seem to have any effect on the problematic PC Safari: text-rendering: geometricPrecision; */
	-webkit-font-smoothing: antialiased;
}

html {
	height: 100%;
	overflow-x: hidden;
	overflow-y: scroll;
}

body 
{
  position:absolute; top:0; bottom:0; right:0; left:0;
  min-height:700px;
  background:rgb(255,255,255) repeat-y fixed center; /*url('../kuvat/background.jpg')*/
  text-align:center;
  margin:0;
  padding:0;
  /* hide scrollbar, prevent scrolling: overflow-y: hidden; */
  /* prevent font scaling on mobile devices */
  -webkit-text-size-adjust: none;
  -moz-text-size-adjust: none;
  -ms-text-size-adjust: none;
}

/* alignment of page contents */
.contents {
	display: block;
	margin: 0 0;
	padding: var(--top-margin) var(--right-margin) 0 var(--left-margin);
}

h3 
{
  font-size: 20px; /* 18 with Verdana */
	color: black; /* white for black bg */
	text-shadow: 0 0 2px #ccc;
}

h4
{
	font-weight: bold;
	color: black; /* white for black bg */
	text-shadow: 0 0 2px #ccc;
}

b, strong {
  font-weight: bold !important;
	letter-spacing: 1px;
}

a 
{
	outline: none;
	color: rgb(78,78,78); /* 224, 224, 224 = half way between white and silver (192, 192, 192) for black bg */
	text-decoration: underline;
}
a:link {color:rgb(80,80,80);}     /* unvisited link, 224, 187, 154 for black bg */
a:visited {color:rgb(80,80,80);}  /* visited link, 224, 187, 154 for black bg */
a:hover {color:rgb(160,160,160);}    /* mouse over link, 224, 224, 224 for black bg */
a:active {color:rgb(0,0,0);}   /* selected link, 255,255,255 for black bg */

input[type=text], textarea
{
	width:100%;
	max-width:500px;
  vertical-align:baseline;
  margin:4px 0 24px 0;
  padding:4px 0 2px 6px;
  color:black;
	border: 2px solid black;
  background:rgb(250,251,252);
}
input {	height:24px; }

input:focus-visible, textarea:focus-visible {
  background-color: var(--theme-color1);
	outline: none;
}

select {
	height:30px;
	margin:4px 0 24px 0;
	padding-left:6px;
}

button {
	top: 0px;
  height: 38px;
  width: auto;
  min-width: 144px;
	display: inline-block;
	outline: none;
	cursor: pointer;
	text-align: center;
	text-decoration: none;
	white-space:nowrap;
  color:black;
	padding: 0 12px 1px 12px;
	background:rgb(200,200,200); /* default; overridden dynamically in bag.js EXCEPT for giftcard.html which isn't created dynamically */
	border:2px solid rgb(0,0,0); /* default; overridden dynamically in bag.js */
	border-radius: 2px;
	-webkit-border-radius: 2px;
	text-shadow: 0 0 2px #fff;
	-webkit-box-shadow: 0 1px 2px rgba(0,0,0,.1);
	box-shadow: 0 1px 2px rgba(0,0,0,.1);
}
button:hover {
	text-decoration: none;
}
button:active {
	position: relative;
	top: 1px;
	left: 1px;
	/* background:rgb(240,240,240) !important; need to use !important to have this working also after dynamic style (color) change */
}

/* close button for alert box */
#closeBtn {
	display:block;
	margin:15px auto;
	width:70px;
}


select {
	box-sizing: border-box;
	margin-right: 0px;
	padding-right: 0px;
  border: 2px solid black;
  border-radius: 2px;
  background-color: rgb(250,251,252);
  cursor: pointer;
	height: 36px;
  width: 100%;
  max-width: 300px;
  transition: border-color 0.2s ease;
}
select:focus  { background-color: var(--theme-color1); outline: none; }
select option { background-color: var(--theme-color1); }


input[type="checkbox"] {
  -webkit-appearance: none;
  appearance: none;
	width:25px !important;
	height:25px;
	margin:0 12px 25px 0;
	border:2px solid black;
	border-radius: 2px;
	display: inline-grid;
  place-content: center;
	flex-shrink: 0;
  cursor: pointer;
  vertical-align: middle;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

input[type="checkbox"]:focus {
  background-color: var(--theme-color1);
}

input[type="checkbox"]::before {
  content: "";
  width: 10px;
  height: 6px;
  border-left: 2px solid black;   /* checkmark body */
  border-bottom: 2px solid black; /* checkmark hook */
  transform: rotate(-45deg) translateX(1px) translateY(-2px); /* Rotate a flat right-angle border into a dynamic checkmark */
  /* Hide it using scale until it gets checked */
  transform-origin: center;
  scale: 0;
  transition: scale 0.15s ease-in-out;
}

/* Reveals the custom checkmark when the input is active */
input[type="checkbox"]:checked::before {
  scale: 1;
}


input[type="radio"] {
  -webkit-appearance: none;
  appearance: none;
  width: 25px !important;
  height: 25px;
  margin: 0 12px 12px 0;
  border: 2px solid black;
  border-radius: 50%; /* Keeps it a perfect circle */
  display: inline-grid;
  place-content: center;
  flex-shrink: 0;
  cursor: pointer;
  vertical-align: middle;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

input[type="radio"]:focus {
  background-color: var(--theme-color1); 
}

/* Creates the inner centered dot */
input[type="radio"]::before {
  content: "";
  width: 11px; /* Size of the inner active dot */
  height: 11px;
  background-color: black;
  border-radius: 50%;
  transform-origin: center;
  scale: 0; /* Hidden by default */
  transition: scale 0.15s ease-in-out;
}

/* Reveals the custom dot when the radio button is active */
input[type="radio"]:checked::before {
  scale: 1;
}

.radioText {
	vertical-align:top;
	line-height:26px;
}


/* shopping cart specific */
.nopentry { white-space: nowrap; }

/* message dialog styling */
#modalContainer {
	background-color:transparent;
	position:absolute;
	width:100%;
	height:100%;
	top:0px;
	left:0px;
	z-index:10000;
}

#alertBox {
	position:relative;
	width:auto;
	min-height:100px;
	min-width:200px;
	border:2px solid #000;
	background-color:rgb(240,240,240);
}

#modalContainer > #alertBox {
	position:fixed;
}

#alertBox h1 {
	margin:0;
	font-weight:bold;
	background-color:rgb(153,123,184); /* default; overridden dynamically in bag.js: */
	color:#fff;
	border-bottom:1px solid #000;
	padding: 3px 0 3px 6px;
}

#alertBox p {
	color:#000;
	height:31px;
	padding: 8px 8px 5px 5px;
	margin: 0px 0px -4px 4px;
}
