/* =========================================================
   THEME VARIABLES
   Default: LIGHT
   Automatically follows the visitor's system preference
   ========================================================= */

:root {
  /* ===== PAGE ===== */
  --bg: #fffdf0;
  --surface: #fffef5;
  --surface-hover: #f7f4e3;

  /* ===== TEXT ===== */
  --text: #162b2a;
  --muted: #5f6f6a;

  /* ===== LINKS / HEADINGS ===== */
  --accent: #005f93;
  --heading: #0a2366;

  /* ===== BORDERS ===== */
  --border: #e6e2c8;

  /* ===== BLOCK COLORS ===== */
  --darkblue: #16224f;
  --darkblue-light: #51a2ff;
  --darkblue-text: #e6fffb;

  --light-block: #f7edb8;
  --ltblue: #8fb8ff;
  --medblue: #4d7fd6;

  /* ===== HEADER ===== */
  --header-bg: #e9f3f8;
  --header-border: #d6e4ec;
  --header-text: #ffffff;
  --header-hover: #ffff00;

  /* ===== CARDS ===== */
  --card-bg: #fffef5;

  /* ===== FORMS ===== */
  --input-bg: #fffef5;
  --input-border: #b9c8c5;

  /* ===== MISCELLANEOUS ===== */
  --hr: #e6e2c8;

  /* ===== LAYOUT ===== */
  --max-width: 1200px;

  /* ===== FONTS ===== */
  --font-sans:
    ui-sans-serif,
    system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    Helvetica,
    Arial;
}


/* =========================================================
   DARK THEME
   Use the visitor's browser/operating-system preference.
   ========================================================= */

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121817;
    --surface: #1b2422;
    --surface-hover: #24302d;

    --text: #e7eeea;
    --muted: #aab9b4;

    --accent: #5bc0eb;
    --heading: #72d6c9;

    --border: #34433f;

    --darkblue: #16224f;
    --darkblue-light: #315f96;
    --darkblue-text: #e6fffb;

    --light-block: #263330;
    --ltblue: #8fb8ff;
    --medblue: #72a0e8;

    --header-bg: #16224f;
    --header-border: #34433f;
    --header-text: #ffffff;
    --header-hover: #72d6c9;

    --card-bg: #1b2422;

    --input-bg: #1b2422;
    --input-border: #52635e;

    --hr: #34433f;
  }
}


/* ===== GLOBAL BACKGROUND ===== */

html, body {
  background-color: var(--bg);
  margin: 0;
  min-height: 100%;
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.7;
}


/* ===== CONTAINER ===== */

main {
  max-width: var(--max-width);
  margin: 2rem auto;
  padding: 0 1.25rem;
}


/* ===== HEADINGS (FORCED CONSISTENCY) ===== */

h1, h2, h3 {
  color: var(--heading);
  font-family: "Space Grotesk", system-ui, sans-serif;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h1 {
  font-size: 3rem;
  font-weight: 700;
  text-align: center;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
}

h2 {
  font-size: 2rem;
  font-weight: 650;
  margin-top: 0.7rem;
  margin-bottom: 0.4rem;
}

h3 {
  font-size: 1.4rem;
  font-weight: 650;
  margin-top: 0.5rem;
  margin-bottom: 0.3rem;
}


/* ===== PARAGRAPHS ===== */

p {
  margin: 1.2rem 0;
}


/* ===== LINKS ===== */

a {
  color: var(--accent);
  /* WELLS REPLACED: text-decoration: none; */
  text-decoration: underline;
}

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


/* ===== HEADER ===== */

header {
  background: #00072a; /* dark blue fallback */
  background: linear-gradient(to right, #00072a, #51a2ff) !important;
  color: white;
  padding: 0.75rem 1rem;
}

header {
  max-width: var(--max-width);
  margin: 1.25rem auto 0;
  padding: 0.75rem 1.25rem;

  font-weight: 600;
  font-size: 1.6rem;

  display: flex;
  justify-content: space-between;
  align-items: center;

  border-bottom: 1px solid var(--header-border);
  border-radius: 0;
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;        /* row gap, column gap */
}

nav a {
  margin: 0;                /* Don't use margin-left */
  color: white;
  text-decoration: none;
}

/* Logo image sizing */
header .logo img {
  height: 50px;   /* control size here */
  width: auto;    /* keeps proportions */
  display: block; /* removes inline spacing quirks */
}

/* ===== MUTED TEXT ===== */

small {
  color: var(--muted);
}

/* ===== LISTS ===== */

ul {
  padding-left: 1.25rem;
}

/* BLOCK WIDTH FORMATTING - ALLOW MULTIPLE PER ROW */
.block {
  padding: 1.25rem;
  border-radius: 0;
  box-sizing: border-box;
}

.button {
  display: inline-block;
  background: #ff6f00; /* deeper than accent */
  color: #ffffff;
  padding: 0.1rem 0.7rem; /* reduced padding */
  border-radius: 6px;
  font-size: 1.1rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.15s ease;
}

.button:hover {
  background: #095a86;
  transform: translateY(-1px);
}

.card {
  padding: 1.25rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--card-bg);
  transition: all 0.15s ease;
}

.card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

header {
  max-width: var(--max-width);
  margin: 1.25rem auto 0;
  padding: 0.75rem 1.25rem;
    
  font-weight: 600;
  font-size: 1.6rem; 

  display: flex;
  justify-content: space-between;
  align-items: center;

  background: #e9f3f8; /* light blue tint, not heavy */
  border-bottom: 1px solid #d6e4ec;

  border-radius: 0; /* removes rounded corners */
}

header a {
  color: #1f5f7a; /* lighter than your body text, still readable */
  font-weight: 600;
}

header a:hover {
  color: var(--accent);
}

/*
nav a {
  margin-left: 1.25rem;
  font-weight: 600;
  font-size: 1.6rem; 
  color: var(--muted);
}

nav a:hover {
  color: var(--text);
}
*/

nav a {
  color: white;
  text-decoration: none;
  margin-left: 2rem;
}

nav a:hover,
nav a.active {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
  color: yellow;
}

section {
  margin: 3rem 0;
}

blockquote {
  border-left: 4px solid var(--accent);
  padding-left: 1rem;
  margin: 1.5rem 0;
  color: var(--muted);
  font-style: italic;
}

hr {
  border: none;
  height: 1px;
  background: var(--hr);
  margin: 2.5rem 0;
}

/* 2026-07-09  --  2026-04-27 */
/* ROW LAYOUT */
.two-block-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 1.5rem 0;
}

