/* Settings Page Styles */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: Verdana, sans-serif;
    background-color: #eeeeee;
    min-height: 100vh;
    min-height: 100dvh;
    overflow: hidden;
    /* Prevent scrolling - content should fit */
}

/* Back Button - Circular Style */
.back {
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 1000;
}

.back a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 60px;
    height: 60px;
    background-color: #4285f4;
    border-radius: 50%;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.1s ease;
    text-decoration: none;
}

.back a:active {
    transform: scale(0.95);
}

.backbtn {
    width: 50%;
    height: 50%;
    filter: brightness(0) invert(1);
}

/* Main Container */
.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    height: 100dvh;
    position: relative;
    padding: 2rem;
}

h1 {
    color: #333;
    margin-bottom: 30px;
    text-align: center;
}

/* Settings Buttons Container */
.buttons {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

/* Button Styling - Pill Shape */
button,
select {
    margin: 0;
    padding: 0.8rem 2.2rem;
    border: none !important;
    border-radius: 50px !important;
    color: white;
    font-family: Verdana, sans-serif;
    font-size: 1rem;
    cursor: pointer;
    transition: transform 0.1s ease, background-color 0.3s;
    min-width: 12rem;
    max-width: 90%;
    background-color: #4285f4 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

button:active,
select:active {
    transform: scale(0.98);
}

button:hover,
select:hover {
    background-color: #3367d6;
}

select {
    appearance: none;
    -webkit-appearance: none;
    text-align: center;
    padding-right: 35px;
}

#modoToggleBtn {
    background-color: #28a745;
}

#modoToggleBtn:hover {
    background-color: #218838;
}

/* Version Indicator */
.version-info {
    position: fixed;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    color: #999;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

/* === LANDSCAPE MODE === */
@media (orientation: landscape) {
    .container {
        padding: 1rem 2rem;
    }

    h1 {
        font-size: 1.5rem;
        margin-bottom: 15px;
    }

    .buttons {
        flex-direction: row;
        gap: 20px;
        margin-top: 10px;
    }

    button,
    select {
        padding: 0.6rem 1.5rem;
        font-size: 0.9rem;
        min-width: 10rem;
    }

    .back a {
        width: 50px;
        height: 50px;
    }

    .version-info {
        bottom: 10px;
        font-size: 0.75rem;
    }
}

/* Small landscape screens */
@media (orientation: landscape) and (max-height: 500px) {
    h1 {
        font-size: 1.2rem;
        margin-bottom: 10px;
    }

    button,
    select {
        padding: 0.5rem 1.2rem;
        font-size: 0.85rem;
        min-width: 8rem;
    }

    .buttons {
        gap: 15px;
        margin-top: 5px;
    }

    .back {
        top: 10px;
        left: 10px;
    }

    .back a {
        width: 40px;
        height: 40px;
    }
}

/* Very small landscape screens */
@media (orientation: landscape) and (max-height: 400px) {
    h1 {
        font-size: 1rem;
        margin-bottom: 8px;
    }

    button,
    select {
        padding: 0.4rem 1rem;
        font-size: 0.8rem;
        min-width: 6rem;
    }

    .version-info {
        bottom: 5px;
        font-size: 0.7rem;
    }
}

/* Tablet Scaling (iPad / Tablets) */
@media (min-width: 768px) and (orientation: portrait) {
    h1 {
        font-size: 2.5rem;
        margin-bottom: 3rem;
    }

    button,
    select {
        padding: 1rem 3rem;
        font-size: 1.2rem;
        min-width: 16rem;
    }

    .container {
        padding: 4rem;
    }
}

/* Large Screens (iPad Pro / Desktop) */
@media (min-width: 1200px) {
    h1 {
        font-size: 4rem;
        margin-bottom: 4rem;
    }

    button,
    select {
        padding: 1.5rem 4rem;
        font-size: 1.8rem;
        min-width: 24rem;
        border-radius: 60px !important;
    }

    .back {
        top: 30px;
        left: 30px;
    }

    .back a {
        width: 80px;
        height: 80px;
    }
}