/* =============================================================================
   layout.css: Lodes & Lanterns shared layout
   Reset, responsive font scale, header, footer.
   ============================================================================= */

/* Reset */
/*-------*/
*, *::before, *::after { box-sizing: border-box; }
body, h1, h2, h3, h4, h5, h6, p, ul, ol, figure, blockquote { margin: 0; padding: 0; }
button, input, textarea, select { font: inherit; }
img, svg { display: block; max-width: 100%; }
[hidden] { display: none !important; }

/* Responsive font scale */
/*-----------------------*/
html { font-size: var(--ll-font-size, 100%); }
@media (min-width: 576px)  { :root { --ll-font-size: 106.25%; } }
@media (min-width: 768px)  { :root { --ll-font-size: 112.5%;  } }
@media (min-width: 1024px) { :root { --ll-font-size: 118.75%; } }
@media (min-width: 1280px) { :root { --ll-font-size: 125%;    } }
@media (min-width: 1536px) { :root { --ll-font-size: 131.25%; } }

/* ---- Header ---- */
/*------------------*/
#header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: var(--ll-max-width, 1400px);
  margin: 0 auto;
  padding: 1.25rem 1rem 0.75rem;
}

#header-branding h1 {
  margin: 0;
  font-size: 1.5rem;
  line-height: 1.2;
}

#header-branding h1 .h1-prefix {
  display: block;
  font-size: 0.48em;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ll-text-muted);
  text-decoration: none;
  margin-bottom: 0.2em;
  transition: color 0.15s;
}
#header-branding h1 .h1-prefix:hover { color: var(--ll-accent); }

#header-branding h1 .h1-title {
  color: var(--ll-text);
  text-decoration: none;
  transition: color 0.15s;
}
#header-branding h1 .h1-title:hover { color: var(--ll-accent); }

#header-branding p {
  margin: 0.5rem 0 0;
  font-size: 0.875rem;
  color: var(--ll-text-muted);
}
#header-branding p a { color: var(--ll-accent); }
#header-branding p a:hover { color: var(--ll-accent-hover); }

#header-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* ---- Theme toggle ---- */
/*------------------------*/
#theme-toggle {
  background: none;
  border: none;
  padding: 0.25rem 0.4rem;
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  border-radius: var(--ll-radius);
  color: inherit;
  transition: background 0.15s;
  /* opacity/filter handled by .theme-toggle in tokens.css */
}
#theme-toggle:hover {
  background: var(--ll-border);
  opacity: 1;
}

/* ---- Footer ---- */
/*------------------*/
footer { padding: 1rem; }

#footer-inner {
  max-width: var(--ll-max-width, 1400px);
  margin: 0 auto;
  font-size: 0.875rem;
  color: var(--ll-text-muted);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}
#footer-inner p { margin: 0; }
#footer-inner a { color: var(--ll-accent); }
#footer-inner a:hover { color: var(--ll-accent-hover); }

#footer-disclaimer {
  max-width: var(--ll-max-width, 1400px);
  margin: 0.75rem auto 0;
  padding-top: 0.75rem;
  border-top: 1px solid var(--ll-border);
  font-size: 0.75rem;
  color: var(--ll-text-muted);
}
