/*
  D&D TRADE COMPANY — Hoja de estilos (versión HTML/PHP/CSS)
  Paleta: Navy #14264A · Silver #B8C0CC · Green #2E9E5B · White
  Tipografía: Playfair Display (títulos) + Montserrat (cuerpo)
*/

:root {
  --navy: #17274c;
  --navy-dark: #101d3b;
  --navy-darker: #0c1730;
  --green: #2e9e5b;
  --green-hover: #268650;
  --green-light: #4bc47d;
  --silver: #b8c0cc;

  --white: #ffffff;
  --foreground: #2a3242;
  --muted: #667085;
  --secondary: #f4f5f8;
  --border: #e5e8ee;

  --font-display: "Playfair Display", Georgia, serif;
  --font-sans: "Montserrat", system-ui, -apple-system, sans-serif;

  --radius: 0.5rem;
  --header-h: 76px;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
}

body {
  font-family: var(--font-sans);
  color: var(--foreground);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  line-height: 1.12;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 640px) {
  .container {
    padding: 0 1.5rem;
  }
}
@media (min-width: 1024px) {
  .container {
    padding: 0 2rem;
  }
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: 0;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease, color 0.2s ease;
  padding: 0.65rem 1.5rem;
  font-size: 0.95rem;
}
.btn:active {
  transform: scale(0.97);
}
.btn-green {
  background: var(--green);
  color: #fff;
}
.btn-green:hover {
  background: var(--green-hover);
}
.btn-outline {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #fff;
}
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.1);
}
.btn-lg {
  height: 56px;
  padding: 0 2rem;
  font-size: 1rem;
}
.btn-xl {
  height: 56px;
  padding: 0 2.5rem;
  font-size: 1rem;
}

/* ---------- Header ---------- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  padding: 1.25rem 0;
  transition: background 0.3s ease, padding 0.3s ease, box-shadow 0.3s ease;
}
.header.scrolled {
  background: rgba(23, 39, 76, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  padding: 0.75rem 0;
}
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.brand__logo {
  height: 44px;
  width: 44px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--navy);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  flex-shrink: 0;
}
.brand__name {
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.125rem;
  letter-spacing: 0.02em;
}
.nav {
  display: none;
  align-items: center;
  gap: 2rem;
}
.nav a {
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
  transition: color 0.2s ease;
}
.nav a:hover {
  color: var(--green-light);
}
.header__cta {
  display: none;
  align-items: center;
  gap: 1rem;
}
.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
  padding: 0.2rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.lang-switch__opt {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.7);
  padding: 0.3rem 0.55rem;
  border-radius: 999px;
  line-height: 1;
  transition: color 0.2s ease, background 0.2s ease;
}
.lang-switch__opt:hover {
  color: #fff;
}
.lang-switch__opt.is-active {
  color: #fff;
  background: var(--green);
}
.lang-switch--mobile {
  align-self: flex-start;
  gap: 0.3rem;
  margin-top: 0.25rem;
}
.lang-switch--mobile .lang-switch__opt {
  font-size: 0.85rem;
  padding: 0.4rem 0.8rem;
}
.menu-toggle {
  display: inline-flex;
  background: none;
  border: 0;
  color: #fff;
  cursor: pointer;
}
.mobile-menu {
  display: none;
  background: var(--navy);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 0.75rem;
}
.mobile-menu.open {
  display: block;
}
.mobile-menu__inner {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem 0;
}
.mobile-menu a {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
}
.mobile-menu .btn {
  width: 100%;
}

@media (min-width: 1024px) {
  .nav {
    display: flex;
  }
  .header__cta {
    display: flex;
  }
  .menu-toggle {
    display: none;
  }
}
@media (max-width: 639px) {
  .brand__logo-img {
    height: 42px;
    padding: 5px 9px;
  }
}

/* ---------- Secciones base ---------- */
.section {
  padding: 6rem 0;
}
.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.section-title {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  margin-top: 0.75rem;
}
.text-center {
  text-align: center;
}
.mx-auto {
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}
.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    100deg,
    rgba(12, 23, 48, 0.95) 0%,
    rgba(16, 29, 59, 0.8) 45%,
    rgba(23, 39, 76, 0.45) 100%
  );
}
.hero__content {
  position: relative;
  z-index: 10;
  padding: 7rem 0 4rem;
  max-width: 48rem;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 999px;
  border: 1px solid rgba(75, 196, 125, 0.4);
  background: rgba(46, 158, 91, 0.1);
  padding: 0.375rem 1rem;
  margin-bottom: 1.5rem;
}
.badge__dot {
  height: 8px;
  width: 8px;
  border-radius: 999px;
  background: var(--green-light);
  animation: pulse 2s infinite;
}
.badge span {
  color: #a6e6c2;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.hero h1 {
  color: #fff;
  font-weight: 800;
  font-size: clamp(2.25rem, 6vw, 3.75rem);
  margin-bottom: 1.5rem;
}
.hero h1 .accent {
  color: var(--green-light);
}
.hero__lead {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.2rem;
  max-width: 40rem;
  margin-bottom: 2.5rem;
}
.hero__actions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.hero__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 3.5rem;
  max-width: 32rem;
}
.stat {
  border-left: 2px solid var(--green);
  padding-left: 0.75rem;
}
.stat__k {
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.125rem;
}
.stat__v {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.875rem;
}

