/* ===============================
   assets/css/style.css
   Refined, clean, fully responsive
   =============================== */

:root {
  --bg: #ffffff;
  --text: #111111;
  --muted: #6b6b6b;
  --accent: #9aa1a6;
  --gap: 8px; /* spacing between grid images */
  --col-count-desktop: 4;
  --col-count-tablet: 3;
  --col-count-mobile: 2;
  --grid-row-height: 8px; /* for masonry */
  --max-width: 1200px;

  --logo-size-desktop: 150px; /* logo size */
  --header-height: 120px; /* header height */
  --hero-height-desktop: 640px; /* hero height (double previous) */

  font-family: Arial, Helvetica, sans-serif;
}

/* ===== RESET ===== */
* { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  font-size: 16px;
}
a { color: inherit; text-decoration: none; }
.container { max-width: var(--max-width); margin: 0 auto; padding: 24px; }

/* ===== HEADER ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.header-inner {
  width: 100%;
  max-width: var(--max-width);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0px;
}

/* Logo */
.logo img {
  height: 90px;
  width: auto;
}

/* Main nav */
.main-nav {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  gap: 36px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-list li {
  display: flex;
  align-items: center; /* centra verticalmente todo el contenido del li */
  margin: 0;
  padding: 0;
}

.nav-list a {
  display: flex;
  align-items: center; /* centra texto y símbolo ▾ */
  line-height: 1;
  padding: 0;
  font-size: 16px;
  font-weight: 600;
  color: #111;
  text-decoration: none;
  transition: color 0.3s ease;
}

.nav-list a:hover {
  color: var(--accent);
}
/* Responsive tweaks */
@media (max-width: 768px) {
  .nav-list {
    gap: 20px;
    font-size: 14px;
  }
  .logo img {
    height: 70px;
  }
}

/* Logo */
.logo {
  position: fixed;
  right: 0px; top: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.logo img {
  height: 120px; 
  width: auto;
  display: block;
}

/* Adjustments on scroll behavior: header stays fixed */
body {
  padding-top: var(--header-height);
}

/* ===== MENU OVERLAY ===== */
.menu-overlay {
  position: fixed;
  left: 0; top: 0; right: 0; bottom: 0;
  background: rgba(255, 255, 255, 0.97);
  z-index: 200;
  display: none;
  flex-direction: column;
  padding: 96px 32px;
  overflow-y: auto;
}
.menu-overlay.open { display: flex; }
.menu-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 22px;
}
.menu-list ul {
  list-style: none;
  margin: 8px 0 0 18px;
  padding: 0;
}
.menu-list a { color: var(--text); }

/* ===== HERO - CARRUSEL PRINCIPAL ===== */  
.hero {
  width: 100%;
  height: 900px;
  position: relative;
  overflow: hidden;
  margin: 0cm auto 0;
  background: white;
}

.hero-slide {
  position: absolute; /* todas encima */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transition: opacity 1s ease;
  z-index: 0;
}

.hero-slide.show {
  opacity: 1;
  z-index: 1;
}

/* ===== FILTERS ===== */
.filters-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 56px;
}
.filters {
  display: flex;
  gap: 28px;
  font-weight: 700;
  color: var(--muted);
  opacity: 1;
  transform: translateY(8px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.filters.show {
  opacity: 1;
  transform: none;
}
.filter-btn {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  cursor: pointer;
  transition: color 0.3s ease;
}
.filter-btn:hover,
.filter-btn.active {
  color: var(--accent);
}

/* ===== GALLERY GRID ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(var(--cols), 1fr);
  gap: var(--gap);
  max-width: var(--max-width);
  margin: 18px auto;
  padding: 0 24px;
  grid-auto-rows: var(--grid-row-height);
}
.grid-item {
  background: #fff;
  overflow: hidden;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.grid-item img {
  width: 100%;
  height: auto;
  display: block;
  filter: grayscale(100%);
  transition: filter 0.35s ease, transform 0.35s ease;
}
.grid-item:hover img {
  filter: grayscale(0%);
  transform: scale(1.02);
}
.grid-caption {
  padding: 8px 6px;
  font-size: 14px;
  color: var(--muted);
  text-align: left;
}

/* Responsive columns */
@media (min-width: 1200px) {
  :root { --cols: 4; }
}
@media (max-width: 1199px) {
  :root { --cols: 3; }
  .hero-title { font-size: 36px; }
  .logo img { height: 110px; }
}
@media (max-width: 768px) {
  :root { --cols: 2; }
  .hero-title { font-size: 28px; }
  .logo img { height: 70px; }
  .header { height: 70px; }
  .brand-title { font-size: 22px; }
  .hero {
    height: 20vh; /* altura adaptable en móvil */
  }
}

/* ===== FOOTER ===== */
.footer {
  border-top: 1px solid #eee;
  margin-top: 28px;
  padding: 28px 24px;
  background: transparent;
}
.grid-footer {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.socials {
  display: flex;
  gap: 12px;
  align-items: center;
}
.footer form {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.footer input,
.footer textarea {
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

/* ===== LIGHTBOX MODERNO ===== */
.lightbox {
  display: none;
  position: fixed;
  z-index: 200;
  top:0; left:0;
  width:100%; height:100%;
  background: rgba(30,30,30,0.85); /* fondo más suave */
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.lightbox-img {
  max-width:90%;
  max-height:90%;
  border-radius:6px;
  object-fit: contain;
  box-shadow: 0 8px 30px rgba(0,0,0,0.5);
  transition: transform 0.3s ease;
}

/* === Botón de cierre minimalista === */
.lightbox .close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 38px;
  color: white;
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1;
  transition: transform 0.2s ease, color 0.3s ease;
  z-index: 10;
}

.lightbox .close:hover {
  color: #ccc;
  transform: scale(1.2);
}

/* ===== Modern Lightbox Arrows ===== */
.lightbox .nav-arrows {
  position: absolute;
  top: 50%;
  width: 100%;
  display: flex;
  justify-content: space-between;
  transform: translateY(-50%);
  padding: 0 40px;
  box-sizing: border-box;
  pointer-events: none; /* evita interferencias al hacer clic fuera */
}

.arrow-btn {
  background: rgba(255, 255, 255, 0.15);
  border: none;
  border-radius: 50%;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  pointer-events: all; /* reactivar clics para el botón */
  transition: background 0.3s ease, transform 0.3s ease;
  backdrop-filter: blur(4px);
}

.arrow-btn svg {
  width: 28px;
  height: 28px;
}

.arrow-btn:hover {
  background: rgba(255, 255, 255, 0.35);
  transform: scale(1.1);
}

@media (max-width: 768px) {
  .arrow-btn {
    width: 44px;
    height: 44px;
  }
  .arrow-btn svg {
    width: 22px;
    height: 22px;
  }
}


/* ===== MASONRY GRID (CSS moderno) ===== */
.masonry-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  grid-template-rows: masonry; /* navegador moderno */
  gap: 16px;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.gallery-item {
  overflow: hidden;
  border-radius: 8px;
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.gallery-item img:hover {
  transform: scale(1.04);
}

/* Responsive */
@media (max-width: 600px) {
  .masonry-grid {
    grid-template-columns: 1fr;
  }
}


/* ===== UTILITIES ===== */
.center { text-align: center; }
.container-spaced { padding-top: 28px; padding-bottom: 28px; }
.hide-on-load { opacity: 0; }


/* ===============================
   CONTACT PAGE - Modern Layout
   =============================== */

/* Contenedor principal de toda la página */
.contact-page {
  display: flex;
  flex-direction: row;
  max-width: 1200px;  /* ancho máximo de todo el contenido */
  margin: 40px auto;  /* margen blanco alrededor */
  padding: 30px;       /* espacio interior */
  background: #fff;    /* fondo blanco uniforme */
  box-shadow: 0 0 0 10px #fff; /* borde blanco extra */
  gap:80px;           /* espacio entre imagen y formulario */
}

/* Lado izquierdo: imagen */
.contact-left {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  background: #000;     /* fondo negro para la imagen */
}

.contact-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: grayscale(0%);  /* imagen en blanco y negro */
}
.contact-left .contact-image:hover {
  filter: grayscale(0%);
}

/* Lado derecho: formulario y texto */
.contact-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 16px;
}

/* Formulario */
.contact-right form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-right input,
.contact-right textarea {
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 16px;
}

.contact-right button {
  padding: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  background: #111;
  color: #fff;
  border: none;
  transition: background 0.3s ease;
}
.contact-right button:hover {
  background: #444;
}

/* ===============================
   HOME PAGE - Compact Contact Section
   =============================== */
.contact-section {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 80px 20px;
  background: #f9f9f9;        /* sutil fondo gris para destacar */
}

.contact-inner {
  width: 100%;
  max-width: 600px;            /* más estrecho */
  text-align: center;
  background: #fff;
  padding: 40px 40px 50px;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}

/* Titular */
.contact-inner h1 {
  font-size: 2rem;
  margin-bottom: 8px;
}

/* Subtexto */
.contact-inner p {
  color: var(--muted);
  margin-bottom: 24px;
}

/* Formulario */
.contact-inner .contact-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-inner .contact-form input,
.contact-inner .contact-form textarea {
  padding: 12px 14px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 16px;
  width: 100%;
  transition: border-color 0.3s ease;
}

.contact-inner .contact-form input:focus,
.contact-inner .contact-form textarea:focus {
  border-color: var(--accent);
  outline: none;
}

.contact-inner .contact-form button {
  background: #111;
  color: #fff;
  padding: 12px;
  border: none;
  border-radius: 6px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease;
}

.contact-inner .contact-form button:hover {
  background: var(--accent);
}

/* Redes sociales */
.contact-inner .contact-socials {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.contact-inner .contact-socials a {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 16px;
  color: var(--text);
}

.contact-inner .icon-social {
  width: 22px;
  height: 22px;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.contact-inner .contact-socials a:hover .icon-social {
  opacity: 1;
}

.contact-inner .user-handle {
  color: var(--muted);
  font-style: italic;
}

/* Responsive */
@media (max-width: 600px) {
  .contact-inner {
    padding: 30px 20px 40px;
    max-width: 90%;
  }
}

/* Footer social links */
.socials {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 16px;
}
.icon-social {
  width: 20px;
  height: 20px;
  vertical-align: middle;
  opacity: 0.6;
  transition: opacity 0.3s ease;
}
.social-link:hover .icon-social {
  opacity: 1;
}

/* Responsive */
@media (max-width: 992px) {
  .contact-page {
    flex-direction: column;
    padding: 24px;
  }
  .contact-left,
  .contact-right {
    width: 100%;
  }
  .contact-left {
    height: 300px; /* altura para móvil */
  }
}

/* ===============================
   ABOUT PAGE - Modern Layout
   =============================== */
.about-page {
  display: flex;
  gap: 40px;
  border: 40px solid #fff; /* marco blanco alrededor */
  padding: 24px;
  background: #ffffff; /* blanco puro */
  align-items: flex-start;
}

/* Left column: image/logo */
.about-left {
  flex: 1;
  display: flex;
  flex-direction: column; /* vertical */
  align-items: center;
  gap: 24px; /* espacio entre logo y los iconos */
}
.about-socials {
  display: flex;
  flex-direction: column; /* vertical */
  gap: 16px; /* espacio entre cada icono */
  align-items: center;
}
.about-image {
  width: 100%;
  max-width: 350px;
  height: auto;
  object-fit: cover;
  object-position: center;
  filter: grayscale(100%);
  transition: filter 0.5s ease;
}
.about-image:hover {
  filter: grayscale(0%);
}

/* Right column: text */
.about-right {
  flex: 2;
  display: flex;
  flex-direction: column;
  line-height: 1.5;     /* mejora la legibilidad */
  text-align: justify;   /* justificado profesional */
}

/* Links to filters */
.about-links ul {
  list-style: none;
  padding-left: 0;
  display: flex;
  gap: 12px;
  margin-top: 8px;
}
.about-links a {
  text-decoration: none;
  color: var(--accent);
  font-weight: 600;
  transition: color 0.3s ease;
}
.about-links a:hover { color: #111; }

/* Social icons */
.contact-socials {
  display: flex;
  justify-content: flex-start;
  gap: 20px;
  margin-top: 16px;
  flex-wrap: wrap;
}
.contact-socials a {
  display: flex;
  align-items: center;
  gap: 6px;
}
.icon-social {
  width: 24px;
  height: 24px;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}
.contact-socials a:hover .icon-social { opacity: 1; }
.user-handle { color: #aaa; font-style: italic; }

/* Responsive */
@media (max-width: 992px) {
  .about-page {
    flex-direction: column;
    gap: 24px;
    border: 20px solid #fff;
    padding: 16px;
  }
  .about-image { max-width: 100%; }
}

/* ===== SOCIAL ICONS ===== */
.contact-socials {
  display: flex;
  justify-content: center; /* centra los iconos horizontalmente */
  gap: 20px;               /* espacio entre cada icono */
  margin-top: 24px;        /* separación respecto al formulario */
  flex-wrap: wrap;          /* permite que se ajusten en móvil */
}

.contact-socials a {
  display: flex;
  align-items: center;
  gap: 6px;                /* espacio entre icono y handle */
  font-size: 16px;
}

.icon-social {
  width: 24px;              /* tamaño de los iconos */
  height: 24px;
  vertical-align: middle;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.contact-socials a:hover .icon-social {
  opacity: 1;
}

.user-handle {
  color: #aaa;
  font-style: italic;
}

/* === WATERMARK / LOGO OVERLAY (grid images) === */
/* Defaults you can override per .image-wrap */
.grid .image-wrap {
  position: relative;
  overflow: visible;
  /* IMPORTANT: CSS file is in assets/css/, so go up one folder to reach /images */
  --logo-image: url('../images/Darkframe_Logo.png'); /* or ../images/Darkframe_Logo.jpeg */
  --logo-size: 60px;        /* square logo size */
  --logo-right: 0px;       /* distance from right edge */
  --logo-bottom: 0px;      /* distance from bottom edge */
  --logo-opacity: 1;     /* overall opacity */
}

/* Paint the logo with a pseudo-element so no extra HTML is needed */
.grid .image-wrap::after {
  content: "";
  position: absolute;
  right: var(--logo-right);
  bottom: var(--logo-bottom);
  /* Backward compatibility with your existing --logo-width / --logo-height vars */
  width:  var(--logo-size, var(--logo-width, 80px));
  height: var(--logo-size, var(--logo-height, var(--logo-width, 80px)));
  background-image: var(--logo-image);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: var(--logo-opacity);
  pointer-events: none;
  z-index: 2; /* sits above the <img> */
}

/* Ensure the image sits under the overlay */
.grid .image-wrap > img {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: auto;
}

/* Optional: smaller default logo on mobile */
@media (max-width: 768px) {
  .grid .image-wrap { --logo-size: 60px; }
}

/* If you ever want to hide the watermark on a specific image */
.grid .image-wrap.no-logo::after { content: none; }



/* === Lightbox watermark overlay (anchored to the displayed image) === */
.lightbox-media {
  position: relative;
  display: inline-block;
  max-width: 90%;
  max-height: 90%;
  /* defaults; JS will override from the clicked .image-wrap when available */
  --logo-image: url('../images/Darkframe_Logo.png'); /* use your real file */
  --logo-size: 120px;
  --logo-right: 0px;
  --logo-bottom: 0px;
  --logo-opacity: 1;
}
.lightbox-media .lightbox-img {
  display: block;
  max-width: 100%;
  max-height: 100%;
}
.lightbox-media::after {
  content: "";
  position: absolute;
  right: var(--logo-right);
  bottom: var(--logo-bottom);
  width:  var(--logo-size);
  height: var(--logo-size);
  background-image: var(--logo-image);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: var(--logo-opacity);
  pointer-events: none;
  z-index: 2;
}

/* Optional: smaller on mobile */
@media (max-width: 768px) {
  .lightbox-media { --logo-size: 60px; }
}
