text:
=head1 TITLE

Universal Asynchronous I/O

=head1 VERSION

  Maintainer: Uri Guttman <uri@sysarch.com>
  Date: 5 Aug 2000
  Mailing List: perl6-language-flow@perl.org
  Number: 47
  Version: 1
  Status: Developing

=head1 ABSTRACT

This RFC describes an OO API for Perl I/O handles that uses asynchronous
callbacks (which are synchronized with the Perl op dispatch loop) and
which works with event loops, threads, signals, and other code flow
areas. It also shows how Perl can integrate all of the flow techniques
and how they can work together in a single process.

=head1 DESCRIPTION

Perl5 has support for various ways to control its logic flow including
threads, event loops (from modules) and signals. All of those have major
flaws in both their language and implentation and especially with their
interaction with each other. Perl 6 can be created with the language
aspects of all of them fully integrated into the core and with simple ways
to use and combine them safely.

=head2 Threads

There is a strong consensus that Perl needs high quality internal
support for threads. 5.005+ tried out various thread experiments with no
final success. Included here is a proposal for a thread model which
works well with the other program flow areas.

=head2 Safe Signals

Perl5 suffers from its well know unsafe signal handling. It is due to
the asynchronous way signals are triggered at the level of C
code. A signal could be delivered in Perl while some critical operation
(e.g. malloc) is happening and all hell breaks loose. Signals have to be
delivered synchronously with respect Perl op code dispatching.

=head2 Event Loop

Every agrees there needs to be one event loop for all of Perl. I propose
that it be in the Perl core as it needs to be able to interact tightly
with the other control areas. I have a proposal for a simple Perl API
which is compatible with I/O objects.

=head2 Asynchronous I/O

Many of us are familiar with multiplexing I/O from sockets, pipes and
other stream based handles. This is usually done with the use of the
select/poll kernel system calls. But asynchronous file I/O is not
supported by those calls as files are always capable of being read and
written. Your program may block doing file I/O and there is no simple
way to control that. An easily used asynchronous I/O paradigm in the
Perl core is needed.

=head2 Timers

Perl needs the ability to support multiple timers. These can be used for
timing out I/O operations, socket connections or other events. Timers
can be independent or associated with an events.

=head2 Coroutines

<FILL THIS IN>

=head2 Continuations

<FILL THIS IN>

=head1 MOTIVATORS

This list meant to be a catchall for all logic flow related
issues. This is a major subset of all language issues and would focus
energy on these topics. It would also lower the volume of the parent
language list.

Doing all of those things correctly and elegantly is not trivial. I see
the need to solve them all together as we don't want multiple
comflicting paradigms like Perl5 currently has. Threads have to be
stable and easy to use, Event loops need a clean API in the core, and
signals have to be safe and work with both events and threads. Async I/O
also needs to interact cleanly with those items.

=head1 IMPLEMENTATION

The only language change I propose is that the new IO object has a set
of builtin methods with callbacks. Think of what you would have if you
merged IO::*.pm with Event.pm. Each IO handle (of any sort, file,
socket, pipe, etc.) can initiate asynchronous I/O and socket requests
and get a Perl level callback when that operation is complete. This
single api can be used for all common events like socket conecctions
(client and server), terminal I/O, mouse events, socket I/O, timers and
even file I/O.

=head2 Callbacks

A typical asynch I/O call might look like this:

	$sock->read( buf => \$buffer, cb => $obj, timeout => 10 ) ;

The cb argument is the callback and its value can be a code ref or an
object. If it is a code ref that sub is called when the socket has data
to be read.

If cb is an object then the default 'readable' method on $obj is invoked
when data could be read from the socket. You can select your own method
with the 'method' argument. Similarly for the timeout, it calls the
'read_timed_out' method by default if that is triggered before any data
is readable. By using well chosen default method names which makes them
easy to use, we make asynchronous I/O calls much simpler and
consistant.

=head2 Event Loop

Event loops have two common API's which can coexist. The most common one
is that you setup callbacks and then call a main_loop function. It does
all the event management and dispatches callbacks. The main line of code
is effectively blocked as only callbacks ever execute. There are some
minor variants to this but that is how Event.pm and Perl/Tk both work.

The other style is for for the main line code to explicitly request the
next event and it does its own dispatching. Event.pm supports this by a
call that gets the next pending event. This call can be made blocking or
non-blocking giving the coder fine control.

Setting up the callbacks is done with the async I/O interface discussed
elsewhere. All the coder has to do to use the event loop is decide to
use the built in amin loop or use his own. You can even use both of them
at the same time. You might want to check for events in the middle of a
very long event handler (which wa dispatched by the built in main loop).

=head2 Threads

I propose that Perl6 threads be in the core (not a compile time option)
and with a proper design and implementation will be effective and
efficient.

I agree with the idea of RFC 27 that the best map of Perl and threads so
far is one complete Perl interpreter per thread. It also has each
interpreter/thread pair with its own complete global namespace with no
implicitly shared Perl level data between threads. All sharing must be
done explicitly (and that design is a whole other RFC). There has to be
a Perlish way for threads to communicate with each other. A form of high
level queues or working with the event loop are possibilities. Also
asynchronous I/O and signals need to work with threads.

One idea is to have a special signal mailbox (think semaphore/queue/pipe
combo) on which any thread can test and block.  That mailbox is toggled
when a signal occurs (e.g. asynch I/O under Unix usually notifies
completion by a signal), and the thread can get the signal info from the
queue. This synchoronizes signals with the op dispatch loop of the
interpreter. The thread which gets the signal can then do work or
communicate with other threads.

=head2 Safe Signals

There are multiple ways to support safe signals and they can all easily
be supported.