@media (min-width: 640px) {
  .hero__actions {
    flex-direction: row;
  }
}

/* ---------- What We Do ---------- */
.bg-white {
  background: #fff;
}
.grid-what {
  display: grid;
  gap: 3rem;
  align-items: flex-start;
}
.what__intro .eyebrow {
  color: var(--green);
}
.what__intro h2 {
  color: var(--navy);
  margin: 0.75rem 0 1.5rem;
}
.what__intro p {
  color: var(--muted);
  font-size: 1.075rem;
  margin-bottom: 1.5rem;
}
.cards {
  display: grid;
  gap: 1.25rem;
}
.card {
  border: 1px solid var(--border);
  background: rgba(244, 245, 248, 0.5);
  border-radius: 1rem;
  padding: 1.75rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}
.card:hover {
  background: #fff;
  box-shadow: 0 20px 40px rgba(23, 39, 76, 0.12);
  transform: translateY(-4px);
}
.card__icon {
  height: 48px;
  width: 48px;
  border-radius: 0.75rem;
  background: var(--navy);
  color: #fff;
  display: grid;
  place-items: center;
  margin-bottom: 1.25rem;
  transition: background 0.3s ease;
}
.card:hover .card__icon {
  background: var(--green);
}
.card h3 {
  font-size: 1.125rem;
  color: var(--navy);
  margin-bottom: 0.5rem;
}
.card p {
  color: var(--muted);
  font-size: 0.9rem;
}

@media (min-width: 640px) {
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .grid-what {
    grid-template-columns: 5fr 7fr;
  }
}

/* ---------- How We Work ---------- */
.bg-navy {
  background: var(--navy);
  position: relative;
  overflow: hidden;
}
.blob {
  position: absolute;
  height: 18rem;
  width: 18rem;
  border-radius: 999px;
  background: rgba(46, 158, 91, 0.12);
  filter: blur(80px);
  pointer-events: none;
}
.blob--tr {
  right: -6rem;
  top: -6rem;
}
.blob--bl {
  left: -5rem;
  bottom: -5rem;
  background: rgba(46, 158, 91, 0.16);
}
.how__head .eyebrow {
  color: var(--green-light);
}
.how__head h2 {
  color: #fff;
}
.steps {
  display: grid;
  gap: 1.5rem;
  margin-top: 4rem;
}
.step {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(4px);
  border-radius: 1rem;
  padding: 1.5rem;
}
.step__num {
  color: rgba(46, 158, 91, 0.45);
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 2.25rem;
  margin-bottom: 0.75rem;
}
.step__icon {
  color: var(--green-light);
  margin-bottom: 0.75rem;
}
.step h3 {
  color: #fff;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.step p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.875rem;
}

@media (min-width: 768px) {
  .steps {
    grid-template-columns: repeat(5, 1fr);
  }
}

/* ---------- Advantage / tabla ---------- */
.bg-soft {
  background: rgba(244, 245, 248, 0.6);
}
.advantage__head h2 {
  color: var(--navy);
}
.advantage__head .eyebrow {
  color: var(--green);
}
.advantage__head p {
  color: var(--muted);
  font-size: 1.075rem;
  margin-top: 1.25rem;
}
.compare {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 1rem;
  box-shadow: 0 20px 50px rgba(23, 39, 76, 0.12);
  background: #fff;
  margin-top: 3.5rem;
}
.compare__row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
}
.compare__head {
  background: var(--navy);
  color: #fff;
}
.compare__head > div {
  padding: 1.25rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
}
.compare__head > div + div {
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}
.compare__head .sub {
  display: block;
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.5);
}
.compare__head .highlight {
  background: var(--green);
}
.compare__body {
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
}
.compare__body:nth-child(even) {
  background: rgba(244, 245, 248, 0.6);
}
.compare__body > div {
  padding: 1.25rem;
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}
.compare__body > div + div {
  border-left: 1px solid var(--border);
}
.compare__feature {
  font-weight: 600;
  color: var(--navy);
}
.compare__neg {
  color: var(--muted);
}
.compare__neg svg {
  color: rgba(102, 112, 133, 0.5);
  flex-shrink: 0;
  margin-top: 2px;
}
.compare__pos {
  color: var(--navy);
  font-weight: 500;
}
.compare__pos svg {
  color: var(--green-hover);
  flex-shrink: 0;
  margin-top: 2px;
}
.advantage__closing {
  text-align: center;
  color: var(--navy);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  margin: 2.5rem auto 0;
  max-width: 42rem;
}

