body {
    font-family: "Segoe UI", sans-serif;
    background: linear-gradient(120deg, #f7f8fc, #dce2f0);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    margin: 0;
}

h1, h2 {
    color: #333;
    text-align: center;
}

.form-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    width: 100%;
}

form {
    background-color: white;
    padding: 30px 40px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    width: 90%;
}

label {
    font-weight: 500;
    color: #444;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="submit"] {
    width: 100%;
    padding: 12px 16px;
    font-size: 16px;
    border-radius: 8px;
    box-sizing: border-box;
}

input[type="text"],
input[type="email"],
input[type="password"] {
    margin-top: 8px;
    margin-bottom: 20px;
    border: 1px solid #ccc;
}

input[type="submit"] {
    background-color: #4a90e2;
    color: white;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 10px;
}

input[type="submit"]:hover {
    background-color: #357bd8;
}

@media (max-width: 500px) {
    form {
        padding: 20px;
    }
}

.success-box {
    background-color: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    max-width: 900px;
    width: 90%;
    text-align: center;
    margin: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.table-container {
    margin-top: 30px;
    background-color: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    width: 100%;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    table-layout: fixed;
}

th, td {
    padding: 15px 20px;
    text-align: left;
    border-bottom: 1px solid #eef3fb;
    word-wrap: break-word;
}

th {
    background-color: #f7f8fc;
    color: #4a90e2;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 14px;
}

tr:nth-child(even) {
    background-color: #fcfdff;
}

tr:hover {
    background-color: #eef3fb;
    cursor: pointer;
}

.admin-create-button-container {
    margin-top: 20px;
    margin-bottom: 20px;
    width: 100%;
}

.admin-create-button-container form {
    max-width: 300px;
    margin: 0 auto;
    background: none;
    box-shadow: none;
    padding: 0;
}

.admin-create-button-container input[type="submit"] {
    width: 100%;
    padding: 12px 16px;
    font-size: 16px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    background-color: #4a90e2;
    color: white;
    transition: background-color 0.3s ease;
    margin-top: 0;
}

.admin-create-button-container input[type="submit"]:hover {
    background-color: #357bd8;
}

.rsvp-id {
    font-size: 24px;
    font-weight: bold;
    color: #4a90e2;
    margin: 20px 0;
    padding: 10px 20px;
    background-color: #eef3fb;
    border-radius: 8px;
    display: inline-block;
    letter-spacing: 1px;
}

.error-box {
    background-color: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    width: 90%;
    text-align: center;
}

.error-message {
    color: #e74c3c;
    font-size: 16px;
    margin: 20px 0;
    font-weight: 500;
}

.back-container {
    margin-top: 30px;
}

.back-link,
.admin-login-link a {
    display: inline-block;
    padding: 10px 16px;
    background-color: #eef3fb;
    border-radius: 8px;
    text-decoration: none;
    color: #4a90e2;
    font-weight: 500;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.back-link:hover,
.admin-login-link a:hover {
    background-color: #d8e5f8;
    color: #357bd8;
    text-decoration: underline;
}

.back-container .back-link {
    background-color: #e74c3c;
    color: white;
    font-weight: 500;
}

.back-container .back-link:hover {
    background-color: #c0392b;
    color: white;
    text-decoration: none;
}

.back-button {
    position: flex;
    top: 15px;
    left: 15px;
    background: none;
    border: none;
    font-size: 14px;
    cursor: pointer;
    color: #333;
    text-decoration: none;
}

.back-button:hover {
    color: #007BFF;
}

.admin-login-link {
    text-align: center;
    margin-top: 20px;
}

.success-box {
    width: 90%;
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    background-color: #fff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    text-align: center;
}

.success-box h1, .success-box p {
    margin-bottom: 10px;
}

.table-container {
    margin-top: 20px;
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

table th, table td {
    padding: 12px;
    border: 1px solid #ddd;
    text-align: left;
}

table thead {
    background-color: #f4f4f4;
}

button.edit-btn, 
button.save-btn, 
button.cancel-btn, 
button.delete-btn, 
button.confirm-delete-btn, 
button#confirm-delete-btn {
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    color: white;
    margin-right: 5px;
}

.edit-btn {
    background-color: #3498db;
}

.save-btn {
    background-color: #2ecc71;
}

.cancel-btn {
    background-color: #e74c3c;
}

.delete-btn {
    background-color: #f39c12;
}

#confirm-delete-btn, .confirm-delete-btn {
    background-color: #e74c3c;
}

#cancel-delete-btn {
    background-color: #95a5a6;
}

/* Styles for editable fields */
.editing .editable-name, .editing .editable-email {
    padding: 0;
}

.editing .editable-name input, .editing .editable-email input {
    width: 100%;
    box-sizing: border-box;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

/* Message container */
#message-container {
    padding: 10px;
    margin-bottom: 20px;
    border-radius: 4px;
    font-weight: bold;
    text-align: center;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s ease;
}

#message-container.success {
    background-color: #e8f5e9;
    color: #27ae60;
    visibility: visible;
    opacity: 1;
}

#message-container.error {
    background-color: #fdeaea;
    color: #e74c3c;
    visibility: visible;
    opacity: 1;
}

#message-container.warning {
    background-color: #fff3cd;
    color: #856404;
    visibility: visible;
    opacity: 1;
}