/* Base reset / improvements */
* {
    box-sizing: border-box;
}

body { 
    min-height: 100vh;
    margin: 0;
    background: linear-gradient(135deg, #1e1e2f, #2c2c3e);
    font-family: Arial, sans-serif;
    color: #eee;

    /* Vertical + horizontal centering */
    display: flex;
    align-items: center;
    justify-content: center;

    padding: 20px; /* Prevent edge-clipping on mobile */
}

/* Container */
.container {
    width: 100%;
    max-width: 420px;
    padding: 24px;
    background: #181826;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
    text-align: center;
}

/* Headings */
h1, h2, h3 {
    margin-bottom: 12px;
    line-height: 1.2;
}

/* Inputs */
input {
    width: 100%;
    padding: 12px;
    margin: 8px 0;
    border-radius: 5px;
    border: none;
    font-size: 16px; /* Prevent iOS zoom on focus */
}

/* Buttons */
.btn {
    display: block; /* Full-width buttons on mobile */
    width: 100%;
    margin-top: 12px;
    padding: 12px;
    background: #c89b3c;
    color: #000;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    text-align: center;
    cursor: pointer;
}

/* Button variants */
.btn.secondary { 
    background: #888; 
    color: #000;
}

.btn.danger { 
    background: #b33; 
    color: #fff; 
}

/* Messages */
.error,
.success {
    padding: 10px;
    margin-bottom: 12px;
    border-radius: 5px;
    font-size: 14px;
}

.error {
    background: #b33;
}

.success {
    background: #26be00;
}

/* Desktop tweaks */
@media (min-width: 768px) {
    .btn {
        display: inline-block;
        width: auto;
        padding: 10px 20px;
    }

    .container {
        padding: 30px;
    }
}

/* Mobile-first, extra-large for high-res phones */
@media (max-width: 1080px) {
    body {
        font-size: 20px; /* bigger base font */
    }

    h1 {
        font-size: 2.8rem; /* really big headings */
    }

    h2 {
        font-size: 2.4rem;
    }

    h3 {
        font-size: 1.8rem;
    }

    p {
        font-size: 1.4rem;
        line-height: 1.6;
    }

    input {
        font-size: 1.4rem;
        padding: 18px; /* easier to tap */
        border-radius: 8px;
    }

    .btn {
        font-size: 1.4rem;
        padding: 18px 24px; /* bigger buttons */
        border-radius: 8px;
    }

    .container {
        max-width: 650px; /* landscape width utilization */
        margin: 40px auto;
        padding: 35px;
    }
}

/* Extra landscape adjustments for large phones */
@media (max-height: 600px) {
    .container {
        margin-top: 20px;
        padding: 30px;
    }

    input, .btn {
        font-size: 1.5rem;
        padding: 20px;
    }

    h1 {
        font-size: 3rem;
    }

    h2 {
        font-size: 2.6rem;
    }

    h3 {
        font-size: 2rem;
    }
}
