:root {
  --header: #323232e6;
  --header-dark: #2c2c2c;
  --accent: #b23121;
  --accent-dark: #8f271a;
  --gold: #ffae00;
  --primary: #1779ba;
  --text: #000;
  --muted: #333;
  --card: #fff;
  --max: 1140px;
  --radius: 10px;
  --shadow: none;
  --font: "Open Sans", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 400;
  color: var(--text);
  background: #e8c99a url("/assets/img/bg.jpg") center / cover fixed no-repeat;
  line-height: 1.5;
}
img { max-width: 100%; height: auto; display: block; }
a {
  color: inherit;
  text-decoration: none;
}
.skip {
  position: absolute; left: -999px; top: 0;
}
.skip:focus { left: 8px; background: #fff; padding: 8px; z-index: 2000; }

.wrap {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
}

/* Header */
.site-header {
  background: var(--header);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 84px;
}
.brand {
  color: #fff;
  text-decoration: none;
  line-height: 1.2;
  padding: 12px 0;
}
.brand-kn {
  font-size: 24px;
  font-weight: 600;
  line-height: 1.25;
  display: block;
}
.brand-en {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.25;
  display: block;
}

.nav-toggle {
  display: none;
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 4px;
  background: var(--accent);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
}
.nav-toggle[aria-expanded="true"] { background: var(--accent-dark); }

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 2px;
}
.nav-list > li { position: relative; }
.nav-list a, .nav-list button.has-sub {
  display: block;
  color: #fff;
  text-decoration: none;
  background: none;
  border: 0;
  font: 600 16px/1.25 var(--font);
  padding: 13px 20px;
  cursor: pointer;
}
.nav-list a:hover, .nav-list button.has-sub:hover,
.nav-list a.is-active,
.nav-list li.is-current > .has-sub { color: var(--gold); }
.caret {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 8px;
  vertical-align: middle;
}
.caret svg {
  display: block;
  width: 11px;
  height: 7px;
  fill: currentColor;
}
.has-sub { display: inline-flex; align-items: center; }

.dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 12em;
  padding: 15px 0 0;
  background: transparent;
  color: #fff;
  list-style: none;
  margin: 0;
  z-index: 30;
}
.dropdown li {
  background: #323232e6;
}
.dropdown a {
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  line-height: 1.25;
  padding: 10px 20px;
}
.dropdown a:hover,
.dropdown a.is-active {
  background: #ffffffe6;
  color: var(--gold);
}
.nav-list > li:hover > .dropdown,
.nav-list > li:focus-within > .dropdown,
.nav-list > li.open > .dropdown {
  display: block;
}

/* Main cards — match Elementor boxed sections */
.page {
  padding: 28px 0 48px;
}
.card {
  background: #fff;
  border-radius: 10px;
  padding: 25px 25px 25px 35px;
  margin: 0 0 30px;
  box-shadow: none;
}
.card-soft {
  background: #ffffffb8;
  padding: 20px 20px 25px;
}
.page-title {
  margin: 0 0 8px;
  font-size: 40px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--text);
}
.ornament {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #666;
  font-style: italic;
  margin: 0 0 22px;
}
.ornament::before, .ornament::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #222;
}

/* Slider — WP carousel: boxed 1140, max-height 650, crop from top-left */
.slider-wrap {
  background: #ffffff5c;
  padding: 15px 0;
}
.slider {
  position: relative;
  overflow: hidden;
  margin: 0 auto;
  width: min(var(--max), calc(100% - 32px));
  max-height: 650px;
}
.slides {
  display: flex;
  width: 100%;
  transition: transform .5s ease;
}
.slide {
  flex: 0 0 100%;
  width: 100%;
  line-height: 0;
}
.slide img {
  width: 100%;
  height: auto;
  max-height: 650px;
  aspect-ratio: 1140 / 650;
  object-fit: cover;
  object-position: 0 0;
}
.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 42px;
  height: 42px;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 34px;
  cursor: pointer;
  text-shadow: 0 1px 8px rgba(0,0,0,.6);
}
.slider-btn.prev { left: 8px; }
.slider-btn.next { right: 8px; }
.dots {
  position: absolute;
  left: 0; right: 0; bottom: 12px;
  display: flex;
  justify-content: center;
  gap: 8px;
}
.dots button {
  width: 15px; height: 15px;
  border-radius: 50%;
  border: 0;
  background: #ffffff75;
  cursor: pointer;
  padding: 0;
  opacity: 1;
}
.dots button.is-on { background: var(--gold); }

