/* ============================================================
   SGMI — Estilos personalizados (complemento a Tailwind)
   Paleta NiceRestaurant: #101719 | #252a2b | #ceaf7f
   ============================================================ */

:root {
  --bg:       #101719;
  --surface:  #252a2b;
  --alt:      #243438;
  --dark:     #060606;
  --accent:   #ceaf7f;
  --text:     #f1f3f5;
  --heading:  #f4f7fa;
  --muted:    rgba(241,243,245,.5);
  --border:   rgba(241,243,245,.12);
  --shadow:   rgba(0,0,0,.35);
}

/* ---- Reset / Base ---- */
*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}
body {
  background-color: var(--bg);
  color: var(--text);
  font-family: 'Roboto', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  overflow-x: hidden;
}
h1,h2,h3,h4,h5,h6 {
  font-family: 'Libre Baskerville', Georgia, serif;
  color: var(--heading);
  line-height: 1.3;
}
a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
input, select, textarea {
  font-family: 'Roboto', sans-serif;
}

/* ---- Scrollbar ---- */
::-webkit-scrollbar       { width: 6px; }
::-webkit-scrollbar-track { background: var(--surface); }
::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 3px; }

/* ============================================================
   NAVBAR
   ============================================================ */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  transition: background .35s ease, box-shadow .35s ease;
  padding: 16px 0;
  font-family: 'Poppins', sans-serif;
}
#navbar.scrolled {
  background: #23292b;
  box-shadow: 0 2px 20px rgba(0,0,0,.5);
  padding: 10px 0;
}
#navbar .nav-link {
  color: var(--text);
  font-size: 15px;
  padding: 6px 4px;
  position: relative;
  transition: color .25s;
}
#navbar .nav-link::after {
  content: '';
  position: absolute; left: 0; bottom: -2px;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width .25s;
}
#navbar .nav-link:hover,
#navbar .nav-link.active { color: var(--accent); }
#navbar .nav-link:hover::after,
#navbar .nav-link.active::after { width: 100%; }

/* Botón login en navbar */
.btn-login {
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  padding: 8px 22px;
  border-radius: 50px;
  border: 2px solid var(--accent);
  color: var(--accent);
  transition: background .25s, color .25s;
}
.btn-login:hover {
  background: var(--accent);
  color: #101719;
}

/* Mobile nav */
#mobile-menu {
  background: var(--alt);
  border-top: 1px solid var(--border);
}
#mobile-menu a {
  display: block;
  padding: 12px 20px;
  font-family: 'Poppins', sans-serif;
  font-size: 15px;
  color: var(--text);
  border-bottom: 1px solid var(--border);
  transition: color .2s, padding-left .2s;
}
#mobile-menu a:hover { color: var(--accent); padding-left: 28px; }

/* ============================================================
   SECTION TITLES
   ============================================================ */
.section-title {
  font-family: 'Libre Baskerville', serif;
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  color: var(--heading);
  position: relative;
  display: inline-block;
  margin-bottom: .6rem;
}
.section-title::after {
  content: '';
  display: block;
  width: 50px; height: 3px;
  background: var(--accent);
  margin-top: 10px;
}
.section-subtitle {
  color: var(--muted);
  font-size: .95rem;
  margin-bottom: 2.5rem;
  font-family: 'Poppins', sans-serif;
}

/* ============================================================
   HERO / SWIPER
   ============================================================ */
#hero {
  height: calc(100vh - 0px);
  min-height: 580px;
}
.hero-slide {
  position: relative;
  height: 100%;
  background-size: cover;
  background-position: center;
}
.hero-slide::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg,
    rgba(6,6,6,.78) 0%,
    rgba(16,23,25,.55) 100%);
}
.hero-content {
  position: relative; z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 clamp(1.5rem, 8vw, 8rem);
}
.hero-content h1 {
  font-family: 'Libre Baskerville', serif;
  font-size: clamp(2rem, 6vw, 4rem);
  color: var(--heading);
  max-width: 680px;
  text-shadow: 0 2px 20px rgba(0,0,0,.5);
}
.hero-content p {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(.95rem, 2vw, 1.1rem);
  color: rgba(241,243,245,.85);
  max-width: 520px;
  margin-top: .8rem;
}

