/* ABOUTME: Main stylesheet for Etc. Collective website */
/* ABOUTME: Design tokens, layout, animations, and responsive breakpoints */

/* ═══════════════════════════════════════════
   FONT FACE
   ═══════════════════════════════════════════ */
@font-face {
  font-family: 'PP Neue Montreal';
  src: url('../assets/fonts/PPNeueMontreal-SemiBold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* ═══════════════════════════════════════════
   DESIGN TOKENS
   ═══════════════════════════════════════════ */
:root {
  --color-black: #000;
  --color-white: #fff;
  --color-orange: #FE3C00;
  --color-dark: #1A1A1A;
  --color-gray: #666;

  --font-primary: 'PP Neue Montreal', Arial, Helvetica, sans-serif;
  --font-weight-semibold: 600;

  --spacing-page: 40px;
  --max-width: 1440px;

  --tracking-tight: -0.03em;
  --tracking-tighter: -0.03em;
}

/* ═══════════════════════════════════════════
   RESET & BASE
   ═══════════════════════════════════════════ */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  font-weight: var(--font-weight-semibold);
  color: var(--color-black);
  background: var(--color-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

/* ═══════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════ */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 600px;
  overflow: hidden;
}

.hero__photos {
  display: flex;
  width: 100%;
  height: 100%;
}

.hero__photo {
  height: 100%;
  background-size: cover;
  background-position: center;
}

.hero__photo--1 {
  flex: 0 0 68%;
  background-image: url('../assets/images/hero.jpg');
}

.hero__photo--2 {
  flex: 0 0 24%;
  background-image: url('../assets/images/hero.jpg');
  background-position: 60% center;
}

.hero__photo--3 {
  flex: 0 0 8%;
  background-image: url('../assets/images/hero.jpg');
  background-position: 80% center;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  padding: var(--spacing-page);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero__logo {
  width: clamp(280px, 36vw, 512px);
  height: auto;
}

.hero__monogram {
  position: absolute;
  right: clamp(60px, 12vw, 200px);
  top: 50%;
  transform: translateY(-50%);
  width: clamp(120px, 17vw, 248px);
  height: auto;
}

.hero__strapline {
  position: absolute;
  bottom: var(--spacing-page);
  left: var(--spacing-page);
  font-size: clamp(10px, 1.1vw, 14px);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  color: var(--color-white);
  letter-spacing: 0.05em;
  line-height: 1.3;
  max-width: 130px;
}

/* ═══════════════════════════════════════════
   STICKY NAV
   ═══════════════════════════════════════════ */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-white);
}

.nav__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 24px var(--spacing-page);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__logo {
  width: 80px;
  height: auto;
}

.nav__monogram {
  width: 36px;
  height: auto;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.nav__actions {
  display: flex;
  gap: 12px;
}

.nav__contact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border: 1.5px solid var(--color-black);
  border-radius: 30px;
  font-size: 14px;
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-tighter);
  transition: background 0.2s ease, color 0.2s ease;
}

.nav__contact:hover {
  background: var(--color-black);
  color: var(--color-white);
}

/* ═══════════════════════════════════════════
   ABOUT / BODY TEXT
   ═══════════════════════════════════════════ */
.about {
  padding: 120px var(--spacing-page) 160px;
}

.about__inner {
  max-width: 1245px;
}

.about__text {
  font-size: clamp(24px, 3.3vw, 48px);
  text-transform: uppercase;
  letter-spacing: var(--tracking-tight);
  line-height: 1.05;
}

.about__text + .about__text {
  margin-top: 1.2em;
}

/* ═══════════════════════════════════════════
   MAP SECTION
   ═══════════════════════════════════════════ */
.map-section {
  background: var(--color-dark);
  padding: 80px var(--spacing-page) 100px;
  position: relative;
}

