/* star3000 font family — local files */

@font-face {
  font-family: 'star3_smallregular';
  src: url(fonts/star3000_small.eot);
  src: url(fonts/star3000_small.eot?#iefix) format("embedded-opentype"),
       url(fonts/star3000_small.woff2) format("woff2"),
       url(fonts/star3000_small.woff) format("woff"),
       url(fonts/star3000_small.ttf) format("truetype"),
       url(fonts/star3000_small.svg#star3_smallregular) format("svg");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'star3_largeregular';
  src: url(fonts/star3000_large.eot);
  src: url(fonts/star3000_large.eot?#iefix) format("embedded-opentype"),
       url(fonts/star3000_large.woff2) format("woff2"),
       url(fonts/star3000_large.woff) format("woff"),
       url(fonts/star3000_large.ttf) format("truetype"),
       url(fonts/star3000_large.svg#star3_largeregular) format("svg");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'star3_large_heavyregular';
  src: url(fonts/star3000_large_heavy.eot);
  src: url(fonts/star3000_large_heavy.eot?#iefix) format("embedded-opentype"),
       url(fonts/star3000_large_heavy.woff2) format("woff2"),
       url(fonts/star3000_large_heavy.woff) format("woff"),
       url(fonts/star3000_large_heavy.ttf) format("truetype"),
       url(fonts/star3000_large_heavy.svg#star3_large_heavyregular) format("svg");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'star3_small_heavyregular';
  src: url(fonts/star3000_small_heavy.eot);
  src: url(fonts/star3000_small_heavy.eot?#iefix) format("embedded-opentype"),
       url(fonts/star3000_small_heavy.woff2) format("woff2"),
       url(fonts/star3000_small_heavy.woff) format("woff"),
       url(fonts/star3000_small_heavy.ttf) format("truetype"),
       url(fonts/star3000_small_heavy.svg#star3_small_heavyregular) format("svg");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'star3regular';
  src: url(fonts/star3000.eot);
  src: url(fonts/star3000.eot?#iefix) format("embedded-opentype"),
       url(fonts/star3000.woff2) format("woff2"),
       url(fonts/star3000.woff) format("woff"),
       url(fonts/star3000.ttf) format("truetype"),
       url(fonts/star3000.svg#star3regular) format("svg");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'star3_heavyregular';
  src: url(fonts/star3000_heavy.eot);
  src: url(fonts/star3000_heavy.eot?#iefix) format("embedded-opentype"),
       url(fonts/star3000_heavy.woff2) format("woff2"),
       url(fonts/star3000_heavy.woff) format("woff"),
       url(fonts/star3000_heavy.ttf) format("truetype"),
       url(fonts/star3000_heavy.svg#star3_heavyregular) format("svg");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'star3_extended_heavyregular';
  src: url(fonts/star3000_extended_heavy.eot);
  src: url(fonts/star3000_extended_heavy.eot?#iefix) format("embedded-opentype"),
       url(fonts/star3000_extended_heavy.woff2) format("woff2"),
       url(fonts/star3000_extended_heavy.woff) format("woff"),
       url(fonts/star3000_extended_heavy.ttf) format("truetype"),
       url(fonts/star3000_extended_heavy.svg#star3_extended_heavyregular) format("svg");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'star3_extra_largeregular';
  src: url(fonts/star3000_extra_large.eot);
  src: url(fonts/star3000_extra_large.eot?#iefix) format("embedded-opentype"),
       url(fonts/star3000_extra_large.woff2) format("woff2"),
       url(fonts/star3000_extra_large.woff) format("woff"),
       url(fonts/star3000_extra_large.ttf) format("truetype"),
       url(fonts/star3000_extra_large.svg#star3_extra_largeregular) format("svg");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'star3_extendedregular';
  src: url(fonts/star3000_extended.ttf) format("truetype");
  font-weight: normal;
  font-style: normal;
}

/* Base */

html, body {
  width: 100%;
  height: 100%;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

body {
  display: -webkit-box;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  background: #000032;
  margin: 0;
  overflow: hidden;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

iframe {
  width: 100%;
  height: 100%;
}

.scaled-iframe {
  -webkit-transform: scale(1.2);
  -ms-transform: scale(1.2);
  transform: scale(1.2);
}

/* Main container */

#current-condition {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  cursor: default;
  display: -webkit-box;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -webkit-flex-direction: column;
  -ms-flex-direction: column;
  flex-direction: column;
  margin: auto;
  width: 100%;
  height: 100%;
  background-color: #4b2b82;
  font-family: 'star3regular';
  font-size: 40pt;
  letter-spacing: 0pt;
  color: white;
  text-shadow: 2px 2px 6px #646464;
}

/* Main content area */

#current-condition .main {
  -webkit-box-flex: 1;
  -webkit-flex: 1;
  -ms-flex: 1;
  flex: 1;
  width: 100%;
  overflow: hidden;
  margin: auto;
  display: -webkit-box;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -webkit-flex-direction: column;
  -ms-flex-direction: column;
  flex-direction: column;
  text-transform: uppercase;
  position: relative;
}

/* Two stacked board slots — both in viewport so iframes initialize fully.
   transform: translateZ(0) creates a stacking context that traps position:fixed
   children (disinteraction-overlay, h1.overlayed) within the slot. */
#current-condition .main .board-slot {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: -webkit-box;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -webkit-flex-direction: column;
  -ms-flex-direction: column;
  flex-direction: column;
  overflow: hidden;
  -webkit-transform: translateZ(0);
  -ms-transform: translateZ(0);
  transform: translateZ(0);
  background-color: #4b2b82; /* fallback before JS sets the gradient */
}

#current-condition .main h1 {
  font-weight: normal;
  padding-top: 0.5em;
  margin: 0.9em auto 0.9em 1.8em;
  font-size: 1em;
}

#current-condition .main h1.stars {
  margin: 0.9em auto 0.9em auto;
  text-align: center;
}

#current-condition .main h1.stars::before,
#current-condition .main h1.stars::after {
  content: '*';
}

#current-condition .main h1.stars.large {
  font-size: 1.5em;
}

#current-condition .main h1.overlayed {
  position: fixed;
  width: 100vw;
  z-index: 1;
}

#current-condition .main .mini {
  font-family: 'star3_smallregular';
  font-size: 0.8em;
  line-height: 0.6em;
}

#current-condition .main .autoscroll-wrapper {
  margin-top: 1em;
  overflow: hidden;
}

#current-condition .main p {
  box-sizing: border-box;
  line-height: 1.25em;
  padding: 0 1.8em;
  margin: 0 auto auto auto;
  width: 100%;
  -webkit-hyphens: auto;
  -moz-hyphens: auto;
  -ms-hyphens: auto;
  hyphens: auto;
  word-wrap: break-all;
}

#current-condition .main p.small {
  font-family: 'star3_smallregular';
}

#current-condition .main [data-hook=locating] {
  position: relative;
  z-index: 10;
  margin: auto;
}

#current-condition .main .cover {
  z-index: 2;
  width: 100vw;
  height: 100vh;
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
}

#current-condition .main .cover.stretch {
  background-size: cover;
}

/* Board background images — set via inline style in server-rendered HTML */
#current-condition .main .ny-region     { }
#current-condition .main .namerica      { background-color: #c1e7ff; }
#current-condition .main .wradar        { background-color: #001020; }
#current-condition .main .flight-delays { background-color: #334d65; }

#current-condition .main .center {
  text-align: center;
}

/* Weather / data tables */

#current-condition .main .table-wrapper {
  height: 100%;
}

#current-condition .main table {
  margin: 0 auto auto auto;
  padding: 0 1.8em;
  width: 100%;
}

