/*
 * Shared styles for codadLabs.art.
 * Structural only. Visual identity comes in a later pass.
 */

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, sans-serif;
  line-height: 1.6;
  color: #222;
  background: #fafafa;
}

header,
main,
footer {
  max-width: 760px;
  margin: 0 auto;
  padding: 16px;
}

header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.logo img {
  display: block;
  width: 64px;
  height: 64px;
}

nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

nav a[aria-current="page"],
nav details.current summary {
  font-weight: 600;
}

nav details {
  position: relative;
}

nav summary {
  cursor: pointer;
  list-style: none;
}

nav summary::-webkit-details-marker {
  display: none;
}

nav summary::after {
  content: " \25BE";
}

nav details ul {
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 1;
  flex-direction: column;
  gap: 8px;
  padding: 12px 16px;
  white-space: nowrap;
  background: #fafafa;
  border: 1px solid #ddd;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0;
}

.actions a {
  padding: 10px 20px;
  border: 1px solid currentColor;
  border-radius: 999px;
  text-decoration: none;
}

.placeholder {
  padding: 4px 8px;
  background: #fff3c4;
}

img,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

main img,
main video {
  margin: 24px 0;
}

main video {
  background: #ddd;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}

.gallery figure {
  margin: 0;
  aspect-ratio: 4 / 3;
  background: #ddd;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #666;
}

footer {
  margin-top: 48px;
  font-size: 14px;
  color: #666;
}
