/* CPRP public site styles */

@font-face {
  font-family: "SK Posad Text";
  src: url("../fonts/SK Posad Text.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --color-navy: #1a3b5d;
  --color-navy-dark: #142f4a;
  --color-teal: #2a9d8f;
  --color-teal-light: #3db8a9;
  --color-white: #ffffff;
  --color-gray-100: #f5f7fa;
  --color-gray-200: #e8ecf1;
  --color-gray-600: #5a6a7a;
  --color-text: #2c3e50;
  --font-main: "SK Posad Text", Georgia, serif;
  --container-width: 1200px;
  --header-height: 88px;
  --radius-sm: 6px;
  --radius-md: 12px;
  --shadow-card: 0 4px 20px rgba(26, 59, 93, 0.1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-white);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-navy);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--color-teal);
}

.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-white);
  box-shadow: 0 2px 12px rgba(26, 59, 93, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-height);
  gap: 24px;
}

.site-branding {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  max-width: min(420px, 48%);
}

.site-logo-link {
  display: block;
  flex-shrink: 0;
  line-height: 0;
}

.site-logo-img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  display: block;
  border-radius: 50%;
  background: #fff;
}

.site-title {
  font-size: 13px;
  line-height: 1.3;
  color: var(--color-navy);
  max-width: 320px;
}

.site-title a {
  color: inherit;
}

.site-title a:hover {
  color: var(--color-teal);
}

.main-navigation {
  flex: 1;
  display: flex;
  justify-content: flex-end;
}

.main-navigation ul {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 8px;
}

.main-navigation a {
  display: block;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--color-navy);
}

.main-navigation a:hover,
.main-navigation .current-menu-item > a,
.main-navigation .current_page_item > a {
  color: var(--color-teal);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 24px;
  font-family: var(--font-main);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 2px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-primary {
  background: var(--color-navy);
  color: var(--color-white);
  border-color: var(--color-navy);
}

.btn-primary:hover {
  background: var(--color-navy-dark);
  border-color: var(--color-navy-dark);
  color: var(--color-white);
}

.btn-outline {
  background: transparent;
  color: var(--color-white);
  border-color: var(--color-white);
}

.btn-outline:hover {
  background: var(--color-white);
  color: var(--color-navy);
}

/* Hero */
.hero {
  position: relative;
  min-height: 520px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  overflow: hidden;
}

.hero-left {
  position: relative;
  background: var(--color-navy);
  display: flex;
  align-items: center;
  padding: 60px 48px;
  overflow: hidden;
}

.hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.3;
  background:
    linear-gradient(135deg, transparent 40%, var(--color-teal) 40%, var(--color-teal) 45%, transparent 45%),
    linear-gradient(225deg, transparent 40%, var(--color-teal-light) 40%, var(--color-teal-light) 50%, transparent 50%),
    linear-gradient(315deg, transparent 30%, rgba(42, 157, 143, 0.4) 30%, rgba(42, 157, 143, 0.4) 40%, transparent 40%);
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 480px;
}

.hero-content h1 {
  margin: 0 0 20px;
  font-size: 36px;
  line-height: 1.2;
  color: var(--color-white);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.hero-content p {
  margin: 0 0 32px;
  font-size: 16px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-right {
  background: linear-gradient(135deg, #4a7c9b 0%, #2a5a7a 50%, #1a3b5d 100%) center / cover no-repeat;
  min-height: 400px;
}

/* Feature cards */
.feature-cards {
  position: relative;
  margin-top: -80px;
  padding-bottom: 60px;
  z-index: 10;
}

.feature-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--color-white);
  border-radius: var(--radius-md);
  padding: 32px 24px;
  box-shadow: var(--shadow-card);
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(26, 59, 93, 0.15);
}

.feature-card-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  background: var(--color-gray-100);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
}

.feature-card h3 {
  margin: 0 0 12px;
  font-size: 16px;
  color: var(--color-navy);
  text-transform: uppercase;
}

.feature-card p {
  margin: 0;
  font-size: 14px;
  color: var(--color-gray-600);
  line-height: 1.5;
}

/* Page content */
.page-header {
  background: var(--color-navy);
  padding: 48px 0;
  margin-bottom: 48px;
}

