body {
  font-family: ‘Palatino Linotype’, ‘Book Antiqua’, Palatino, serif; 
  font-size: 21px;
  line-height: 1.505;
  background-color: #fefeff;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6, p, body, a, img, ul, ol, blockquote, pre {
  margin: 0; padding: 0; border: 0;
}

h1,h2,h3,h4 { 
  font-family:calibri, verdana, sans-serif; 
}

.content-wrap {
  width: 34em;
  margin: 0 auto;
}

body, a {
  color: #171717;
}

a:hover {
  color: #8080ff;
  text-decoration: underline;
}

p {
  margin-bottom: 1.52em;
}

pre {
  font-size: 0.9em;
  overflow: auto;
  background: #fff;
  border: 1px dashed #d2d2d2;
  border-radius: 0.25em;
  margin-bottom: 1.8em;
  padding: 1em;
}

h1 {
  font-size: 2em;
  margin-bottom: 1em;
}

h2 {
  font-style: italic;
  text-align: center;
  font-weight: 400;
  font-size: 1.4em;
  margin-top: 1.8em;
  margin-bottom: 0.8em;
}

h3 {
  font-size: 1.2em;
  font-weight: 400;
  line-height: 1.43;
  margin-bottom: 1.35em;
}

ol, ul {
  margin: 0 1.4em 1.4em 2em;
}

li {
  margin-bottom: 0.5em;
}

ol > li {
  font-size:0.8em;
  padding-left:0;
  margin-left:0;
}

blockquote {
  margin: 1.2em 3em;
  padding-left: 1em;
  font-style: italic;
}

hr {
  border: 0;
  border-top: 1px dashed #d2d2d2;
  height: 0;
  margin: 1.6em 0;
}

/* page header */

hr.bow {
  width:100%;
  height:0.1em;
  margin:0;
  border:0;
}

.red {
  background-color:#ff505f;
}

.yellow {
  background-color:#f5f05f;
}

.viored {
  background-color:#f50f5f;
}

.violet {
  background-color:#f505ff;
}

.blue {
  background-color:#505fff;
}

.sky {
  background-color:#55ccff;
}

.header {
  margin: 0;
  border-bottom:1px solid #ccc;
  width:100%;
  background-color:#55ccff;
}

.header h1 {
  font-size: 1em;
  text-align: left;
  font-weight: 700;
  margin:0;
}

.header h2 {
  font-size: 0.8em;
  font-weight: normal;
  text-align:left;
  margin:0;
  float:right;
  margin-top:-1.6em;
}

.header a, .header a:hover {
  text-decoration: none;
  color: #171717;
}

.header .author {
  font-family: ‘Palatino Linotype’, ‘Book Antiqua’, Palatino, serif;
  text-rendering: auto;
  text-align: left;
  font-weight: 400;
  letter-spacing: 1px;
}

.header .nav {
  font-family: ‘Palatino Linotype’, ‘Book Antiqua’, Palatino, serif;
  text-rendering: auto;
  text-align: left;
  font-weight: 400;
  letter-spacing: 1px;
}

.header .nav-list {
  padding:0;
  margin:0;
}

.header .nav-list > li {
  list-style: none;
  display:inline-block;
  margin:0;
  margin-right:10px;
}

.header .description {
  font-size: 1.2em;
  font-style: italic;
  text-align: center;
  margin-top: -0.3em;
}

body.article-detail > header > *:not(.logo) > h1 {
  font-size: 2.5em;
  font-style: italic;
  font-weight: 400;
  margin-bottom: -0.2em;
}

body.article-detail > header {
  margin-bottom: 3em;
}

body.article-detail .logo {
  border:0;
  margin-bottom:3em;
}

.thai {
  color:#505fff;
}

.calendaryear {
  font-size: 1.6em;
  width:100px;
}

/* page footer */

footer {
  margin: 3em 0;
}

footer .nav {
  text-align: center;
  margin-top: 5em;
  margin-bottom: 3.5em;
}

footer .nav a {
  padding: 0 0.5em;
  font-size: 1.2em;
  text-decoration: none;
}

footer .about {
  border-top: 1px dashed #d2d2d2;
  padding: 2.2em 3em;
  font-size: 0.7em;
  -webkit-column-count: 3;
  -moz-column-count: 3;
  -ms-column-count: 3;
  column-count: 3;
  -webkit-column-gap: 2em;
  -moz-column-gap: 2em;
  -ms-column-gap: 2em;
  column-gap: 2em;
}

footer .copy {
  text-align: center;
  font-size: 0.7em;
  font-style: italic;
  margin-top: 1em;
}

footer .copy, footer .copy a {
  color: #8e8e8e;
}

