/* =========================================================
   style.css - Custom stylesheet based on provided HTML
   Primary color: #1c2f72 (matches inline styles in HTML)
   ========================================================= */

/* ------------------------------
   1) Base / Reset
------------------------------ */
:root{
  --primary: #1c2f72;
  --text: #1f2937;
  --muted: #6b7280;
  --bg: #ffffff;
  --bg-soft: #f6f7fb;
  --border: #e5e7eb;
  --shadow: 0 10px 25px rgba(0,0,0,.08);
  --radius: 10px;
  --container: 1100px;
}

*,
*::before,
*::after{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

body{
  margin: 0;
  font-family: "Roboto Slab", Georgia, "Times New Roman", serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
}

img{
  max-width: 100%;
  height: auto;
  display: block;
}

a{
  color: var(--primary);
  text-decoration: none;
}
a:hover,
a:focus{
  text-decoration: underline;
}

p{ margin: 0 0 1rem; }
h1,h2,h3,h4,h5,h6{ line-height: 1.25; margin: 0 0 .75rem; }
small{ color: var(--muted); }

blockquote{
  margin: 1.25rem 0;
  padding: .75rem 1rem;
  background: var(--bg-soft);
  border-left: 5px solid var(--primary);
  border-right: 2px solid var(--primary);
}

/* Accessibility */
.skip-link.screen-reader-text{
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.skip-link.screen-reader-text:focus{
  left: 1rem;
  top: 1rem;
  width: auto;
  height: auto;
  background: #fff;
  border: 2px solid var(--primary);
  padding: .5rem .75rem;
  z-index: 9999;
}

/* Utility */
.clear{ clear: both; }
.smallPart{ font-size: .95rem; }
.updated{ display: none; }

/* ------------------------------
   2) Layout Containers
------------------------------ */
#page.site{
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

#content.site-content{
  flex: 1;
  padding: 1.25rem 0 2.5rem;
}

#primary.content-area,
#secondary.widget-area{
  padding: 0 1rem;
}

#content .content-area,
#content .widget-area{
  width: 100%;
}

@media (min-width: 980px){
  #content.site-content > #primary.content-area,
  #content.site-content > #secondary.widget-area{
    padding: 0 1.25rem;
  }

  /* two-column layout */
  #content.site-content{
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 1.5rem;
    max-width: var(--container);
    margin: 0 auto;
  }
}

/* ------------------------------
   3) Header (Masthead)
------------------------------ */
#masthead.site-header{
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

#masthead .theTop{
  max-width: var(--container);
  margin: 0 auto;
  padding: 1.25rem 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.site-branding{
  flex: 1;
  min-width: 0;
}

.site-title{
  font-size: 1.35rem;
  margin: 0;
  font-weight: 700;
}
.site-title a{
  color: var(--text);
  text-decoration: none;
}
.site-title a:hover{ color: var(--primary); }

.site-description{
  margin: .2rem 0 0;
  font-size: .95rem;
  color: var(--muted);
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

/* Social icons / search icon */
.socialLine{
  display: flex;
  align-items: center;
  gap: .6rem;
}

.socialLine a{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--primary);
  background: #fff;
}
.socialLine a:hover{
  background: var(--bg-soft);
  text-decoration: none;
}

/* FontAwesome helper spacing classes */
.spaceRightDouble{ margin-right: .35rem; }
.spaceLeft{ margin-left: .35rem; }

/* Top search form (hidden by default) */
.topSearchForm{
  display: none;
  width: 100%;
  margin-top: .75rem;
}
.topSearchForm form{
  display: flex;
  gap: .5rem;
}
.topSearchForm input.search{
  width: 100%;
  padding: .6rem .75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  outline: none;
}
.topSearchForm input.search:focus{
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(28,47,114,.12);
}

/* If JS toggles .active on .top-search, you can show the form:
   (You may adjust based on theme JS behavior) */
.top-search.active + .topSearchForm{ display: block; }

/* ------------------------------
   4) Main Navigation
------------------------------ */
#site-navigation.main-navigation{
  background: var(--primary);
  color: #fff;
}

#site-navigation .menu{
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1rem;
}

#site-navigation .menu ul{
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: .25rem;
}

#site-navigation .menu li{
  margin: 0;
  padding: 0;
}

#site-navigation .menu a{
  display: block;
  padding: .75rem .8rem;
  color: #fff;
  text-decoration: none;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  font-weight: 600;
  font-size: .92rem;
  border-radius: 8px;
}

#site-navigation .menu a:hover,
#site-navigation .menu a:focus{
  background: rgba(255,255,255,.12);
  text-decoration: none;
}

/* current page highlight */
.current_page_item > a{
  background: rgba(255,255,255,.18);
}

/* Menu toggle button (mobile) */
.menu-toggle{
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: var(--primary);
  color: #fff;
  border: 0;
  padding: .75rem 1rem;
  width: 100%;
  cursor: pointer;
  font-size: 1rem;
}

@media (min-width: 980px){
  .menu-toggle{ display: none; }
}

/* Mobile nav behavior: hide menu by default, show when body has class "toggled"
   (common WP pattern, adjust if needed) */
@media (max-width: 979px){
  #site-navigation .menu ul{
    display: none;
    padding: .5rem 0 1rem;
  }
  body.toggled #site-navigation .menu ul{
    display: flex;
    flex-direction: column;
    gap: .25rem;
  }
}

/* ------------------------------
   5) Main Content (Article)
------------------------------ */
#main.site-main{
  background: #fff;
}

article.page,
article.post{
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.entry-header{
  padding: 1.25rem 1.25rem .75rem;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff, var(--bg-soft));
}