#current-condition .main table.mountains td {
  font-size: 0.5em;
}

#current-condition .main table .location {
  text-align: left;
}

#current-condition .main table .delay-type {
  width: 1%;
  white-space: nowrap;
  text-align: left;
  padding-right: 1em;
}

#current-condition .main table .temp {
  width: 2.5em;
  text-align: right;
}

#current-condition .main table .wind {
  text-align: right;
  width: 3.5em;
}

#current-condition .main table .sky {
  text-align: right;
  width: 5.5em;
}

#current-condition .main table th {
  padding-top: 0;
  margin-top: 0;
  vertical-align: top;
  text-align: left;
  font-family: 'star3_smallregular';
}

#current-condition .main table td:nth-child(2) {
  text-align: right;
}

/* Board wrapper (injected by JS) */

#current-condition .main .wrapper {
  display: -webkit-box;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -webkit-flex-direction: column;
  -ms-flex-direction: column;
  flex-direction: column;
  -webkit-box-flex: 1;
  -webkit-flex: 1;
  -ms-flex: 1;
  flex: 1;
  z-index: 1;
}

/* Video embeds */

#current-condition .video-wrapper {
  -webkit-box-flex: 1;
  -webkit-flex: 1;
  -ms-flex: 1;
  flex: 1;
}

[data-hook=ustream] {
  -webkit-transform: scale(1.8);
  -ms-transform: scale(1.8);
  transform: scale(1.8);
}

[data-hook=live-flights] {
  -webkit-transform: scale(2);
  -ms-transform: scale(2);
  transform: scale(2);
}

/* Overlay to prevent click-through on iframes */
.disinteraction-overlay {
  z-index: 1000;
  position: fixed;
  width: 100vw;
  height: 100vh;
  background-color: #0000ff;
  opacity: 0.01;
}

/* Divider bar */

#current-condition .divider {
  border-top: 0.12em solid white;
  box-shadow: 0 -1px 0px 0px #646464;
  padding: 0 1.8em 0 1.8em;
  box-sizing: border-box;
  display: -webkit-box;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  width: 100%;
}

#current-condition .divider .left,
#current-condition .divider .right {
  display: block;
  white-space: nowrap;
  font-family: 'star3_smallregular';
  font-size: 1em;
  letter-spacing: 0;
}

#current-condition .divider .left {
  margin: -0.1em auto auto 0;
}

#current-condition .divider .right {
  margin: -0.1em 0 auto auto;
}

/* Footer / ticker */

#current-condition footer {
  overflow: hidden;
  width: 100%;
  margin-bottom: 0.55em;
}

#current-condition footer span {
  display: inline;
  white-space: nowrap;
}

#current-condition footer .mobile-play-overlay {
  display: none;
  width: 100vw;
  text-align: center;
}

/* Responsive breakpoints */

@media only screen and (max-width: 640px) {
  #current-condition {
    font-size: 12pt;
  }
  #current-condition [data-hook=ustream] {
    -webkit-transform: scale(1.4);
    -ms-transform: scale(1.4);
    transform: scale(1.4);
  }
  #current-condition .main h1 {
    width: 100%;
    margin: 0.45em auto 0.45em 0.9em;
  }
  #current-condition .main h1.stars {
    text-align: center;
    margin: 0.45em auto 0.45em auto;
  }
  #current-condition .main p {
    padding: 0 0.9em;
  }
  #current-condition .main table {
    padding: 0 0.9em;
  }
  #current-condition .divider {
    padding: 0 0.9em 0 0.9em;
  }
}

