/* =====================================================
   CÁMARA DE COMERCIO ÁRABE ECUATORIANA
   Paleta: Verde #1B6B3A | Acento menta #A8D5B5
   ===================================================== */

/* ---------- Variables ---------- */
:root {
  --green:       #1B6B3A;
  --green-dark:  #134f2b;
  --green-mid:   #2a8a4e;
  --mint:        #A8D5B5;
  --mint-light:  #d4edd9;
  --white:       #ffffff;
  --off-white:   #f7faf8;
  --text-dark:   #0f2d1c;
  --text-mid:    #3d6650;
  --text-light:  #7aab8a;
  --border:      rgba(168,213,181,0.25);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: 'DM Sans', sans-serif;
  background: var(--white);
  color: var(--text-dark);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { display: block; max-width: 100%; }
.hidden { display: none !important; }

/* =====================================================
   HEADER
   ===================================================== */
.header {
  position: fixed;
  top: 0;
  z-index: 100;
  width: 100%;
  height: 88px;
  background: rgba(255,255,255,0.0);
  border-bottom: 1px solid transparent;
  transition: background 400ms var(--ease-out),
              border-color 400ms var(--ease-out),
              box-shadow 400ms var(--ease-out),
              backdrop-filter 400ms var(--ease-out);
}
.header.scrolled {
  background: rgba(255,255,255,0.72);
  border-bottom: 1px solid rgba(27,107,58,0.1);
  box-shadow: 0 4px 32px rgba(27,107,58,0.1);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
}
/* Nav links — mismo color en top y en scroll */
.header .nav-link { color: #555; }
.header .nav-link.active { color: var(--green); }
.header .nav-link::after { background: var(--green); }
.header .lang-btn { color: var(--green); border-color: var(--green); }
.header.scrolled {
  background: rgba(255,255,255,0.72);
  border-bottom: 1px solid rgba(27,107,58,0.1);
  box-shadow: 0 4px 32px rgba(27,107,58,0.1);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
}
.header.scrolled .nav-link { color: #555; }
.header.scrolled .nav-link.active { color: var(--green); }
.header.scrolled .nav-link::after { background: var(--green); }
.header.scrolled .lang-btn { color: var(--green); border-color: var(--green); }

.header-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 60px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 24px;
}

.logo-img {
  height: 44px;
  width: auto;
  display: block;
}



/* ---------- Nav ---------- */
.nav {
  display: flex;
  align-items: center;
  gap: 36px;
  flex: 1;
  justify-content: center;
}
.nav-link {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: #555;
  text-transform: uppercase;
  position: relative;
  transition: color 200ms;
  padding-bottom: 2px;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--green);
  border-radius: 2px;
  transition: width 250ms var(--ease-out);
}
.nav-link:hover { color: var(--green); }
.nav-link:hover::after { width: 100%; }
.nav-link.active { color: var(--green); }
.nav-link.active::after { width: 100%; }

/* ---------- Language selector ---------- */
.lang-wrap {
  position: relative;
  flex-shrink: 0;
}
.lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 16px;
  height: 40px;
  background: transparent;
  border: 1.5px solid var(--green);
  border-radius: 8px;
  color: var(--green);
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: background 200ms, color 200ms;
}
.lang-btn:hover {
  background: var(--green);
  color: var(--white);
}
.lang-drop {
  position: absolute;
  top: 48px;
  right: 0;
  background: var(--white);
  border: 1px solid rgba(27,107,58,0.15);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(27,107,58,0.15);
  overflow: hidden;
  min-width: 76px;
  z-index: 200;
  /* Animation */
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 200ms var(--ease-out),
              transform 200ms var(--ease-out);
  pointer-events: none;
}
.lang-drop.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}
.lang-opt {
  display: block;
  width: 100%;
  padding: 10px 18px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #444;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: background 150ms, color 150ms;
}
.lang-opt:hover { background: var(--mint-light); color: var(--green); }
.lang-opt.active { color: var(--green); font-weight: 700; }

/* =====================================================
   HERO
   ===================================================== */
.hero {
  position: relative;
  width: 100%;
  height: calc(100dvh - 60px);
  min-height: 520px;
  display: flex;
  align-items: center;
  overflow: hidden;
  /* No top margin — header is transparent/fixed, hero goes full */
}