.entry-title{
  margin: 0;
  font-size: 1.6rem;
}

.entry-content{
  padding: 1.25rem;
}

/* WordPress image alignment helpers */
.alignnone{ margin: 0 auto 1rem; }
.aligncenter{ margin: 0 auto 1.25rem; }
.alignleft{ float: left; margin: 0 1rem 1rem 0; }
.alignright{ float: right; margin: 0 0 1rem 1rem; }

/* Make inline centered headings look nice */
.entry-content h1[style*="text-align: center"],
.entry-content h2[style*="text-align: center"],
.entry-content h3[style*="text-align: center"]{
  margin-left: auto;
  margin-right: auto;
}

/* Links inside content */
.entry-content a{
  text-decoration: underline;
  text-underline-offset: 2px;
}
.entry-content a:hover{ opacity: .9; }

/* Buttons (matches theme inline rules) */
button,
input[type="button"],
input[type="reset"],
input[type="submit"]{
  background: var(--primary);
  color: #fff;
  border: 1px solid var(--primary);
  border-radius: 999px;
  padding: .65rem 1rem;
  cursor: pointer;
  font-weight: 700;
}

button:hover,
input[type="button"]:hover,
input[type="reset"]:hover,
input[type="submit"]:hover{
  background: #fff;
  color: var(--primary);
}

/* ------------------------------
   6) Comments Section
------------------------------ */
#comments.comments-area{
  margin-top: 1.25rem;
  padding: 0 0 1rem;
}

.comment-respond{
  margin-top: 1.25rem;
  border-top: 1px solid var(--border);
  padding: 1.25rem;
}

.comment-reply-title{
  font-size: 1.2rem;
  margin: 0 0 1rem;
}

.comment-form{
  display: grid;
  grid-template-columns: 1fr;
  gap: .75rem;
}

@media (min-width: 720px){
  .comment-form{
    grid-template-columns: 1fr 1fr;
  }
  .comment-form-comment,
  .form-submit,
  .comment-notes{
    grid-column: 1 / -1;
  }
}

.comment-form input[type="text"],
.comment-form textarea{
  width: 100%;
  padding: .65rem .75rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  outline: none;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

.comment-form textarea{ min-height: 150px; resize: vertical; }

.comment-form input[type="text"]:focus,
.comment-form textarea:focus{
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(28,47,114,.12);
}

.form-submit{
  display: flex;
  justify-content: flex-start;
  gap: .75rem;
  align-items: center;
}

/* ------------------------------
   7) Sidebar Widgets
------------------------------ */
#secondary.widget-area{
  display: grid;
  gap: 1rem;
}

.widget{
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  box-shadow: 0 6px 18px rgba(0,0,0,.05);
}

.widget-title{
  margin: 0;
  padding: .85rem 1rem;
  background: var(--primary);
  color: #fff;
  font-size: 1rem;
}
.widget-title h2{
  margin: 0;
  font-size: 1rem;
  color: #fff;
}

.widget ul{
  list-style: none;
  padding: .75rem 1rem 1rem;
  margin: 0;
}

.widget ul li{ margin: .35rem 0; }
.widget ul a{ color: var(--text); text-decoration: none; }
.widget ul a:hover{ color: var(--primary); text-decoration: underline; }

.textwidget{
  padding: .75rem 1rem 1rem;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  font-size: .95rem;
  color: var(--text);
}
.textwidget br{ line-height: 1.8; }

/* Search widget */
.widget_search .search-form{
  padding: .85rem 1rem 1rem;
  display: flex;
  gap: .5rem;
}
.widget_search .search-field{
  flex: 1;
  padding: .6rem .75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
}
.widget_search .search-field:focus{
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(28,47,114,.12);
}
.widget_search .search-submit{
  white-space: nowrap;
}

/* Calendar widget */
#calendar_wrap{
  padding: .85rem 1rem 1rem;
  overflow-x: auto;
}

#wp-calendar{
  width: 100%;
  border-collapse: collapse;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  font-size: .92rem;
}

#wp-calendar caption{
  text-align: left;
  font-weight: 700;
  padding: .25rem 0 .75rem;
  color: var(--text);
}

#wp-calendar th,
#wp-calendar td{
  border: 1px solid var(--border);
  text-align: center;
  padding: .45rem .4rem;
}

#wp-calendar thead th{
  background: var(--bg-soft);
  font-weight: 700;
}

#wp-calendar tbody td#today{
  background: rgba(28,47,114,.12);
  border-color: var(--primary);
  font-weight: 700;
}

#wp-calendar tfoot td{
  padding: .6rem .4rem;
}
#wp-calendar #prev a{
  color: var(--primary);
  font-weight: 700;
}

/* ------------------------------
   8) Footer
------------------------------ */
#colophon.site-footer{
  margin-top: 2rem;
  border-top: 1px solid var(--border);
  background: var(--bg-soft);
}

.site-info{
  max-width: var(--container);
  margin: 0 auto;
  padding: 1.25rem 1rem;
  color: var(--muted);
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

.site-info a{ color: var(--primary); }
.sep{ margin: 0 .35rem; color: rgba(0,0,0,.25); }

/* ------------------------------
   9) Back to top button
------------------------------ */
#toTop{
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow);
  z-index: 999;
}
#toTop:hover{
  filter: brightness(1.05);
  text-decoration: none;
}

/* ------------------------------
   10) Forms (generic)
------------------------------ */
input[type="search"],
input[type="email"],
input[type="url"],
input[type="password"], 
textarea{
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

/* ------------------------------
   11) Minor: Wayback footer notice (if present)
------------------------------ */
center font{
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--muted);
}