/* OPTION A – nav width auto-adjusts to title size (plus padding) */

body {
    margin: 0;
    padding: 0px 0 0 0px;           /* keep your 2px top/left padding */
    font-family: Helvetica, sans-serif;
    background: #000;               /* CHANGED: black page background */
    color: #ffffff;                    /* NEW: default light text on dark bg */
}

.floating-nav {
    position: fixed;
    top: 1px;                       
    left: 1px;                      
    background: rgba(0, 0, 0, 0.1);
    padding: 10px 40px 0px 20px;   /* top right bottom left */
    box-sizing: content-box;        /* width = content only, padding added */
    z-index: 1000;
    width: fit-content;             /* shrink-wrap to content */
    display: inline-block;          /* required for shrink-wrap */
    max-width: calc(100vw - 2px);   /* ensure it never overflows viewport */
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    animation: fadeIn 2s ease-out;
    border-radius: 5px;            
    overflow: hidden;               
    color: #ffffff; 
}

.site-title {
    font-family: Arial Black, sans-serif;
    font-size: 72px;
    font-stretch: condensed;
    transform: scaleY(0.6);
    font-weight: bold;
    margin-top: -20px;
    margin-bottom: -40px;
    color: #ffffff;
    white-space: nowrap;            /* ensures title defines nav width */
}

@media (max-width: 1024px) {
    .site-title {
        font-size: 56px;
    }
     .floating-nav ul li a {
        font-size: 20px;
    }
}

/* Small tablets / large phones */
@media (max-width: 768px) {
    .site-title {
        font-size: 42px;
    }
    .floating-nav ul li a {
        font-size: 18px;
    }
}

/* Phones */
@media (max-width: 480px) {
    .site-title {
        font-size: 25px;
        margin-bottom: -20px;
        margin-top: -10px;
    }
}

.floating-nav ul {
    list-style: none;
    padding: 0;
    max-width: 100%;                /* don’t exceed nav width */
}

.floating-nav ul li a {
    font-family: Helvetica;
    font-weight: bold;
    text-decoration: none;
    transform: scaleY(0.6);
    display: block;
    margin-top: -7px;
    padding: 3px 0;
    color: #ffffff;
    transition: color 0.3s ease;
    font-size: 24px;                /* ADDED: control link size */
}

.floating-nav ul li a:hover { color: #888; }

/* Dropdown Base */
.dropdown { position: relative; }
.dropdown > a { cursor: pointer; }

/* Animated Dropdown (no CSS variables) */
/* Collapsed */
.dropdown-menu {
  list-style: none;
  margin: 0;
  padding-left: 10px;
  overflow: hidden;
  max-height: 0;                 
  opacity: 0;
  transform: translateY(-5px);
  position: relative;
  transition: max-height 500ms ease, opacity 200ms ease, transform 200ms ease;
  will-change: max-height, opacity, transform;
}

/* Open state (desktop hover + touch .show) */
.dropdown:hover .dropdown-menu,
.dropdown-menu.show {
  opacity: 1;
  transform: translateY(0);
}

/* Hover height cap for desktop (adjust as needed) */
.dropdown:hover .dropdown-menu {
  max-height: 600px;             
}

/* --- BIGGER GRID: max 2 columns, stacks downward --- */
.grid-container {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr)); 
    gap: 10px;
    padding: 0px 0px 0px; 
    grid-auto-flow: row;
}

.grid-container img {
    width: 100%;
    height: auto;
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px);
    transition: transform 0.4s ease, opacity 0.4s ease;
}

.grid-container img.loaded {
    opacity: 1;
    transform: translateY(0);
}

.grid-container img:hover {
    transform: scale(0.980); 
}

.project-detail {
    padding: 0px 0px 0px 0PX; 
    color: #eee;
}

.project-detail img, 
.project-detail video {
    max-width: 100%;
    display: block;
    margin-bottom: 0px;
    opacity: 0;
    transform: translateY(20px);
    transition: transform 0.4s ease, opacity 0.4s ease;
}

.project-detail img.loaded,
.project-detail video.loaded {
    opacity: 1;
    transform: translateY(0);
}

.project-detail .description {
    font-size: 16px;
    line-height: 1.5;
    margin-top: 20px;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive: switch to 1 column when space is tight */
@media (max-width: 1200px) {
    .grid-container {
        grid-template-columns: 1fr;
    }
}
