/* MRRUIZ Jardines & Piscinas - styles.css (mejorado espaciado + tablet/móvil) */
:root {
  --brand: #1e5a3d;
  --brand-light: #2a7d55;
  --brand-accent: #d4a017;
  --dark: #0b1f17;
  --light: #f7faf9;
  --muted: #5a6c65;
  --accent: #3a9d7d;

  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 8px 25px rgba(0, 0, 0, 0.08);
  --radius: 16px;
}

/* Reset / base */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, Cantarell, "Noto Sans", sans-serif;
  color: var(--dark);
  background: var(--light);
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--brand-light);
  text-decoration: none;
}

a:hover {
  color: var(--brand-accent);
  text-decoration: underline;
}

ul {
  list-style: none;
}

.container {
  width: min(1200px, 92vw);
  margin: 0 auto;
  padding: 0;
}

.section {
  padding: clamp(56px, 7vw, 96px) 0;
}

/* Header / nav */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.07);
  box-shadow: var(--shadow-sm);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 90px;
  position: relative;
  gap: 18px;
}

.logo img {
  height: 90px;
  width: auto;
  object-fit: contain;
  transition: transform .25s;
}

.logo img:hover {
  transform: scale(1.03);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-links a {
  margin-left: 0;
  font-weight: 700;
  color: var(--dark);
  transition: color .2s, background .2s;
  padding: 10px 12px;
  border-radius: 12px;
}

.nav-links a:hover {
  color: var(--brand);
  background: rgba(30, 90, 61, 0.08);
  text-decoration: none;
}

.mobile-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  border: 1px solid rgba(0, 0, 0, .10);
  background: #fff;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  font-size: 20px;
}

.nav-links .btn {
  margin-left: 0;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: 14px;
  border: 1px solid transparent;
  font-weight: 800;
  cursor: pointer;
  transition: transform .2s, box-shadow .2s, background .2s, border-color .2s;
  box-shadow: var(--shadow-sm);
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff !important;
  text-decoration: none !important;
}

.btn-primary:hover {
  background: var(--brand-light);
  border-color: var(--brand-light);
  box-shadow: var(--shadow-md);
}

.btn-outline {
  background: #fff;
  border-color: rgba(30, 90, 61, 0.20);
  color: var(--brand) !important;
  text-decoration: none !important;
}

.btn-outline:hover {
  border-color: rgba(30, 90, 61, 0.32);
  box-shadow: var(--shadow-md);
}

/* HERO (index) */
.hero {
  position: relative;
  padding: clamp(70px, 10vw, 120px) 0;
  overflow: hidden;
  background:
    radial-gradient(900px 420px at 20% 20%, rgba(58, 157, 125, 0.20), transparent 60%),
    radial-gradient(900px 420px at 80% 30%, rgba(212, 160, 23, 0.18), transparent 60%),
    linear-gradient(180deg, #ffffff, #f2faf7);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(22px, 4vw, 46px);
  align-items: center;
}

.hero h1 {
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.05;
  margin-bottom: 14px;
}

.hero p {
  font-size: clamp(16px, 2.2vw, 20px);
  color: var(--muted);
  margin-bottom: 22px;
  max-width: 60ch;
}

.cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.badges {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 999px;
  padding: 10px 12px;
  color: var(--muted);
  box-shadow: var(--shadow-sm);
  font-weight: 700;
}

.badge i {
  color: var(--brand);
}

.hero-img {
  border-radius: 24px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  min-height: 320px;
}

/* HERO (páginas interiores con imagen) */
.hero-section {
  background:
    linear-gradient(rgba(30, 90, 61, .90), rgba(30, 90, 61, .82)),
    var(--hero-image, none);
  background-size: cover;
  background-position: center;
  color: #fff;
  padding: clamp(70px, 10vw, 100px) 0 clamp(52px, 8vw, 80px);
  text-align: center;
}

.hero-section h1 {
  font-size: clamp(32px, 4.5vw, 48px);
  margin-bottom: 14px;
}

.hero-section p {
  font-size: clamp(16px, 2.2vw, 20px);
  max-width: 900px;
  margin: 0 auto clamp(18px, 3vw, 30px);
  opacity: .92;
}

/* Blocks / cards */
.section-title {
  text-align: center;
  margin-bottom: clamp(22px, 3vw, 36px);
}

.section-title h2 {
  font-size: clamp(28px, 4vw, 40px);
  margin-bottom: 10px;
}

.section-title p {
  color: var(--muted);
  max-width: 760px;
  margin: 0 auto;
  font-size: clamp(16px, 2vw, 18px);
}

.card,
.service-card,
.contact-card,
.legal-content {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: var(--shadow-sm);
}

/* Index: “por qué nosotros” */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 22px);
}