/* BLOCK BASE */
.block {
  padding: 1.25rem;
  border-radius: 0;
}

/* Odd rows: A = darkblue gradient, B = light */
.two-block-row:nth-of-type(odd) .block--a {
  background: var(--darkblue); /* fallback */
  background: linear-gradient(to bottom, var(--darkblue), var(--darkblue-light)) !important;
  color: white;
  --accent: #fcd34d;
}
.two-block-row:nth-of-type(odd) .block--a h1,
.two-block-row:nth-of-type(odd) .block--a h3 {
  color: var(--darkblue-text);
}
.two-block-row:nth-of-type(odd) .block--a h2 {
  color: var(--ltblue);
}

.two-block-row:nth-of-type(odd) .block--b {
  background: var(--light-block);
}
.two-block-row:nth-of-type(odd) .block--b h1,
.two-block-row:nth-of-type(odd) .block--b h3 {
  color: var(--darkblue);
}
.two-block-row:nth-of-type(odd) .block--b h2 {
  color: var(--medblue);
}

/* Even rows: swap — A = light, B = darkblue gradient */
.two-block-row:nth-of-type(even) .block--a {
  background: var(--light-block);
}
.two-block-row:nth-of-type(even) .block--a h1,
.two-block-row:nth-of-type(even) .block--a h3 {
  color: var(--darkblue);
}
.two-block-row:nth-of-type(even) .block--a h2 {
  color: var(--medblue);
}

.two-block-row:nth-of-type(even) .block--b {
  background: var(--darkblue);
  background: linear-gradient(to bottom, var(--darkblue), var(--darkblue-light)) !important;
  color: white;
  --accent: #fcd34d;
}
.two-block-row:nth-of-type(even) .block--b h1,
.two-block-row:nth-of-type(even) .block--b h3 {
  color: var(--darkblue-text);
}
.two-block-row:nth-of-type(even) .block--b h2 {
  color: var(--ltblue);
}

/* RESPONSIVE: stack on small screens */
@media (max-width: 800px) {
  .two-block-row {
    grid-template-columns: 1fr;
  }
}
/* End of block row code */


/* THREE-BLOCK ROW LAYOUT */
.three-block-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin: 1.5rem 0;
}

.three-block-row .block {
  flex: 1 1 calc(33.333% - 1rem);
  min-width: 0;
}

/* Medium screens: two per row, third wraps and auto-centers */
@media (max-width: 900px) {
  .three-block-row .block {
    flex: 1 1 calc(50% - 1rem);
  }
  .three-block-row .block--c {
    flex: 0 1 calc(50% - 1rem);
  }
}

/* Small screens: stack to one column */
@media (max-width: 500px) {
  .three-block-row .block {
    flex: 1 1 100%;
  }
}

