/* Paleta de cores: preto, cinza escuro e branco */
:root {
    --black: #000000;
    --dark-gray: #333333;
    --white: #FFFFFF;
}

/* Reset básico */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: monospace;
}

body {
    background-image: url('background.png'); /* background full screen */
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover; /* cobre toda a tela mantendo proporção */
    background-attachment: fixed;
    color: var(--black);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: 100vw;
    animation: fadeIn 1s ease-in;
}

header {
    text-align: center;
    padding: 1.5rem;
    background-color: var(--dark-gray);
    color: var(--white);
    width: 100%;
}

header .logo {
    max-width: 300px;
    margin-bottom: 1rem;
    animation: fadeIn 2s ease-in;
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 1rem;
    width: 100%; /* ocupa toda largura */
    min-height: calc(100vh - 160px); /* considerando header + footer */
    background-color: rgba(255, 255, 255, 0.85);
}

button {
    padding: 1.0rem 2.7rem;
    font-size: 1.7rem;
    cursor: pointer;
    border: none;
    border-radius: 50px;
    background-color: var(--black);
    color: var(--white);
    transition: all 0.3s ease;
}

button:hover {
    background-color: var(--dark-gray);
    transform: scale(1.05);
}

pre {
    text-align: center;
    white-space: pre-wrap; /* permite quebrar linhas ao centralizar */
    background-color: var(--dark-gray);
    color: var(--white);

    /* Valores padrão (desktop) */
    padding: 1rem;
    border-radius: 15px;
    width: 30%;
    max-width: 50%;

    font-size: 1.7rem;
    line-height: 1;

    overflow-x: auto;
    transition: background-color 0.3s;
}

/* MOBILE ATÉ 768px — valores reduzidos */
@media (max-width: 768px) {
    pre {
        padding: 0.7rem;
        border-radius: 10px;

        width: 90%;      /* mantém largura total */
        max-width: 100%;  /* impede estourar a tela */
    }
}

/* DESKTOP — garante valores maiores */
@media (min-width: 769px) {
    pre {
        padding: 1rem;
        border-radius: 15px;

        width: 30%;
        max-width: 50%;
    }
}

pre:hover {
    background-color: #555555;
}

footer {
    text-align: center;
    padding: 1rem;
    background-color: var(--black);
    color: var(--white);
    width: 100%; /* ocupa toda largura */
}

/* Animação fade-in */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}