/*
Theme Name: JMD fans
Theme URI: https://example.com/jmd-fans
Author: JMD Fans
Author URI: https://example.com
Description: A minimal starter theme for JMD fans.
Version: 1.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: jmd-fans
Tags: custom-background, custom-logo, custom-menu, featured-images
*/

/* Basic theme styles */
@font-face {
  font-family: 'LT_superior_serif';
  src: url('fonts/LT_superior_serif/LTSuperiorSerif-Regular.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'LT_superior_serif';
  src: url('fonts/LT_superior_serif/LTSuperiorSerif-Bold.otf') format('opentype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

body {
  font-family: 'LT_superior_serif', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: #222;
  line-height: 1.6;
  margin: 0;
  padding: 0;
}

:root {
  --jmd-header: #f5f5f5;
  --jmd-primary: #0073aa;
  --jmd-accent: #00a0d2;
  --jmd-header-text: #222;
}

.site-header, .site-footer {
  padding: 1rem;
  background: var(--jmd-header);
  transition: background .18s ease, box-shadow .18s ease;
}

.site-header {
  /* full-width header background; inner content constrained with .header-inner/.container */
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  max-width: var(--jmd-container-width, 1100px);
  margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
}

.container {
  max-width: var(--jmd-container-width, 1100px);
  margin: 2em auto;
  padding: 0 1rem;
  width: 100%;
}

.site-branding {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.site-logo {
  max-height: 64px;
  width: auto;
  display: block;
}

.main-navigation {
  margin-left: auto;
}

/* Make nav list horizontal and remove bullets */
.main-navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: nowrap; /* keep items on a single line where possible */
}
.main-navigation li {
  margin: 0;
}
.main-navigation a {
  display: inline-block;
  padding: .25rem .5rem;
  text-decoration: none;
}

.site-header.is-sticky {
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
} 

@media (max-width:700px) {
  .main-navigation { width: 100%; order: 3; margin-left: 0; }
  .site-branding { width: 100%; order: 1; justify-content: flex-start; }
  /* Allow nav to wrap on small screens for accessibility */
  .main-navigation ul { flex-wrap: wrap; gap: .5rem; }
}  

/* Use CSS variables for colors so they're configurable via the theme options */
a { color: var(--jmd-primary); }

/* Header/footer text and links (overrides global link color inside header/footer) */
.site-header, .site-header a, .site-header .site-title, .site-header .site-description {
  color: var(--jmd-header-text);
}
.site-footer, .site-footer a {
  color: var(--jmd-header-text);
}

/* Buttons — use header/footer text color as background, readable white text, padding and rounded corners */
.button, .btn {
  display: inline-block;
  color: var(--jmd-header-text);
  background-color: var(--jmd-accent);
  padding: .6rem 1rem;
  border-radius: 6px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: filter .12s ease, transform .08s ease;
}
.button:hover, .btn:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
}

/* Hero banner */
.hero-banner {
  position: relative;
  display: block;
  width: 100%;
  height: 50vh; /* overridden by inline CSS from theme options */
  color: #fff;
  background-color: #222;
  overflow: hidden;
}
.hero-banner .hero-overlay {
  position: absolute;
  inset: 0;
  opacity: 0.95;
}
.hero-banner .hero-inner {
  position: relative;
  z-index: 2;
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 1rem;
  text-align: center;
  top: 50%;
  transform: translateY(-50%);
}
.hero-title { font-size: 3rem; margin: 0 0 0.5rem 0; color: inherit; font-family: 'LT_superior_serif', sans-serif; line-height: 1; }
.hero-text { font-size: 2rem; max-width: 900px; margin: 0 auto; color: rgba(255,255,255,0.95); font-family: 'LT_superior_serif', sans-serif; }

/* Responsive fallback to prevent overflow on small screens */
@media (max-width: 700px) {
  .hero-title { font-size: 1.333rem; }
  .hero-text { font-size: 0.667rem; }
}


.entry-title { font-size: 1.5rem; margin: 0 0 .5rem 0; }
.entry-content { margin-bottom: 1.5rem; }

/* Post listing: show featured image on the left and excerpt on the right */
.post {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.post .entry-thumbnail {
  flex: 0 0 200px;
  max-width: 200px;
  overflow: hidden;
  border-radius: 6px;
}
.post .entry-thumbnail img {
  display: block;
  width: 100%;
  height: auto;
}
.post .entry-body {
  flex: 1 1 auto;
}

@media (max-width: 700px) {
  .post { flex-direction: column; }
  .post .entry-thumbnail { max-width: 100%; flex: none; }
}

/* 404 page styles */
.error-404 { padding: 6rem 1rem; text-align: center; }
.error-404-inner { max-width: 900px; margin: 0 auto; }
.error-title { font-size: 4rem; margin: 0 0 1rem 0; font-family: 'LT_superior_serif', sans-serif; }
.error-subtext { font-size: 1.125rem; color: rgba(0,0,0,0.7); margin-bottom: 1.5rem; }
.error-actions .button { display: inline-block; margin-top: .5rem; padding: .65rem 1rem; }

@media (max-width:700px) {
  .error-title { font-size: 2rem; }
  .error-subtext { font-size: 1rem; }
}
