/* Ports v2: a real map of Egypt with the six ports and three offices. International markets live in service 07.
   To return to the previous photo version, restore backups/network-photo.html and drop this stylesheet. */
.ports-section { position: relative; isolation: isolate; overflow: hidden; padding-block: 64px 56px; background: var(--navy); color: #fff; }
/* brand angle on the top edge, like the band above the old section */
.ports-section::before { content: ''; position: absolute; top: 0; inset-inline-start: 0; width: 38%; height: 14px; background: var(--paper); clip-path: polygon(0 0,100% 0,calc(100% - 14px) 100%,0 100%); }
html[dir="rtl"] .ports-section::before { clip-path: polygon(0 0,100% 0,100% 100%,14px 100%); }
/* a faint chevron from the mark behind the map */
.ports-section::after { content: ''; position: absolute; z-index: -1; top: 8%; inset-inline-end: -120px; width: 520px; height: 680px; background: rgb(255 255 255 / 3%); clip-path: polygon(0 0,43% 0,100% 50%,43% 100%,0 100%,57% 50%); }

.ports-layout { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(28px, 4vw, 64px); align-items: center; }
.ports-section .section-kicker--light { color: var(--blue); }
.ports-copy h2 { margin-bottom: 14px; color: #fff; font-size: clamp(34px, 3.4vw, 48px); line-height: 1.4; }
.ports-summary { color: #b9c4da; font-size: 16px; line-height: 2; max-width: 520px; }

.ports-groups { display: grid; gap: 16px; margin-top: 24px; }
.ports-group h3 { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; color: var(--blue); font-size: 14px; font-weight: 800; }
.ports-group h3::after { content: ''; flex: 1; height: 1px; background: rgb(255 255 255 / 12%); }
.ports-count { order: 2; color: #6f80a3; font: 700 11px Arial, sans-serif; letter-spacing: .1em; }
.ports-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.port-chip { display: inline-flex; align-items: center; gap: 10px; padding: 10px 18px; background: rgb(255 255 255 / 6%); color: #fff; font-size: 15px; font-weight: 700; clip-path: polygon(8px 0,100% 0,calc(100% - 8px) 100%,0 100%); transition: background .25s, color .25s; }
.port-chip-pin { color: var(--blue); font-size: 14px; transition: color .25s; }
.port-chip:hover, .port-chip:focus-visible, .port-chip.is-active { background: var(--blue); }
.port-chip:hover .port-chip-pin, .port-chip:focus-visible .port-chip-pin, .port-chip.is-active .port-chip-pin { color: #fff; }

.ports-legend { display: flex; flex-wrap: wrap; gap: 22px; margin-top: 18px; color: #8d9ab5; font-size: 13px; font-weight: 600; }
.ports-legend li { display: inline-flex; align-items: center; gap: 8px; }
.legend-port { color: var(--blue); font-size: 14px; }
.legend-office { color: #d4d9e2; font-size: 14px; }

/* Map */
.ports-map { margin: 0; }
.ports-svg { display: block; width: 100%; height: auto; overflow: visible; direction: ltr; font-family: Cairo, Tahoma, sans-serif; -webkit-mask-image: linear-gradient(to bottom, #000 72%, transparent); mask-image: linear-gradient(to bottom, #000 72%, transparent); }  /* the empty south fades out */
.map-land { fill: #102347; stroke: #2c4677; stroke-width: 1.5; stroke-linejoin: round; }
.map-nile { fill: none; stroke: #2f6fe0; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; opacity: .55; }
.map-sea { fill: #4a6496; font-size: 13px; font-weight: 700; letter-spacing: .02em; }
.map-city { fill: #b9c4da; font-size: 13px; font-weight: 700; }
.map-marker--office .map-pin { fill: #d4d9e2; stroke: var(--navy); }   /* UNEX office: silver pin */
.map-marker--office .map-pin-hole { fill: var(--navy); }
.map-leader { fill: none; stroke: rgb(7 84 255 / 55%); stroke-width: 1; transition: stroke .25s; }
.map-marker { transform-box: fill-box; transform-origin: 50% 100%; transition: transform .25s var(--ease); filter: drop-shadow(0 3px 4px rgb(0 0 0 / 35%)); }
.map-pin { fill: var(--blue); stroke: #fff; stroke-width: 1.5; stroke-linejoin: round; transition: fill .25s; }
.map-pin-hole { fill: #fff; }
.map-pulse { fill: none; stroke: var(--blue); stroke-width: 1.5; opacity: 0; transform-box: fill-box; transform-origin: center; }
.map-label { fill: #fff; font-size: 15px; font-weight: 800; transition: fill .25s; }
.map-port { cursor: pointer; }
.map-port.is-active .map-marker { transform: scale(1.3); }
.map-port.is-active .map-pin { fill: var(--blue); }
.map-port.is-active .map-label { fill: var(--blue); }
.map-port.is-active .map-leader { stroke: var(--blue); }
.map-port.is-active .map-pulse { animation: map-pulse 1.6s ease-out infinite; }
@keyframes map-pulse { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(3.4); } }

@media (max-width: 1023px) {
  .ports-section { padding-block: 56px 48px; }
  .ports-layout { grid-template-columns: 1fr; }
  .ports-map { max-width: 560px; width: 100%; margin-inline: auto; }
}
@media (max-width: 767px) {
  .ports-section { padding-block: 48px 40px; }
  .ports-section::before { width: 60%; height: 10px; }
  .ports-summary { font-size: 14px; }
  .port-chip { font-size: 14px; padding: 9px 14px; }
  .map-label { font-size: 19px; }
  .map-city, .map-sea { font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  .map-port.is-active .map-pulse { animation: none; }
}