.feature {
  padding: clamp(18px, 2.5vw, 26px);
}

.feature i {
  color: var(--brand);
  font-size: 28px;
  margin-bottom: 12px;
}

.feature h3 {
  margin: 8px 0 6px;
}

.feature p {
  color: var(--muted);
}

/* Servicios */
.service-index {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(12px, 2vw, 18px);
  margin-bottom: clamp(22px, 3vw, 34px);
}

.service-index a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: var(--shadow-sm);
  color: var(--dark);
  font-weight: 800;
}

.service-index a:hover {
  border-color: rgba(30, 90, 61, .35);
  text-decoration: none;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 2.5vw, 26px);
}

.service-card {
  padding: clamp(18px, 2.5vw, 26px);
  transition: transform .25s, box-shadow .25s;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

.service-icon {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(30, 90, 61, 0.10);
  color: var(--brand);
  font-size: 22px;
  margin-bottom: 14px;
}

.service-card h3 {
  margin-bottom: 8px;
}

.service-card p {
  color: var(--muted);
}

.service-card ul {
  margin-top: 14px;
  display: grid;
  gap: 8px;
  padding-left: 0;
}

.service-card li {
  color: var(--muted);
  display: flex;
  gap: 10px;
}

.service-card li i {
  color: var(--brand);
  margin-top: 4px;
}

/* Galería */
.filter-buttons {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: clamp(18px, 3vw, 30px);
}

.filter-btn {
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid rgba(0, 0, 0, 0.10);
  background: #fff;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  font-weight: 800;
  color: var(--dark);
}

.filter-btn.active,
.filter-btn:hover {
  background: rgba(30, 90, 61, 0.10);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(12px, 2vw, 18px);
}

/* Galería (estructura con overlay; soporta <img> o iconos) */
.gallery-category {
  margin-top: clamp(18px, 3vw, 34px);
}

.gallery-category h3 {
  font-size: clamp(22px, 3vw, 30px);
  margin: clamp(18px, 3vw, 26px) 0 14px;
  color: var(--dark);
}

.gallery-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: var(--shadow-sm);
  background: #fff;
  min-height: 260px;
  transition: transform .25s, box-shadow .25s;
}

.gallery-item:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

.gallery-img {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(30, 90, 61, 0.08), rgba(58, 157, 125, 0.10));
  color: var(--muted);
}

.gallery-img i {
  font-size: 80px;
  color: #b8d9c9;
}

.gallery-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, rgba(11, 31, 23, 0), rgba(11, 31, 23, 0.86));
  color: #fff;
  padding: 18px 18px 16px;
  transform: translateY(60%);
  transition: transform .25s;
}

.gallery-overlay h4 {
  margin-bottom: 4px;
  font-size: 18px;
}

.gallery-overlay .small {
  opacity: .86;
  font-size: 14px;
}

.gallery-item:hover .gallery-overlay {
  transform: translateY(0);
}

/* Contacto */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(16px, 2.5vw, 30px);
  margin-top: clamp(18px, 3vw, 40px);
}

.contact-card {
  padding: clamp(18px, 2.5vw, 28px);
  text-align: center;
  transition: transform .25s, box-shadow .25s;
}

.contact-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

.contact-icon {
  font-size: 3rem;
  color: var(--brand);
  margin-bottom: 18px;
}

.contact-card h3 {
  margin: 10px 0;
  font-size: clamp(20px, 2.5vw, 26px);
}

