/* =============== CUSTOM OVERRIDES FOR YOUR COLOR SCHEME =============== */
:root {
  /* Reassigning Bootstrap’s standard colors to my palette: */
  --bs-primary:    #344CB7;  /* medium navy */
  --bs-secondary:  #000957;  /* very dark navy */
  --bs-info:       #577BC1;  /* lighter blue */
  --bs-warning:    #FFEB00;  /* bright yellow */
}

/* =============== MASTHEAD AND NAVBAR =============== */
.masthead {
  position: relative;
  width: 100%;
  height: 400px;
  margin-bottom: 3rem;
  padding: 0;
  background-color: var(--bs-secondary);
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
}

.masthead:before {
  content: "";
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent overlay */
  opacity: 0.3;
  z-index: 0;
}

.masthead .masthead-content,
.masthead .container {
  position: relative;
  z-index: 1;
  color: #fff;
}

.masthead h1 {
  font-size: 4rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.masthead .subheading {
  font-size: 2rem;
  font-weight: 400;
}

.masthead h1, .masthead .meta, .masthead .subheading {
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
}

/* Headings in Montserrat */
h1, h2, h3, .masthead .subheading, .masthead h1 {
  font-family: 'Montserrat', sans-serif;
}

.navbar {
  background: linear-gradient(90deg, #000957, #344CB7);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.navbar-nav .nav-link {
  transition: color 0.3s ease;
  font-weight: 500;
  padding: 0.75rem 1rem;
}

.navbar-nav .nav-link:hover {
  color: #FFEB00;  /* bright yellow on hover */
}

.navbar-toggler {
  padding: 0.75rem 1.25rem;
  font-size: 1.25rem;
}

.navbar-brand,
.navbar-nav .nav-link {
  font-family: 'Montserrat', sans-serif;
}

/* =============== MAIN CONTENT & SIDEBAR LAYOUT =============== */
/* Base body font (Open Sans) */
body {
  font-family: 'Open Sans', sans-serif;
  font-size: 16px;
  color: #333;
  margin-top: 66px;
}

.content-area {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 2rem;
  width: 100%;
}

/* Posts container remains largely unchanged */
.posts-container {
  background-color: #ffffff;
  padding: 1rem;
  margin: 2rem auto;
  width: 100%;
  border-radius: 4px;
  box-sizing: border-box;
}

/* =============== BLOG POST SEMANTIC STRUCTURE =============== */
/* Adjusting for semantic markup (article > header, section, footer) */
article.post {
  margin-bottom: 2rem;
  border-bottom: 1px solid #ddd;
  padding-bottom: 1rem;
}

article.post header {
  margin-bottom: 1rem;
}

article.post header .post-image img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

article.post header h2.post-title {
  font-size: 2rem;
  margin: 0.5rem 0;
  text-decoration: underline double;
}

article.post header h3.post-subtitle {
  font-size: 1.5rem;
  margin: 0.5rem 0;
}

article.post header .post-meta {
  font-size: 0.9rem;
  color: #666;
}

article.post section.post-excerpt {
  margin-bottom: 1rem;
  font-size: 1rem;
}

article.post footer {
  background: #FFF;
  box-shadow: none;
  padding: 0.5rem 0;
  margin-top: 0.5rem;
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

article.post footer a.btn {
  margin-right: 0.5rem;
  margin-left: 0.5rem;
  margin-bottom: 0.5rem;
}

/* Button styles for posts */
.post .btn {
  transition: background-color 0.3s ease;
}

.post .btn:hover {
  background-color: #FFEB00;
  border-color: #FFEB00;
  color: #000;
}

/* =============== SIDEBAR (PUBLICIDAD) =============== */
.sidebar {
  background-color: var(--bs-info);
  color: #fff;
  padding: 1rem;
  border-radius: 4px;
  max-height: auto;
  max-width: 300px;
  overflow-y: auto;
  margin-left: auto;
  margin-top: 50px;
  margin-bottom: 50px;
  position: relative;
  right: 0;
}

.sidebar h2 {
  color: var(--bs-warning);
}

.sidebar .ad-box {
  background-color: var(--bs-primary);
  margin-bottom: 1rem;
  text-align: center;
  padding: 1rem;
  border-radius: 4px;
}

.sidebar .ad-box img {
  max-width: 100%;
  height: auto;
}

/* =============== FOOTER =============== */
footer {
  background: linear-gradient(90deg, #000957, #344CB7);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  padding: 2rem;
  text-align: center;
}

footer ul.list-inline li {
  margin: 0 0.5rem;
}

footer a {
  transition: color 0.3s ease;
  padding: 0.75rem 1rem;
}

footer a:hover {
  color: #FFEB00;
}

footer a:hover .fa-stack-1x {
  color: #000957;
  transition: color 0.3s ease;
}

.site-footer .text-muted {
  color: #fff !important;
}

/* Specific styles for privacy & contact links */
.footer-link {
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer-link:hover {
  color: #FFEB00;
}

/* =============== COMMENT STYLING =============== */
.commentBox {
  padding: 10px;
  border-top: 1px dotted #bbb;
}

.commentBox .form-group:first-child,
.actionBox .form-group:first-child {
  width: 80%;
}

.commentBox .form-group:nth-child(2),
.actionBox .form-group:nth-child(2) {
  width: 18%;
}

.comment {
  padding-top: 20px;
}

.commentList {
  padding: 0;
  list-style: none;
  max-height: 200px;
  overflow: auto;
}

.commentList li {
  margin: 0;
  margin-top: 10px;
}

.commentList li > div {
  display: table-cell;
}

.commenterImage {
  width: 45px;
  margin-right: 10px;
  height: auto;
  float: left;
}

.commenterImage img {
  width: 100%;
  border-radius: 50%;
}

.commentText p {
  margin: 0;
}

.sub-text {
  color: #aaa;
  font-family: verdana;
  font-size: 13px;
}

/* =============== FLASH MESSAGE STYLING =============== */
.flash {
  color: #ee6f57;
  text-align: center;
}

/* =============== MEDIA QUERIES =============== */
@media (max-width: 800px) {
  .row {
    display: block;
  }

  .posts-container, .sidebar {
    width: 100%;
    margin: 1rem 0;
    padding: 0.5rem;
  }

  .container {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }

  .sidebar {
    margin-top: 1rem;
  }
  #sidebar {
    display: flex;
    justify-content: center;
  }

  body {
    font-size: 14px;
  }

  .masthead {
    height: 300px;
  }

  .masthead h1 {
    font-size: 1.5rem;
  }

  .masthead .subheading {
    font-size: 1rem;
  }

  .navbar-nav .nav-link {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
  }

  .navbar-brand img {
    height: 30px;
  }

  footer {
    padding: 1rem;
    font-size: 0.9rem;
  }

  .site-footer .copyright {
    margin-top: 0.5rem;
  }
}

/* =============== COOKIES POPUP =============== */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.85);
  color: white;
  text-align: center;
  padding: 15px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  z-index: 1000;
}

#cookie-banner {
    display: none;
    /* Other styling properties */
}

.cookie-banner p {
  margin: 0;
  font-size: 14px;
}

.cookie-banner a {
  color: #FFEB00;
  text-decoration: underline;
}

.cookie-banner button {
  background: #344CB7;
  border: none;
  color: white;
  padding: 10px 20px;
  cursor: pointer;
  border-radius: 5px;
}

.cookie-banner button.btn-secondary {
  background: #777;
}

.cookie-banner button:hover {
  opacity: 0.8;
}

.hidden {
  display: none;
}
