/*
Theme Name: Priekamprieks v4 (cleaned)
Author: Vents
Description: Same as v4 but with header/footer kick-in animation removed.
Version: 4.3
*/

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background-color: #f9f5ef;
  color: #111;
}

/* ===== Header ===== */
header#site-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 24px;
  gap: 6px;
  opacity: 1;
  border: 2px solid #fff;
}

.header-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.site-title {
  font-size: 1.6em;
  font-weight: 700;
  font-family: 'Fredericka the Great', cursive;
  letter-spacing: 0.5px;
  color: #555;
}

.header-logo,
.header-logo img,
.custom-logo-link img {
  display: block;
  max-width: 150px;
  max-height: 54px;
  width: auto;
  height: auto;
  margin: 4px auto 10px;
}

/* ===== Menu hover ===== */
.primary-menu {
  margin: 0 auto;
  margin-top: 14px;
}

.primary-menu ul {
  list-style: none;
  display: flex;
  gap: 28px;
  margin: 0;
  padding: 0;
  align-items: center;
}

.primary-menu li {
  text-align: center;
}

.primary-menu a {
  text-decoration: none;
  color: inherit;
  transition: opacity 0.8s ease-in-out;
  display: inline-block;
  text-align: center;
  white-space: normal;
  word-break: keep-all;
}

.primary-menu a:hover {
  opacity: 0.25;
}

/* ===== Main content fade-in ===== */
@keyframes fade-in {
  0% { opacity: 0; }
  100% { opacity: 1; }
}

main {
  margin-left: 20vw;
  margin-right: 20vw;
  padding: 10px 0 120px 0;
  text-align: center;
  box-sizing: border-box;
  opacity: 0;
  animation: fade-in 0.8s ease-in-out forwards;
}

main h1,
main h2,
main h3,
main p {
  text-align: center;
}

/* ===== Footer ===== */
footer#site-footer {
  background: #fff;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 5px 5px;
  min-height: 10px;
  box-shadow: 0 -2px 8px rgba(0,0,0,0.05);
  box-sizing: border-box;
  opacity: 1;
}

.footer-inner {
  width: 100%;
  max-width: 1100px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-contact {
  display: flex;
  gap: 16px;
  align-items: center;
}

.footer-contact .graffiti2,
#email-link a {
  font-family: 'Fredericka the Great', cursive;
  font-size: 14px;
  line-height: 1.2;
  color: #111;
}

/* ===== Footer Subscribe Form ===== */
#subscribe-form {
  display: flex;
  align-items: center;
}

#subscribe-form input,
#subscribe-form button {
  transform: none;
  transform-origin: center center;
  font-size: 14px;
  line-height: 1.2;
  padding: 4px 8px;
}

#subscribe-form input {
  margin-right: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

#subscribe-form button {
  background: #F75C80;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

#subscribe-form button:hover {
  opacity: 0.85;
}

/* ===== Footer Email Color ===== */
#email-link a {
  color: #1DB3AB !important;
  text-decoration: none;
}

/* ===== Responsive tweaks ===== */
@media (max-width: 820px) {
  header#site-header { padding: 12px; }
  .site-title { font-size: 1.2em; }
  .header-logo img { max-height: 42px; max-width: 120px; }
  main { margin-left: 6vw; margin-right: 6vw; }
  .footer-inner { flex-direction: column; gap: 8px; }
}

/* ===== Shared Page Formatting (Par Mums, Realizētie Projekti, Konvojs, Last Menu) ===== */
.page-id-132 main,
.page-id-116 main,
.page-id-47 main,
.page-id-120 main {
  margin-left: auto;
  margin-right: auto;
  max-width: 800px;
  padding: 30px 20px;
  text-align: justify;
  line-height: 1.7;
  box-sizing: border-box;
}

.page-id-132 main h1,
.page-id-132 main h2,
.page-id-132 main h3,
.page-id-116 main h1,
.page-id-116 main h2,
.page-id-116 main h3,
.page-id-47 main h1,
.page-id-47 main h2,
.page-id-47 main h3,
.page-id-120 main h1,
.page-id-120 main h2,
.page-id-120 main h3 {
  text-align: center;
}

.page-id-132 main p,
.page-id-116 main p,
.page-id-47 main p,
.page-id-120 main p {
  text-align: justify;
}

/* ===== Mobile optimization for these pages - max width 99% ===== */
@media (max-width: 820px) {
  .page-id-132 main,
  .page-id-116 main,
  .page-id-47 main,
  .page-id-120 main {
    max-width: 99% !important;       /* wider text on phones */
    padding: 20px 8px 80px 8px !important; /* smaller horizontal padding */
    text-align: justify !important;
    line-height: 1.6 !important;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box !important;
  }

  .page-id-132 main h2,
  .page-id-132 main h3,
  .page-id-132 main p,
  .page-id-116 main h2,
  .page-id-116 main h3,
  .page-id-116 main p,
  .page-id-47 main h2,
  .page-id-47 main h3,
  .page-id-47 main p,
  .page-id-120 main h2,
  .page-id-120 main h3,
  .page-id-120 main p {
    text-align: inherit !important;
  }
}

/* ===== Custom link styles for red/green links ===== */
.link-red {
  color: #F75C80;        /* red like logo */
  text-decoration: none;
  transition: opacity 0.3s ease-in-out; /* very subtle hover effect */
}

.link-red:hover {
  opacity: 0.9;          /* subtle hover */
}

.link-green {
  color: #1DB3AB;        /* green like footer email */
  text-decoration: none;
  transition: opacity 0.3s ease-in-out; /* very subtle hover effect */
}

.link-green:hover {
  opacity: 0.9;          /* subtle hover */
}
