body {
    font-family: Verdana, Arial, sans-serif;
    max-width: 900px;
    margin: 20px auto;
    padding: 0 15px;
    line-height: 1.4;
    background: white;
    color: black;
}

#pmonth {
    margin-bottom: 1em; /* haha gay bottom */
    color:white;
    text-shadow: 3px 3px 3px #555;
    background-image: linear-gradient(to left, violet, indigo, blue, green, yellow, orange, red);

}

h1 {
    margin-bottom: 5px;
}

p {
    margin-top: 0;
    margin-bottom: 20px;
}

a {
    color: blue;
}

.version {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.85em;

  color: #374151;            
  background: #e5e7eb;       

  padding: 0.15em 0.4em;
  border-radius: 4px;
  border: 1px solid #cbd5e1; 

  letter-spacing: 0.02em;
  user-select: all;

  /* --- Multi-line Handling --- */
  white-space: normal;            /* Allows the text to naturally wrap */
  word-break: break-word;         /* Prevents long strings or hashes from breaking the layout */
  box-decoration-break: clone;    /* Applies padding/border/bg to each wrapped line line individually */
  -webkit-box-decoration-break: clone; /* Required for Safari support */
}

.tg {
    border-collapse: collapse;
    border-spacing: 0;
    margin: 0 auto 30px auto;
    display: table; /* important reset */
    width: auto;    /* remove fit-content behavior */
}

.tg {
    width: fit-content;
    max-width: 100%;
}

.tg td,
.tg th {
    border: 1px solid black;
    font-family: Arial, sans-serif;
    font-size: 14px;
    padding: 10px 8px;
    text-align: left;
    vertical-align: top;
}

.carousel h2 {
    text-align: center;
    margin-bottom: 10px;
}

.carousel {
    padding: 10px;
    background: white;
}

.image-container {
    text-align: center;
}

.image-link {
    display: inline-block;
}

.carousel-image {
    display: block;
    max-width: 100%;
    max-height: 500px;
    object-fit: contain;
    cursor: pointer;
}

.caption {
    text-align: center;
    margin-top: 10px;
    min-height: 20px;
    font-size: 14px;
}

.counter {
    text-align: center;
    margin-top: 5px;
    font-size: 13px;
}

.controls {
    text-align: center;
    margin-top: 10px;
}

.controls button {
    font-family: inherit;
    font-size: 14px;
    padding: 4px 12px;
    margin: 0 5px;
    cursor: pointer;
}

.hint {
    text-align: center;
    font-size: 12px;
    color: #555;
    margin-top: 8px;
}

@media (max-width: 768px) {

    body {
        max-width: 100%;
        margin: 10px;
        padding: 0 10px;
        line-height: 1.5;
    }

    h1 {
        font-size: 1.6rem;
        text-align: center;
    }

    #pmonth {
        font-size: 1.4rem;
        text-align: center;
        padding: 10px;
        background-image: linear-gradient(
            to right,
            violet, indigo, blue, green, yellow, orange, red
        );
    }

    p {
        font-size: 0.95rem;
    }

    .tg {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .tg td,
    .tg th {
        font-size: 13px;
        padding: 8px;
        white-space: nowrap;
    }

    .carousel {
        padding: 8px;
    }

    .carousel-image {
        max-height: 300px;
    }

    .controls button {
        width: 45%;
        font-size: 16px;
        padding: 8px 0;
    }

    .caption {
        font-size: 13px;
    }

    .counter {
        font-size: 12px;
    }

    .version {
        font-size: 0.75em;
    }
}

/* Extra small phones */
@media (max-width: 420px) {

    h1 {
        font-size: 1.3rem;
    }

    #pmonth {
        font-size: 1.2rem;
    }

    .controls {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .controls button {
        width: 100%;
    }

    .carousel-image {
        max-height: 220px;
    }
}