Event loops support safe signals by delivering them synchronously with
the dispatch of other callbacks. Then the signal callback cannot collide
with any others. This is currently being done in Event.pm (and i think
Perl/Tk's event loop is similar here).

Threads can work with signals in two ways. First, one or more threads can
run event loops and the signal handlers are safe and can do work or
communicate with other threads. Second, any thread can block on the
special signal mailbox. When the signal is delivered, the blocked thread
can continue safely and can then do the work for that signal.

If you have only a single linear thread of code and want safe signals,
you have to pay the penalty of checking for them in between Perl op
codes. This can be done every N ops with N being some special global
value. The code to do the test can be done inline in the main dispatch
loop and be very fast. The actual C handlers will just be like the ones
in the event loop and just bump counters and set flags.

I propose a pragma which would make this more of a top level
operation and remove the need for the %SIG hash. It would be somthing
like this:

use signal name => 'SIGHUP', cb => \&hup_handler, timeout => 1000 ;

This pragma would use the same callback interface as all the new I/O
object would. This consistancy of callback style in the language is a
major win here. Again the default method names would be carefully chosen
to be easy to remember and use, e.g. sighup_received and sighup_timeout
would be the ones for the above example if the cb value was an object.

The pragma would be stackable so you could override a handler inside a
code block.

=head2 Timers

All callback methods in this RFC support timeouts.  A timer is created
by using the timeout arguments to the async call.  Dispatching the main
callback will reset the timer clock.  If the timer goes off it will
dispatch its callback.

You can also have freestanding timers assoicated with no I/O handle. I
haven't worked out a syntax yet but it will have the same callback api
as the other async calls.

Note: even if we support finer grained timing than alarm's 1 second, we
should not promote Perl timer support as being truly real time. Timer
callbacks are delivered some time after the the actual timeout period
elapsed. The is no guarantee of speedy delivery only synchronous
delivery is supported.

=head2 Sockets

The two blocking socket operations are connect and accept. They are
supported by all event loops as the wizards of Berkeley had the wisdom
to make those tests supported in select. If only they had also added
async file I/O and signals! So in keeping in the vein of callbacks, the
API is propose is the exact same but with the socket handle calling
connect and accept methods

	$err = IO::Connect( port => 80, cb => $sock_obj ) ;

That has a default timeout builtin, localhost is assumed, the default
callback names are used (connected, connect_timeout), etc.
The callback looks like this:

package Foo ;

sub connected {
	my( $self, $socket ) = @_ ;
}

Similarly for accept:

	$err = IO::Accept( port => 80, cb => $sock_obj ) ;

You now have a 1 line server. It will call the accepted method of
$sock_obj whenever a connection rewuest is received.

Note: I do not want to eliminate all the low level ways of doing
sockets. But we could hide those names under a pragma? or just support
them all in the I/O object way that perl 5 does.

Note: The proposed ideas regarding a net smart open() which can do
http, ftp, etc. can be supported by this design. All that is needed is
some sugar to overlay them.

=head2 Asynchronous I/O

Asynchronous file I/O is just done like any other I/O with a
callback. If the underlying OS supports true asynch file I/O (Solaris,
VMS and i think NT and W2K do) then Perl will use it. Otherwise it is
faked just by using regular file I/O calls which will block.

To use asynch I/O you have to be under an event loop or do the same test
every Nth op code like with signals.

If you are using threads, then you can just have a thread block on a
regular file I/O call and manage multiple requests that way or just have
a thread run an event loop. So there is need to do special support for
async I/O under threads.

=head2 IMPACT

All of the areas brought up impact each other in complex ways in both
the language and the internal areas. That is why this RFC proposes they
get their own sub-group. The goal is to minimize their impact on each
other which would happen if they were designed separately.

The requirement that each thread have its own interpreter and global
storage, means the perl interpreter has to be completely reentrant.

Some of this code could be included in a dynamic library (most of it has
to be in C for speed and safety). Loading it could be done with pragmas.

=head2 UNKNOWNS

Designing the internals for this will be tricky. The best way to support
all these needs is not clear.

=head1 REFERENCES

IO::*			- Perl 5 I/O modules

perl-loop@perl.org	- Mailing list on Perl Event loops

Event.pm		- XS based event loop module.

Perl/Tk			- Tk based module with its own event loop

POE			- Perl Object Enviroment, an event based system

Stem			- A message passing system based on events.

Thread.pm		- Perl 5 threads

RFC #1			- Implementation of Threads in Perl

RFC #27			- Coroutines

aioread, aiowait	- Solaris asynchronous I/O

aio_read, aio_wait	- POSIX asynchronous I/O

redpajama_set_name: RedPajamaGithub


text:
/* your styles go here */
@charset "UTF-8";
/*
Theme Name: Tracks
Theme URI: https://www.competethemes.com/tracks/
Author: Compete Themes
Author URI: https://www.competethemes.com
Description: A bold, beautiful, and responsive theme. Tracks is perfect for personal blogs, magazines, and photography websites. It includes a logo uploader, over 50+ social media icons, search bar, comment display controls, premium layouts, and more. Tracks has a dark, simple, and minimalist design that makes it great for publish both text and image based content. Use it for a travel blog, online newspaper, video site, or podcast. As a free theme, you can use Tracks for as many projects as you'd like. Preview Tracks now on desktop, tablets, and mobile devices with the interactive live demo: https://www.competethemes.com/demos/?theme=tracks
Version: 1.59
Tags: one-column, custom-logo, custom-menu, editor-style, featured-image-header, featured-images, footer-widgets, full-width-template, sticky-post, theme-options, threaded-comments, translation-ready, blog, photography, portfolio
Text Domain: tracks
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html

Tracks WordPress Theme, Copyright 2017 Compete Themes
Tracks is distributed under the terms of the GNU GPL
*/
/*===== Variables =====*/
/* Theme Colors */
.site-title, .toggle-navigation i {
  font-size: 1.625em;
  line-height: 1.85;
}

.wp-caption-text, .excerpt-meta, .entry-meta, .more-link, .pagination, .further-reading span,
.further-reading a,
.entry-categories span,
.entry-categories a,
.entry-tags span,
.entry-tags a, .author-meta .author span, .comments-number h2, .comment-author div, .design-credit, .singular-attachment .attachment-caption, .widget li, .menu-footer-items a, .menu-secondary-items a {
  font-size: 0.813em;
  line-height: 1.85;
}

.entry-container, .comments {
  padding: 0 5.55%;
}

.site-title, .menu-unset > ul a,
.menu-primary-items a, .excerpt-meta, .entry-meta, .excerpt-title, .entry-title, .more-link, .pagination, .further-reading,
.entry-categories,
.entry-tags, .author-meta .author span, .comments-number h2, .comment-author .author-name, .site-footer h1, .design-credit, .widget-title, .widget li, .menu-footer-items a, .menu-secondary-items a {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

/* Social Media Brand Colors */
/*===== Mixins =====*/
/* grid stuff */
/* Baseline Grid
background-image: linear-gradient(#fff 23px, #00fffc 24px, #fff 0px);
background-size: 1px 24px; /* this is a 24px baseline grid */
/* Column Grid
background-color: gray;
background-image: linear-gradient(90deg, transparent 99%, rgba(255,255,255,.5) 0%);
background-size: 11.1%; /* This is at 6-columns -> just change this # */
/*===== Basic Styles =====*/
/* apply a natural box layout model to all elements */
*, *:before, *:after {
  box-sizing: border-box;
}

body {
  height: 100%;
  font-size: 100%;
  margin: 0;
  padding: 0;
  font-family: "raleway", sans-serif;
  line-height: 1.5;
  color: #4d4d4d;
  background: #222;
  -webkit-font-smoothing: antialiased;
  word-wrap: break-word;
  -ms-word-wrap: break-word;
}

.overflow-container {
  overflow: hidden;
  position: relative;
  height: auto;
  min-height: 100%;
}

.main {
  background: #222;
  padding-bottom: 1.5em;
  margin: 0 auto;
}

.loop-container:after {
  content: ".";
  display: block;
  clear: both;
  visibility: hidden;
  line-height: 0;
  height: 0;
}

p {
  margin: 1.5em 0;
}

a {
  text-decoration: none;
  color: #222;
  -webkit-transition: all 0.2s ease;
  transition: all 0.2s ease;
}
a:link {
  color: #222;
}
a:visited, a:hover, a:active, a:focus {
  color: black;
}

article a {
  text-decoration: underline;
}

h1, h2, h3, h4, h5, h6 {
  font-family: "raleway", sans-serif;
  margin: 0;
  padding: 0;
  font-weight: 400;
}

h1 {
  font-size: 2.625em;
  /* 42px / 16px */
  line-height: 1.143;
}

h2 {
  font-size: 2.25em;
  /* 36px / 16px */
  line-height: 1.34;
}

h3 {
  font-size: 1.625em;
  /* 26px / 16px */
  line-height: 1.85;
}

h4 {
  font-size: 1.313em;
  /* 21px / 16px */
  line-height: 1.143;
}

h5 {
  font-size: 1.125em;
  /* 18px / 16px */
  line-height: 1.34;
}

h6 {
  font-size: 1em;
  line-height: 1.5;
}

ul,
ol {
  font-size: 1em;
  padding: 0;
  margin: 1.5em;
}
ul ul, ul ol,
ol ul,
ol ol {
  margin: 0 1.5em;
}

ul ul,
ol ol,
ul ol,
ol ul,
li li {
  font-size: 1em;
}

/* Markup styles */
pre {
  word-wrap: break-word;
  -ms-word-wrap: break-word;
  word-break: break-all;
  white-space: pre-wrap;
  padding: 0.75em;
  background: #f5f5f5;
}

code {
  padding: 0 0.375em;
  background: #f5f5f5;
}

blockquote {
  margin: 1.5em 0;
  padding: 0 1.5em;
  border-left: solid 0.75em #222;
}
blockquote cite {
  display: block;
  text-align: right;
}

hr {
  margin: 0.69em 0;
}

/* Table styles */
table {
  border-spacing: 0;
  border-collapse: collapse;
  margin: 1.5em 0;
}

td {
  padding: 0.5em 0.75em;
  border: solid 1px #4d4d4d;
  line-height: 1.5;
}

th {
  padding: 0.5em 0.75em;
  border: solid 1px #4d4d4d;
  line-height: 1.5;
}

/* Images */
.alignright,
.alignleft,
.aligncenter,
.alignnone,
.size-auto,
.size-full,
.size-large,
.size-medium,
.size-thumbnail {
  height: auto;
  line-height: 0;
  max-width: 100%;
  max-width: calc(100% - 48px);
}
.alignright img,
.alignleft img,
.aligncenter img,
.alignnone img,
.size-auto img,
.size-full img,
.size-large img,
.size-medium img,
.size-thumbnail img {
  max-width: 100%;
}

.alignleft {
  float: left;
  margin: 0 1.5em 1.5em 0;
}

.alignright {
  float: right;
  margin: 0 0 1.5em 1.5em;
}

.aligncenter {
  text-align: center;
  margin: 1.5em auto;
  display: block;
  max-width: 100%;
}

.alignnone {
  margin: 1.5em;
}

img {
  height: auto;
  line-height: 0;
}

.singular-attachment img {
  max-width: 100%;
}

.wp-caption-text {
  margin: 0;
  color: #8c8c8c;
}

.wp-caption.aligncenter {
  max-width: none;
  margin: 0 auto;
  width: auto !important;
}

/* Form styles */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="search"],
input[type="tel"],
input[type="url"],
textarea {
  padding: 0.8em;
  width: 100%;
  max-width: 27.75em;
  min-height: 45px;
  outline: solid 1px #000;
  border: none;
  font-family: "raleway", sans-serif;
  font-size: 0.813em;
  line-height: 1.85;
  border-radius: 0;
  -webkit-appearance: none;
  -webkit-transition: all 0.2s ease;
          transition: all 0.2s ease;
}

textarea {
  max-width: 41.625em;
  overflow: auto;
}

input[type="submit"] {
  background: #222;
  color: white;
  max-width: 22.2em;
  min-width: 11.1em;
  padding: 0.8em;
  min-height: 45px;
  outline: none;
  border: none;
  font-family: "raleway", sans-serif;
  font-size: 0.813em;
  line-height: 1.85;
  border-radius: 0;
  -webkit-appearance: none;
  -webkit-transition: all 0.2s ease;
          transition: all 0.2s ease;
}
input[type="submit"]:hover, input[type="submit"]:active, input[type="submit"]:focus {
  cursor: pointer;
  background: black;
}

input[type="search"] {
  margin-right: 1.5em;
  padding-right: 0.375em;
  /* so safari 'x' doesn't get cut off */
}

/* sticky */
.excerpt.sticky .excerpt-container {
  background: wheat;
}

/* ie image border fix */
a img {
  border: none;
}

.screen-reader-text {
  position: absolute;
  clip: rect(1px 1px 1px 1px);
  /* IE6, IE7 */
  clip: rect(1px, 1px, 1px, 1px);
  overflow: hidden;
  height: 1px;
  width: 1px;
}

.skip-content {
  position: absolute;
  width: 100%;
  background: #111;
  color: #aaaaaa;
  text-align: center;
  padding: 0.375em;
  top: -4.5em;
  z-index: 19;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.skip-content:active, .skip-content:focus {
  top: 0;
  color: #ffffff;
}

.search .sticky {
  background: white;
}

.blog .main,
.archive .main,
.search .main {
  width: 88.89%;
  max-width: 1280px;
}
.blog #breadcrumbs,
.archive #breadcrumbs,
.search #breadcrumbs {
  width: 100%;
}

.entry {
  max-width: 1280px;
}

.infinite-loader,
#infinite-handle {
  clear: both;
}

#breadcrumbs {
  margin: 1.5em auto;
  width: 88.88%;
  max-width: 1280px;
  color: #aaaaaa;
}
#breadcrumbs a {
  color: #fff;
}

@media only screen and (min-device-width: 320px) and (max-device-width: 480px) and (orientation: landscape) {
  html {
    -webkit-text-size-adjust: none;
    /* none for no scaling */
  }
}
@media only screen and (min-device-width: 768px) and (max-device-width: 1024px) and (orientation: landscape) {
  html {
    -webkit-text-size-adjust: none;
    /* none for no scaling */
  }
}
.site-header {
  padding: 0.75em 5.55%;
}
.site-header .container {
  margin: 0 auto;
  max-width: 1280px;
}
.site-header:after {
  content: ".";
  display: block;
  clear: both;
  visibility: hidden;
  line-height: 0;
  height: 0;
}

.title-info {
  float: left;
  position: relative;
  z-index: 29;
}

.site-title {
  letter-spacing: 0.06em;
  opacity: 0.6;
  -webkit-transition: opacity 0.2s ease;
          transition: opacity 0.2s ease;
}
.site-title span {
  opacity: 0;
  position: absolute;
  top: -99em;
}
.site-title a {
  color: white;
}
.site-title a:link, .site-title a:visited, .site-title a:hover, .site-title a:active, .site-title a:focus {
  color: white;
}
.site-title img {
  max-width: 5em;
  max-height: 1.5em;
}
.site-title:hover, .site-title:active, .site-title:focus {
  opacity: 1;
}

.toggle-navigation {
  position: relative;
  float: right;
  z-index: 29;
  border: none;
  background: none;
  font-size: 1em;
  margin: 0;
  padding: 0 0 0 1.5em;
  color: white;
  opacity: 0.6;
  -webkit-transition: opacity 0.2s ease;
          transition: opacity 0.2s ease;
}
.toggle-navigation:hover, .toggle-navigation:active, .toggle-navigation:focus {
  opacity: 1;
  cursor: pointer;
  outline: none;
}