.page-header h1 {
  margin: 0;
  font-size: 32px;
  color: var(--color-white);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.page-content {
  padding-bottom: 80px;
}

.page-content .entry-content {
  max-width: 800px;
}

.page-content .entry-content p {
  margin: 0 0 1.2em;
  font-size: 17px;
  line-height: 1.7;
}

.page-intro {
  margin-bottom: 40px;
}

/* One column of equal-width news cards */
.news-blocks {
  --news-width: 680px;
  width: 100%;
  max-width: var(--news-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-sizing: border-box;
}

.news-block {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  background: var(--color-gray-100);
  border: 1px solid var(--color-gray-200);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.news-block-inner {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.news-block-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.35;
  color: var(--color-navy);
}

.news-block-text {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--color-text);
  overflow-wrap: anywhere;
  word-break: break-word;
}

.news-block-text p {
  margin: 0 0 0.75em;
  font-size: 15px;
  line-height: 1.55;
  max-width: 100%;
}

.news-block-text p:last-child {
  margin-bottom: 0;
}

.news-block-text ul,
.news-block-text ol {
  margin: 0 0 0.75em;
  padding-left: 1.25em;
}

.news-block-text a {
  word-break: break-all;
}

.news-block-teaser {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--color-text);
}

.news-expand {
  margin: 0;
}

.news-expand-toggle {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--color-teal);
  font-weight: 600;
  font-size: 14px;
  font-family: var(--font-main);
  user-select: none;
}

.news-expand-toggle::-webkit-details-marker {
  display: none;
}

.news-expand-toggle::after {
  content: '';
  width: 0.45em;
  height: 0.45em;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-top: -2px;
  transition: transform 0.15s ease;
}

.news-expand[open] .news-expand-toggle::after {
  transform: rotate(-135deg);
  margin-top: 2px;
}

.news-expand-close {
  display: none;
}

.news-expand[open] .news-expand-open {
  display: none;
}

.news-expand[open] .news-expand-close {
  display: inline;
}

.news-expand-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 14px;
}

.news-media-grid {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
}

.news-media-grid.is-single {
  grid-template-columns: minmax(0, 1fr);
}

.news-media-grid.is-three .news-media-item:first-child {
  grid-column: 1 / -1;
}

.news-media-item {
  margin: 0;
  padding: 0;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: #e4e9ef;
}

.news-media-item img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  border: 0;
}

.news-block .entry-content,
.news-blocks .entry-content {
  max-width: 100% !important;
  width: 100%;
}

.map-embed {
  width: 100%;
  max-width: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-gray-200);
}

.map-embed iframe {
  width: 100%;
  max-width: 100%;
  height: 520px;
  border: 0;
  display: block;
}

.news-pre {
  background: #fff;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  margin: 0 0 12px;
  white-space: normal;
  line-height: 1.55;
  font-size: 14px;
}

.file-download {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin: 12px 0;
}

.file-download .btn {
  padding: 8px 16px;
  font-size: 13px;
}

.text-center {
  text-align: center;
}

details {
  margin: 12px 0 0;
  padding: 10px 14px;
  background: #fff;
  border-radius: var(--radius-sm);
}

details summary {
  cursor: pointer;
  color: var(--color-navy);
  font-weight: 600;
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  align-items: center;
  margin: 28px auto 8px;
  max-width: var(--news-width, 680px);
}

.pagination-btn {
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-gray-200);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--color-navy);
  font-family: var(--font-main);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.pagination-btn:hover {
  border-color: var(--color-teal);
  color: var(--color-teal);
}

.pagination-btn.is-current {
  background: var(--color-navy);
  border-color: var(--color-navy);
  color: #fff;
  cursor: default;
}

@media (max-width: 768px) {
  .news-blocks {
    --news-width: 100%;
  }

  .news-block-inner {
    padding: 14px;
    gap: 12px;
  }

  .news-block-title {
    font-size: 16px;
  }

  .news-media-grid {
    gap: 8px;
  }

  .map-embed iframe {
    height: 360px;
  }
}
/* Footer */
.site-footer {
  background: var(--color-navy);
  color: rgba(255, 255, 255, 0.8);
  padding: 40px 0;
  margin-top: auto;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.9);
}

.site-footer a:hover {
  color: var(--color-teal-light);
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  color: var(--color-navy);
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: currentColor;
  margin: 5px 0;
  transition: transform 0.2s ease;
}

/* Responsive */
@media (max-width: 992px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .hero-right {
    min-height: 280px;
    order: -1;
  }

  .hero-left {
    padding: 40px 24px;
  }

  .feature-cards-grid {
    grid-template-columns: 1fr;
  }

  .feature-cards {
    margin-top: 0;
    padding-top: 40px;
  }
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }

  .main-navigation {
    display: none;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--color-white);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 16px 0;
  }

  .main-navigation.is-open {
    display: block;
  }

  .main-navigation ul {
    flex-direction: column;
    align-items: center;
  }

  .site-branding {
    max-width: calc(100% - 48px);
  }

  .site-logo-img {
    width: 52px;
    height: 52px;
  }

  .site-title {
    font-size: 11px;
    max-width: 200px;
  }

  .hero-content h1 {
    font-size: 28px;
  }
}
