* {
    box-sizing: border-box;
    padding: 0;
    margin: 0;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: linear-gradient(to bottom, #e8f5e9, #fdfdfd);
    font-family: 'Segoe UI', Arial, sans-serif;
    color: #2e2e2e;
}

header {
    margin-top: 2rem;
    text-align: center;
}

header h1 {
    font-size: 2.5rem;
    color: #1b5e20;
    margin-bottom: 0.5rem;
}

header p {
    font-size: 1rem;
    color: #555;
}

.teclado {
    margin-top: 3rem;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    width: 95vw;  /* largura máxima do container */
}

.tecla {
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    flex: 1;               /* faz todas as teclas ocuparem proporcionalmente o espaço disponível */
    max-width: 140px;      /* opcional: evita que fiquem enormes em telas grandes */
    height: 220px;
    border: 2px solid #ccc;
    border-radius: 1.5rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: transform 0.2s, box-shadow 0.2s;
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.tecla img {
    width: 100%;
    height: 70%;
    object-fit: cover;
    border-top-left-radius: 1.5rem;
    border-top-right-radius: 1.5rem;
    display: block;
}

.tecla p {
    margin: 0;
    padding: 0.6rem 0;
    font-size: 1.1rem;
    font-weight: bold;
    color: #2e2e2e;
    background: #f5f5f5;
    width: 100%;
    text-align: center;
    border-bottom-left-radius: 1.5rem;
    border-bottom-right-radius: 1.5rem;
}

.tecla:hover {
    transform: translateY(-6px) scale(1.05);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    border-color: #66bb6a;  /* verde natural */
}

.tecla:active {
    transform: scale(0.98);
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}