.menu-primary, .menu-primary-tracks {
  -webkit-transform: translateZ(0);
          transform: translateZ(0);
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
  position: absolute;
  top: 0;
  padding-top: 6em;
  left: 100%;
  height: 100%;
  width: 100%;
  z-index: 19;
  background-image: -webkit-linear-gradient(#222 26px, transparent 24px, transparent 24px);
  background-image: linear-gradient(#222 26px, transparent 24px, transparent 24px);
  background-size: 1px 48px;
  /* this is a 24px baseline grid */
  text-align: center;
  -webkit-transition: all 0.3s ease-in-out;
          transition: all 0.3s ease-in-out;
}

.menu-primary-tracks {
  top: 1.5em;
  left: -100%;
  z-index: 19;
}

.site-header .site-description {
  opacity: 0;
  color: white;
}

.menu-unset > ul,
.menu-primary-items {
  list-style: none;
  opacity: 0;
}
.menu-unset > ul a,
.menu-primary-items a {
  display: block;
  color: white;
  opacity: 0.6;
  margin: 1.5em 0 0.75em 0;
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
}
.menu-unset > ul a:only-child,
.menu-primary-items a:only-child {
  margin: 1.5em 0;
}
.menu-unset > ul a:link, .menu-unset > ul a:visited,
.menu-primary-items a:link,
.menu-primary-items a:visited {
  color: white;
}
.menu-unset > ul a:hover, .menu-unset > ul a:active, .menu-unset > ul a:focus,
.menu-primary-items a:hover,
.menu-primary-items a:active,
.menu-primary-items a:focus {
  opacity: 1;
}
.menu-unset > ul .sub-menu,
.menu-unset > ul .children,
.menu-primary-items .sub-menu,
.menu-primary-items .children {
  list-style: none;
}
.menu-unset > ul .sub-menu li a,
.menu-unset > ul .children li a,
.menu-primary-items .sub-menu li a,
.menu-primary-items .children li a {
  margin: 0.75em 0;
  opacity: 0.4;
}
.menu-unset > ul .sub-menu li a:hover, .menu-unset > ul .sub-menu li a:active, .menu-unset > ul .sub-menu li a:focus,
.menu-unset > ul .children li a:hover,
.menu-unset > ul .children li a:active,
.menu-unset > ul .children li a:focus,
.menu-primary-items .sub-menu li a:hover,
.menu-primary-items .sub-menu li a:active,
.menu-primary-items .sub-menu li a:focus,
.menu-primary-items .children li a:hover,
.menu-primary-items .children li a:active,
.menu-primary-items .children li a:focus {
  opacity: 1;
}

.site-header.toggled .menu-unset > ul,
.site-header.toggled .menu-primary-items,
.site-header.toggled .site-description {
  -webkit-transition: opacity 0.3s 0.3s ease;
          transition: opacity 0.3s 0.3s ease;
}
.site-header.toggled .menu-primary, .site-header.toggled .menu-primary-tracks,
.site-header.toggled .menu-primary-tracks {
  left: 0;
}
.site-header.toggled .menu-unset > ul,
.site-header.toggled .menu-primary-items {
  opacity: 1;
}
.site-header.toggled .site-description {
  opacity: 0.9;
}

/* 800px */
@media all and (min-width: 50em) {
  .site-header {
    position: relative;
    z-index: 2;
    padding: 1.5em 5.55% 2.25em;
    border-top: solid 0.75em #111;
  }

  .title-info {
    margin-top: -0.75em;
  }

  .site-title img {
    max-width: 8em;
    max-height: 3em;
  }

  .toggle-navigation {
    display: none;
  }

  .menu-primary, .menu-primary-tracks {
    background: none;
    position: static;
    width: 100%;
    height: auto;
    padding: 0;
    margin: 0;
    text-align: right;
    min-height: 37px;
  }
  .menu-primary .site-description, .menu-primary-tracks .site-description {
    position: absolute;
    left: 0;
    opacity: 0.6;
  }
  .menu-primary .site-description + div, .menu-primary-tracks .site-description + div {
    margin-bottom: 0.75em;
  }

  .ie9 .site-description {
    left: 5.55%;
  }

  .menu-primary-tracks {
    display: none;
  }

  .menu-unset > ul,
  .menu-primary-items {
    margin: 0 0 0 3em;
    opacity: 1;
    /* Tier 2 */
    /* Tier 3 */
  }
  .menu-unset > ul li,
  .menu-unset > ul a,
  .menu-primary-items li,
  .menu-primary-items a {
    display: inline-block;
  }
  .menu-unset > ul li,
  .menu-primary-items li {
    position: relative;
  }
  .menu-unset > ul > li,
  .menu-primary-items > li {
    font-size: 0.813em;
    line-height: 1.85;
  }
  .menu-unset > ul > li:after,
  .menu-primary-items > li:after {
    content: '/';
    position: absolute;
    right: -6px;
    top: 0;
    color: white;
    opacity: 0.6;
  }
  .menu-unset > ul > li:last-child:after,
  .menu-primary-items > li:last-child:after {
    display: none;
  }
  .menu-unset > ul > li:last-child a,
  .menu-primary-items > li:last-child a {
    margin-right: 0;
  }
  .menu-unset > ul a,
  .menu-primary-items a {
    opacity: 0.6;
    margin: 0 0.75em;
  }
  .menu-unset > ul a:only-child,
  .menu-primary-items a:only-child {
    margin: 0 0.75em;
  }
  .menu-unset > ul ul,
  .menu-primary-items ul {
    position: absolute;
    top: -9999px;
    opacity: 0;
    left: -70%;
    right: -70%;
    min-width: 100%;
    max-width: 220px;
    margin: 0 auto;
    background: #111;
    text-align: center;
    -webkit-transition: opacity 0.3s ease, -webkit-transform 0.3s ease;
            transition: opacity 0.3s ease, transform 0.3s ease;
    -webkit-transform: scale(0.95);
            transform: scale(0.95);
  }
  .menu-unset > ul ul li,
  .menu-unset > ul ul a,
  .menu-primary-items ul li,
  .menu-primary-items ul a {
    display: block;
  }
  .menu-unset > ul ul:hover,
  .menu-primary-items ul:hover {
    top: 24px;
    opacity: 1;
    -webkit-transform: scale(1);
            transform: scale(1);
  }
  .menu-unset > ul ul a,
  .menu-primary-items ul a {
    padding: 0 1.5em;
  }
  .menu-unset > ul ul li:first-child > a,
  .menu-primary-items ul li:first-child > a {
    padding-top: 0.75em;
  }
  .menu-unset > ul ul li:last-child > a,
  .menu-primary-items ul li:last-child > a {
    padding-bottom: 0.75em;
  }
  .menu-unset > ul a:hover + ul, .menu-unset > ul a:active + ul, .menu-unset > ul a:focus + ul,
  .menu-primary-items a:hover + ul,
  .menu-primary-items a:active + ul,
  .menu-primary-items a:focus + ul {
    top: 24px;
    opacity: 1;
    -webkit-transform: scale(1);
            transform: scale(1);
  }
  .menu-unset > ul ul ul,
  .menu-primary-items ul ul {
    left: auto;
    right: 100%;
  }
  .menu-unset > ul ul ul:hover,
  .menu-primary-items ul ul:hover {
    top: -0.75em;
  }
  .menu-unset > ul ul a:hover + ul, .menu-unset > ul ul a:active + ul, .menu-unset > ul ul a:focus + ul,
  .menu-primary-items ul a:hover + ul,
  .menu-primary-items ul a:active + ul,
  .menu-primary-items ul a:focus + ul {
    top: -0.75em;
  }
}
.excerpt-container {
  padding: 0 5.55%;
  position: relative;
  z-index: 9;
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
}

.excerpt {
  text-align: center;
  background: white;
  overflow: hidden;
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
  margin-bottom: 1.5em;
}

.featured-image {
  position: relative;
  height: 0;
  padding-bottom: 50%;
  background-position: 50%;
  background-size: cover;
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
  -webkit-transition: -webkit-transform 0.3s ease;
          transition: transform 0.3s ease;
}

.zoom .featured-image-link {
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
}
.zoom .featured-image-link:hover .featured-image, .zoom .featured-image-link:active .featured-image, .zoom .featured-image-link:focus .featured-image {
  -webkit-transform: scale(1.05);
          transform: scale(1.05);
  -moz-transform: scale(1.05) rotate(0.02deg);
}

.excerpt-meta, .entry-meta {
  color: #aaaaaa;
  padding-top: 1.84502em;
}
.excerpt-meta a, .entry-meta a {
  color: #aaaaaa;
}
.excerpt-meta a:link, .entry-meta a:link, .excerpt-meta a:visited, .entry-meta a:visited {
  color: #aaaaaa;
}
.excerpt-meta a:hover, .entry-meta a:hover, .excerpt-meta a:active, .entry-meta a:active, .excerpt-meta a:focus, .entry-meta a:focus {
  color: #222;
}

.excerpt-title, .entry-title {
  letter-spacing: 0.04em;
  font-size: 1.313em;
  /* 21px / 16px */
  line-height: 1.143;
}
.excerpt-title a, .entry-title a {
  color: #4d4d4d;
}
.excerpt-title a:link, .entry-title a:link, .excerpt-title a:visited, .entry-title a:visited {
  color: #4d4d4d;
}
.excerpt-title a:hover, .entry-title a:hover, .excerpt-title a:active, .entry-title a:active, .excerpt-title a:focus, .entry-title a:focus {
  color: #222;
}

.excerpt-header, .entry-header {
  position: relative;
}
.excerpt-header:after, .entry-header:after {
  content: '';
  position: absolute;
  background: #4d4d4d;
  width: 4.5em;
  height: 0.375em;
  left: 0;
  right: 0;
  margin: 0 auto;
  bottom: -1.5em;
}

.excerpt-content {
  padding: 1.5em 0;
}

.more-link {
  position: relative;
  text-decoration: none;
  color: #4d4d4d;
  clear: both;
}
.more-link:link, .more-link:visited {
  color: #4d4d4d;
}
.more-link:hover, .more-link:active, .more-link:focus {
  color: #222;
}
.more-link:hover:after, .more-link:active:after, .more-link:focus:after {
  -webkit-transform: scaleX(1);
          transform: scaleX(1);
}
.more-link:after {
  content: '';
  position: absolute;
  width: 1.5em;
  height: 3px;
  background: #4d4d4d;
  bottom: -0.75em;
  left: 0;
  right: 0;
  margin: 0 auto;
  -webkit-transition: all 0.2s ease;
          transition: all 0.2s ease;
  -webkit-transform: scaleX(0);
          transform: scaleX(0);
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
}

.pagination {
  text-align: center;
  padding: 1.5em;
  margin-bottom: -1.5em;
}
.pagination a,
.pagination span {
  margin: 0 0.375em;
  color: #8c8c8c;
}
.pagination a:link,
.pagination a:visited {
  color: #8c8c8c;
}
.pagination a:hover, .pagination:active, .pagination:focus {
  color: #aaaaaa;
}

.infinite-scroll .pagination {
  display: none;
}

/* 600 */
@media all and (min-width: 37.5em) {
  .excerpt {
    background: #111;
    margin-bottom: 1.5em;
  }
  .excerpt:first-child {
    padding-top: 0;
  }

  .excerpt-container {
    background: white;
    padding: 0 6.2%;
  }

  .pagination {
    padding: 0.75em 1.5em 3em;
  }

  .excerpt-title, .entry-title {
    font-size: 1.875em;
    /* 30px */
    line-height: 1.6;
  }
}
/* 900px */
@media all and (min-width: 56.25em) {
  .excerpt-container {
    width: 50%;
    padding: 0 5.55%;
  }

  .excerpt {
    -webkit-transform: translateZ(0);
            transform: translateZ(0);
    /* fix weird chrome wiggle glitch */
    position: relative;
    clear: both;
    padding: 0;
    margin-bottom: 1.5em;
    opacity: 0.8;
  }
  .excerpt .featured-image {
    -webkit-transform: translateZ(0);
            transform: translateZ(0);
    /* fixes FF glitch where image focuses & unfocuses */
    width: 50%;
    width: calc(50% + 2px);
    height: 100%;
    padding-bottom: 0;
    position: absolute;
    right: -1px;
  }
  .excerpt:hover {
    opacity: 1;
  }

  .excerpt.even .excerpt-container {
    float: right;
  }
  .excerpt.even .featured-image {
    right: auto;
    left: -1px;
  }
  .excerpt.even:after {
    content: ".";
    display: block;
    clear: both;
    visibility: hidden;
    line-height: 0;
    height: 0;
  }

  .rtl .excerpt.odd .excerpt-container {
    float: left;
  }

  .excerpt-meta, .entry-meta {
    padding-top: 3.69004em;
  }

  .excerpt-content {
    padding-bottom: 3em;
  }

  .full-without-featured:not(.has-post-thumbnail):not(.has-video):not(.has-featured-slider) .excerpt-container {
    width: 100%;
  }
}
.entry {
  background: white;
  padding-bottom: 1.5em;
}

.entry-meta {
  text-align: center;
}

.entry-header {
  text-align: center;
}

.entry-meta,
.entry-header {
  padding-left: 5.55%;
  padding-right: 5.55%;
}

.entry-content {
  margin: 3em 0;
}
.entry-content img.full-width {
  position: relative;
  max-width: none;
  width: 113%;
  left: -6.5%;
}
.entry-content iframe {
  max-width: 100%;
}
.entry-content:after {
  content: ".";
  display: block;
  clear: both;
  visibility: hidden;
  line-height: 0;
  height: 0;
}

.further-reading span,
.entry-categories span,
.entry-tags span {
  display: block;
}
.further-reading a,
.entry-categories a,
.entry-tags a {
  font-weight: 400;
  color: #8c8c8c;
}
.further-reading a:link, .further-reading a:visited,
.entry-categories a:link,
.entry-categories a:visited,
.entry-tags a:link,
.entry-tags a:visited {
  color: #8c8c8c;
}
.further-reading a:hover, .further-reading a:active, .further-reading a:focus,
.entry-categories a:hover,
.entry-categories a:active,
.entry-categories a:focus,
.entry-tags a:hover,
.entry-tags a:active,
.entry-tags a:focus {
  color: black;
}

.entry-categories a,
.entry-tags a {
  margin-right: 0.375em;
}

.entry-meta-bottom {
  margin-bottom: 3em;
}

.author-meta {
  background: #222;
  color: white;
  padding: 1.5em;
  margin: 3em 0 0;
}
.author-meta a {
  color: #8c8c8c;
}
.author-meta a:link, .author-meta a:visited {
  color: #8c8c8c;
}
.author-meta a:hover, .author-meta a:active, .author-meta a:focus {
  color: white;
}
.author-meta p {
  clear: both;
}
.author-meta .author img {
  float: left;
  margin: 0 0.75em 1.5em 0;
  width: 4.5em;
  height: 4.5em;
  border-radius: 50%;
}
.author-meta .author a {
  font-weight: 400;
  letter-spacing: 0.1em;
  display: block;
}
.author-meta .bio a {
  margin-right: 0.375em;
  display: inline-block;
}

/* 600px */
@media all and (min-width: 37.5em) {
  .entry {
    width: 88.88%;
    margin: 0 auto;
  }

  .entry-container {
    padding: 0 5.55%;
  }

  .further-reading p {
    display: inline-block;
    width: 50%;
    vertical-align: top;
    padding-right: 3em;
  }
  .further-reading .prev {
    float: left;
  }
  .further-reading .next {
    float: right;
    text-align: right;
    padding: 0 0 0 3em;
  }
  .further-reading:after {
    content: ".";
    display: block;
    clear: both;
    visibility: hidden;
    line-height: 0;
    height: 0;
  }

  .author-meta .author {
    display: inline-block;
  }
  .author-meta .author img {
    margin-bottom: 0;
  }
  .author-meta:after {
    content: ".";
    display: block;
    clear: both;
    visibility: hidden;
    line-height: 0;
    height: 0;
  }

  .bio {
    float: right;
    width: 50%;
  }
  .bio p {
    margin-top: 0;
  }
}
/* 700px */
@media all and (min-width: 43.75em) {
  .entry-container {
    padding: 0 11.11%;
  }

  .entry-meta,
  .entry-header {
    padding-left: 5.55%;
    padding-right: 5.55%;
  }

  .entry-content img.full-width {
    width: 128.6%;
    left: -14.3%;
  }
}
/* 900px */
@media all and (min-width: 56.25em) {
  .entry .featured-image:after {
    position: absolute;
    content: '';
    background: #222;
    top: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    opacity: 0.2;
    -webkit-transition: opacity 0.2s ease;
            transition: opacity 0.2s ease;
  }
  .entry .featured-image:hover:after {
    opacity: 0;
  }

  .entry-container {
    padding: 0 16.66%;
  }

  .entry-header h1 {
    font-size: 4.25em;
    line-height: 1.06;
  }

  .entry-meta {
    font-size: 1em;
    line-height: 1.5;
    padding-top: 3em;
    letter-spacing: 0.08em;
  }

  .entry-content {
    margin-top: 4.5em;
  }
  .entry-content img.full-width {
    width: 150%;
    left: -25%;
  }
}
/* 1100px */
@media all and (min-width: 68.75em) {
  .entry-meta,
  .entry-header {
    padding-left: 11.11%;
    padding-right: 11.11%;
  }

  .entry-container {
    padding: 0 19.435%;
    position: relative;
  }

  .entry-content img.full-width {
    width: 163.6%;
    left: -31.8%;
  }

  .entry-meta-bottom.float .entry-tags,
  .entry-meta-bottom.float .entry-categories {
    position: absolute;
    width: 16.66%;
    left: 0;
    top: 4.5em;
    text-align: right;
    padding-left: 5.55%;
  }
  .entry-meta-bottom.float .entry-tags a,
  .entry-meta-bottom.float .entry-categories a {
    font-weight: 700;
    text-transform: none;
    letter-spacing: 0;
    display: block;
    margin-right: 0;
  }
}
/* 1200px */
@media all and (min-width: 75em) {
  .entry-container {
    padding: 0 22.22%;
  }

  .entry-content img.full-width {
    width: 179.9%;
    left: -39.95%;
  }
}
.comments {
  background: white;
  padding-bottom: 3em;
  max-width: 1280px;
}

.comments-number {
  padding: 1.5em 0;
}

.comment-list {
  list-style: none;
  margin: 0;
}
.comment-list ul {
  list-style: none;
  margin: 3em 0 1.5em 3em;
}
.comment-list article ul {
  list-style: disc;
}

li.comment,
li.pingback {
  margin: 3em 0;
}
li.comment:first-child,
li.pingback:first-child {
  margin-top: 1.5em;
}

.comment-author {
  /* contains everything but the avatar */
}
.comment-author img {
  width: 4.5em;
  height: 4.5em;
  border-radius: 50%;
  float: left;
  margin: 0 0.75em 0 0;
}
.comment-author .author-name a {
  text-decoration: none;
  color: #4d4d4d;
}
.comment-author .author-name a:link, .comment-author .author-name a:visited {
  color: #4d4d4d;
}
.comment-author .author-name a:hover, .comment-author .author-name a:active, .comment-author .author-name a:focus {
  color: #222;
}
.comment-author:after {
  content: ".";
  display: block;
  clear: both;
  visibility: hidden;
  line-height: 0;
  height: 0;
}

.comment-reply-link,
.comment-edit-link {
  color: #4d4d4d;
  text-decoration: none;
}
.comment-reply-link:link, .comment-reply-link:visited,
.comment-edit-link:link,
.comment-edit-link:visited {
  color: #4d4d4d;
}
.comment-reply-link:hover, .comment-reply-link:active, .comment-reply-link:focus,
.comment-edit-link:hover,
.comment-edit-link:active,
.comment-edit-link:focus {
  color: black;
}

.comment-edit-link:before {
  content: " / ";
}

.comment-content {
  margin: 1.5em 0;
}

.bypostauthor > article .author-name:after {
  content: ' (author)';
  text-transform: none;
  font-weight: 400;
  letter-spacing: 0;
}

/* 600px */
@media all and (min-width: 37.5em) {
  .comments {
    padding: 0 5.55% 3em;
    width: 88.88%;
    margin: 0 auto;
  }

  .comment-pagination p {
    width: 50%;
    display: inline-block;
    vertical-align: top;
    text-align: left;
  }
  .comment-pagination .next-comment {
    text-align: right;
  }
}
/* 700px */
@media all and (min-width: 43.75em) {
  .comments {
    padding: 0 11.11% 3em;
  }
}
/* 900px */
@media all and (min-width: 56.25em) {
  .comments {
    padding: 0 16.66% 3em;
  }
}
/* 1000px */
@media all and (min-width: 62.5em) {
  li.comment article,
  li.pingback article {
    line-height: 0;
    /* this is messing up the vertical rhythm */
  }
  li.comment article:after,
  li.pingback article:after {
    content: ".";
    display: block;
    clear: both;
    visibility: hidden;
    line-height: 0;
    height: 0;
  }

  .comment-author {
    display: inline-block;
    min-height: 4.5em;
  }
  .comment-author img {
    float: none;
  }
  .comment-author div {
    display: inline-block;
    vertical-align: top;
  }
  .comment-author div div {
    display: block;
  }

  .comment-content {
    float: right;
    width: 50%;
    margin: 0;
    line-height: 1.5;
    /* after turning it off on article */
  }
  .comment-content p {
    line-height: 1.5;
  }
  .comment-content p:first-child {
    margin-top: 0;
  }
  .comment-content p:last-child {
    margin-bottom: 0;
  }
}
/* 1100px */
@media all and (min-width: 68.75em) {
  .comments {
    padding: 0 19.435% 3em;
  }
}
/* 1445px */
@media all and (min-width: 1445px) {
  .comments {
    padding: 0 284px 3em;
  }
}
.site-footer {
  color: #8c8c8c;
  text-align: center;
  padding-top: 3em;
  overflow: hidden;
  clear: both;
}
.site-footer a {
  color: #8c8c8c;
}
.site-footer h1 {
  letter-spacing: 0.06em;
  opacity: 0.4;
  -webkit-transition: opacity 0.2s ease;
          transition: opacity 0.2s ease;
}
.site-footer h1:hover, .site-footer h1:active, .site-footer h1:focus {
  opacity: 0.9;
}
.site-footer p {
  margin: 0 0 1.5em;
  opacity: 0.6;
}
.site-footer .social-media-icons {
  margin: 0.75em 0 1.5em;
}
.site-footer .social-media-icons a {
  opacity: 0.4;
}

.sidebar-footer {
  background: #1A1A1A;
  margin-bottom: -48px;
  padding: 1.5em 5.55%;
}
.sidebar-footer .widget {
  margin: 3em 0;
}
.sidebar-footer .widget:first-child {
  margin-top: 1.5em;
}
.sidebar-footer .widget a:hover, .sidebar-footer .widget a:active, .sidebar-footer .widget a:focus {
  color: #ededed;
}
.sidebar-footer .widget-title {
  margin-bottom: 12px;
}

.design-credit {
  background: #111;
  color: #8c8c8c;
  padding: 0.75em 0;
  margin-top: 48px;
}
.design-credit a {
  color: #8c8c8c;
}
.design-credit a:link, .design-credit a:visited {
  color: #8c8c8c;
}
.design-credit a:hover, .design-credit a:active, .design-credit a:focus {
  color: #aaaaaa;
}
.design-credit p {
  margin: 0;
  opacity: 0.6;
}

.return-top {
  display: none;
}

/* 600px */
@media all and (min-width: 37.5em) {
  .return-top {
    display: block;
    position: fixed;
    bottom: -4em;
    right: 0;
    width: 5.55%;
    height: 4em;
    background: white;
    border: none;
    opacity: 0.8;
    text-align: center;
    line-height: 4em;
    outline: none;
    -webkit-transition: all 0.3s ease;
            transition: all 0.3s ease;
  }
  .return-top i {
    position: relative;
    top: 0;
    -webkit-transition: top 0.3s ease;
            transition: top 0.3s ease;
  }

  .return-top.visible {
    bottom: 0;
  }
  .return-top.visible:hover, .return-top.visible:active, .return-top.visible:focus {
    opacity: 1;
    cursor: pointer;
  }
  .return-top.visible:hover i, .return-top.visible:active i, .return-top.visible:focus i {
    top: -6px;
  }

  .sidebar-footer {
    margin-bottom: -72px;
  }

  .design-credit {
    margin-top: 72px;
  }
}
/* 700px */
@media all and (min-width: 43.75em) {
  .sidebar-footer {
    margin-top: 3em;
  }
  .sidebar-footer:after {
    content: ".";
    display: block;
    clear: both;
    visibility: hidden;
    line-height: 0;
    height: 0;
  }

  .sidebar-footer:not(.active-1) .widget {
    width: 47%;
    float: left;
    margin-top: 1.5em;
  }
  .sidebar-footer:not(.active-1) .widget:nth-child(odd) {
    margin-right: 3%;
  }
}
/* 900px */
@media all and (min-width: 56.25em) {
  .site-footer h1 {
    font-size: 2.625em;
    line-height: 1.143;
  }
}
/* 1000px */
@media all and (min-width: 62.5em) {
  .sidebar-footer:not(.active-1):not(.active-2) .widget {
    width: 31%;
    margin-right: 0;
    margin-top: 1.5em;
  }
  .sidebar-footer:not(.active-1):not(.active-2) .widget:nth-child(3n - 2), .sidebar-footer:not(.active-1):not(.active-2) .widget:nth-child(3n - 1) {
    margin-right: 3%;
  }
  .sidebar-footer:not(.active-1):not(.active-2) .widget:nth-child(3n + 4) {
    clear: left;
  }
}
/* page */
.singular-page .entry,
.error404 .entry,
.search .entry {
  padding-top: 3em;
}

.singular-page .featured-image {
  margin-top: -3em;
  margin-bottom: 3em;
}

.error404 input,
.search input {
  margin: 0.75em 0;
}
.error404 input[type="search"],
.search input[type="search"] {
  margin-right: 0.75em;
}

.search-form-container {
  margin: 1.5em 0 3em;
}
.search-form-container .search-icon {
  display: none;
}

.archive-header {
  padding: 1.5em 0;
  text-transform: uppercase;
  color: #8c8c8c;
}
.archive-header span {
  letter-spacing: 0.08em;
}
.archive-header h1 {
  letter-spacing: 0.06em;
  font-weight: 700;
  font-size: 1em;
  line-height: 1.5;
  display: inline-block;
}
.archive-header p {
  margin: 0.75em 0;
  text-transform: none;
}

.archive .main {
  padding-bottom: 0;
}

.search .search-box {
  padding: 1.5em;
  margin-bottom: 1.5em;
  background: white;
  text-align: center;
  clear: both;
}
.search .search-box .search-form-container {
  margin-bottom: 1.5em;
}
.search .search-box.bottom {
  margin-top: 1.5em;
}

.page-template-full-width .entry {
  width: 100%;
  max-width: none;
}
.page-template-full-width .entry-container {
  padding: 0 5%;
  max-width: 1280px;
  margin: 0 auto;
}

/* 900px */
@media all and (min-width: 56.25em) {
  .search-form-container {
    margin: 1.5em 0 4.5em;
  }
}
/* Attachment styles */
.singular-attachment .further-reading a {
  font-weight: 700;
  font-size: 1em;
  line-height: 1.5;
  color: #8c8c8c;
}
.singular-attachment .further-reading a:link, .singular-attachment .further-reading a:visited {
  color: #8c8c8c;
}
.singular-attachment .further-reading a:hover, .singular-attachment .further-reading a:active, .singular-attachment .further-reading a:focus {
  color: black;
}
.singular-attachment .further-reading p {
  width: 49.5%;
}
.singular-attachment .attachment-container img {
  display: block;
}

/* Widget Area Styles */
.sidebar-after-post-content,
.sidebar-after-page-content {
  padding: 3em 0 0.75em;
  border-top: solid 1px #ededed;
  border-bottom: solid 1px #ededed;
  margin-bottom: 1.5em;
}
.sidebar-after-post-content .widget,
.sidebar-after-page-content .widget {
  margin-bottom: 2.25em;
}

/* Widget Styles */
.widget-title {
  font-size: 1em;
  line-height: 1.5;
}

.widget ul {
  margin: 1.5em 0;
  list-style: none;
}
.widget li {
  font-weight: 400;
}
.widget li a {
  color: #8c8c8c;
}
.widget li a:link, .widget li a:visited {
  color: #8c8c8c;
}
.widget li a:hover, .widget li a:active, .widget li a:focus {
  color: black;
}

.widget-search .search-form-container {
  margin-bottom: 3em;
}

.site-footer .widget_search .search-field {
  max-width: none;
}
.site-footer .widget_search .search-submit {
  background: #4d4d4d;
  width: 100%;
  max-width: none;
  min-width: none;
}

.widget_categories select {
  margin-top: 1.5em;
}

@media all and (min-width: 50em) {
  .site-footer .widget_search .search-form {
    display: -webkit-box;
    display: flex;
  }
  .site-footer .widget_search .search-field,
  .site-footer .widget_search .search-submit {
    width: auto;
  }
  .site-footer .widget_search .search-field {
    margin-right: 0;
    -webkit-box-flex: 1;
            flex-grow: 1;
  }
}
/* Footer menu styles */
.menu-footer-items {
  list-style: none;
  margin: 0.75em 0 1.5em;
}
.menu-footer-items li {
  position: relative;
  display: block;
}
.menu-footer-items a {
  color: #8c8c8c;
  opacity: 0.4;
}
.menu-footer-items a:link, .menu-footer-items a:visited {
  color: #8c8c8c;
}
.menu-footer-items a:hover, .menu-footer-items a:active, .menu-footer-items a:focus {
  color: #8c8c8c;
  opacity: 0.9;
}
.menu-footer-items ul {
  list-style: none;
}

/* 700px */
@media all and (min-width: 43.75em) {
  .menu-footer-items li,
  .menu-footer-items a {
    display: inline-block;
  }
  .menu-footer-items a {
    margin: 0 8px;
  }
  .menu-footer-items a:hover + ul, .menu-footer-items a:active + ul, .menu-footer-items a:focus + ul {
    bottom: 24px;
    opacity: 1;
    -webkit-transform: scale(1);
            transform: scale(1);
  }
  .menu-footer-items .sub-menu {
    position: absolute;
    background: #1A1A1A;
    text-align: center;
    margin: 0;
    min-width: 100%;
    max-width: 220px;
    left: auto;
    right: auto;
    bottom: -9999px;
    -webkit-transition: opacity 0.3s ease, -webkit-transform 0.3s ease;
            transition: opacity 0.3s ease, transform 0.3s ease;
    -webkit-transform: scale(0.95);
            transform: scale(0.95);
  }
  .menu-footer-items .sub-menu:hover {
    bottom: 24px;
    opacity: 1;
    -webkit-transform: scale(1);
            transform: scale(1);
  }
  .menu-footer-items .sub-menu a {
    display: block;
    margin: 0;
    padding: 0.75em 1.5em;
  }
  .menu-footer-items .sub-menu .sub-menu:hover {
    bottom: 0;
    left: 100%;
    right: auto;
  }
  .menu-footer-items .sub-menu a:hover + ul, .menu-footer-items .sub-menu a:active + ul, .menu-footer-items .sub-menu a:focus + ul {
    bottom: 0;
    left: 100%;
    right: auto;
  }
}
/* top navigation styles */
.top-navigation {
  position: relative;
  left: -6%;
  width: 112%;
  min-height: 3em;
  background: #111;
  padding: 0.375em 5.55%;
  margin: -0.75em 0 0;
  line-height: 0;
}
.top-navigation ~ button {
  top: 2.25em;
}
.top-navigation .container {
  margin: 0 auto;
  max-width: 1280px;
}
.top-navigation .container:after {
  content: ".";
  display: block;
  clear: both;
  visibility: hidden;
  line-height: 0;
  height: 0;
}

.rtl .top-navigation {
  right: -6%;
}

/* 600px */
@media all and (min-width: 37.5em) {
  .top-navigation {
    margin-top: -0.75em;
    left: -6.2%;
    width: 112.4%;
    z-index: 39;
  }
}
/* 800px */
@media all and (min-width: 50em) {
  .top-navigation {
    margin: -2.25em 0 1.5em 0;
  }
}
/* secondary menu styles */
.menu-secondary {
  float: left;
  z-index: 9;
}

.toggle-secondary-navigation {
  background: none;
  border: none;
  color: white;
  opacity: 0.4;
  font-size: 1.313em;
  /* 21px / 16px */
  line-height: 1.714;
  margin: 0;
  padding: 0;
  outline: none;
  -webkit-transition: -webkit-transform 0.3s ease;
          transition: transform 0.3s ease;
}
.toggle-secondary-navigation:hover {
  cursor: pointer;
}

.menu-secondary-items {
  list-style: none;
  position: absolute;
  z-index: -1;
  opacity: 0;
  width: 100%;
  left: 0;
  padding: 1.5em;
  margin: 0;
  background: #111;
  -webkit-transition: all 0.3s ease;
          transition: all 0.3s ease;
}
.menu-secondary-items a {
  color: white;
  opacity: 0.4;
  margin-right: 0.75em;
}
.menu-secondary-items a:link, .menu-secondary-items a:visited {
  color: white;
}
.menu-secondary-items a:hover, .menu-secondary-items a:active, .menu-secondary-items a:focus {
  color: white;
  opacity: 0.9;
}
.menu-secondary-items ul {
  list-style: none;
}

/* when secondary menu is open */
#main, #title-info, #toggle-navigation, #site-header, #site-footer {
  -webkit-transition: -webkit-transform 0.3s ease;
          transition: transform 0.3s ease;
}

.secondary-toggle .site-header {
  background: transparent;
}
.secondary-toggle .toggle-secondary-navigation {
  opacity: 0.9;
  -webkit-transform: rotate(315deg);
          transform: rotate(315deg);
}
.secondary-toggle .menu-secondary-items {
  z-index: 1;
  opacity: 1;
}

/* 600px */
@media all and (min-width: 37.5em) {
  .menu-secondary-items {
    position: relative;
    z-index: 1;
    opacity: 1;
    padding: 0.5em 0;
  }
  .menu-secondary-items:before {
    content: '//';
    margin-right: 16px;
    color: white;
    opacity: 0.4;
  }
  .menu-secondary-items li,
  .menu-secondary-items a {
    display: inline-block;
  }

  .toggle-secondary-navigation {
    display: none;
  }

  .menu-secondary-items {
    /* Tier 2 */
    /* Tier 3 */
  }
  .menu-secondary-items li {
    position: relative;
  }
  .menu-secondary-items ul {
    position: absolute;
    top: -9999px;
    margin: 0 auto;
    left: -70%;
    right: -70%;
    max-width: 200px;
    opacity: 0;
    background: #111;
    text-align: center;
    -webkit-transform: scale(0.95);
            transform: scale(0.95);
    -webkit-transition: opacity 0.3s ease, -webkit-transform 0.3s ease;
            transition: opacity 0.3s ease, transform 0.3s ease;
  }
  .menu-secondary-items ul li,
  .menu-secondary-items ul a {
    display: block;
  }
  .menu-secondary-items ul a {
    padding: 0 1.5em;
    margin: 0.75em 0;
  }
  .menu-secondary-items ul li:first-child > a {
    padding-top: 0.75em;
  }
  .menu-secondary-items ul li:last-child > a {
    padding-bottom: 0.75em;
  }
  .menu-secondary-items ul:hover {
    top: 1.5em;
    opacity: 1;
    -webkit-transform: scale(1);
            transform: scale(1);
  }
  .menu-secondary-items a:hover + ul, .menu-secondary-items a:active + ul, .menu-secondary-items a:focus + ul {
    top: 1.5em;
    opacity: 1;
    -webkit-transform: scale(1);
            transform: scale(1);
  }
  .menu-secondary-items ul ul:hover {
    left: 100%;
    right: -100%;
    top: -0.60975em;
  }
  .menu-secondary-items ul a:hover + ul, .menu-secondary-items ul a:active + ul, .menu-secondary-items ul a:focus + ul {
    left: 100%;
    right: -100%;
    top: -0.60975em;
  }
}
/* search form styles */
.site-header .search-form-container {
  position: absolute;
  right: 5.55%;
  left: 12.55%;
  top: 0;
  height: 100%;
  margin: 0;
}
.site-header .search-form-container button {
  -webkit-transform: translateZ(0);
          transform: translateZ(0);
  position: relative;
  z-index: 9;
  display: block;
  left: 0;
  height: 100%;
  float: right;
  border: none;
  background: #111;
  font-size: 1em;
  padding: 0.75em;
  margin: 0 -12px 0 0;
  outline: none;
  -webkit-transition: all 0.3s ease;
          transition: all 0.3s ease;
}
.site-header .search-form-container button:hover i, .site-header .search-form-container button:active i {
  opacity: 1;
}
.site-header .search-form-container button:hover {
  cursor: pointer;
}
.site-header .search-form-container i {
  position: relative;
  z-index: 9;
  color: white;
  opacity: 0.4;
  line-height: 1.5;
  -webkit-transition: opacity 0.2s ease;
          transition: opacity 0.2s ease;
}
.site-header .search-form-container input {
  margin: 0;
  height: 100%;
  position: absolute;
}
.site-header .search-form-container .search-form {
  -webkit-transform: translateZ(0);
          transform: translateZ(0);
  position: absolute;
  top: 0;
  z-index: 19;
  left: 107%;
  width: 90%;
  height: 100%;
  -webkit-transition: all 0.3s ease;
          transition: all 0.3s ease;
}
.site-header .search-form-container input.search-field {
  width: 80%;
  left: 0;
  max-width: none !important;
  outline: none !important;
}
.site-header .search-form-container input.search-submit {
  width: 30%;
  right: 0;
  max-width: none !important;
  min-width: 0 !important;
  outline: none !important;
}
.site-header .search-form-container + ul {
  margin-right: 3.75em;
}

.search-open .site-header .search-form {
  -webkit-transform: translateX(-100%);
          transform: translateX(-100%);
}
.search-open .site-header .search-form-container {
  left: 5.55%;
}
.search-open .site-header .search-form-container button {
  width: 24%;
}
.search-open .site-header .search-form-container i {
  opacity: 1;
}

.rtl .site-header .search-form-container input.search-field {
  width: calc(100% - 120px) !important;
  right: 120px;
}

/* 600px */
@media all and (min-width: 37.5em) {
  .search-open .site-header .search-form-container button {
    width: auto;
  }

  .site-header .search-form-container .search-form {
    width: 20em;
  }
  .site-header .search-form-container input.search-submit {
    min-width: 120px !important;
  }
}
/* social icon styling */
.social-media-icons {
  list-style: none;
  margin: 0;
  -webkit-transition: opacity 0.3s ease-in-out, -webkit-transform 0.2s ease-in-out;
          transition: opacity 0.3s ease-in-out, transform 0.2s ease-in-out;
}
.social-media-icons li,
.social-media-icons a {
  display: inline-block;
}
.social-media-icons a {
  font-size: 1.313em;
  /* 21px / 16px */
  line-height: 1.714;
  margin: 0 0.375em;
  color: white;
  opacity: 0.4;
  position: relative;
  z-index: 9;
}
.social-media-icons a:link, .social-media-icons a:visited {
  color: white;
}
.social-media-icons a:hover, .social-media-icons a:active, .social-media-icons a:focus {
  color: white;
  opacity: 1;
}

.site-header .social-media-icons {
  float: right;
  height: 100%;
}

.search-open .site-header .social-media-icons {
  opacity: 0;
  -webkit-transform: translateX(12px);
          transform: translateX(12px);
}

@media all and (min-width: 1500px) {
  .top-navigation .social-media-icons {
    margin-right: 0px !important;
  }
}
/**
 * 14.2 Galleries
 */
.gallery {
  margin: 2.25em auto;
}

.gallery-item {
  display: inline-block;
  padding: 0.75em;
  text-align: center;
  vertical-align: top;
  width: 100%;
  margin: 0;
}
.gallery-item img {
  max-width: 100%;
  max-height: 100%;
}

.gallery-columns-2 .gallery-item {
  max-width: 50%;
}

.gallery-columns-3 .gallery-item {
  max-width: 33.33%;
}

.gallery-columns-4 .gallery-item {
  max-width: 25%;
}

.gallery-columns-5 .gallery-item {
  max-width: 20%;
}

.gallery-columns-6 .gallery-item {
  max-width: 16.66%;
}

.gallery-columns-7 .gallery-item {
  max-width: 14.28%;
}

.gallery-columns-8 .gallery-item {
  max-width: 12.5%;
}

.gallery-columns-9 .gallery-item {
  max-width: 11.11%;
}

.gallery-icon img {
  margin: 0 auto;
}

.gallery-caption {
  color: #8c8c8c;
  display: block;
  font-family: "raleway", sans-serif;
  font-size: 12px;
  padding: 0.5em 0;
}

.gallery-columns-6 .gallery-caption,
.gallery-columns-7 .gallery-caption,
.gallery-columns-8 .gallery-caption,
.gallery-columns-9 .gallery-caption {
  display: none;
}

/* Jetpack Galleries */
.tiled-gallery {
  margin: 2.25em auto !important;
}
.tiled-gallery .gallery-row {
  margin: 0 auto;
}

/* Styles for when user selects a dark header */
.dark-header {
  /* Secondary Nav */
  /* Search Icon */
}
.dark-header .site-title a {
  color: #222;
}
.dark-header .site-title a:link, .dark-header .site-title a:visited, .dark-header .site-title a:hover, .dark-header .site-title a:active, .dark-header .site-title a:focus {
  color: #222;
}
.dark-header .toggle-navigation {
  color: #222;
}
.dark-header .site-header .site-description {
  color: #222;
}
.dark-header .site-header .social-media-icons a {
  color: #222;
}
.dark-header .site-header .social-media-icons a:link, .dark-header .site-header .social-media-icons a:visited {
  color: #222;
}
.dark-header .site-header .social-media-icons a:hover, .dark-header .site-header .social-media-icons a:active, .dark-header .site-header .social-media-icons a:focus {
  color: #222;
}
.dark-header .toggle-secondary-navigation {
  color: #222;
}
.dark-header .menu-secondary-items a,
.dark-header .menu-secondary-items a:link,
.dark-header .menu-secondary-items a:visited,
.dark-header .menu-secondary-items a:hover,
.dark-header .menu-secondary-items a:active,
.dark-header .menu-secondary-items a:focus {
  color: #222;
}
.dark-header .site-header .search-form-container i {
  color: #222;
}
.dark-header .site-header.toggled .site-title a {
  color: white;
}
.dark-header .site-header.toggled .site-title a:link, .dark-header .site-header.toggled .site-title a:visited, .dark-header .site-header.toggled .site-title a:hover, .dark-header .site-header.toggled .site-title a:active, .dark-header .site-header.toggled .site-title a:focus {
  color: white;
}
.dark-header .site-header.toggled .toggle-navigation {
  color: white;
}
.dark-header .site-header.toggled .site-description {
  color: white;
}

/* 600px */
@media all and (min-width: 37.5em) {
  .dark-header .menu-secondary-items:before {
    color: #222;
  }
  .dark-header .menu-secondary-items ul {
    background: white;
  }
}
/* 800px */
@media all and (min-width: 50em) {
  .dark-header .menu-unset > ul a,
  .dark-header .menu-primary-items a {
    color: #222;
  }
  .dark-header .menu-unset > ul a:link, .dark-header .menu-unset > ul a:visited,
  .dark-header .menu-primary-items a:link,
  .dark-header .menu-primary-items a:visited {
    color: #222;
  }
  .dark-header .menu-unset > ul > li:after,
  .dark-header .menu-primary-items > li:after {
    color: #222;
  }
  .dark-header .menu-unset > ul ul,
  .dark-header .menu-primary-items ul {
    background: white;
  }
}
/* background image styles */
.background-image-active .background-image {
  background-size: cover;
  background-position: 50%;
  position: fixed;
  z-index: -1;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
}
.background-image-active .site-header {
  border-color: transparent;
}
.background-image-active .excerpt {
  opacity: 1;
}
.background-image-active .site-header,
.background-image-active .site-header .search-form-container button,
.background-image-active .main,
.background-image-active .menu-secondary-items {
  background: none;
}
.background-image-active .top-navigation {
  background: rgba(255, 255, 255, 0.2);
}
.background-image-active .site-footer {
  background: #222;
}

/* background style textures */
.background-texture-active .site-header,
.background-texture-active .site-header .search-form-container button,
.background-texture-active .main,
.background-texture-active .menu-secondary-items {
  background: none;
}
.background-texture-active .site-header {
  border-color: transparent;
}
.background-texture-active .site-footer {
  background: #222;
}
.background-texture-active .top-navigation {
  background: rgba(255, 255, 255, 0.2);
}
.background-texture-active .excerpt {
  opacity: 1;
}

/* Featured Video styles */
.featured-video video {
  width: 100%;
}

.singular-page .featured-video {
  margin: -3em 0 3em;
}

.full-width-images.blog .excerpt.has-video,
.full-width-images.archive .excerpt.has-video,
.two-column-images.blog .excerpt.has-video,
.two-column-images.archive .excerpt.has-video {
  background: none;
}
.full-width-images.blog .excerpt.has-video .overlay,
.full-width-images.blog .excerpt.has-video .overlay-link,
.full-width-images.blog .excerpt.has-video i,
.full-width-images.archive .excerpt.has-video .overlay,
.full-width-images.archive .excerpt.has-video .overlay-link,
.full-width-images.archive .excerpt.has-video i,
.two-column-images.blog .excerpt.has-video .overlay,
.two-column-images.blog .excerpt.has-video .overlay-link,
.two-column-images.blog .excerpt.has-video i,
.two-column-images.archive .excerpt.has-video .overlay,
.two-column-images.archive .excerpt.has-video .overlay-link,
.two-column-images.archive .excerpt.has-video i {
  display: none;
}
.full-width-images.blog .excerpt.has-video .excerpt-container,
.full-width-images.archive .excerpt.has-video .excerpt-container,
.two-column-images.blog .excerpt.has-video .excerpt-container,
.two-column-images.archive .excerpt.has-video .excerpt-container {
  position: relative;
  opacity: 1;
}
.full-width-images.blog .excerpt.has-video .excerpt-header, .full-width-images.blog .excerpt.has-video .entry-header,
.full-width-images.archive .excerpt.has-video .excerpt-header,
.full-width-images.archive .excerpt.has-video .entry-header,
.two-column-images.blog .excerpt.has-video .excerpt-header,
.two-column-images.blog .excerpt.has-video .entry-header,
.two-column-images.archive .excerpt.has-video .excerpt-header,
.two-column-images.archive .excerpt.has-video .entry-header {
  padding: 0.75em 1.5em 1.5em;
}
.full-width-images.blog .excerpt.has-video .excerpt-title, .full-width-images.blog .excerpt.has-video .entry-title,
.full-width-images.archive .excerpt.has-video .excerpt-title,
.full-width-images.archive .excerpt.has-video .entry-title,
.two-column-images.blog .excerpt.has-video .excerpt-title,
.two-column-images.blog .excerpt.has-video .entry-title,
.two-column-images.archive .excerpt.has-video .excerpt-title,
.two-column-images.archive .excerpt.has-video .entry-title {
  font-size: 1em;
  line-height: 1.5;
}
.full-width-images.blog .excerpt.has-video .excerpt-title a, .full-width-images.blog .excerpt.has-video .entry-title a,
.full-width-images.archive .excerpt.has-video .excerpt-title a,
.full-width-images.archive .excerpt.has-video .entry-title a,
.two-column-images.blog .excerpt.has-video .excerpt-title a,
.two-column-images.blog .excerpt.has-video .entry-title a,
.two-column-images.archive .excerpt.has-video .excerpt-title a,
.two-column-images.archive .excerpt.has-video .entry-title a {
  color: white;
  opacity: 0.8;
}
.full-width-images.blog .excerpt.has-video .excerpt-title a:link, .full-width-images.blog .excerpt.has-video .entry-title a:link, .full-width-images.blog .excerpt.has-video .excerpt-title a:visited, .full-width-images.blog .excerpt.has-video .entry-title a:visited,
.full-width-images.archive .excerpt.has-video .excerpt-title a:link,
.full-width-images.archive .excerpt.has-video .entry-title a:link,
.full-width-images.archive .excerpt.has-video .excerpt-title a:visited,
.full-width-images.archive .excerpt.has-video .entry-title a:visited,
.two-column-images.blog .excerpt.has-video .excerpt-title a:link,
.two-column-images.blog .excerpt.has-video .entry-title a:link,
.two-column-images.blog .excerpt.has-video .excerpt-title a:visited,
.two-column-images.blog .excerpt.has-video .entry-title a:visited,
.two-column-images.archive .excerpt.has-video .excerpt-title a:link,
.two-column-images.archive .excerpt.has-video .entry-title a:link,
.two-column-images.archive .excerpt.has-video .excerpt-title a:visited,
.two-column-images.archive .excerpt.has-video .entry-title a:visited {
  color: white;
}
.full-width-images.blog .excerpt.has-video .excerpt-title a:hover, .full-width-images.blog .excerpt.has-video .entry-title a:hover, .full-width-images.blog .excerpt.has-video .excerpt-title a:active, .full-width-images.blog .excerpt.has-video .entry-title a:active, .full-width-images.blog .excerpt.has-video .excerpt-title a:focus, .full-width-images.blog .excerpt.has-video .entry-title a:focus,
.full-width-images.archive .excerpt.has-video .excerpt-title a:hover,
.full-width-images.archive .excerpt.has-video .entry-title a:hover,
.full-width-images.archive .excerpt.has-video .excerpt-title a:active,
.full-width-images.archive .excerpt.has-video .entry-title a:active,
.full-width-images.archive .excerpt.has-video .excerpt-title a:focus,
.full-width-images.archive .excerpt.has-video .entry-title a:focus,
.two-column-images.blog .excerpt.has-video .excerpt-title a:hover,
.two-column-images.blog .excerpt.has-video .entry-title a:hover,
.two-column-images.blog .excerpt.has-video .excerpt-title a:active,
.two-column-images.blog .excerpt.has-video .entry-title a:active,
.two-column-images.blog .excerpt.has-video .excerpt-title a:focus,
.two-column-images.blog .excerpt.has-video .entry-title a:focus,
.two-column-images.archive .excerpt.has-video .excerpt-title a:hover,
.two-column-images.archive .excerpt.has-video .entry-title a:hover,
.two-column-images.archive .excerpt.has-video .excerpt-title a:active,
.two-column-images.archive .excerpt.has-video .entry-title a:active,
.two-column-images.archive .excerpt.has-video .excerpt-title a:focus,
.two-column-images.archive .excerpt.has-video .entry-title a:focus {
  color: white;
  opacity: 1;
}

@media all and (min-width: 56.25em) {
  .excerpt .featured-video {
    -webkit-transform: translateZ(0);
            transform: translateZ(0);
    /* fixes FF glitch where image focuses & unfocuses */
    width: 50%;
    height: 100%;
    padding-bottom: 0;
    position: absolute;
    right: 0;
    -webkit-backface-visibility: hidden;
            backface-visibility: hidden;
  }
  .excerpt .featured-video div,
  .excerpt .featured-video video {
    position: relative;
    top: 50%;
    -webkit-transform: translateY(-50%);
            transform: translateY(-50%);
  }

  .excerpt.even .featured-video {
    right: 50%;
    right: calc(50% - 1px);
  }

  /* Premium Layouts */
  .full-width .excerpt .featured-video,
  .full-width-images .excerpt .featured-video,
  .two-column .excerpt .featured-video,
  .two-column-images .excerpt .featured-video {
    width: 100%;
    height: auto;
    position: relative;
    right: 0;
  }
  .full-width .excerpt .featured-video div,
  .full-width .excerpt .featured-video video,
  .full-width-images .excerpt .featured-video div,
  .full-width-images .excerpt .featured-video video,
  .two-column .excerpt .featured-video div,
  .two-column .excerpt .featured-video video,
  .two-column-images .excerpt .featured-video div,
  .two-column-images .excerpt .featured-video video {
    position: relative;
    top: 0;
    -webkit-transform: none;
            transform: none;
  }
}
/* 900px */
@media all and (min-width: 56.25em) {
  .ie9 .excerpt {
    opacity: 1;
  }
  .ie9 .excerpt:hover {
    opacity: 1;
  }
}
/* Styles for Disqus Comment System */
#disqus_thread {
  background: white;
  padding: 1.5em 5.55%;
  max-width: 1280px;
}