/* Full-bleed background image */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 60% center;
  display: block;
  transform: scale(1.04);
  transition: transform 8s var(--ease-out);
}
.hero-bg img.loaded {
  transform: scale(1);
}

/* Gradient: white left → transparent */
.hero-grad {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to right,
    rgba(255,255,255,1)    0%,
    rgba(255,255,255,0.96) 30%,
    rgba(255,255,255,0.80) 45%,
    rgba(255,255,255,0.35) 62%,
    rgba(255,255,255,0.05) 78%,
    transparent            100%
  );
}

/* Top/bottom vignette — abajo funde con el off-white de #nosotros */
.hero-vign {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to bottom,
    rgba(255,255,255,0.38) 0%,
    transparent 12%,
    transparent 65%,
    rgba(247,250,248,0.6)  82%,
    rgba(247,250,248,0.92) 93%,
    rgba(247,250,248,1)    100%
  );
}

/* Text content */
.hero-content {
  position: relative;
  z-index: 2;
  width: 52%;
  padding: 40px 40px 40px 100px;
  display: flex;
  flex-direction: column;
}

.hero-pre {
  font-size: 16px;
  font-weight: 400;
  color: #444;
  margin-bottom: 2px;
}

.hero-title {
  display: flex;
  flex-direction: column;
  line-height: 0.93;
  margin-bottom: 14px;
}
.t-accent {
  font-family: 'Cormorant Garamond', serif;
  font-size: 86px;
  font-weight: 800;
  color: var(--green);
  letter-spacing: -0.01em;
}
.t-dark {
  font-family: 'Cormorant Garamond', serif;
  font-size: 68px;
  font-weight: 700;
  color: var(--text-dark);
  letter-spacing: -0.01em;
}

.hero-rule {
  width: 0;
  height: 3px;
  background: var(--green);
  border-radius: 2px;
  margin-bottom: 14px;
  transition: width 700ms var(--ease-out);
}
.hero-rule.expanded { width: 64px; }

.hero-desc {
  font-size: 13.5px;
  font-weight: 400;
  color: #555;
  line-height: 1.75;
  margin-bottom: 28px;
}

.hero-btns {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.btn-center {
  display: block;
  text-align: center;
}

.btn-primary {
  height: 46px;
  padding: 0 28px;
  background: var(--green);
  color: var(--white);
  border: 2px solid var(--green);
  border-radius: 9px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 250ms, transform 200ms;
}
.btn-primary::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.15);
  opacity: 0;
  transition: opacity 200ms;
}
.btn-primary:hover { background: var(--green-dark); transform: translateY(-2px); }
.btn-primary:hover::after { opacity: 1; }
.btn-primary:active { transform: translateY(0); }

.btn-outline {
  height: 46px;
  padding: 0 28px;
  background: transparent;
  color: var(--green);
  border: 2px solid var(--green);
  border-radius: 9px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  cursor: pointer;
  transition: background 250ms, color 250ms, transform 200ms;
}
.btn-outline:hover {
  background: var(--green);
  color: var(--white);
  transform: translateY(-2px);
}
.btn-outline:active { transform: translateY(0); }

/* =====================================================
   SCROLL ANIMATIONS
   ===================================================== */
[data-anim] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 600ms var(--ease-out),
              transform 600ms var(--ease-out);
}
[data-anim].visible {
  opacity: 1;
  transform: translateY(0);
}
[data-anim="expand"] {
  transform: none;
}

/* =====================================================
   FOOTER
   ===================================================== */
.footer {
  background: #fff;
  border-top: 3px solid var(--green);
}

.footer-inner {
  max-width: 1440px;
  margin: 0 auto;
  display: flex;
  align-items: flex-start;
  padding: 28px 60px 20px;
}

.footer-col {
  flex: 1;
  padding: 0 36px;
}
.footer-col:first-child { padding-left: 0; }
.footer-col:last-child  { padding-right: 0; }

.footer-sep {
  width: 1px;
  background: rgba(27,107,58,0.12);
  align-self: stretch;
  flex-shrink: 0;
}



