/* Notre Dame colors for R Markdown HTML output.
   Generated by NDPalette::nd_css(); edit the palette, not this file. */
:root {
  --nd-navy:             #0c2340;
  --nd-bright-gold:      #d39f10;
  --nd-metallic-gold:    #ae9142;
  --nd-green:            #0a843d;
  --nd-bright-blue:      #1c4f8f;
  --nd-black:            #1e1a13;
  --nd-warm-white:       #efe9d9;
  --nd-light-warm-white: #f8f4ec;
  --nd-medium-sky-blue:  #e1e8f2;
  --nd-light-sky-blue:   #edf2f9;
  /* Page background: Warm White, a non-white brand tint. For a soft-yellow
     background instead (not a Notre Dame brand color), set --nd-background
     to NDPalette::nd_informal_tints[["soft_yellow"]]. */
  --nd-background:       #efe9d9;
}

body {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  line-height: 1.7;
  color: var(--nd-black);
  background-color: var(--nd-background);
  font-size: 16px;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--nd-navy);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-weight: 600;
  margin-top: 1.5em;
  margin-bottom: 0.75em;
}
h1 {
  border-bottom: 3px solid var(--nd-bright-gold);
  padding-bottom: 0.5em;
  margin-bottom: 1em;
}
h2 {
  border-bottom: 2px solid var(--nd-metallic-gold);
  padding-bottom: 0.4em;
}
h3 {
  color: var(--nd-metallic-gold);
  border-left: 4px solid var(--nd-navy);
  padding-left: 0.75em;
}
h4 {
  color: var(--nd-navy);
  font-style: italic;
}

a {
  color: var(--nd-navy);
  text-decoration: none;
  border-bottom: 1px solid var(--nd-bright-gold);
  transition: all 0.3s ease;
}
a:hover {
  color: var(--nd-bright-gold);
  border-bottom-color: var(--nd-bright-gold);
}

pre {
  background-color: var(--nd-light-warm-white);
  border: 1px solid #dddddd;
  border-left: 4px solid var(--nd-bright-gold);
  border-radius: 4px;
  padding: 1em;
  overflow-x: auto;
  position: relative;
}
code {
  background-color: var(--nd-light-warm-white);
  padding: 2px 6px;
  border-radius: 3px;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.9em;
  color: var(--nd-navy);
}
pre code {
  background-color: transparent;
  padding: 0;
}
.sourceCode {
  background-color: var(--nd-light-warm-white);
  position: relative;
}

blockquote {
  border-left: 4px solid var(--nd-metallic-gold);
  padding: 1em 1em 1em 1.5em;
  margin: 1.5em 0;
  color: #555555;
  font-style: italic;
  background-color: var(--nd-warm-white);
}

table {
  border-collapse: collapse;
  width: 100%;
  margin: 1.5em 0;
  background-color: #ffffff;
}
thead {
  background-color: var(--nd-navy);
  color: #ffffff;
}
th {
  padding: 12px;
  text-align: left;
  font-weight: 600;
}
td {
  padding: 10px;
  border-bottom: 1px solid #dddddd;
}
tbody tr:hover {
  background-color: var(--nd-light-sky-blue);
}
tbody tr:nth-child(even) {
  background-color: var(--nd-light-warm-white);
}

#TOC {
  background-color: #ffffff;
  border: 1px solid #dddddd;
  border-left: 4px solid var(--nd-navy);
  padding: 1.5em;
  border-radius: 4px;
}
#TOC a {
  border-bottom: none;
  color: var(--nd-navy);
  transition: color 0.3s ease;
}
#TOC a:hover {
  color: var(--nd-bright-gold);
}
#TOC ul {
  list-style-type: none;
  padding-left: 1em;
}

.note {
  background-color: var(--nd-light-warm-white);
  border-left: 4px solid var(--nd-bright-gold);
  padding: 1em;
  margin: 1em 0;
  border-radius: 4px;
}
.important {
  background-color: var(--nd-light-sky-blue);
  border-left: 4px solid var(--nd-navy);
  padding: 1em;
  margin: 1em 0;
  border-radius: 4px;
}
.tip {
  background-color: var(--nd-warm-white);
  border-left: 4px solid var(--nd-green);
  padding: 1em;
  margin: 1em 0;
  border-radius: 4px;
}

.title {
  color: var(--nd-navy);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 0.25em;
}
.subtitle {
  color: var(--nd-metallic-gold);
  font-size: 1.3em;
  font-weight: 400;
  margin-bottom: 0.5em;
}
.author {
  color: var(--nd-navy);
  font-size: 1.1em;
  font-weight: 600;
  margin-bottom: 0.5em;
}
.author em {
  font-style: normal;
}

.book-citation {
  background-color: var(--nd-light-warm-white);
  border-left: 4px solid var(--nd-bright-gold);
  padding: 1em 1.5em;
  margin: 1.5em 0;
  border-radius: 4px;
  font-size: 0.95em;
}
.book-citation strong {
  color: var(--nd-navy);
}

em {
  color: var(--nd-navy);
  font-style: italic;
}
strong {
  color: var(--nd-navy);
  font-weight: 700;
}

.main-container {
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
}

.r-output {
  background-color: var(--nd-light-warm-white);
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  padding: 0.5em;
  font-family: 'Courier New', monospace;
}

.footer {
  margin-top: 3em;
  padding-top: 1.5em;
  border-top: 2px solid var(--nd-bright-gold);
  color: #666666;
  font-size: 0.9em;
  text-align: center;
}

.section.level1 > .header-section-number {
  color: var(--nd-bright-gold);
  font-weight: 700;
}
.section.level2 > .header-section-number {
  color: var(--nd-navy);
  font-weight: 600;
}

.copy-button {
  position: absolute;
  top: 5px;
  right: 5px;
  padding: 4px 10px;
  background-color: var(--nd-bright-gold);
  color: #ffffff;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  font-size: 0.8em;
  font-weight: 600;
  transition: all 0.3s ease;
  opacity: 0.7;
  z-index: 10;
}
.copy-button:hover {
  opacity: 1;
  background-color: var(--nd-metallic-gold);
  transform: scale(1.05);
}
.copy-button:active {
  transform: scale(0.95);
}
.copy-button.copied {
  background-color: var(--nd-green);
}
.copy-button.copied::after {
  content: " \2713";
}

@media (max-width: 768px) {
  body { font-size: 14px; }
  .title { font-size: 2em; }
  .subtitle { font-size: 1.1em; }
  .copy-button { font-size: 0.7em; padding: 3px 8px; }
}