/* article */

.article {
  margin: 3em 0 4em;
}

.article header {
  border-top: 1px dashed #d2d2d2;
}

.article header h2 {
  font-style: italic;
  text-align: center;
  font-weight: 400;
  margin: 0.8em 0;
  font-size: 1.4em;
}

.article header h2 a {
  text-decoration: none;
}

.article header .date {
  text-align: center;
  font-size: 0.8em;
  margin-top: -0.7em;
}

.article header .date span {
  background-color: #fdfdff;
  padding: 0 0.7em;
}

.article.intro .content p {
  display: inline;
}

.article.intro .content .more {
  text-decoration: underline;
  font-weight: 700;
  padding-left: 0.3em;
}

.article .content img {
  display: block;
  width: 100%;
}

.more, .date {
  font-family: ‘Palatino Linotype’, ‘Book Antiqua’, Palatino, serif;
  font-variant: small-caps;
  text-transform: lowercase;
  font-weight: 400;
  text-rendering: auto;
  letter-spacing: 1px;
}

.author .date {
  font-size: 0.85em;
}

/* archive */

.archive {
  width: 32em;
  margin: 5em auto 6em;
  padding-left: 2em;
}

.archive h2 {
  font-size: 2em;
  margin: 0;
  margin-left: 6.1em;
  margin-bottom: 0.5em;
  font-style: italic;
}

.archive a, .archive span{
  display: block;
  float: left;
  margin-bottom: -1px;
  text-decoration: none;
}
.archive li:not(:last-child) {
	border-bottom: 1px solid #d2d2d2;
	margin-bottom: -1px;
}

.archive a.last, .archive span.last {
  border: 0;
  margin-bottom: 0;
}

.archive a {
  width: 21em;
  text-indent: 1em;
  white-space: nowrap;
}

.archive .year-label,
.archive .month-label{
  width: 4em;
  font-family: ‘Palatino Linotype’, ‘Book Antiqua’, Palatino, serif;
  font-variant: small-caps;
  text-transform: lowercase;
  font-weight: 400;
  text-rendering: auto;
  letter-spacing: 1px;
  text-align: center;
}

.archive .month-label {
  width: 7em;
}

.archive ul {
  list-style: none;
  margin: 0;
}

.archive ul li {
  margin: 0;
}

/* code styling */

code {
  font-family: 'Anonymous Pro', monospace;
  font-size: 0.85em;
  color: #000;
}

pre code {
  display: block;
  line-height: 1.1;
}

p code {
  padding: 0.1em 0.3em 0.2em;
  border-radius: 0.3em;
  position: relative;
  background: #fffff3;

  white-space: nowrap;
}

/* syntax hl stuff */

code.lang-markdown {
  color: #424242;
}

code.lang-markdown .header,
code.lang-markdown .strong {
  font-weight: bold;
}

code.lang-markdown .emphasis {
  font-style: italic;
}

code.lang-markdown .horizontal_rule,
code.lang-markdown .link_label,
code.lang-markdown .code,
code.lang-markdown .header,
code.lang-markdown .link_url {
  color: #555;
}

code.lang-markdown .blockquote,
code.lang-markdown .bullet {
  color: #bbb;
}

/* Tomorrow Theme */
/* http://jmblog.github.com/color-themes-for-google-code-highlightjs */
/* Original theme - https://github.com/chriskempson/tomorrow-theme */
/* http://jmblog.github.com/color-themes-for-google-code-highlightjs */
.tomorrow-comment, pre .comment, pre .title {
  color: #8e908c;
}

.tomorrow-red, pre .variable, pre .attribute, pre .tag, pre .regexp, pre .ruby .constant, pre .xml .tag .title, pre .xml .pi, pre .xml .doctype, pre .html .doctype, pre .css .id, pre .css .class, pre .css .pseudo {
  color: #c82829;
}

.tomorrow-orange, pre .number, pre .preprocessor, pre .built_in, pre .literal, pre .params, pre .constant {
  color: #f5871f;
}

.tomorrow-yellow, pre .class, pre .ruby .class .title, pre .css .rules .attribute {
  color: #eab700;
}

.tomorrow-green, pre .string, pre .value, pre .inheritance, pre .header, pre .ruby .symbol, pre .xml .cdata {
  color: #718c00;
}

.tomorrow-aqua, pre .css .hexcolor {
  color: #3e999f;
}

.tomorrow-blue, pre .function, pre .python .decorator, pre .python .title, pre .ruby .function .title, pre .ruby .title .keyword, pre .perl .sub, pre .javascript .title, pre .coffeescript .title {
  color: #4271ae;
}