/* ---------- Global Reach ---------- */
.bg-navy-dark {
  background: var(--navy-dark);
}
.global__head .eyebrow {
  color: var(--green-light);
}
.global__head h2 {
  color: #fff;
}
.map-wrap {
  border-radius: 1.5rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 3rem;
}
.map-wrap img {
  width: 100%;
  object-fit: cover;
}
.locations {
  display: grid;
  gap: 1.5rem;
  margin-top: 2rem;
}
.location {
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 2rem;
}
.location__head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}
.location__head svg {
  color: var(--green-light);
}
.location h3 {
  color: #fff;
  font-size: 1.25rem;
}
.location p {
  color: rgba(255, 255, 255, 0.7);
}

@media (min-width: 768px) {
  .locations {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ---------- Team ---------- */
.team__head .eyebrow {
  color: var(--green);
}
.team__head h2 {
  color: var(--navy);
}
.team {
  display: grid;
  gap: 2.5rem;
  margin-top: 4rem;
}
.member {
  text-align: center;
}
.member__avatar {
  position: relative;
  margin: 0 auto 1.5rem;
  width: 176px;
  height: 176px;
}
.member__avatar-glow {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: rgba(46, 158, 91, 0.2);
  filter: blur(24px);
  transition: background 0.3s ease;
}
.member:hover .member__avatar-glow {
  background: rgba(46, 158, 91, 0.4);
}
.member__img,
.member__initials {
  position: relative;
  width: 176px;
  height: 176px;
  border-radius: 999px;
  object-fit: cover;
  border: 4px solid #fff;
  box-shadow: 0 20px 40px rgba(23, 39, 76, 0.18);
}
.member__initials {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--navy), var(--navy-light, #2f4373));
  color: #fff;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 3rem;
}
.member h3 {
  font-size: 1.25rem;
  color: var(--navy);
}
.member__role {
  color: var(--green);
  font-weight: 600;
  font-size: 0.875rem;
  margin: 0.25rem 0 0.75rem;
}
.member p {
  color: var(--muted);
  font-size: 0.9rem;
  max-width: 20rem;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .team {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ---------- Contact ---------- */
.contact__inner {
  position: relative;
  text-align: center;
  max-width: 48rem;
  margin: 0 auto;
}
.contact h2 {
  color: #fff;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  margin-bottom: 1.25rem;
}
.contact__lead {
  color: rgba(255, 255, 255, 0.75);
  font-size: 1.15rem;
  margin-bottom: 2.5rem;
}
.contact-form {
  display: grid;
  gap: 1rem;
  text-align: left;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 1.25rem;
  padding: 2rem;
  margin-bottom: 2rem;
}
.contact-form .field-row {
  display: grid;
  gap: 1rem;
}
.contact-form label {
  display: block;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 0.6rem;
  padding: 0.75rem 1rem;
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(255, 255, 255, 0.4);
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--green-light);
  background: rgba(255, 255, 255, 0.12);
}
.contact-form .btn {
  justify-self: start;
}
.form-alert {
  border-radius: 0.6rem;
  padding: 0.85rem 1rem;
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
}
.form-alert--ok {
  background: rgba(46, 158, 91, 0.18);
  border: 1px solid rgba(75, 196, 125, 0.5);
  color: #bef2d3;
}
.form-alert--err {
  background: rgba(220, 60, 60, 0.15);
  border: 1px solid rgba(220, 90, 90, 0.5);
  color: #f7c4c4;
}

@media (min-width: 640px) {
  .contact-form .field-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ---------- Footer ---------- */
.footer {
  background: var(--navy-darker);
  color: rgba(255, 255, 255, 0.7);
  padding: 3rem 0;
}
.footer__top {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.footer__nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  font-size: 0.875rem;
}
.footer__nav a:hover {
  color: var(--green-light);
}
.footer__bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 2rem;
  font-size: 0.875rem;
}
.footer__bottom .muted {
  color: rgba(255, 255, 255, 0.5);
}

@media (min-width: 768px) {
  .footer__top {
    flex-direction: row;
  }
  .footer__bottom {
    flex-direction: row;
  }
}

/* ---------- Animaciones ---------- */
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s cubic-bezier(0.23, 1, 0.32, 1),
    transform 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
  .reveal {
    opacity: 1;
    transform: none;
  }
}