/* 600px */
@media all and (min-width: 37.5em) {
  #disqus_thread {
    width: 88.88%;
    margin: 0 auto;
  }
}
/* 700px */
@media all and (min-width: 43.75em) {
  #disqus_thread {
    padding: 1.5em 10%;
  }
}
/* 900px */
@media all and (min-width: 56.25em) {
  #disqus_thread {
    padding: 1.5em 14.66%;
  }
}
/* 1100px */
@media all and (min-width: 68.75em) {
  #disqus_thread {
    padding: 1.5em 17.435% 3em;
  }
}
/* 1200px */
@media all and (min-width: 75em) {
  #disqus_thread {
    padding: 1.5em 19.75% 3em;
  }
}
@media all and (min-width: 1400px) {
  #disqus_thread {
    padding: 1.5em 285px 3em;
  }
}
/* bbpress Styles */
.bbpress.archive .main {
  width: 100%;
  margin-bottom: 3em;
}

.entry-bbpress {
  padding-top: 3em;
}
.entry-bbpress .entry-container {
  padding: 0 11.11%;
}

#wp-bbp_topic_content-editor-container input,
#wp-bbp_reply_content-editor-container input {
  width: auto;
  padding: 6px 24px !important;
}
#wp-bbp_topic_content-editor-container textarea,
#wp-bbp_reply_content-editor-container textarea {
  outline: solid 1px #222;
  margin-top: 1.5em !important;
}