.footer-col-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--mint);
  text-transform: uppercase;
  margin-bottom: 10px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.footer-links li a {
  font-size: 12.5px;
  color: rgba(255,255,255,0.7);
  transition: color 200ms, padding-left 200ms;
}
.footer-links li a:hover {
  color: var(--mint);
  padding-left: 4px;
}







/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 1200px) {
  .header-inner { padding: 0 40px; }
  .hero-content { padding: 60px 40px 60px 60px; }
  .t-accent { font-size: 80px; }
  .t-dark   { font-size: 64px; }
  .nav { gap: 24px; }
}

@media (max-width: 900px) {
  .hero { min-height: auto; }
  .hero-content { width: 100%; padding: 60px 40px; }
  .hero-grad {
    background: linear-gradient(
      to bottom,
      rgba(255,255,255,0.9) 0%,
      rgba(255,255,255,0.75) 60%,
      rgba(255,255,255,0.5) 100%
    );
  }
  .footer-inner { flex-wrap: wrap; gap: 32px; }
  .footer-col { flex: 1 1 42%; padding: 0 16px 20px; }
  .footer-sep { display: none; }
}

@media (max-width: 640px) {
  .nav { display: none; }
  .header-inner { padding: 0 20px; }
  .t-accent { font-size: 60px; }
  .t-dark   { font-size: 48px; }
  .hero-content { padding: 48px 20px; }
  .footer-col { flex: 1 1 100%; padding: 0 0 20px; }
  .footer-inner { padding: 40px 24px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0ms !important;
    animation-duration: 0ms !important;
  }
}

/* =====================================================
   SECCIONES — VARIABLES COMPARTIDAS
   ===================================================== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 60px;
}

.section-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--green);
  text-transform: uppercase;
  margin-bottom: 10px;
}
.section-label--light { color: var(--mint); }

.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 40px;
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.15;
  margin-bottom: 16px;
}
.section-title em { font-style: italic; color: var(--green); }
.section-title--white { color: #fff; }

.section-rule {
  width: 48px;
  height: 3px;
  background: var(--green);
  border-radius: 2px;
  margin-bottom: 24px;
}
.section-rule--center { margin-left: auto; margin-right: auto; }

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

/* =====================================================
   NOSOTROS
   ===================================================== */
.section-nosotros {
  background: var(--off-white);
  padding: 40px 0 80px;
  margin-top: -2px; /* elimina posible línea de 1px entre secciones */
}

.nosotros-grid {
  display: grid;
  grid-template-columns: 420px 1fr;
  gap: 64px;
  align-items: center;
}

.nosotros-img-wrap {
  position: relative;
}
.nosotros-img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  border-radius: 16px;
  display: block;
  background: var(--mint-light);
}
.nosotros-img-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(27,107,58,0.92) 0%, transparent 100%);
  padding: 40px 24px 20px;
  border-radius: 0 0 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  color: #fff;
}
.nosotros-img-caption strong {
  font-size: 16px;
  font-weight: 700;
  font-family: 'Cormorant Garamond', serif;
}
.nosotros-img-caption span {
  font-size: 12px;
  color: var(--mint);
  font-weight: 500;
}

.nosotros-text { display: flex; flex-direction: column; }
.nosotros-text p {
  font-size: 15px;
  line-height: 1.8;
  color: #555;
}

/* Placeholder when no image */
.nosotros-img[src="assets/img/mohammad-ali.jpg"]:not([complete]) {
  min-height: 480px;
}

/* =====================================================
   GLASS OVERLAY — used in Servicios & Testimonios
   ===================================================== */
.section-servicios,
.section-testimonios {
  position: relative;
  overflow: hidden;
}

.section-bg-img {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  z-index: 0;
}

.section-glass-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(27,107,58,0.72);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

/* =====================================================
   SERVICIOS
   ===================================================== */
.section-servicios {
  padding: 80px 0;
}
/* fallback bg if no image */
.section-servicios .section-bg-img {
  background-color: var(--green-dark);
}

.section-rule--mint { background: var(--mint); }

/* =====================================================
   SOCIAL WRAPPER
   ===================================================== */
.section-social {
  /* just a wrapper, no padding */
}

.section-fotos {
  background: #fff;
  padding: 80px 0;
}

/* =====================================================
   TESTIMONIOS
   ===================================================== */