.swiper-button-next,
.swiper-button-prev {
  width: 48px !important; height: 48px !important;
  background: rgba(0,0,0,.6);
  border-radius: 50%;
  transition: background .25s;
}
.swiper-button-next:hover,
.swiper-button-prev:hover { background: var(--accent); }
.swiper-button-next::after,
.swiper-button-prev::after {
  font-size: 16px !important;
  color: var(--heading);
}
.swiper-pagination-bullet {
  background: rgba(241,243,245,.5) !important;
  opacity: 1 !important;
}
.swiper-pagination-bullet-active {
  background: var(--accent) !important;
  width: 24px !important;
  border-radius: 4px !important;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-accent {
  display: inline-block;
  font-family: 'Poppins', sans-serif;
  font-size: .95rem;
  font-weight: 500;
  padding: .9rem 2.2rem;
  border-radius: 4px;
  background: var(--accent);
  color: #101719;
  transition: transform .25s, box-shadow .25s, filter .25s;
}
.btn-accent:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(206,175,127,.35);
  filter: brightness(1.05);
}
.btn-outline {
  display: inline-block;
  font-family: 'Poppins', sans-serif;
  font-size: .95rem;
  font-weight: 500;
  padding: .85rem 2rem;
  border-radius: 4px;
  border: 2px solid var(--heading);
  color: var(--heading);
  transition: background .25s, color .25s, transform .25s;
}
.btn-outline:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #101719;
  transform: translateY(-3px);
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: var(--surface);
  border-radius: 10px;
  overflow: hidden;
  transition: transform .3s, box-shadow .3s;
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0,0,0,.35);
}
.card img {
  width: 100%; height: 220px;
  object-fit: cover;
  transition: transform .4s;
}
.card:hover img { transform: scale(1.05); }

/* Blog card badge */
.badge-categoria {
  display: inline-block;
  font-family: 'Poppins', sans-serif;
  font-size: .72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 50px;
  background: var(--accent);
  color: #101719;
  text-transform: uppercase;
  letter-spacing: .05em;
}

/* ============================================================
   MULTIMEDIA
   ============================================================ */
.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Poppins', sans-serif;
  font-size: .8rem;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: 50px;
  background: #e74c3c;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: .08em;
  animation: pulse-live 1.5s infinite;
}
.live-badge .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #fff;
}
@keyframes pulse-live {
  0%,100% { box-shadow: 0 0 0 0 rgba(231,76,60,.5); }
  50%      { box-shadow: 0 0 0 8px rgba(231,76,60,0); }
}
.video-wrapper {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 10px;
  background: #000;
}
.video-wrapper iframe {
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%;
  border: none;
}

/* ============================================================
   HORARIOS
   ============================================================ */
.horario-item {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding: 1rem 1.4rem;
  background: var(--surface);
  border-radius: 8px;
  border-left: 3px solid var(--accent);
  transition: transform .25s, box-shadow .25s;
}
.horario-item:hover {
  transform: translateX(5px);
  box-shadow: 0 4px 16px var(--shadow);
}
.horario-time {
  font-family: 'Libre Baskerville', serif;
  font-size: 1.1rem;
  color: var(--accent);
  min-width: 80px;
}
.horario-dia {
  font-family: 'Poppins', sans-serif;
  font-size: .8rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* ============================================================
   DIRECTIVAS
   ============================================================ */
.directiva-card {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 3/4;
  background: var(--surface);
  cursor: default;
}
.directiva-card img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .4s;
}
.directiva-card:hover img { transform: scale(1.08); }
.directiva-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(6,6,6,.85) 40%, transparent);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1rem;
  opacity: 1;
  transition: opacity .3s;
}

/* ============================================================
   FORMS (PQRS)
   ============================================================ */
.form-input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: .8rem 1.1rem;
  color: var(--text);
  font-family: 'Roboto', sans-serif;
  font-size: .95rem;
  transition: border-color .25s, box-shadow .25s;
  outline: none;
}
.form-input::placeholder { color: var(--muted); }
.form-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(206,175,127,.15);
}
select.form-input option { background: var(--surface); }
label.form-label {
  display: block;
  font-family: 'Poppins', sans-serif;
  font-size: .85rem;
  color: var(--muted);
  margin-bottom: .4rem;
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  background: var(--dark);
  border-top: 1px solid var(--border);
}
footer h4 {
  font-family: 'Poppins', sans-serif;
  font-size: .9rem;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: .1em;
  margin-bottom: 1rem;
}
footer a {
  color: var(--muted);
  font-size: .9rem;
  transition: color .2s;
  display: block;
  margin-bottom: .45rem;
}
footer a:hover { color: var(--accent); }
.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 1rem;
  transition: border-color .25s, color .25s, background .25s;
}
.social-link:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(206,175,127,.1);
}

/* ============================================================
   SCROLL TO TOP
   ============================================================ */
#scroll-top {
  position: fixed;
  bottom: 1.5rem; right: 1.5rem; z-index: 999;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--accent);
  color: #101719;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
  opacity: 0; pointer-events: none;
  transform: translateY(12px);
  transition: opacity .3s, transform .3s;
  cursor: pointer;
  border: none;
}
#scroll-top.visible {
  opacity: 1; pointer-events: auto; transform: none;
}