#bbp_topic_tags {
  max-width: 500px;
  font-size: 13px;
}

#bbp_topic_title {
  max-width: none;
}

.bbp-submit-wrapper button {
  background: #222;
  color: white;
  max-width: 22.2em !important;
  min-width: 11.1em;
  padding: 0.8em;
  min-height: 45px;
  outline: none;
  border: none;
  font-family: "raleway", sans-serif;
  font-size: 0.813em;
  line-height: 1.85;
  border-radius: 0;
  -webkit-appearance: none;
  -webkit-transition: all 0.2s ease;
          transition: all 0.2s ease;
}
.bbp-submit-wrapper button:hover, .bbp-submit-wrapper button:active, .bbp-submit-wrapper button:focus {
  cursor: pointer;
  background: black;
}

@media all and (min-width: 62.5em) {
  #bbp_topic_title {
    width: 70%;
  }
}
#bbpress-forums div.bbp-search-form {
  margin: 1px 0 12px 0;
}

@media all and (min-width: 43.75em) {
  #bbpress-forums #bbp-search-form #bbp_search {
    width: 500px !important;
  }
}
/*

ATTENTION:

Please do not edit this. Your changes will be overwritten when you update Tracks.

If you want to make CSS edits, use the "Custom CSS" section in the Customizer instead (Appearance > Customize).

If you want more information about customizing Tracks with CSS, check out this guide: https://www.competethemes.com/help/custom-css-tracks/

*/


