/* ===== RSVP ===== */
.rsvp-section {
    margin-bottom: 20px;
}

.rsvp-title {
    font-size: 56px;
    text-align: center;
}

.rsvp-form {
    font-family: Arial, Helvetica, sans-serif;
    letter-spacing: 1.5px;
    display: flex;
    flex-direction: column;
    gap: 0.66rem;
    margin: 1rem 5.157rem 0;
}

.rsvp-row.two-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.hp-field {
    position: absolute;
    left: -9999px;
    opacity: 0;
    pointer-events: none;
}

.rsvp-field label {
    display: block;
    font-size: 14px;
    height: 21px;
    color: #111;
    text-align: left;
}

.rsvp-field input {
    width: 100%;
    height: 51.5625px;
    border: none;
    border-bottom: 1px solid #e6e6e6;
    font-size: 14px;
    outline: none;
}

.rsvp-field input::placeholder {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 16px;
    color: #8aa0c2;
}

/* ===== Attendance ===== */
.attendance-field {
    margin-top: 20px;
    margin-bottom: 20px;
}

.attendance-title {
    display: block;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 1.4px;
    text-align: center;
    margin-bottom: 16px;
}

.attendance-options {
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 14px;
}

.attendance-card {
    cursor: pointer;
}

.attendance-card input {
    display: none;
}

.attendance-content {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: center;

    padding: 16px 18px;
    border: 2px solid #e6e6e6;
    border-radius: 10px;

    transition: border-color 0.2s ease, background 0.2s ease;
}

#attendance-moji {
    font-size: 21px;
}

.attendance-text {
    font-size: 14px;
    color: #111;
}

/* Custom radio */
.attendance-radio {
    width: 18px;
    height: 18px;
    border: 2px solid #cfcfcf;
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
}

.attendance-card input:checked+.attendance-content {
    border-color: #2f6fed;
    background: #dee9ff;
}

.attendance-card input:checked+.attendance-content .attendance-radio {
    border-color: #2f6fed;
}

.attendance-card input:checked+.attendance-content .attendance-radio::after {
    content: "";
    width: 8px;
    height: 8px;
    background: #2f6fed;
    border-radius: 50%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.attendance-card.rejected input:checked+.attendance-content {
    border-color: #ed2f2f;
    background: #ffe9e9;
}

.attendance-card.rejected input:checked+.attendance-content .attendance-radio {
    border-color: #ed2f2f;
}

.attendance-card.rejected input:checked+.attendance-content .attendance-radio::after {
    background: #ed2f2f;
}

.select-field {
    margin-top: 20px;
    width: 20vw;
    align-self: center;
}

.custom-select {
    position: relative;
    text-align: center;
}

.custom-select select {
    width: 100%;
    padding-top: 14px;
    padding-bottom: 14px;
    border-radius: 15px;
    border: 1px solid #e6e6e6;
    background: #ffffff;
    font-size: 16px;
    color: #111;
    appearance: none;
    cursor: pointer;
    transition: all 0.25s ease;
    text-align: center;
}

.custom-select select:invalid {
    color: #8aa0c2;
}

.custom-select select:focus,
.custom-select select:valid {
    color: #111;
    outline: none;
    border: 1px solid #2f6fed;
    background: #f3f9ff;
}

.custom-select select:hover {
    outline: none;
    border: 1px solid #2f6fed;
    background: #f3f9ff;
    box-shadow: 0 0 0 4px rgba(30, 107, 231, 0.15);
}

.rsvp-submit.is-disabled {
    background: #e5e7eb;
    border: 1px solid #d1d5db;
    color: #9ca3af;
    cursor: not-allowed;
    box-shadow: none;
}

.rsvp-submit {
    width: 80%;
    margin-top: 16px;
    padding: 14px 0;

    border: 1px solid rgb(0, 255, 42);
    border-radius: 50px;
    background: #d0fcd8;
    color: rgb(0, 0, 0);

    font-size: 16px;
    font-weight: 600;
    letter-spacing: 1.5px;
    cursor: pointer;
    align-self: center;

    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
}

.btn-spinner svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
    animation: spin 1s linear infinite;

    margin-right: 8px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.rsvp-tip {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 12px;
    font-weight: 600;
    line-height: 21px;
    color: rgb(133, 150, 176);
    opacity: 0.7;
    text-align: center;
    margin: 0 1.345rem 0.9em;
}

.rsvp-result {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.result-card {
    width: 100%;
    max-width: 520px;
    border-radius: 24px;
    padding: 40px 20px;
    text-align: center;
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.05);
    background:
        radial-gradient(ellipse at top center,
            rgba(41, 228, 110, 0.432) 0%,
            rgba(34, 197, 94, 0.233) 25%,
            rgba(255, 255, 255, 1) 65%);
    border: 1px solid rgba(0, 0, 0, 0.2);
}

.result-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 25px;
    background: #22c55e;
    color: white;
    font-size: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.result-card.error {
    background:
        radial-gradient(ellipse at top center,
            rgba(228, 41, 41, 0.432) 0%,
            rgba(197, 34, 34, 0.233) 25%,
            rgb(255, 255, 255) 65%);
}

.result-icon.error {
    background: #c52222;
}

.result-icon svg {
    width: 40px;
    height: 40px;
    color: #ffffff;
}

.result-card h2 {
    font-family: "Josefin Sans", sans-serif;
    font-size: 22px;
    line-height: 1.5;
    color: #111;
    margin-bottom: 16px;
}

.result-card p {
    color: #555;
    margin-bottom: 25px;
    font-size: 15px;
}

.result-btn {
    padding: 14px 30px;
    border-radius: 30px;
    border: none;
    background: #22c55e;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s ease;
}


.result-btn.error {
    background: #c52222;
}

.result-btn:hover {
    opacity: 0.9;
}

.result-btn.retry {
    background: #111;
}

@media (max-width: 1100px) {
    .select-field {
        width: 30vw;
    }
}

@media (max-width: 900px) {
    .result-card {
        max-width: 500px;
    }

    .rsvp-title {
        font-size: 42px;
    }

    .rsvp-form {
        padding: 0 0;
        margin: 1rem 1.5rem 0;
    }

    .rsvp-row.two-cols {
        grid-template-columns: 1fr;
    }

    .attendance-options {
        margin-left: auto;
        margin-right: auto;
        width: 80vw;
        flex-direction: column;
        align-items: center;
    }

    .select-field {
        width: 60vw;
    }

    .rsvp-tip {
        margin: 0 0.5rem 0.9em;
    }
}

@media (max-width: 400px) {
    .select-field {
        width: 80vw;
    }
}