/* Home about */
.about-grid {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 24px;
  align-items: center;
}
.about-grid h2 {
  margin: 0 0 12px;
  font-size: 32px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--text);
}
.about-grid p { margin: 0 0 18px; font-size: 16px; font-weight: 400; line-height: 1.5; color: var(--text); }
.about-grid img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  margin-left: auto;
}

.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff !important;
  text-decoration: none;
  padding: 10px 22px;
  border-radius: 2px;
  font-weight: 500;
  border: 0;
  cursor: pointer;
  font-family: inherit;
}
.btn:hover { background: var(--accent-dark); }
.btn-small { padding: 6px 14px; font-size: 14px; }

.section-title {
  text-align: center;
  font-size: 25px;
  font-weight: 600;
  line-height: 1.25;
  margin: 0 0 20px;
  color: var(--text);
}
.events {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.events img {
  width: 100%;
  height: auto;
  border-radius: 2px;
}

.posts {
  display: grid;
  gap: 18px;
}
.post-preview h3 { margin: 0 0 6px; font-size: 20px; }
.post-preview h3 a { color: var(--text); text-decoration: none; }
.post-preview h3 a:hover { color: var(--accent); }
.post-preview p { margin: 0 0 8px; color: var(--muted); }
.more { font-weight: 600; text-decoration: none; }

.knowledge {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 30px;
  row-gap: 35px;
  padding: 8px 10px 10px;
}
.knowledge-card {
  background: #fff;
  border-radius: 5px;
  box-shadow: 0 4px 16px 0 rgba(0, 0, 0, 0.25);
  padding: 20px;
}
.knowledge-card h3 {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.25;
  margin: 0 0 15px;
}
.knowledge-card h3 a { color: var(--primary); }
.knowledge-card h3 a:hover { color: var(--accent); }
.knowledge-card p { color: #777; margin: 0 0 12px; font-size: 14px; line-height: 1.3; }
.knowledge-card .more { color: var(--accent); font-size: 12px; font-weight: 500; }
.knowledge-section { margin-bottom: 60px; }

/* Article */
.article {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--text);
}
.article p { margin: 0 0 1em; }
.article img { margin: 12px auto; }
.article-figure { margin: 16px 0; }
.file-block { margin: 16px 0; }
.pdf-embed { width: 100%; height: 70vh; border: 0; }

/* Contact */
.contact-top {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  gap: 24px;
  align-items: stretch;
}
.contact-list { list-style: none; margin: 0; padding: 0; }
.contact-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 0 0 12px;
}
.contact-list svg {
  flex: 0 0 1.25em;
  width: 1.25em;
  height: 1em;
  font-size: 20px;
  margin-top: 3px;
  color: var(--accent);
}
.map iframe {
  width: 100%;
  height: 100%;
  min-height: 240px;
  border: 0;
  border-radius: 4px;
}
.form-grid {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 24px;
  align-items: start;
}
.form-grid h2 { margin: 8px 0 0; font-size: 28px; font-weight: 600; line-height: 1.25; color: var(--text); }
form { display: grid; gap: 12px; }
input, textarea {
  width: 100%;
  border: 1px solid #e6c58a;
  background: #fffaf0;
  padding: 12px 14px;
  font: inherit;
  border-radius: 2px;
}
input:focus, textarea:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.hp { position: absolute; left: -9999px; }
.form-grid .btn { justify-self: start; min-width: 160px; }