.map-section__heading {
  font-size: clamp(24px, 3.3vw, 48px);
  text-transform: uppercase;
  color: var(--color-white);
  letter-spacing: var(--tracking-tight);
  line-height: 1;
  margin-bottom: 60px;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
}

.map-section__layout {
  display: flex;
  gap: 60px;
  align-items: flex-start;
  max-width: var(--max-width);
  margin: 0 auto;
}

.map-section__container {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  aspect-ratio: 1358 / 693;
}

.map-section__map-frame {
  position: relative;
}

.map-section__canvas {
  width: 100%;
  height: auto;
  display: block;
}

/* Map pins */
.map-pin {
  position: absolute;
  transform: translate(-50%, -50%);
  cursor: pointer;
  z-index: 2;
}

.map-pin__dot {
  display: block;
  width: 14px;
  height: 14px;
  background: var(--color-white);
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.map-pin:hover .map-pin__dot,
.map-pin--active .map-pin__dot {
  background: var(--color-orange);
  transform: scale(1.3);
  box-shadow: 0 0 12px rgba(254, 60, 0, 0.5);
}

.map-pin__tooltip {
  position: absolute;
  bottom: calc(100% + 16px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-white);
  color: var(--color-black);
  padding: 20px 24px;
  border-radius: 4px;
  font-size: 13px;
  line-height: 1.4;
  text-transform: none;
  white-space: normal;
  width: 260px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  transform: translateX(-50%) translateY(4px);
}

.map-pin__tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: var(--color-white);
}

.map-pin:hover .map-pin__tooltip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.map-pin__name {
  font-size: 18px;
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-tight);
  line-height: 1.1;
  margin-bottom: 4px;
}

.map-pin__region {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--color-gray);
  margin-bottom: 12px;
}

.map-pin__desc {
  font-size: 12px;
  font-weight: 400;
  line-height: 1.5;
  color: #333;
}

/* ═══════════════════════════════════════════
   AGENCY DIRECTORY
   ═══════════════════════════════════════════ */
.map-section__directory {
  flex: 0 0 320px;
  align-self: stretch;
}

.directory {
  list-style: none;
}

.directory__entry {
  padding: 20px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.directory__entry:first-child {
  padding-top: 0;
}

.directory__link {
  display: block;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: var(--tracking-tight);
  color: var(--color-white);
  line-height: 1.1;
  transition: color 0.2s ease;
}

.directory__link:hover {
  color: var(--color-orange);
}

.directory__region {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--color-gray);
  margin-top: 4px;
}

/* ═══════════════════════════════════════════
   LOGO CAROUSEL
   ═══════════════════════════════════════════ */
.logos {
  padding: 80px var(--spacing-page) 80px;
  overflow: hidden;
}

.logos__heading {
  font-size: clamp(24px, 3.3vw, 48px);
  text-transform: uppercase;
  letter-spacing: var(--tracking-tight);
  line-height: 1;
  margin-bottom: 60px;
}

.logos__marquee {
  overflow: hidden;
  width: 100vw;
  margin-left: calc(-1 * var(--spacing-page));
}

.logos__track {
  display: flex;
  align-items: center;
  animation: marquee 40s linear infinite;
  width: max-content;
}

.logos__item {
  width: auto;
  height: auto;
  max-height: var(--logo-h, clamp(26px, 2.8vw, 38px));
  max-width: var(--logo-w, clamp(80px, 9vw, 120px));
  object-fit: contain;
  flex-shrink: 0;
  margin-right: 56px;
  filter: grayscale(1) contrast(2);
}

/* Per-logo optical balancing — wide logos shrink, icon logos grow.
   Tuned by aspect ratio so visual weight reads consistent. */
