/* --- Base Typography & Background --- */
* {
  box-sizing: border-box;
}


p{ 
    text-align: justify;
  text-justify: inter-word;
}
body {
  /* Soft, neutral background to make the white column pop */
  background-color: #f4f5f7; 
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  line-height: 1.6;
  color: #333333;
  margin: 0;
}

footer{
  background-color:black;
  margin:0;
  margin-top:3em;
  padding:3em;
}

footer, footer a{
    color:white;

}
.alert {
    padding: 20px;
    background-color: #f44336;
    color: white;
    opacity: 0.83;
    transition: opacity 0.6s;
    margin-bottom: 15px;
}

.alert.success {background-color: #04AA6D;}
.alert.info {background-color: #2196F3;}
.alert.warning {background-color: #ff9800;}
.alert a {color: white}
/* --- Central Column / Elevated Effect --- */
article {
  max-width: 800px;
  margin: 0 auto;
  background-color: #ffffff;
  padding: 3rem 4rem;
  border-radius: 12px;
  /* This box-shadow creates the "above the background" illusion */
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05), 0 1px 3px rgba(0, 0, 0, 0.03);
}

/* Styling the H1 to sit nicely above the white card */
h1 {
  max-width: 800px;
  margin: 0 auto 1.5rem auto;
  text-align: center;
  font-size: 2.2rem;
  line-height: 1.3;
  color: #111827;
  padding: 0 1rem;
}

h2 {
  color: #1f2937;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #f3f4f6;
  clear:both;
}


a {
  color: #2563eb;
  border-bottom: 1px transparent;
  transition: border-color 0.2s ease;
}

a:hover {
  border-bottom:1px solid;
}


header {
    position: absolute;
    left: 0;
    padding: 1em;
    margin: 1em;
    border-radius: 0.2em;
    background-color: #fbfeff;
    box-shadow: 13px 11px 30px 5px rgba(0, 0, 0, 0.05), 0 1px 3px rgb(0 0 0 / 0%);
}

code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  background-color: #f1f5f9; 
  color: #db2777;
  padding: 0.2em 0.4em;
  border-radius: 4px;
  font-size: 0.9em;
}

pre {
  background-color: #1e293b; 
  color: #e2e8f0; 
  padding: 1.5rem;
  padding-bottom:0;
  border-radius: 8px;
  overflow-x: auto;
  margin: 1.5rem 0;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
  text-align:left;
}

/* Remove inline code styling when inside a pre block */
pre code {
  background-color: transparent;
  color: inherit;
  padding: 0;
  font-size: 0.95em;
}

/* --- Tables --- */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  font-size: 0.95rem;
}

th, td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid #e5e7eb;
}

th {
  background-color: #f9fafb;
  font-weight: 600;
  color: #374151;
}

/* --- Media (Images, Figures, Iframes) --- */
figure {
  margin: 2.5rem 0;
  text-align: center;
}

img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  /* Optional: adds a tiny border to images with white backgrounds */
  border: 1px solid #f3f4f6; 
}

figcaption {
  margin-top: 0.75rem;
  font-size: 0.9rem;
  color: #6b7280;
  font-style: italic;
}

iframe {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  margin-top: 1.5rem;
  background: #f9fafb;
}

@media (max-width: 80em)  {
  header {
    position: static;
    display: block;
    width: 100%;
    margin: 0; 
    box-shadow: none; 
  }
}
  
@media (max-width: 50em)  {
  section, 
  article {
    width: 100%;
    max-width: 100%;
    margin: 0;
    border-radius: 0;     
    box-shadow: none; 
    padding:0;    
  }
  article{padding:0.5em}
  footer{padding:0.5em}
}



/* https://stackoverflow.com/questions/36966873/tooltip-using-css-only */
[tip]{
  cursor:help;
  margin-left:0.2rem;
  display: inline;
  border-bottom:1px dashed gray;
  margin-right:1.2rem;
}

[tip]:after{
  background: black;
  color: white;
  font-size:0.8rem;
  content: "❓";
  position:absolute;
  padding-bottom:1em;
  vertical-align: top;
  border-radius:0.5rem;
  padding:0.1rem;
  margin-top: -0.5rem;
  transition: width 1s ease;
 }

 [tip]:hover:after{
  content: "❓" attr(tip);
  z-index:2;
 }
 /*
[tip]:before {
background: #737373;
    color: white;
    padding: 0.5rem;
    content: attr(tip);
    border-radius: 0.5rem;
    position: absolute;
    width: max-content;
    display: none;
        adisplay:block;

    margin-top: -2.5rem;
    border: 1px solid black;
}

[tip]:hover:before {
    display:inline-block;
}
*/