/* ============================================================
   LOGIN PAGE
   ============================================================ */
.login-bg {
  min-height: 100vh;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
}
.login-card {
  background: var(--surface);
  border-radius: 14px;
  box-shadow: 0 24px 64px rgba(0,0,0,.5);
  padding: 2.8rem 2.4rem;
  width: 100%; max-width: 420px;
}
.login-logo {
  text-align: center;
  margin-bottom: 2rem;
}
.login-logo .logo-circle {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: rgba(206,175,127,.15);
  border: 2px solid var(--accent);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1.8rem;
  color: var(--accent);
  margin-bottom: 1rem;
}
.login-logo h1 {
  font-size: 1.2rem;
  color: var(--heading);
  font-family: 'Libre Baskerville', serif;
}
.login-logo p {
  font-size: .8rem;
  color: var(--muted);
  font-family: 'Poppins', sans-serif;
  margin-top: .2rem;
}

/* Alert */
.alert {
  padding: .85rem 1.1rem;
  border-radius: 6px;
  font-family: 'Poppins', sans-serif;
  font-size: .88rem;
  margin-bottom: 1.2rem;
}
.alert-error   { background: rgba(231,76,60,.15);  border: 1px solid rgba(231,76,60,.4);  color: #e74c3c; }
.alert-success { background: rgba(46,204,113,.12); border: 1px solid rgba(46,204,113,.4); color: #2ecc71; }
.alert-info    { background: rgba(206,175,127,.1); border: 1px solid rgba(206,175,127,.3);color: var(--accent); }

/* ============================================================
   UTILITIES
   ============================================================ */
.divider-accent {
  width: 60px; height: 3px;
  background: var(--accent);
  border-radius: 2px;
  margin: .5rem 0 1.5rem;
}
.section-pad { padding: 80px 0; }
.section-pad-alt { padding: 80px 0; background: var(--alt); }

/* ============================================================
   GRIDS — Frontend público (base, sin inline styles)
   ============================================================ */
.pub-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
}
.pub-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.8rem;
}
.pub-grid-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.pub-grid-footer {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2.5rem;
}
.pub-footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ============================================================
   INSTAGRAM BUTTON (sección ministerios)
   ============================================================ */
.ig-btn {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  font-family: 'Poppins', sans-serif;
  font-size: .78rem;
  font-weight: 500;
  padding: .38rem .9rem;
  border-radius: 50px;
  border: 1px solid rgba(188,24,136,.4);
  color: #e1306c;
  background: rgba(188,24,136,.08);
  cursor: pointer;
  transition: background .2s, transform .2s;
}
.ig-btn:hover {
  background: rgba(188,24,136,.18);
  transform: translateY(-2px);
}

/* ============================================================
   RESPONSIVE — TABLET  (≤1024px)
   ============================================================ */
@media (max-width: 1024px) {
  .pub-grid-footer { grid-template-columns: 1fr 1fr !important; }
  .pub-grid-3      { grid-template-columns: repeat(2, 1fr) !important; }
  .pub-grid-2      { gap: 2.5rem !important; }
}

/* ============================================================
   RESPONSIVE — MOBILE  (≤767px)
   ============================================================ */
@media (max-width: 767px) {

  .section-pad,
  .section-pad-alt { padding: 52px 0; }

  /* Hero */
  .hero-content        { padding: 0 1.5rem; }
  .hero-content h1     { font-size: clamp(1.6rem, 7vw, 2.4rem); }
  .hero-content p      { font-size: .9rem; }
  #inicio .swiper-button-next,
  #inicio .swiper-button-prev { display: none; }

  /* Grids → 1 columna */
  .pub-grid-2,
  .pub-grid-3,
  .pub-grid-footer,
  .pub-grid-form {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
  }
  .pub-grid-3 { gap: 1.4rem !important; }

  /* Horarios */
  .horario-item { padding: .75rem 1rem; }
  .horario-time { font-size: .95rem; min-width: 60px; }

  /* Footer bottom */
  .pub-footer-bottom {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: .6rem !important;
  }

  #scroll-top  { bottom: 1rem; right: 1rem; width: 38px; height: 38px; font-size: .9rem; }
  .login-card  { padding: 2rem 1.4rem; margin: 1rem; }
}

/* ============================================================
   RESPONSIVE — MOBILE PEQUEÑO  (≤480px)
   ============================================================ */
@media (max-width: 480px) {
  .section-pad,
  .section-pad-alt { padding: 40px 0; }
}