.contact-details {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  display: grid;
  gap: 10px;
  color: var(--muted);
}

.contact-details a {
  color: var(--brand);
  font-weight: 900;
  text-decoration: none;
}

.contact-details a:hover {
  text-decoration: underline;
}

.contact-details i {
  color: var(--brand);
  margin-right: 8px;
}

.map-container {
  height: clamp(260px, 40vw, 420px);
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: var(--shadow-sm);
}

/* Legal */
.legal-content {
  padding: clamp(22px, 5vw, 50px);
}

.legal-content h1 {
  font-size: clamp(28px, 4vw, 44px);
  margin-bottom: 14px;
}

.legal-content p {
  color: var(--muted);
  margin: 10px 0;
}

.legal-content h2 {
  font-size: clamp(22px, 3vw, 30px);
  margin: clamp(26px, 5vw, 40px) 0 18px;
}

.legal-content ul {
  margin-left: 22px;
  list-style: disc;
  display: grid;
  gap: 10px;
  color: var(--muted);
}

/* Footer */
.footer {
  background: var(--dark);
  color: #dfe8e4;
  padding: clamp(44px, 7vw, 60px) 0 26px;
  margin-top: clamp(42px, 6vw, 70px);
}

.footer-content {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: clamp(24px, 5vw, 40px);
  align-items: start;
}

.footer h3 {
  color: #fff;
  margin-bottom: 10px;
}

.footer p {
  color: #cfe0d9;
}

.footer a {
  color: #cfe0d9;
}

.footer a:hover {
  color: #fff;
  text-decoration: none;
}

.social-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.social-links a {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .2s, background .2s;
}

.social-links a:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.14);
}

.footer-bottom {
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  text-align: center;
  color: #bcd0c8;
  font-size: 14px;
}

/* Cookie banner */
.cookie-banner {
  position: fixed;
  left: 14px;
  right: 14px;
  bottom: 14px;
  max-width: 980px;
  margin: 0 auto;
  background: #fff;
  border-radius: 18px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: var(--shadow-md);
  padding: 16px;
  display: none;
  z-index: 2000;
}

.cookie-banner.active {
  display: block;
}

.cookie-banner p {
  color: var(--muted);
  font-size: 15px;
}

.cookie-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.cookie-actions .btn {
  flex: 1 1 160px;
}

/* ===== Responsive: tablet ===== */
@media (max-width:1024px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .services-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .features-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .service-index {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-content {
    grid-template-columns: 1fr 1fr;
  }
}

/* ===== Responsive: móvil ===== */
@media (max-width:800px) {
  .mobile-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 90px;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    padding: 14px 16px;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    box-shadow: 0 10px 22px rgba(0, 0, 0, .12);
    border-radius: 0 0 18px 18px;
  }

  .nav-links a {
    width: 100%;
    padding: 12px 12px;
  }

  .cta {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    width: 100%;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .service-index {
    grid-template-columns: 1fr;
  }

  .footer-content {
    grid-template-columns: 1fr;
  }

  .hero-img {
    min-height: 260px;
  }
}

/* ===== móviles pequeños ===== */
@media (max-width:480px) {
  .nav {
    height: 84px;
  }

  .logo img {
    height: 80px;
  }

  .hero-section {
    padding: 62px 0 52px;
  }

  .cookie-banner {
    left: 10px;
    right: 10px;
    bottom: 10px;
  }
}


/* ===== FAQ (index) ===== */
.faq {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  gap: 12px;
}

.faq details {
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 16px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
  overflow: hidden;
}

.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 16px;
  font-weight: 900;
  color: var(--dark);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  font-weight: 900;
  color: var(--brand);
  font-size: 18px;
  line-height: 1;
}

.faq details[open] summary::after {
  content: "–";
}

.faq-content {
  padding: 0 16px 16px;
  color: var(--muted);
}

.faq-content p {
  margin-top: 8px;
}

/* ===== Fotos dentro de Servicios ===== */
.work-section {
  margin-top: clamp(24px, 4vw, 48px);
  padding-top: clamp(10px, 2vw, 18px);
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(12px, 2vw, 18px);
  margin-top: clamp(14px, 2vw, 20px);
}