.logos__item[alt="Samsung"]    { --logo-h: clamp(18px, 1.8vw, 24px); --logo-w: clamp(90px, 9vw, 118px); }
.logos__item[alt="Polestar"]   { --logo-h: clamp(20px, 2vw, 28px);   --logo-w: clamp(72px, 7.2vw, 100px); }
.logos__item[alt="Logitech"]   { --logo-h: clamp(20px, 2vw, 28px);   --logo-w: clamp(64px, 6.4vw, 90px); }
.logos__item[alt="Popeyes"]    { --logo-h: clamp(14px, 1.4vw, 20px); --logo-w: clamp(88px, 8.8vw, 120px); }
.logos__item[alt="Apple"]      { --logo-h: clamp(34px, 3.6vw, 48px); }
.logos__item[alt="PlayStation"]{ --logo-h: clamp(28px, 3vw, 40px); }
.logos__item[alt="Bacardi"]    { --logo-h: clamp(28px, 3vw, 40px); }

@keyframes marquee {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* ═══════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════ */
.footer {
  background: var(--color-dark);
  color: var(--color-white);
  padding: 120px var(--spacing-page) 40px;
}

.footer__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  min-height: 60vh;
  justify-content: space-between;
}

.footer__line {
  font-size: clamp(24px, 3.5vw, 48px);
  text-transform: uppercase;
  letter-spacing: var(--tracking-tight);
  line-height: 1.2;
}

.footer__link {
  transition: color 0.2s ease;
}

.footer__link:hover {
  color: var(--color-orange);
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding-top: 40px;
}

.footer__legal,
.footer__copyright {
  font-size: clamp(10px, 1vw, 14px);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--color-gray);
}

/* ═══════════════════════════════════════════
   RESPONSIVE — TABLET (768px)
   ═══════════════════════════════════════════ */
@media (max-width: 768px) {
  :root {
    --spacing-page: 24px;
  }

  .hero__photo--2,
  .hero__photo--3 {
    display: none;
  }

  .hero__photo--1 {
    flex: 1;
  }

  .hero__monogram {
    right: 24px;
    width: 100px;
  }

  .about {
    padding: 80px var(--spacing-page) 100px;
  }

  .map-section__layout {
    flex-direction: column;
    gap: 40px;
    align-items: stretch;
  }

  .map-section__directory {
    flex: none;
  }

  .map-section__container {
    overflow: hidden;
    aspect-ratio: auto;
    min-height: 280px;
  }

  .map-section__map-frame {
    position: relative;
    width: 170%;
    left: 50%;
    transform: translateX(-50%);
    aspect-ratio: 1358 / 693;
  }

  .map-section__canvas {
    width: 100%;
    height: auto;
  }

  .map-pin__dot {
    width: 16px;
    height: 16px;
  }

  .logos__item {
    margin-right: 32px;
  }

  .footer {
    padding: 80px var(--spacing-page) 24px;
  }

  .footer__bottom {
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
  }
}

/* ═══════════════════════════════════════════
   RESPONSIVE — MOBILE (375px)
   ═══════════════════════════════════════════ */
@media (max-width: 480px) {
  :root {
    --spacing-page: 16px;
  }

  .hero {
    min-height: 500px;
  }

  .hero__logo {
    width: 200px;
  }

  .hero__monogram {
    width: 70px;
    right: 16px;
  }

  .nav__inner {
    padding: 16px var(--spacing-page);
  }

  .nav__logo {
    width: 60px;
  }

  .nav__monogram {
    width: 24px;
  }

  .nav__contact {
    padding: 8px 16px;
    font-size: 12px;
  }

  .about {
    padding: 60px var(--spacing-page) 80px;
  }

  .map-section {
    padding: 48px var(--spacing-page) 60px;
  }

  .map-section__heading {
    margin-bottom: 32px;
  }

  .logos {
    padding: 48px var(--spacing-page);
  }

  .logos__heading {
    margin-bottom: 32px;
  }

  .map-pin__dot {
    width: 18px;
    height: 18px;
  }

  .directory__entry {
    padding: 16px 0;
  }

  .directory__link {
    font-size: 16px;
  }

  .footer__inner {
    min-height: 50vh;
  }
}
