* {
  box-sizing: border-box;
}

body {
  min-height: 75vh;
  margin: 0;
  padding: 1rem;
  background-color: lightblue;
  color: black;
  font-family: system-ui, -apple-system, sans-serif;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.grid {
  width: 100%;
  max-width: 1200px;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding: 1rem 0;
}

/* Navigation - exact col-4 replica */
.nav-row {
  display: flex;
  flex-wrap: wrap;
}

.nav-spacer {
  flex: 1 1 33%;  /* Left/Right col-4 */
  min-width: 100px;
}

.nav-center {
  flex: 1 1 33%;  /* Middle col-4 */
  display: flex;
  justify-content: center;
  gap: 1rem;
  padding: 0.5rem;
}

.nav-center img {
  width: auto;  /* Original PNG size - no scaling */
  height: auto;
}

/* App icons grid */
.app-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

.item {
  padding: 0.75rem;
  text-align: center;
  flex: 1 1 150px; /* 3-col on wide screens */
  max-width: 200px;
}

.item img {
  display: block;
  margin: 0 auto 0.5rem;
  width: 64px;
  height: 64px;
}

.item-text {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 500;
}

/* Tablet (iPad portrait ~768px+) */
@media (min-width: 768px) {
  .item {
    flex: 1 1 180px;
  }
  .nav-center {
    gap: 1.5rem;
  }
}

/* Desktop (1024px+) */
@media (min-width: 1024px) {
  body {
    padding: 2rem;
  }
  .nav-row {
    gap: 0;
  }
  .item {
    flex: 1 1 160px;
  }
}

/* iPhone landscape tweak */
@media (max-width: 480px) {
  .item {
    flex: 1 1 100px;  /* 3-col on iPhone - tighter fit */
    max-width: 130px;
    padding: 0.5rem;  /* Less padding */
  }
  .nav-center {
    flex-direction: row;
    gap: 0.5rem;
  }
  .nav-center img {
    width: 48px;
    height: auto;
  }
}