.section-testimonios {
  padding: 80px 0;
}
.section-testimonios .section-bg-img {
  background-color: var(--green);
}

/* =====================================================
   FOOTER — fondo blanco, color verde principal
   ===================================================== */
.footer {
  background: #fff;
  border-top: 3px solid var(--green);
}

.footer-col-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--green);
  text-transform: uppercase;
  margin-bottom: 10px;
}

.footer-links li a {
  font-size: 12.5px;
  color: var(--text-mid);
  transition: color 200ms, padding-left 200ms;
}
.footer-links li a:hover {
  color: var(--green);
  padding-left: 4px;
}

.footer-tagline {
  font-size: 12px;
  color: var(--text-mid);
  font-style: italic;
  line-height: 1.6;
}

.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-mid);
}
.footer-contact-item svg { flex-shrink: 0; fill: var(--green); }

.footer-bottom {
  border-top: 1px solid rgba(27,107,58,0.12);
  text-align: center;
  padding: 10px 0;
  font-size: 11px;
  color: var(--text-light);
  letter-spacing: 0.03em;
}

.soc-btn {
  width: 34px;
  height: 34px;
  border: 1.5px solid rgba(27,107,58,0.35);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--green);
  transition: background 200ms, border-color 200ms, transform 200ms, box-shadow 200ms;
}
.soc-btn:hover {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 4px 14px rgba(27,107,58,0.25);
}

.footer-social {
  display: flex;
  flex-direction: row;
  gap: 10px;
  margin-bottom: 16px;
}

.card {
  background: rgba(10, 40, 20, 0.55);
  border: 1px solid rgba(168,213,181,0.40);
  border-radius: 16px;
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: background 300ms, transform 300ms, border-color 300ms;
}
.card:hover {
  background: rgba(10, 40, 20, 0.72);
  border-color: rgba(168,213,181,0.7);
  transform: translateY(-6px);
}

.card-icon {
  width: 52px;
  height: 52px;
  background: rgba(168,213,181,0.15);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--mint);
  flex-shrink: 0;
}
.card-icon svg { width: 28px; height: 28px; }

.card-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 700;
  color: #fff;
}

.card-text {
  font-size: 13.5px;
  line-height: 1.75;
  color: rgba(255,255,255,0.7);
  flex: 1;
}

/* cards grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.fotos-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: 220px 220px;
  gap: 12px;
}

.foto-item {
  overflow: hidden;
  border-radius: 12px;
  background: var(--mint-light);
}
.foto-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 500ms var(--ease-out);
}
.foto-item:hover img { transform: scale(1.05); }

.foto-item--tall {
  grid-row: span 2;
}
.foto-item--wide {
  grid-column: span 2;
}

/* =====================================================
   GALERÍA grid
   ===================================================== */

.testimonios-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.testimonio-card {
  background: rgba(10, 40, 20, 0.55);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 16px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: background 300ms, transform 300ms;
}
.testimonio-card:hover {
  background: rgba(10, 40, 20, 0.72);
  transform: translateY(-4px);
}

.testimonio-stars {
  color: var(--mint);
  font-size: 15px;
  letter-spacing: 2px;
}

.testimonio-text {
  font-size: 14px;
  line-height: 1.75;
  color: rgba(255,255,255,0.85);
  font-style: italic;
  flex: 1;
}

.testimonio-autor {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 4px;
}
.testimonio-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(168,213,181,0.3);
  flex-shrink: 0;
}
.testimonio-autor strong {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
}
.testimonio-autor span {
  font-size: 11.5px;
  color: var(--mint);
}

/* =====================================================
   RESPONSIVE NUEVAS SECCIONES
   ===================================================== */
@media (max-width: 1100px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .nosotros-grid { grid-template-columns: 1fr; }
  .nosotros-img { height: 320px; }
  .testimonios-grid { grid-template-columns: 1fr; }
  .fotos-grid { grid-template-columns: repeat(2, 1fr); }
  .foto-item--tall { grid-row: span 1; }
  .foto-item--wide { grid-column: span 1; }
  .container { padding: 0 24px; }
}

@media (max-width: 640px) {
  .cards-grid { grid-template-columns: 1fr; }
  .section-title { font-size: 30px; }
  .fotos-grid { grid-template-columns: 1fr; }
}