.work-card {
  background: #fff;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.06);
}

.work-card img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  display: block;
}

.work-card figcaption {
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.work-card figcaption strong {
  color: var(--dark);
  font-size: 16px;
}

.work-card figcaption span {
  color: var(--muted);
  font-size: 14px;
}

/* Responsive */
@media (max-width:1024px) {
  .work-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .work-card img {
    height: 220px;
  }
}

@media (max-width:800px) {
  .work-grid {
    grid-template-columns: 1fr;
  }

  .work-card img {
    height: 220px;
  }
}


/* ===== Servicios: nueva disposición (bloques con imagen + texto) ===== */

.hero-actions {
  margin-top: 18px;
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.services-nav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: clamp(18px, 3vw, 34px);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.10);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
  font-weight: 900;
  color: var(--dark);
  text-decoration: none;
}

.pill:hover {
  border-color: rgba(30, 90, 61, 0.30);
  text-decoration: none;
}

.services-layout {
  display: grid;
  gap: clamp(14px, 2.5vw, 22px);
}

.service-row {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 0;
  background: #fff;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.06);
}

.service-row.reverse {
  grid-template-columns: 0.95fr 1.05fr;
}

.service-row.reverse .service-content {
  order: 2;
}

.service-row.reverse .service-media {
  order: 1;
}

.service-content {
  padding: clamp(18px, 3vw, 30px);
}

.service-content h2 {
  font-size: clamp(22px, 2.6vw, 30px);
  margin-bottom: 10px;
}

.service-content h2 i {
  color: var(--brand);
  margin-right: 10px;
}

.service-content .muted {
  color: var(--muted);
  margin-bottom: 14px;
}

.service-list {
  display: grid;
  gap: 10px;
  margin: 14px 0 0;
  padding: 0;
}

.service-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: var(--muted);
}

.service-list li i {
  color: var(--brand);
  margin-top: 4px;
}

.service-actions {
  margin-top: 18px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.service-media {
  position: relative;
  min-height: 320px;
  background: linear-gradient(135deg, rgba(30, 90, 61, 0.08), rgba(58, 157, 125, 0.10));
}

.service-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Tablet */
@media (max-width:1024px) {

  .service-row,
  .service-row.reverse {
    grid-template-columns: 1fr;
  }

  .service-row.reverse .service-content,
  .service-row.reverse .service-media {
    order: initial;
  }

  .service-media {
    min-height: 260px;
  }
}

/* Móvil */
@media (max-width:800px) {
  .hero-actions .btn {
    width: 100%;
  }

  .services-nav {
    justify-content: flex-start;
  }

  .pill {
    width: 100%;
    justify-content: flex-start;
  }

  .service-actions .btn {
    width: 100%;
  }
}


/* ===== Footer mejorado (sin Galería) ===== */
.footer {
  background: var(--dark);
  color: #dfe8e4;
  padding: clamp(44px, 7vw, 64px) 0 22px;
  margin-top: clamp(42px, 6vw, 70px);
}

.footer-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: clamp(18px, 4vw, 40px);
  align-items: start;
}

.footer-logo img {
  height: 62px;
  width: auto;
  border-radius: 14px;
  display: block;
}

.footer-text {
  margin-top: 12px;
  color: #cfe0d9;
  max-width: 46ch;
}

.footer-col h3 {
  color: #fff;
  margin-bottom: 12px;
  font-size: 16px;
  letter-spacing: .2px;
}

.footer-links {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
}

.footer-links a {
  color: #cfe0d9;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.footer-links a:hover {
  color: #fff;
}

.footer-bottom {
  margin-top: 26px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  color: #bcd0c8;
  font-size: 14px;
}

.footer-bottom a {
  color: #cfe0d9;
  text-decoration: none;
}

.footer-bottom a:hover {
  color: #fff;
}

.footer-sep {
  opacity: .6
}

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

@media (max-width:800px) {
  .footer-top {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    justify-content: flex-start;
  }
}