:root {
    background-color: black;
    color: rgb(204, 204, 204);
    font-kerning: auto;
    font-size: 13px;
    line-height: 1.05;
}

body {
    padding: 0;
    margin: 20px 10px 10px 10px;
    overflow-x: hidden;
    scroll-behavior: smooth;
    align-content: baseline;
}

a {
    text-decoration: underline;
    text-decoration-thickness: 1.5px;
    color: inherit;
    cursor: pointer;
}

a:hover,
button:hover {
    color: blue;
}

.name a {
    text-decoration: none;
}

ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

P {
    padding: 0;
    margin: 0;
}

header {
    position: fixed;
    top: 0;
    left: 0;
    padding: 10px 10px 0px 10px;
    width: -webkit-fill-available;
}

nav {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 10px;
}

nav span:nth-child(1) {
    grid-column: 1 / span 5;   /* columns 1–4 */
}

nav span:nth-child(2) {
    grid-column: 6 / span 3;   /* columns 5–7 */
}

nav span:nth-child(3) {
    grid-column: 9 / span 3;   /* columns 8–10 */
}

nav span:nth-child(4) {
    grid-column: 12 / span 1;  /* columns 11–12 */
    text-align: left;
}

footer nav span:nth-child(2) {
    grid-column: 6 / span 7;
}

.about {
    font-size: 24px;
    padding-top: 5px;
}

aside {
    position: absolute;
    right: 5px;
    text-align: center;
    writing-mode: vertical-rl;
    text-orientation: upright;
    letter-spacing: -0.25em;
}

.landing {
    display: flex;
    flex-direction: column;
    height: 80vh;
    padding-bottom: 10px;
}

.blue-rect {
  background: blue;
  max-width: 100%;
  height: 500px;
}

.place-visual {
    display: none;
    align-self: end;
}

#contact {
    font-size: 24px;
    display: none;
}

.copyright {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 10px;
}

.copyright p:nth-child(1) {
    grid-column: 1 / span 5;   /* columns 1–4 */
}

.copyright p:nth-child(2) {
    grid-column: 6 / span 5;   /* columns 1–4 */
}

.copyright button {
    grid-column: 12 / span 1;   /* columns 1–4 */
}

.project-nav {
    border-bottom: 0.5px solid white;
    padding-bottom: 3px;
}

#close {
    text-align: center;
}

button {
    all: unset;    
    cursor: pointer;
} 

aside button.active,
.places-word.active {
    color: blue;
}

.places-word {
    text-decoration: underline;
    text-decoration-thickness: 1.5px;
    color: inherit;
    cursor: pointer;
}

.project-info {
    height: 0;
    font-size: 16px;
    overflow: hidden;
    transition: height 500ms ease-in-out;
    padding-top: 3px;
}

.images,
.images img {
  user-select: none;
  -webkit-user-drag: none;
}

.images video {
  max-height: 500px;
  height: auto;
}

.places {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    padding-top: 3px;
    gap: 10px;
    flex: 1 1 auto;
    height: auto;
}

.places img {
    display: none;
    width: 100%;
    height: auto;
}

.places picture {
  display: contents; /* lets children behave like direct grid items */
}

/* first image: 4 columns, touches bottom */
#serra {
    grid-column: 1 / span 4;
    align-self: end; /* bottom */
}

/* second image: 4 columns, touches bottom, leaves 1 column gap */
#isia {
    grid-column: 6 / span 3; /* columns 6-9 */
    align-self: end;          /* bottom */
}

/* third image: 3 columns, touches top */
#ouieieee {
    grid-column: 10 / span 3; /* columns 10-12 */
    align-self: start;
}

/* fourth image: 3 columns, touches top */
#mut {
    grid-column: 10 / span 3; /* same as third image, can overlap */
    align-self: end;         
}

.images {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    padding-top: 10px;
    padding-bottom: 30px;
    cursor: grab;
    scrollbar-width: none;
    -ms-overflow-style: none;
    height: 500px;
}

.images:active {
  cursor: grabbing;
}

.images::-webkit-scrollbar {
    display: none;
}

.images img {
    height: 100%;
    width: auto;        /* 👈 width adapts */
    display: block;
}

figure {
    margin: 0;
}

.video-wrapper {
  height: 500px;
}

.video-wrapper iframe {
  height: 100%;
  aspect-ratio: 2.7 / 1;
  border: 0;
  pointer-events: none;
}

/* ---------- MOBILE ONLY LAYOUT ---------- */
.mobile-only {
  display: none;
}

@media (max-width: 768px) {
  /* Hide everything by default */
  main,
  .landing,
  .places,
  .images,
  footer,
  .projects,
  section,
  article {
    display: none !important;
  }

  /* Show header */
  header {
    display: block;
  }

  /* Show mobile message */
  .mobile-only {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
  }

.mobile-only h1 {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: clip;
    font-size: 13VW;
    line-height: 1.1;
    font-weight: normal;
    text-align: center;
    margin: 0;
    padding: 0;
}

  .mobile-only img {
    width: 100%;
    height: calc(100vh - 200px);
    object-fit: contain;
  }

    nav span:nth-child(1) {
        grid-column: 1 / span 5;
    }

    nav span:nth-child(2) {
        display: none;
    }

    nav span:nth-child(3) {
        grid-column: 6 / span 4;   /* columns 8–10 */
    }

    nav span:nth-child(4) {
        grid-column: 10 / span 3;  /* columns 11–12 */
    }

    nav {
        font-size: 9px;
    }
}