@import url("fonts.css");

:root {
  --primary: #7E1D21;
  --primary-dark: #301718;
  --secondary: #54595F;
  --text: #7A7A7A;
  --white: #fff;
  --container: 1140px;
  --font: "Montserrat", sans-serif;
  --font-alt: "Varela Round", sans-serif;
  --header-h: 90px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-weight: 400;
  color: var(--text);
  line-height: 1.5;
  background: #fff;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; transition: color .3s; }
a:hover { color: #c3363c; }
.ico { width: 1em; height: 1em; display: inline-block; vertical-align: -0.125em; }

.skip-link { position: absolute; left: -9999px; top: 0; z-index: 1000; background: #fff; padding: 8px 16px; }
.skip-link:focus { left: 8px; top: 8px; }

/* ---------- Header ---------- */
.site-header {
  position: relative;
  z-index: 10;
  background: var(--primary);
  box-shadow: 0 10px 20px rgba(0, 0, 0, .2);
  margin-bottom: calc(-1 * var(--header-h));
}
.header-inner {
  max-width: 1400px;
  min-height: var(--header-h);
  margin: 0 auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 1fr 2fr 1fr;
  align-items: center;
  gap: 20px;
}
.logo img { max-height: 70px; width: auto; }
.main-nav { justify-self: end; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 30px; }
.main-nav a {
  position: relative;
  display: block;
  padding: 35px 0;
  color: #fff;
  font-family: var(--font-alt);
  font-size: 17px;
  font-weight: 300;
}
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 25px;
  height: 3px;
  background: #fff;
  opacity: 0;
  transform: scaleX(.3);
  transition: opacity .3s, transform .3s;
}
.main-nav a:hover::after, .main-nav a.active::after { opacity: 1; transform: none; }
.main-nav a:hover { color: #fff; }

.menu-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 10px;
  cursor: pointer;
}
.menu-toggle .bar { display: block; width: 26px; height: 3px; margin: 5px 0; background: #fff; transition: transform .3s, opacity .3s; }
.menu-toggle[aria-expanded="true"] .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .bar:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

.header-phones { justify-self: end; list-style: none; margin: 0; padding: 0; }
.header-phones.icon-list li { padding: 2px 0; }
.header-phones.icon-list a, .header-phones.icon-list li { color: #fff; font-size: 14px; letter-spacing: .5px; }
.header-phones.icon-list a:hover .il-text { color: #fff; opacity: .8; }
.header-phones.icon-list .il-icon { color: #fff; margin-right: 8px; }

/* ---------- Hero slider ---------- */
.hero { position: relative; height: 600px; overflow: hidden; background: var(--primary); }
.slide { position: absolute; inset: 0; opacity: 0; transition: opacity .5s ease; }
.slide.is-active { opacity: 1; z-index: 1; }
.slide-bg {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1);
  transition: transform 6s linear;
}
.slide.is-active .slide-bg { transform: scale(1.3); }
.slide-overlay { position: absolute; inset: 0; background: #4310121C; }
.slider-arrow {
  position: absolute; top: 50%; z-index: 2;
  transform: translateY(-50%);
  background: none; border: 0; color: #fff; font-size: 40px;
  cursor: pointer; padding: 10px; opacity: .8;
}
.slider-arrow:hover { opacity: 1; }
.slider-arrow.prev { left: 10px; }
.slider-arrow.next { right: 10px; }
.slider-dots { position: absolute; bottom: 20px; left: 0; right: 0; z-index: 2; display: flex; justify-content: center; gap: 8px; }
.dot { width: 15px; height: 15px; border-radius: 50%; border: 0; padding: 0; background: rgba(255, 255, 255, .5); cursor: pointer; }
.dot.is-active { background: #fff; }

/* ---------- Layout ---------- */
.section { padding: 15px; margin-top: 2rem; }
.container { max-width: var(--container); margin: 0 auto; }
.row { display: flex; flex-wrap: wrap; }
.row.v-middle { align-items: center; }
.col { padding: 10px; min-width: 0; }
.col > * + * { margin-top: 20px; }
.col-100 { width: 100%; }
.col-66 { width: 66.666%; }
.col-50 { width: 50%; }
.col-33 { width: 33.333%; }
.col-25 { width: 25%; }
.col-20 { width: 20%; }
.sub-section { margin: 1rem 0; }

/* ---------- Widgets ---------- */
.heading {
  margin: 0;
  color: var(--primary);
  font-family: var(--font);
  font-size: 2.5rem;
  font-weight: 900;
  line-height: 1.2;
  text-shadow: 3px 3px 4px rgba(0, 0, 0, .2);
}
h3.heading, h4.heading { font-size: 1.6rem; font-weight: 700; }
.text { font-size: 1.1rem; line-height: 1.7; }
.text p { margin: 0 0 1em; }
.text p:last-child { margin-bottom: 0; }
.text b, .text strong { color: var(--secondary); font-weight: 700; }
.text h1, .text h2, .text h3, .text h4 { color: var(--primary); font-weight: 700; line-height: 1.3; }
.text ul { padding-left: 1.3em; }
.text li { margin-bottom: .3em; }
.text table { border-collapse: collapse; width: 100%; }
.text td, .text th { border: 1px solid #ddd; padding: 6px 10px; }

.btn {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 500;
  border: 0;
  border-radius: 0;
  cursor: pointer;
  transition: background .3s, transform .2s;
  font-family: var(--font);
}
.btn:hover, .btn:focus { background: #5c1417; color: #fff; }
.btn-block { width: 100%; }
p:has(> .btn) { margin: 0; }

.image img { width: 100%; border-radius: 4px; box-shadow: 0 10px 25px rgba(0, 0, 0, .15); }
.image { margin: 0; }

.icon-list { list-style: none; margin: 0; padding: 0; }
.icon-list li { padding: 5px 0; }
.icon-list a, .icon-list li { color: var(--text); font-size: 1.2rem; display: flex; align-items: center; }
.icon-list .il-icon { color: var(--primary); margin-right: 20px; display: inline-flex; flex: none; }
.icon-list a:hover .il-text { color: var(--primary); }

.counter { text-align: center; }
.counter-num {
  color: var(--primary);
  font-size: 3rem;
  font-weight: 700;
  line-height: 1;
  text-shadow: 3px 3px 4px rgba(0, 0, 0, .2);
}
.counter-title { color: var(--secondary); font-size: 1.2rem; margin-top: 8px; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; margin: 20px 0; }
.card {
  background: #fff;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 0 10px rgba(0, 0, 0, .15);
  display: flex; flex-direction: column;
  transition: box-shadow .3s;
}
.card:hover { box-shadow: 0 0 30px rgba(0, 0, 0, .15); }
.card-thumb { display: block; position: relative; padding-bottom: 50%; overflow: hidden; }
.card-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.card:hover .card-thumb img { transform: scale(1.05); }
.card-body { padding: 15px 15px 20px; }
.card-title { margin: 0 0 10px; font-size: 1.3rem; font-weight: 600; }
.card-title a { color: var(--primary); }
.card-body p { font-size: .95rem; margin: 0 0 10px; }
.card-more { font-size: 12px; font-weight: 600; text-transform: uppercase; }

.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.gallery-item { display: block; overflow: hidden; aspect-ratio: 3 / 2; background: #eee; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s; }
.gallery-item:hover img { transform: scale(1.1); }

.map iframe { width: 100%; height: 400px; border: 0; display: block; }

.pdf-embed object { width: 100%; height: 85vh; min-height: 500px; border: 1px solid #ddd; display: block; }
.pdf-fallback { padding: 30px; text-align: center; }
.pdf-actions { text-align: right; font-size: .9rem; margin: 6px 0 0; }

/* ---------- Forms ---------- */
.contact-form .field { margin-bottom: 12px; }
.contact-form label { display: block; font-size: 14px; color: var(--secondary); margin-bottom: 4px; }
.contact-form input, .contact-form textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #69727d;
  border-radius: 3px;
  font: inherit;
  font-size: 15px;
  color: #333;
}
.contact-form input:focus, .contact-form textarea:focus { outline: 2px solid var(--primary); border-color: var(--primary); }
.contact-form .invalid { border-color: #d63638; }
.form-status { margin: 10px 0 0; font-size: 14px; min-height: 1em; }
.form-status.ok { color: #2e7d32; }
.form-status.err { color: #d63638; }

/* ---------- Footer ---------- */
.site-footer {
  margin-top: 3rem;
  background: linear-gradient(90deg, var(--primary) 0%, var(--primary-dark) 100%);
  box-shadow: 0 -10px 20px rgba(0, 0, 0, .2);
  color: #fff;
}
.footer-inner {
  padding: 3rem 10rem;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}
.site-footer h4 {
  margin: 0 0 20px;
  font-family: var(--font-alt);
  font-size: 20px;
  font-weight: 400;
  letter-spacing: 1px;
  line-height: 25px;
  color: #fff;
}
.footer-logo img { max-width: 220px; }
.icon-list-light a, .icon-list-light li { color: #fff; font-size: 14px; font-family: var(--font-alt); }
.icon-list-light .il-icon { color: #fff; margin-right: 8px; }
.icon-list-light li { padding: 2px 0; }
.icon-list-light a:hover .il-text { color: #fff; text-decoration: underline; }
.credit { font-family: var(--font-alt); font-size: 14px; text-shadow: 0 0 10px rgba(0, 0, 0, .3); margin: 15px 0 0; }
.credit a { color: #fff; }
.gallery-footer { gap: 7px; }
.quick-links { list-style: none; margin: 0 0 20px; padding: 0; }
.quick-links a { color: #fff; font-family: var(--font-alt); font-size: 14px; display: block; padding: 4px 0; }
.quick-links a:hover { text-decoration: underline; }
.social {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: #fff; color: var(--primary); font-size: 20px;
}
.social:hover { color: #3b5998; }
.footer-bottom { text-align: center; font-size: 13px; padding: 15px; border-top: 1px solid rgba(255, 255, 255, .15); font-family: var(--font-alt); }

/* ---------- Modal & lightbox ---------- */
.modal, .lightbox {
  position: fixed; inset: 0; z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0, 0, 0, .75);
  padding: 20px;
}
.modal[hidden], .lightbox[hidden] { display: none; }
.modal-box {
  position: relative;
  background: #fff;
  width: 100%; max-width: 520px;
  max-height: 100%; overflow: auto;
  padding: 40px 30px 30px;
  animation: pop .3s ease;
}
.modal-box .heading { font-size: 1.8rem; margin-bottom: 20px; }
.modal-box .icon-list { margin-top: 20px; }
.modal-box .icon-list a { font-size: 1rem; }
.modal-close, .lb-close {
  position: absolute; top: 8px; right: 12px;
  background: none; border: 0; font-size: 34px; line-height: 1; cursor: pointer; color: var(--secondary);
}
.lightbox img { max-width: 90vw; max-height: 85vh; box-shadow: 0 0 30px rgba(0, 0, 0, .5); }
.lb-close { color: #fff; top: 15px; right: 25px; font-size: 44px; }
.lb-prev, .lb-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: none; border: 0; color: #fff; font-size: 40px; cursor: pointer; padding: 15px;
}
.lb-prev { left: 10px; }
.lb-next { right: 10px; }
@keyframes pop { from { transform: scale(.9); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .header-inner { grid-template-columns: 1fr auto; }
  .header-phones { display: none; }
  .menu-toggle { display: block; }
  .main-nav ul {
    display: none;
    position: absolute; left: 0; right: 0; top: var(--header-h);
    flex-direction: column; gap: 0;
    background: #fff;
    box-shadow: 0 10px 20px rgba(0, 0, 0, .2);
  }
  .main-nav ul.open { display: flex; }
  .main-nav li:not(:last-child) { border-bottom: 1px solid #efefef; }
  .main-nav a { color: var(--secondary); padding: 15px; text-align: center; font-family: var(--font); font-size: 16px; }
  .main-nav a::after { display: none; }
  .main-nav a:hover, .main-nav a.active { color: var(--primary); background: #f7f7f7; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { padding: 3rem 2rem; grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .gallery-footer { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 767px) {
  .hero { height: 300px; }
  .col-66, .col-50, .col-33, .col-25, .col-20 { width: 100%; }
  .heading { font-size: 2rem; }
  .cards { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .gallery-footer { grid-template-columns: repeat(3, 1fr); }
  .footer-inner { grid-template-columns: 1fr; text-align: left; }
  .logo img { max-height: 55px; }
  .pdf-embed object { height: 70vh; }
}
@media (prefers-reduced-motion: reduce) {
  .slide-bg, .slide.is-active .slide-bg { transition: none; transform: none; }
  html { scroll-behavior: auto; }
}