/* Gallery */
.filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 18px;
  margin: 0 0 22px;
}
.filters button {
  background: none;
  border: 0;
  font: 600 13px/1 var(--font);
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #666;
  cursor: pointer;
  padding: 8px 10px;
}
.filters button.is-on {
  background: #3a3a3a;
  color: #fff;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.gallery-grid a {
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #eee;
}
.gallery-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
}
.gallery-grid a:hover img { transform: scale(1.04); }
.gallery-grid a.is-hidden { display: none; }
.gallery-more-wrap {
  text-align: center;
  margin-top: 24px;
}

.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.88);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.lightbox.is-open { display: flex; }
.lightbox img {
  max-width: min(92vw, 1100px);
  max-height: 88vh;
  object-fit: contain;
}
.lightbox .close {
  position: absolute;
  top: 12px; right: 16px;
  background: none; border: 0; color: #fff;
  font-size: 32px; cursor: pointer;
}

/* Footer */
.site-footer {
  background: rgba(50, 50, 50, .92);
  color: #fff;
  padding: 36px 0 0;
  font-weight: 400;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 28px;
  padding-bottom: 28px;
}
.site-footer h3 {
  margin: 0 0 14px;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.25;
  color: #fff;
}
.site-footer p, .site-footer li, .site-footer span {
  color: #fff;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.4;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li {
  display: flex;
  gap: 15px;
  margin: 0 0 10px;
  align-items: flex-start;
}
.site-footer li svg {
  flex: 0 0 1.25em;
  width: 1.25em;
  height: 1em;
  font-size: 20px;
  margin-top: 3px;
  color: #fff;
  fill: currentColor;
}
.site-footer a { color: inherit; }
.footer-btn {
  display: inline-block;
  min-width: 180px;
  text-align: center;
  margin: 0 0 18px;
  color: #fff !important;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.3;
}
.times {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 16px;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.3;
  color: #fff;
}
.social { display: flex; gap: 15px; margin-top: 8px; }
.social a {
  width: 45px; height: 45px; border-radius: 50%;
  display: grid; place-items: center;
  color: #fff;
  font-size: 25px;
}
.social svg { width: 22px; height: 22px; flex: none; margin: 0; }
.social .fb { background: #3b5998; }
.social .ig { background: #c13584; }
.social .tw { background: #1da1f2; }
.social .yt { background: #cd201f; }
.copyright {
  background: #333;
  text-align: center;
  padding: 20px 15px;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.4;
  color: #fff;
  font-family: "Open Sans", sans-serif;
}
.copyright a { color: inherit; }

@media (max-width: 1024px) {
  .knowledge { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .about-grid, .contact-top, .form-grid, .events, .footer-grid {
    grid-template-columns: 1fr;
  }
  .gallery-grid { grid-template-columns: 1fr 1fr; }
  .page-title { font-size: 32px; }
  .card { padding: 22px 18px; }
}

@media (max-width: 767px) {
  .nav-toggle { display: inline-flex !important; align-items: center; justify-content: center; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--header);
    padding: 8px 0 16px;
    box-shadow: 0 8px 16px rgba(0,0,0,.25);
  }
  .nav.is-open { display: block; }
  .nav-list { flex-direction: column; align-items: stretch; }
  .nav-list a, .nav-list button.has-sub { text-align: left; width: 100%; }
  .dropdown {
    position: static;
    display: none;
    min-width: 0;
    box-shadow: none;
    background: transparent;
    border-radius: 0;
    padding: 0;
  }
  .dropdown li { background: #323232e6; }
  .dropdown a { color: #fff; padding-left: 28px; }
  .nav-list > li.open > .dropdown { display: block; }
  .gallery-grid { grid-template-columns: 1fr; }
  .knowledge { grid-template-columns: 1fr; }
}