text:
constexpr char const * kStreetObjectName = "addr:street";
constexpr char const * kHouseNumberObjectName = "addr:housenumber";
constexpr char const * kPostcodeObjectName = "addr:postcode";
constexpr char const * kInternetObjectName = "internet_access";

EditorDialog::EditorDialog(QWidget * parent, osm::EditableMapObject & emo)
  : QDialog(parent), m_feature(emo)
{
  QGridLayout * grid = new QGridLayout();
  int row = 0;

  {  // Coordinates.
    ms::LatLon const ll = emo.GetLatLon();
    grid->addWidget(new QLabel("Latitude/Longitude:"), row, 0);
    QHBoxLayout * coords = new QHBoxLayout();
    coords->addWidget(new QLabel(QString::fromStdString(strings::to_string_dac(ll.m_lat, 7) + " " +
                                                        strings::to_string_dac(ll.m_lon, 7))));
    grid->addLayout(coords, row++, 1);
  }

  {  // Feature types.
    grid->addWidget(new QLabel("Type:"), row, 0);

    string const raw = DebugPrint(m_feature.GetTypes());
    QLabel * label = new QLabel(QString::fromStdString(raw));
    label->setTextInteractionFlags(Qt::TextSelectableByMouse);
    grid->addWidget(label, row++, 1);
  }

  if (emo.IsNameEditable())
  {  // Names.
    char const * defaultLangStr =
        StringUtf8Multilang::GetLangByCode(StringUtf8Multilang::kDefaultCode);
    // Default name editor is always displayed, even if feature name is empty.
    grid->addWidget(new QLabel(QString("Name:")), row, 0);
    QLineEdit * defaultName = new QLineEdit();
    defaultName->setObjectName(defaultLangStr);
    QGridLayout * namesGrid = new QGridLayout();
    int namesRow = 0;
    namesGrid->addWidget(defaultName, namesRow++, 0, 1, 0);

    auto const namesDataSource = emo.GetNamesDataSource();

    for (auto const & ln : namesDataSource.names)
    {
      if (ln.m_code == StringUtf8Multilang::kDefaultCode)
      {
        defaultName->setText(QString::fromStdString(ln.m_name));
      }
      else
      {
        char const * langStr = StringUtf8Multilang::GetLangByCode(ln.m_code);
        namesGrid->addWidget(new QLabel(ln.m_lang), namesRow, 0);
        QLineEdit * lineEditName = new QLineEdit(QString::fromStdString(ln.m_name));
        lineEditName->setReadOnly(!emo.IsNameEditable());
        lineEditName->setObjectName(langStr);
        namesGrid->addWidget(lineEditName, namesRow++, 1);
      }
    }
    grid->addLayout(namesGrid, row++, 1);
  }

  if (emo.IsAddressEditable())
  {  // Address rows.
    auto nearbyStreets = emo.GetNearbyStreets();
    grid->addWidget(new QLabel(kStreetObjectName), row, 0);
    QComboBox * cmb = new QComboBox();
    cmb->setEditable(true);

    if (emo.GetStreet().m_defaultName.empty())
      cmb->addItem("");

    for (size_t i = 0; i < nearbyStreets.size(); ++i)
    {
      string street = nearbyStreets[i].m_defaultName;
      if (!nearbyStreets[i].m_localizedName.empty())
        street += " / " + nearbyStreets[i].m_localizedName;
      cmb->addItem(street.c_str());
      if (emo.GetStreet() == nearbyStreets[i])
        cmb->setCurrentIndex(static_cast<int>(i));
    }
    cmb->setObjectName(kStreetObjectName);
    grid->addWidget(cmb, row++, 1);

    grid->addWidget(new QLabel(kHouseNumberObjectName), row, 0);
    QLineEdit * houseLineEdit = new QLineEdit(emo.GetHouseNumber().c_str());
    houseLineEdit->setObjectName(kHouseNumberObjectName);
    grid->addWidget(houseLineEdit, row++, 1);

    grid->addWidget(new QLabel(kPostcodeObjectName), row, 0);
    QLineEdit * postcodeEdit = new QLineEdit(QString::fromStdString(emo.GetPostcode()));
    postcodeEdit->setObjectName(kPostcodeObjectName);
    grid->addWidget(postcodeEdit, row++, 1);
  }

  // Editable metadata rows.
  for (osm::Props const prop : emo.GetEditableProperties())
  {
    string v;
    switch (prop)
    {
    case osm::Props::Phone: v = emo.GetPhone(); break;
    case osm::Props::Fax: v = emo.GetFax(); break;
    case osm::Props::Email: v = emo.GetEmail(); break;
    case osm::Props::Website: v = emo.GetWebsite(); break;
    case osm::Props::Internet:
      {
        grid->addWidget(new QLabel(kInternetObjectName), row, 0);
        QComboBox * cmb = new QComboBox();
        string const values[] = {DebugPrint(osm::Internet::Unknown), DebugPrint(osm::Internet::Wlan),
                                 DebugPrint(osm::Internet::Wired), DebugPrint(osm::Internet::Yes),
                                 DebugPrint(osm::Internet::No)};
        for (auto const & v : values)
          cmb->addItem(v.c_str());
        cmb->setCurrentText(DebugPrint(emo.GetInternet()).c_str());
        cmb->setObjectName(kInternetObjectName);
        grid->addWidget(cmb, row++, 1);
      }
      continue;
    case osm::Props::Cuisine: v = strings::JoinStrings(emo.GetLocalizedCuisines(), ", "); break;
    case osm::Props::OpeningHours: v = emo.GetOpeningHours(); break;
    case osm::Props::Stars: v = strings::to_string(emo.GetStars()); break;
    case osm::Props::Operator: v = emo.GetOperator(); break;
    case osm::Props::Elevation:
      {
        double ele;
        if (emo.GetElevation(ele))
          v = strings::to_string_dac(ele, 2);
      }
      break;
    case osm::Props::Wikipedia: v = emo.GetWikipedia(); break;
    case osm::Props::Flats: v = emo.GetFlats(); break;
    case osm::Props::BuildingLevels: v = emo.GetBuildingLevels(); break;
    case osm::Props::Level: v = emo.GetLevel(); break;
    }
    QString const fieldName = QString::fromStdString(DebugPrint(prop));
    grid->addWidget(new QLabel(fieldName), row, 0);
    QLineEdit * lineEdit = new QLineEdit(QString::fromStdString(v));
    // Mark line editor to query it's text value when editing is finished.
    lineEdit->setObjectName(fieldName);
    grid->addWidget(lineEdit, row++, 1);
  }

  {  // Dialog buttons.
    QDialogButtonBox * buttonBox =
        new QDialogButtonBox(QDialogButtonBox::Cancel | QDialogButtonBox::Save);
    connect(buttonBox, SIGNAL(accepted()), this, SLOT(OnSave()));
    connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject()));
    // Delete button should send custom int return value from dialog.
    QPushButton * deletePOIButton = new QPushButton("Delete POI");
    QSignalMapper * signalMapper = new QSignalMapper();
    connect(deletePOIButton, SIGNAL(clicked()), signalMapper, SLOT(map()));
    signalMapper->setMapping(deletePOIButton, QDialogButtonBox::DestructiveRole);
    connect(signalMapper, SIGNAL(mapped(int)), this, SLOT(done(int)));
    buttonBox->addButton(deletePOIButton, QDialogButtonBox::DestructiveRole);
    grid->addWidget(buttonBox, row++, 1);
  }

  setLayout(grid);
  setWindowTitle("OSM Editor");
}

