/*
 * NOTE:
 * - The use of browser-specific styles (-moz-, -webkit-) should be avoided.
 *   If used, they may not render correctly for people reading the email in
 *   a different browser than the one from which the email was sent.
 * - The use of state-dependent styles (like a:hover) don't work because they
 *   don't match at the time the styles are made explicit. (In email, styles
 *   must be explicitly applied to all elements -- stylesheets get stripped.)
 */

/* This is the overall wrapper, it should be treated as the `body` section. */
.markdown-here-wrapper {
}

/* To add site specific rules, you can use the `data-md-url` attribute that we
   add to the wrapper element. Note that rules like this are used depending
   on the URL you're *sending* from, not the URL where the recipient views it.
*/
/* .markdown-here-wrapper[data-md-url*="mail.yahoo."] ul { color: red; } */
html {
  margin: 0px;
  padding: 0px;
  font-weight: 300;
}

body {
  background-color: #fff;
  margin: 0px auto;
  text-align: justify;
  font-family: "Linux Libertine", "Times New Roman", Times, serif;
}

@media screen {
  html {
    background-color: #bbb;
  }
  body {
    font-size: 12pt;
    width: 915px;
    padding-top: 10px;
    padding-bottom: 10px;
    padding-right: 10px;
    padding-left: 10px;
    min-height: 100%;
    border-left: 1px solid #888;
    border-right: 1px solid #888;
    position: relative;
  }
  #pdf-link {
    position: absolute;
    top: 0px;
    left: 0px;
    padding: 5px;
  }
}
@media print {
  body {
    font-size: 9pt;
    widows: 1;
    orphans: 1;
  }
  #pdf-link {
    display: none;
  }
  #main {
    -webkit-column-count: 2; /* Chrome, Safari, Opera */
    -moz-column-count: 2; /* Firefox */
    column-count: 2;
  }
  #MathJax_Message {
    display: none;
  }
}

div.authors {
  font-family: "Linux Biolinum", "HelveticaNeue-Light", "Helvetica Neue Light",
    "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
  font-size: 1.0833em;
  text-align: center;
  padding-bottom: 10px;
}

img {
  max-width: 100%;
}

img.fig-teaser {
  width: 100%;
}

figcaption {
  font-style: italic;
}

pre,
code {
  /* display: inline-block; */
  font-size: 0.85em;
  font-family: Consolas, Inconsolata, Courier, monospace;
}

code {
  margin: 0 0.15em;
  padding: 0 0.3em;
  border: 1px solid #eaeaea;
  background-color: #f8f8f8;
  border-radius: 3px;
  display: inline; /* added to fix Yahoo block display of inline code */
}

pre {
  font-size: 1em;
  line-height: 1.2em;
}

pre code {
  white-space: pre;
  overflow: auto; /* fixes issue #70: Firefox/Thunderbird: Code blocks with horizontal scroll would have bad background colour */
  border-radius: 3px;
  border: 1px solid #ccc;
  padding: 0.5em 0.7em;
  display: block !important; /* added to counteract the Yahoo-specific `code` rule; without this, code blocks in Blogger are broken */
}

/* In edit mode, Wordpress uses a `* { font: ...;} rule+style that makes highlighted
code look non-monospace. This rule will override it. */
.markdown-here-wrapper[data-md-url*="wordpress."] code span {
  font: inherit;
}

/* Wordpress adds a grey background to `pre` elements that doesn't go well with
our syntax highlighting. */
.markdown-here-wrapper[data-md-url*="wordpress."] pre {
  background-color: transparent;
}

/* This spacing has been tweaked to closely match Gmail+Chrome "paragraph" (two line breaks) spacing. */
body p {
  /* !important is needed here because Hotmail/Outlook.com uses !important to
     kill the margin in <p>. We need this to win. */
  margin: 1.2em 0 !important;
}

table,
pre,
dl,
blockquote,
q,
ul,
ol {
  margin: 1.2em 0;
}

ul,
ol {
  padding-left: 1em;
}

ul {
  list-style-type: none;
}

li.coming-soon {
  font-style: italic;
  color: #555;
}
li.coming-soon a:after {
  content: " (coming soon)";
}

li {
  margin-bottom: 0em;
  margin-top: 0;
}

li:before {
  content: "\21aa";
  padding: 0 0.5em;
  font-style: normal;
}

/* Space paragraphs in a list the same as the list itself. */
li p {
  /* Needs !important to override rule above. */
  margin: 0.5em 0 !important;
}

/* Smaller spacing for sub-lists */
ul ul,
ul ol,
ol ul,
ol ol {
  margin: 0;
  padding-left: 1em;
}

dl {
  padding: 0;
}

dl dt {
  font-size: 1em;
  font-weight: bold;
  font-style: italic;
}

dl dd {
  margin: 0 0 1em;
  padding: 0 1em;
}

blockquote,
q {
  border-left: 4px solid #ddd;
  padding: 0 1em;
  color: #777;
  quotes: none;
}

blockquote::before,
blockquote::after,
q::before,
q::after {
  content: none;
}

h1 {
  text-align: center;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 1.3em 0 1em;
  padding: 0;
  font-weight: normal;
  font-family: "Linux Biolinum", "HelveticaNeue-Light", "Helvetica Neue Light",
    "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
}

