/* Corpo e estilo básico */
body, html {
    margin: 0;
    padding: 0;
    font-family: 'Nunito', sans-serif;
    color: #3e4e3f;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-size: cover;
    background-repeat: no-repeat;
    transition: background-image 0.3s ease;
}

/* Fundo para desktop */
@media (min-width: 768px) {
    body {
        background-image: url('images/green-leaves-horizontal.jpg');
    }
}

/* Fundo para mobile */
@media (max-width: 767px) {
    body {
        background-image: url('images/green-leaves-vertical.jpg');
    }
}

@font-face {
    font-family: 'Burgues Script';
    src: url('./Burgues Script W00 Regular.ttf') format('opentype');
}

/* Estilos principais da caixa */
.container {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    padding: 30px;
    max-width: 500px;
    width: 100%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border: 1px solid #d9d9d9;
    text-align: justify;
    margin: 2em 0; /* Adicione margem para espaçar o contêiner das bordas da tela */
}

/* Estilos do cabeçalho (nomes e data) */
.header {
    text-align: center;
    padding-top: 50px;
}

.header h1 {
    font-family: 'Burgues Script', cursive;
    font-size: 4.5em;
    color: #567d66;
    margin: 0;
    font-weight: 500;
    line-height: 0.8; /* Ajuste o valor conforme necessário */
}

.header h2 {
    font-family: 'Poiret One', sans-serif;
    font-size: 1.5em;
    color: #8b9c8e;
    margin-top: 1em;
    margin-bottom: 1.5em;
    font-weight: 500;
}

/* Estilos do título e descrição */
h3 {
    font-size: 1.8em;
    color: #567d66;
    margin-top: 0;
    margin-bottom: 20px;
    text-align: center;
}

p {
    font-size: 1.1em;
    margin: 10px 0 20px;
}

/* Input de nome e contêiner */
.input-container {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    gap: 10px;
}

label {
    font-size: 1em;
    color: #567d66;
    margin-bottom: 5px;
}

input[type="text"] {
    padding: 10px;
    border: 1px solid #d1d1d1;
    border-radius: 4px;
    font-size: 1em;
    outline: none;
    flex-grow: 1;
    transition: border 0.3s ease;
}

input[type="text"]:focus {
    border-color: #9fb59b;
    box-shadow: 0 0 8px rgba(89, 143, 105, 0.2);
}

/* Botão para remover convidado */
.remove-btn {
    padding: 8px;
    background-color: #dcdcdc;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 0.9em;
    cursor: pointer;
    flex: 0 0 10%; /* Ocupa 10% da largura da linha */
    margin-top: 0;
    transition: background-color 0.3s ease, transform 0.1s ease;
}

.remove-btn:hover {
    background-color: #c7c7c7;
    transform: scale(1.1);
}

/* Estilo dos botões */
button {
    padding: 10px;
    width: 100%;
    font-size: 1em;
    font-weight: bold;
    border: none;
    border-radius: 4px;
    margin-top: 10px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.1s ease;
}

/* Botão adicionar convidado */
.add-guest-btn {
    color: #3e4e3f;
    background-color: #dcdcdc;
}

.add-guest-btn:hover {
    background-color: #c7c7c7;
    transform: scale(1.02);
}

/* Botão confirmar presença */
.confirm-btn {
    color: white;
    background-color: #89ab98;
}

.confirm-btn:hover {
    background-color: #709b81;
    transform: scale(1.02);
}
/* Estilos do Modal */
.modal {
    display: none; /* Escondido por padrão */
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Fundo semitransparente */
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease; /* Animação de entrada */
}

.modal-content {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    width: 80%;
    max-width: 400px;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    animation: scaleUp 0.3s ease; /* Efeito de ampliação */
}

/* Botão de Fechar */
.close-btn {
    color: #aaaaaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    margin-top: -10px;
    margin-right: -10px;
}

.close-btn:hover {
    color: #000;
}

/* Animações */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scaleUp {
    from { transform: scale(0.7); }
    to { transform: scale(1); }
}

/* Estilo do ícone no modal */
.icon {
    font-size: 2em;
    margin-right: 10px;
    display: inline-block;
    vertical-align: middle;
}

/* Cores para cada tipo de mensagem */
.icon.success {
    color: #89ab98;
}

.icon.error {
    color: #89ab98;
}

.icon.alert {
    color: #89ab98;
}

.loading-spinner {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2;
    font-size: 1.5em;
    color: #567d66;
}

.spinner {
    border: 5px solid rgba(89, 143, 105, 0.2);
    border-top: 5px solid #89ab98;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}


/* Adicione esta regra ao seu CSS para garantir que o box-sizing seja aplicado */
* {
    box-sizing: border-box; /* Inclui padding e border na largura e altura total dos elementos */
}

/* Responsividade */
@media (max-width: 600px) {
    .header h1 {
        font-size: 3em; /* Aumente o tamanho da fonte */
    }

    .header h2 {
        font-size: 1.2em; /* Ajuste o tamanho do h2 se necessário */
    }

    .container {
        padding: 20px; /* Ajuste o padding para criar espaço interno */
        margin: 10px; /* Adicione margem para espaçar o contêiner das bordas da tela */
        width: calc(100% - 20px); /* Garante que o contêiner não ultrapasse a largura da tela */
    }

    h3 {
        font-size: 1.6em;
    }

    p {
        font-size: 1em;
    }
}