void EditorDialog::OnSave()
{
  // Store all edits.
  if (m_feature.IsNameEditable())
  {
    StringUtf8Multilang names;
    for (int8_t langCode = StringUtf8Multilang::kDefaultCode;
         langCode < StringUtf8Multilang::kMaxSupportedLanguages; ++langCode)
    {
      QLineEdit * le = findChild<QLineEdit *>(StringUtf8Multilang::GetLangByCode(langCode));
      if (!le)
        continue;
      string const name = le->text().toStdString();
      if (!name.empty())
        names.AddString(langCode, name);
    }
    m_feature.SetName(names);
  }

  if (m_feature.IsAddressEditable())
  {
    m_feature.SetHouseNumber(findChild<QLineEdit *>(kHouseNumberObjectName)->text().toStdString());
    QString const editedStreet = findChild<QComboBox *>(kStreetObjectName)->currentText();
    QStringList const names = editedStreet.split(" / ", QString::SkipEmptyParts);
    QString const localized = names.size() > 1 ? names.at(1) : QString();
    if (!names.empty())
      m_feature.SetStreet({names.at(0).toStdString(), localized.toStdString()});
    else
      m_feature.SetStreet({});
    m_feature.SetPostcode(findChild<QLineEdit *>(kPostcodeObjectName)->text().toStdString());
  }

  for (osm::Props const prop : m_feature.GetEditableProperties())
  {
    if (prop == osm::Props::Internet)
    {
      QComboBox * cmb = findChild<QComboBox *>(kInternetObjectName);
      string const str = cmb->currentText().toStdString();
      osm::Internet v = osm::Internet::Unknown;
      if (str == DebugPrint(osm::Internet::Wlan))
        v = osm::Internet::Wlan;
      else if (str == DebugPrint(osm::Internet::Wired))
        v = osm::Internet::Wired;
      else if (str == DebugPrint(osm::Internet::No))
        v = osm::Internet::No;
      else if (str == DebugPrint(osm::Internet::Yes))
        v = osm::Internet::Yes;
      m_feature.SetInternet(v);
      continue;
    }

    QLineEdit * editor = findChild<QLineEdit *>(QString::fromStdString(DebugPrint(prop)));
    if (!editor)
      continue;

    string const v = editor->text().toStdString();
    switch (prop)
    {
    case osm::Props::Phone: m_feature.SetPhone(v); break;
    case osm::Props::Fax: m_feature.SetFax(v); break;
    case osm::Props::Email: m_feature.SetEmail(v); break;
    case osm::Props::Website: m_feature.SetWebsite(v); break;
    case osm::Props::Internet: ASSERT(false, ("Is handled separately above."));
    case osm::Props::Cuisine:
    {
      vector<string> cuisines;
      strings::Tokenize(v, ";", base::MakeBackInsertFunctor(cuisines));
      m_feature.SetCuisines(cuisines);
    }
    break;
    case osm::Props::OpeningHours: m_feature.SetOpeningHours(v); break;
    case osm::Props::Stars:
    {
      int num;
      if (strings::to_int(v, num))
        m_feature.SetStars(num);
    }
    break;
    case osm::Props::Operator: m_feature.SetOperator(v); break;
    case osm::Props::Elevation:
    {
      double ele;
      if (strings::to_double(v, ele))
        m_feature.SetElevation(ele);
    }
    break;
    case osm::Props::Wikipedia: m_feature.SetWikipedia(v); break;
    case osm::Props::Flats: m_feature.SetFlats(v); break;
    case osm::Props::BuildingLevels: m_feature.SetBuildingLevels(v); break;
    case osm::Props::Level: m_feature.SetLevel(v); break;
    }
  }
  accept();
}