/* Three-block rows colors: A = dark, B = light, C = dark */
.three-block-row .block--a,
.three-block-row .block--c {
  background: var(--darkblue); /* fallback */
  background: linear-gradient(to bottom, var(--darkblue), var(--darkblue-light)) !important;
  color: white;
  --accent: #fcd34d;
}
.three-block-row .block--a h1,
.three-block-row .block--a h3,
.three-block-row .block--c h1,
.three-block-row .block--c h3 {
  color: var(--darkblue-text);
}
.three-block-row .block--a h2,
.three-block-row .block--c h2 {
  color: var(--ltblue);
}

.three-block-row .block--b {
  background: var(--light-block);
}
.three-block-row .block--b h1,
.three-block-row .block--b h3 {
  color: var(--darkblue);
}
.three-block-row .block--b h2 {
  color: var(--medblue);
}

/* End of THREE-BLOCK ROW LAYOUT */


/* Scale images. Use  imgsmj Espanso <img src="/assets/img/example.png" class="imgsm" alt="Example">
.imgsm { max-height: 150px; }  
.imgmd { max-height: 300px; }  
.imglg { max-height: 500px; }  
  
.imgsm,  
.imgmd,  
.imglg {  
  width: auto;  
  height: auto;  
}
*/


/* Stretch image from right margin to left margin */
.imgfullwide {
  display: block;
  width: 100vw;
  max-width: none;
  margin-left: calc(50% - 50vw);
  height: auto;
}

/* Align images Center Left or Right */
.imgctr {  
  display: block;  
  margin: 0 auto;  
}

.imgleft {  
  display: block;  
  margin-right: auto;  
}  
  
.imgright {  
  display: block;  
  margin-left: auto;  
}

/* Prevent overflow on phones */
img {  
  max-width: 100% !important;  
}

/* Image sizes for blogs */
/* <img src="/assets/imgblog/image.jpg" alt="Description" class="img-lg"> */

.img-blog {  
  display: block;  
  margin: 0 auto;
  width: 450px;
  height: auto;
}

.img-xs {
  width: 150px;
  height: auto;
}

.img-sm {
  width: 300px;
  height: auto;
}

.img-med {
  width: 450px;
  height: auto;
}

.img-lg {
  width: 600px;
  height: auto;
}

.img-xl {
  width: 800px;
  height: auto;
}

/* Categories and Go to Top links in footer */
.post-footer-rule {
    margin: 2rem 0 0.5rem;
}

.post-footer-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0;
}

.footer-left,
.footer-right {
    font-weight: 600;
    text-decoration: underline;
}

.footer-right a:hover,
.footer-left a:hover {
    text-decoration: underline;
}

/* Blog post navigation links at botton */
.post-navigation {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #ccc;
    flex-wrap: wrap;
}

.prev-post,
.random-post,
.next-post {
    flex: 1;
    min-width: 220px;
}

.random-post {
    text-align: center;
}

.next-post {
    text-align: right;
}

.post-navigation a {
    display: inline;
    overflow-wrap: anywhere;
}
.random-post a {
    color: #003366;
    text-decoration: underline;
}
/* Make posts narrow */
body.is-post {
  --max-width: 650px;
  margin: 0 auto;
}
/* Optional narrow page using front matter  bodyClass: width650 */
body.width650 main {
  --max-width: 650px;
}
/* Optional narrow page using front matter  bodyClass: width725 */
body.width725 main {
  --max-width: 725px;
}

/* ========== Rotating images code ========== */

#rotating-image-1,
#rotating-image-2,
#rotating-image-3 {
    transition: opacity 0.5s ease-in-out;
}

.fade-out {
    opacity: 0;
}

/* =========================================================
   CONTACT FORM
   ========================================================= */

.contact-form {
  max-width: 800px;
  margin: 2rem 0;
}

.contact-form .form-row {
  display: grid;

  grid-template-columns: 100px minmax(0, 600px);

  gap: 1rem;

  align-items: start;

  margin-bottom: 1rem;
}

.contact-form label {
  padding-top: 0.35rem;
  padding-right: 0.25rem;
  font-weight: 600;
  text-align: right;
}

.contact-form input,
.contact-form textarea {
  box-sizing: border-box;

  width: 100%;

  padding: 0.45rem 0.6rem;

  background: var(--input-bg);
  color: var(--text);

  border: 1px solid var(--input-border);
  border-radius: 5px;

  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.5;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;

  border-color: var(--accent);
}

.contact-form textarea {
  resize: vertical;
}

.contact-form .form-submit {
  margin-top: 0.5rem;
  margin-left: 116px;
}


/* =========================================================
   CONTACT FORM: RESPONSIVE
   ========================================================= */

@media (max-width: 600px) {

  .contact-form .form-row {
    display: block;

    margin-bottom: 1rem;
  }

  .contact-form label {
    display: block;
    margin-bottom: 0.25rem;
    text-align: left;
  }

  .contact-form .form-submit {
    margin-left: 0;
  }

}