h1 em,
h2 em,
h3 em,
h4 em,
h5 em,
h6 em {
  font-family: "Linux Biolinum", "HelveticaNeue-UltraLight",
    "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica,
    Arial, "Lucida Grande", sans-serif;
  font-size: 0.7em;
  font-style: italic;
  font-weight: normal;
}

h1 {
  font-size: 1.416667em;
}

h2 {
  font-size: 1.166667em;
}

h3 {
  font-size: 1.08333333em;
}

h4 {
  font-size: 1.75em;
}

h5 {
  font-size: 1em;
}

h6 {
  font-size: 1em;
  color: #777;
}

table {
  padding: 0;
  border-collapse: collapse;
  border-spacing: 0;
  font-size: 1em;
  font: inherit;
  border: 0;
}

tbody {
  margin: 0;
  padding: 0;
  border: 0;
}

table tr {
  border: 0;
  border-top: 1px solid #ccc;
  background-color: white;
  margin: 0;
  padding: 0;
}

table tr:nth-child(2n) {
  background-color: #f8f8f8;
}

table tr th,
table tr td {
  font-size: 1em;
  border: 1px solid #ccc;
  margin: 0;
  padding: 0.5em 1em;
}

table tr th {
  font-weight: bold;
  background-color: #f0f0f0;
}

div.authors p a {
  color: inherit;
  text-decoration: none;
}

div.authors p a:hover {
  color: #0000ee;
  text-decoration: underline;
}

a.citation {
  color: inherit;
  text-decoration: none;
}

a.citation:hover {
  color: #0000ee;
  text-decoration: underline;
}

div.footnotes hr {
  border: 0;
}

/*
p { page-break-inside: avoid;  } 
figure { page-break-inside: avoid;  } 
*/

.footnotes b {
}

.footnotes ol li strong {
  font-variant: small-caps;
  font-weight: inherit;
}

figcaption strong {
  font-style: normal;
}

/* http://www.princexml.com/forum/topic/2971/using-mathjax-with-princexml */
nobr > span > span:last-child[style] {
  border-left-width: 0em !important;
  border-left-style: none !important;
}
.venue {
  font-size: 0.7em;
  font-style: italic;
  font-weight: normal;
}

a[href=""] {
  font-style: italic;
  color: #aaa;
}
a[href=""]:after {
  content: " (coming soon)";
}

@font-face {
  font-family: "Linux Libertine"; /* normal */
  src: url("./fonts/linux-libertine/LinLibertine_R.woff") format("woff");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "Linux Libertine"; /* italic */
  src: url("./fonts/linux-libertine/LinLibertine_RI.woff") format("woff");
  font-weight: normal;
  font-style: italic;
}

@font-face {
  font-family: "Linux Libertine"; /* bold */
  src: url("./fonts/linux-libertine/LinLibertine_RB.woff") format("woff");
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: "Linux Libertine"; /* bold */
  src: url("./fonts/linux-libertine/LinLibertine_RBI.woff") format("woff");
  font-weight: bold;
  font-style: italic;
}

@font-face {
  font-family: "Linux Biolinum"; /* normal */
  src: url("./fonts/linux-biolinum/LinBiolinum_R.woff") format("woff");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "Linux Biolinum"; /* italic */
  src: url("./fonts/linux-biolinum/LinBiolinum_RI.woff") format("woff");
  font-weight: normal;
  font-style: italic;
}

@font-face {
  font-family: "Linux Biolinum"; /* bold */
  src: url("./fonts/linux-biolinum/LinBiolinum_RB.woff") format("woff");
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: "Linux Biolinum"; /* bold */
  src: url("./fonts/linux-biolinum/LinBiolinum_RBI.woff") format("woff");
  font-weight: bold;
  font-style: italic;
}

/* Joonho Custom */
/* Shared underline look (roughly \setul{0.5ex}{0.3ex}) */
:root {
  --ul-thickness: 0.18em; /* ≈ 0.3ex */
  --ul-offset: 0.25em; /* ≈ 0.5ex */
}
.u-underline {
  text-decoration-line: underline;
  text-decoration-thickness: var(--ul-thickness);
  text-underline-offset: var(--ul-offset);
}

/* Color mappings from your \definecolor */
.stroke {
  text-decoration-color: rgb(234, 133, 0);
} /* c_stroke */
.abscurve {
  text-decoration-color: rgb(103, 162, 200);
} /* c_abscurve */
.rigcurve {
  text-decoration-color: rgb(91, 83, 197);
} /* c_rigcurve */
.bookmarkcurve {
  text-decoration-color: rgb(171, 88, 198);
} /* c_bookmarkcurve */

/* Append an external-link SVG icon to all target="_blank" anchors */
a[target="_blank"]::after {
  content: "";
  display: inline-block;
  width: 0.75em;
  height: 0.75em;
  margin-left: 0.25em;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" fill="none" stroke="%23000" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24"><path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"/><polyline points="15 3 21 3 21 9"/><line x1="10" y1="14" x2="21" y2="3"/></svg>');
  background-repeat: no-repeat;
  background-size: contain;
  vertical-align: text-bottom;
}

/*Code Box Styling*/
.code-box {
  width: inherit; /* inherit width from parent */
  overflow-x: auto; /* adds scroll if content overflows */
  white-space: pre-wrap; /* optional: wraps long lines instead of overflowing */
}

.copy-code-button {
  position: absolute;
  top: 8px;
  right: 8px;
  background-color: #333;
  color: #fff;
  border: none;
  padding: 5px 8px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.copy-code-button:hover {
  opacity: 1;
}