.tomorrow-purple, pre .keyword, pre .javascript .function {
  color: #8959a8;
}

.image-column-left {
  width:49%!important;
  display:inline-block!important;
}

.image-column-right {
  width:49%!important;
  display:inline-block!important;
}

.datasheet {
  font-family:monospace;
  font-size:0.6em;
  margin:0px;
}

.datasheet th,td {
  margin:0;
  border:1px solid #ccc;
}


:root {
  --paper-base: #EBEBEB;   /* warm brownish-grey newsprint */
  --paper-mid:  #E8E8E8;
  --paper-dark: #E4E4E4;
  --ink:        #1a1a1a;
  --ink-soft:   #333;
  --accent:     #7d6b55;
}

/* Newspaper clipping container (fixed) */
.newspaper {
  display: block;
  padding: 1.05rem 1.15rem;
  font-size: 0.8rem;
  color: var(--ink);
  line-height: 1.5;
  letter-spacing: 0.01em;
  font-family: "Georgia", "Times New Roman", Times, serif;
  background-color: linear-gradient(0deg, var(--paper-mid), var(--paper-base));
  border: 1px solid rgba(0,0,0,0.18);
  border-radius: 4px;
  transform: rotate(-0.35deg);
  box-shadow:
    0 1.2px 0.8px rgba(0,0,0,0.08),
    0 8px 18px rgba(0,0,0,0.08),
    0 24px 42px rgba(0,0,0,0.06);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-kerning: normal;
  font-feature-settings: "liga" 1, "kern" 1, "onum" 1;
  position: relative;
  isolation: isolate;
}

/* Vignette & corner fold kept intact */
.newspaper::before,
.newspaper::after {
  content: "";
  position: absolute;
  pointer-events: none;
  inset: 0;
}
.newspaper::before {
  box-shadow: inset 0 0 80px rgba(0,0,0,0.10), inset 0 0 2px rgba(0,0,0,0.18);
  mix-blend-mode: multiply;
  border-radius: inherit;
}
.newspaper::after {
  width: 46px;
  height: 46px;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.5), rgba(0,0,0,0.06));
  clip-path: polygon(100% 0, 0 100%, 100% 100%);
  opacity: 0.65;
}

/* Helpers & subclasses */
.newspaper hr {
  border: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0,0,0,0.25), transparent);
  margin: 0.75rem 0 0.85rem;
  opacity: 0.65;
}

.newspaper__section-title {
  font-family: "Times New Roman", Times, "Georgia", serif;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.15;
  font-size: clamp(1.25rem, 2.4vw + 0.6rem, 1.85rem);
  color: var(--ink);
  margin: 0 0 0.4rem 0;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(0,0,0,0.2);
  padding-bottom: 0.25rem;
}

.newspaper__body {
  font-family: "Georgia", "Times New Roman", Times, serif;
  font-size: 0.965rem;
  line-height: 1.65;
  letter-spacing: 0.003em;
  word-spacing: 0.02em;
  color: var(--ink-soft);
  margin: 0.4rem 0 0;
}

/* media queries */

@media (min-width: 1600px) {
  body { font-size: 26px; }
}

@media (max-width: 900px) {
  body { font-size: 18px; }
}

@media (max-width: 690px) {

  .content-wrap {
    width: auto;
    padding: 0 0.3em;
  }
  .article {
    margin: 1em 0 2.5em;
    padding: 1em;
    font-size:0.9em;
  }

  .datasheet {
    font-family:monospace;
    font-size:0.3em;
    margin:0px;
  }
  .archive {
    width: 80%;
    margin: 0 auto;
  }
  .archive * {
    float: none !important;
    line-height: 1.6 !important;
    width: auto !important;
    height: auto !important;
    text-align: left !important;
    border: 0 !important;
    margin: 0 !important;
  }

  footer .nav {
    margin: 1em 0;
  }
  footer .about {
    padding: 0;
    font-size: 0.9em;
    padding-top: 1.6em;
    -webkit-column-count: 1;
    -moz-column-count: 1;
    -ms-column-count: 1;
    column-count: 1;
  }
  footer .about p {
    margin-bottom: 1em;
  }
}

@media (max-width: 500px) {

  .header h1 {
    text-align:center;
    margin-bottom:0.4em;
  }

  .header h2 {
    float:none;
    margin:0;
    text-align:center;
    margin-bottom:0.4em;
  }
  .header .author {
    text-align:center;
  }

  .image-column-left {
    width:100%!important;
    display:block!important;
    margin-bottom:0.5em;
  }
  .image-column-right {
    width:100%!important;
    display:block!important;
    margin-bottom:0em;
  }
}