text:
/**
 * Pipedrive API v1
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 1.0.0
 *
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 *
 */

import ApiClient from '../ApiClient';
import ActivityResponseObject from './ActivityResponseObject';
import GetActivitiesResponse200RelatedObjects from './GetActivitiesResponse200RelatedObjects';
import ItemSearchAdditionalData from './ItemSearchAdditionalData';

/**
 * The GetActivitiesResponse200 model module.
 * @module model/GetActivitiesResponse200
 * @version 1.0.0
 */
class GetActivitiesResponse200 {
    /**
     * Constructs a new GetActivitiesResponse200.
     * @alias module:model/GetActivitiesResponse200
     */
    constructor() {

        GetActivitiesResponse200.initialize(this);
    }

    /**
     * Initializes the fields of this object.
     * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
     * Only for internal use.
     */
    static initialize(obj) {
    }

    /**
     * Constructs a GetActivitiesResponse200 from a plain JavaScript object, optionally creating a new instance.
     * Copies all relevant properties from data to obj if supplied or a new instance if not.
     * @param {Object} data The plain JavaScript object bearing properties of interest.
     * @param {module:model/GetActivitiesResponse200} obj Optional instance to populate.
     * @return {module:model/GetActivitiesResponse200} The populated GetActivitiesResponse200 instance.
     */
    static constructFromObject(data, obj) {
        if (data) {
            obj = obj || new GetActivitiesResponse200();

            if (data.hasOwnProperty('success')) {
                obj['success'] = ApiClient.convertToType(data['success'], 'Boolean');

                delete data['success'];
            }
            if (data.hasOwnProperty('data')) {
                obj['data'] = ApiClient.convertToType(data['data'], [ActivityResponseObject]);

                delete data['data'];
            }
            if (data.hasOwnProperty('additional_data')) {
                obj['additional_data'] = ItemSearchAdditionalData.constructFromObject(data['additional_data']);

                delete data['additional_data'];
            }
            if (data.hasOwnProperty('related_objects')) {
                obj['related_objects'] = GetActivitiesResponse200RelatedObjects.constructFromObject(data['related_objects']);

                delete data['related_objects'];
            }

            if (Object.keys(data).length > 0) {
                Object.assign(obj, data);
            }

        }
        return obj;
    }

}

/**
 * @member {Boolean} success
 */
GetActivitiesResponse200.prototype['success'] = undefined;

/**
 * @member {Array.<module:model/ActivityResponseObject>} data
 */
GetActivitiesResponse200.prototype['data'] = undefined;

/**
 * @member {module:model/ItemSearchAdditionalData} additional_data
 */
GetActivitiesResponse200.prototype['additional_data'] = undefined;

/**
 * @member {module:model/GetActivitiesResponse200RelatedObjects} related_objects
 */
GetActivitiesResponse200.prototype['related_objects'] = undefined;

export default GetActivitiesResponse200;


text:
import cProfile as profiler
import os
import pstats
import subprocess
import sys

import numpy as np

from numba import jit
from numba.tests.support import needs_blas
import unittest

def dot(a, b):
    sum = 0
    for i in range(len(a)):
        sum += a[i]*b[i]
    return sum

def np_dot(a, b):
    return np.dot(a, b)

class TestProfiler(unittest.TestCase):

    def check_profiler_dot(self, pyfunc):
        """
        Make sure the jit-compiled function shows up in the profile stats
        as a regular Python function.
        """
        a = np.arange(16, dtype=np.float32)
        b = np.arange(16, dtype=np.float32)
        cfunc = jit(nopython=True)(pyfunc)
        # Warm up JIT
        cfunc(a, b)
        p = profiler.Profile()
        p.enable()
        try:
            cfunc(a, b)
        finally:
            p.disable()
        stats = pstats.Stats(p).strip_dirs()
        code = pyfunc.__code__
        expected_key = (os.path.basename(code.co_filename),
                        code.co_firstlineno,
                        code.co_name,
                        )
        self.assertIn(expected_key, stats.stats)

    def test_profiler(self):
        self.check_profiler_dot(dot)

    @needs_blas
    def test_profiler_np_dot(self):
        # Issue #1786: initializing BLAS would crash when profiling
        code = """if 1:
            import cProfile as profiler

            import numpy as np

            from numba import jit
            from numba.tests.test_profiler import np_dot

            cfunc = jit(nopython=True)(np_dot)

            a = np.arange(16, dtype=np.float32)
            b = np.arange(16, dtype=np.float32)

            p = profiler.Profile()
            p.enable()
            cfunc(a, b)
            cfunc(a, b)
            p.disable()
            """
        subprocess.check_call([sys.executable, "-c", code])

    def test_issue_3229(self):
        # Issue #3229: Seemingly random segfaults when profiling due to
        # frame injection.
        # numba.tests.npyufunc.test_dufunc.TestDUFunc.test_npm_call is the
        # first test case crashing when profiling. Fingers crossed fixing
        # this is sufficient proof for the general case.

        code = """if 1:
            import cProfile as profiler
            p = profiler.Profile()
            p.enable()

            from numba.tests.npyufunc.test_dufunc import TestDUFunc
            t = TestDUFunc('test_npm_call')
            t.test_npm_call()

            p.disable()
            """
        subprocess.check_call([sys.executable, "-c", code])

if __name__ == '__main__':
    unittest.main()


text:
/* $Id$ */

package ibis.ipl.impl.nio;

import java.io.IOException;
import java.nio.channels.ReadableByteChannel;
import java.nio.channels.SelectableChannel;
import java.nio.channels.SelectionKey;
import java.nio.channels.Selector;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * Dissipator which reads from a single channel, with the channel normally in
 * non-blocking mode.
 */
final class NonBlockingChannelNioDissipator extends NioDissipator {
    private static Logger logger
            = LoggerFactory.getLogger(NonBlockingChannelNioDissipator.class);

    Selector selector;

    NonBlockingChannelNioDissipator(ReadableByteChannel channel)
            throws IOException {
        super(channel);

        if (!(channel instanceof SelectableChannel)) {
            throw new IOException("wrong type of channel given on creation of"
                    + " ChannelNioDissipator");
        }

        selector = Selector.open();
        SelectableChannel sc = (SelectableChannel) this.channel;
        sc.configureBlocking(false);
        sc.register(selector, SelectionKey.OP_READ);
    }

    /**
     * fills the buffer upto at least "minimum" bytes.
     *
     */
    protected void fillBuffer(int minimum) throws IOException {
        if (logger.isDebugEnabled()) {
            logger.debug("filling buffer");
        }

        // Always do one read, even if it isn't strictly needed
        // and without looking if we're going to get any data.
        readFromChannel();

        while (unUsedLength() < minimum) {
            if (logger.isDebugEnabled()) {
                logger.debug("doing a select for data");
            }
            selector.select();
            selector.selectedKeys().clear();
            readFromChannel();
        }

        if (logger.isDebugEnabled()) {
            logger.debug("filled buffer");
        }
    }

    public void close() throws IOException {
        selector.close();
        super.close();
    }
}