html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    background: #0a0a0a;
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

/* Full-viewport flexbox that shrinks content when needed */
.wrapper {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.container {
    background: rgba(255, 255, 255, 0.97);
    padding: 40px 30px;
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.4);
    text-align: center;
    width: 100%;
    max-width: 520px;
    
    /* This is the magic: shrink-to-fit on small screens */
    max-height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.logo {
    max-width: 100%;
    height: auto;
    max-height: 40vh;          /* Prevents the Capitol image from pushing content off-screen */
    object-fit: contain;
    margin-bottom: 24px;
}

.tagline {
    font-size: clamp(16px, 2.8vw, 20px);
    line-height: 1.5;
    color: #222;
    margin: 0 0 32px 0;
    padding: 0 10px;
}

.email-form {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: auto;
}

.email-form input {
    padding: 14px 16px;
    font-size: 16px;
    border: 1px solid #999;
    border-radius: 8px;
    flex: 1;
    min-width: 220px;
}

.email-form button {
    padding: 14px 28px;
    font-size: 16px;
    background: #c41e3a;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    white-space: nowrap;
}

.email-form button:hover {
    background: #a0172e;
}

/* Mobile fine-tuning */
@media (max-height: 680px) {
    .container { padding: 24px 20px; }
    .logo { max-height: 30vh; margin-bottom: 16px; }
    .tagline { margin-bottom: 20px; font-size: 16px; }
}