/* REG S.R.L. - sitio estático (reconstrucción del tema Divi / REG) */
:root {
  --red: #d03740;
  --red-dark: #b12d35;
  --ink: #333;
  --text: #666;
  --dark: #1a1a1a;
  --font-body: "Open Sans", Arial, sans-serif;
  --font-head: "Oswald", "Open Sans", Arial, sans-serif;
  --header-h: 80px;
  --header-h-fixed: 60px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.7;
  color: var(--text);
  background: #fff;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--red); text-decoration: none; }
a:hover { color: var(--red-dark); }
.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.center { text-align: center; }
.icon {
  width: 1em; height: 1em; fill: none; stroke: currentColor;
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}

/* ---------- Header ---------- */
#main-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--header-h);
  background: transparent;
  transition: background .4s, height .4s, box-shadow .4s;
}
#main-header.is-fixed {
  height: var(--header-h-fixed);
  background: rgba(20,20,20,.96);
  box-shadow: 0 1px 0 rgba(255,255,255,.08);
}
.header-inner {
  max-width: 1080px; margin: 0 auto; padding: 0 20px;
  height: 100%; display: flex; align-items: center; justify-content: space-between;
}
.logo img { height: 52px; width: auto; transition: height .4s; }
#main-header.is-fixed .logo img { height: 40px; }
.nav { height: 100%; }
.top-menu { list-style: none; margin: 0; padding: 0; display: flex; height: 100%; }
.top-menu > li { position: relative; display: flex; align-items: center; padding-right: 22px; }
.top-menu > li:last-child { padding-right: 0; }
.top-menu a {
  display: block; color: #fff; font: 600 14px/1 var(--font-body);
  padding: 10px 0; transition: opacity .3s;
}
.top-menu a:hover { opacity: .7; color: #fff; }
.sub-menu {
  display: none; position: absolute; top: 100%; left: -20px;
  min-width: 240px; background: #fff; border-top: 3px solid var(--red);
  box-shadow: 0 2px 5px rgba(0,0,0,.1);
  list-style: none; margin: 0; padding: 20px 0;
}
.has-sub:hover > .sub-menu,
.has-sub:focus-within > .sub-menu { display: block; }
.sub-menu a { color: #666; font-size: 14px; line-height: 1.4; padding: 6px 20px; }
.sub-menu a:hover { color: #666; background: rgba(0,0,0,.03); opacity: 1; }
.menu-toggle { display: none; }

/* ---------- Slider ---------- */
.slider {
  position: relative; height: 100vh; min-height: 560px; max-height: 820px;
  overflow: hidden; background: #000; color: #fff;
}
.slide {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center; text-align: center;
  opacity: 0; visibility: hidden;
  transition: opacity .8s ease, visibility .8s;
  background-size: cover; background-position: center; background-attachment: fixed;
}
.slide.is-active { opacity: 1; visibility: visible; z-index: 2; }
.slide-1 { background-image: url("../img/fondo3.webp"); }
.slide-2 { background-image: url("../img/fondo2.webp"); }
.slide-3 { background-image: url("../img/fondo1.webp"); }
.slide-inner { max-width: 1080px; padding: 60px 20px 0; }
.slide h2 {
  margin: 0 0 14px; font: 600 52px/1.15 var(--font-head);
  letter-spacing: .04em; text-transform: uppercase;
}
.slide h2 a { color: #fff; }
.slide p { margin: 0 0 28px; font-size: 20px; line-height: 1.5; }
.slider-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 5;
  width: 46px; height: 46px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(0,0,0,.35); color: #fff; font-size: 22px;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .3s, background .3s;
}
.slider-arrow:hover { background: rgba(0,0,0,.6); }
.slider:hover .slider-arrow, .slider-arrow:focus-visible { opacity: 1; }
.slider-arrow.prev { left: 20px; }
.slider-arrow.next { right: 20px; }
.slider-dots {
  position: absolute; bottom: 26px; left: 0; right: 0; z-index: 5;
  display: flex; justify-content: center; gap: 10px;
}
.slider-dots button {
  width: 11px; height: 11px; padding: 0; border: 0; border-radius: 50%;
  background: rgba(255,255,255,.4); cursor: pointer; transition: background .3s;
}
.slider-dots button.is-active { background: #fff; }

/* ---------- Botones ---------- */
.btn {
  position: relative; display: inline-block;
  font: 600 18px/1.7 var(--font-body);
  padding: .3em 1em; border-radius: 3px; cursor: pointer;
  border: 2px solid transparent; transition: all .3s;
}
.btn::after {
  content: "\2192"; position: absolute; right: .55em; top: 50%;
  transform: translateY(-50%); opacity: 0; transition: opacity .3s;
}
.btn:hover { padding: .3em 2em .3em .7em; }
.btn:hover::after { opacity: 1; }
.btn-outline { color: #fff; border-color: #fff; background: transparent; }
.btn-outline:hover { color: #fff; background: rgba(255,255,255,.2); }
.btn-red { color: #fff; background: var(--red); border-color: var(--red); }
.btn-red:hover { color: #fff; background: var(--red-dark); border-color: var(--red-dark); }
button.btn-red { font-family: var(--font-body); }

/* ---------- Secciones ---------- */
.section { padding: 80px 0; }
.section-title {
  margin: 0 0 40px; text-align: center;
  font: 500 34px/1.2 var(--font-head); color: var(--ink);
}
.section-title span { color: var(--red); }
.section-title.light { color: #fff; }

.about blockquote {
  max-width: 820px; margin: 0 auto; text-align: justify;
  font-size: 18px; color: var(--text);
}
.about blockquote p { margin: 0 0 1em; }
.about cite { display: block; font-style: normal; font-weight: 700; color: var(--ink); }

.parallax {
  background-size: cover; background-position: center; background-attachment: fixed;
}
.section-services { background-image: url("../img/fondo2_servicios.webp"); color: #fff; }
.services-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-bottom: 44px;
}
.service-head { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.icon-circle {
  flex: 0 0 auto; width: 58px; height: 58px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--red); color: #fff; font-size: 28px;
}
.icon-circle:hover { color: #fff; background: var(--red-dark); }
.service h4 { margin: 0; font: 500 22px/1.2 var(--font-head); }
.service h4 a { color: #fff; }
.service p { margin: 0; font-size: 16px; color: #eee; }

.section-form { background: #f2f2f2; }
.contact-form { max-width: 820px; margin: 0 auto; }
.contact-form label { display: block; margin: 0 0 18px; font-weight: 600; color: var(--ink); font-size: 14px; }
.contact-form input, .contact-form textarea {
  display: block; width: 100%; margin-top: 6px; padding: 16px;
  border: 0; background: #e9e9e9; color: #333; font: 400 18px var(--font-body);
  border-radius: 0;
}
.contact-form input:focus, .contact-form textarea:focus {
  outline: 2px solid var(--red); background: #fff;
}

.section-contact {
  background-image: url("../img/fondo_contacto.webp"); color: #fff; padding: 70px 0;
}
.contact-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 40px; align-items: start; }
.contact-grid h3 { margin: 0 0 14px; font: 500 22px/1.2 var(--font-head); }
.contact-item { display: flex; gap: 16px; margin-bottom: 22px; font-size: 16px; line-height: 1.6; }
.contact-item .icon { flex: 0 0 auto; color: var(--red); font-size: 30px; }
.contact-item a { color: #fff; }
.btn-fb {
  display: inline-flex; align-items: center; gap: 10px;
  background: #3b5998; color: #fff; padding: 8px 18px; border-radius: 3px;
  font-weight: 600; font-size: 14px;
}
.btn-fb:hover { background: #2d4373; color: #fff; }
.btn-fb .icon { font-size: 18px; }

/* ---------- Footer ---------- */
#main-footer { background: #222; padding: 20px 0; }
#footer-info { margin: 0; color: #666; font-size: 14px; text-align: left; }
#footer-info a { color: #666; }
#footer-info a:hover { color: #999; }

/* ---------- Páginas internas ---------- */
.page-banner {
  padding: 160px 0 80px; text-align: center; color: #fff;
  background: #111 center/cover no-repeat;
}
.banner-lubricentro { background-image: url("../img/fondo1.webp"); }
.banner-petrolera { background-image: url("../img/fondo3.webp"); }
.banner-novedades { background-image: url("../img/fondo2.webp"); }
.page-banner h1 {
  margin: 0 0 10px; font: 600 40px/1.2 var(--font-head);
  letter-spacing: .04em; text-transform: uppercase;
}
.page-banner p { margin: 0 auto; max-width: 700px; font-size: 18px; color: #eee; }
.page-body { padding: 60px 0 70px; background: #fff; }
.post {
  background: #fff; border: 1px solid #e5e5e5; border-radius: 3px;
  box-shadow: 0 2px 8px rgba(0,0,0,.05); padding: 28px; margin-bottom: 28px;
}
.post h2 { margin: 0 0 14px; font: 500 26px/1.2 var(--font-head); color: var(--ink); }
.post p { margin: 0 0 10px; font-size: 16px; }
.post .flyer { max-width: 400px; margin: 14px 0; border-radius: 3px; }
.post .tags { color: var(--red); font-weight: 600; margin: 12px 0 0; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; margin-top: 14px; }
.gallery img { width: 100%; height: 100%; object-fit: cover; border-radius: 3px; }
.subtitle { margin: 50px 0 24px; font: 500 26px/1.2 var(--font-head); color: var(--ink); text-transform: uppercase; }
.subtitle::after { content: ""; display: block; width: 50px; height: 3px; background: var(--red); margin-top: 10px; }
.posts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 24px; }
.mini { background: #fff; border: 1px solid #e5e5e5; border-radius: 3px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,.05); }
.mini img { width: 100%; height: 260px; object-fit: cover; }
.mini h3 { margin: 0; padding: 14px 16px; font: 500 18px/1.3 var(--font-head); color: var(--ink); }
.pad-top { padding-top: 70px; }

/* ---------- Tablet / móvil ---------- */
@media (max-width: 980px) {
  .slide, .parallax { background-attachment: scroll; }
  .slide h2 { font-size: 38px; }
  .menu-toggle {
    display: flex; align-items: center; gap: 12px;
    background: none; border: 0; cursor: pointer; color: #fff;
    font: 600 14px var(--font-body);
  }
  .menu-toggle .bars, .menu-toggle .bars::before, .menu-toggle .bars::after {
    display: block; width: 26px; height: 3px; background: #fff; border-radius: 2px; position: relative;
  }
  .menu-toggle .bars::before, .menu-toggle .bars::after { content: ""; position: absolute; left: 0; }
  .menu-toggle .bars::before { top: -8px; }
  .menu-toggle .bars::after { top: 8px; }
  .nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0; height: auto;
    background: rgba(20,20,20,.98); border-top: 3px solid var(--red);
    padding: 10px 20px 20px;
  }
  .nav.is-open { display: block; }
  .top-menu { flex-direction: column; height: auto; }
  .top-menu > li { display: block; padding: 0; }
  .top-menu a { padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,.1); }
  .sub-menu {
    display: block; position: static; min-width: 0;
    background: transparent; border: 0; box-shadow: none; padding: 0 0 0 18px;
  }
  .sub-menu a { color: #ddd; padding: 10px 0; }
  .sub-menu a:hover { color: #fff; background: transparent; }
  .services-grid { grid-template-columns: 1fr; gap: 34px; }
  .contact-grid { grid-template-columns: 1fr; gap: 24px; }
  .slider-arrow { opacity: .7; }
}
@media (max-width: 600px) {
  .slide h2 { font-size: 30px; }
  .slide p { font-size: 17px; }
  .section { padding: 56px 0; }
  .section-title { font-size: 28px; }
  .page-banner h1 { font-size: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .slide { transition: none; }
}
