/* Variáveis */
:root {
    --primary-gold: #d4af37;
    --secondary-gold: #b8972d;
    --bg-champagne: #f9f5f0;
    --text-dark: #2c2c2c;
    --text-light: #666;
    --white: #ffffff;
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 15px 40px rgba(212, 175, 55, 0.15);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Playfair Display', serif;
    background: linear-gradient(135deg, #f9f5f0 0%, #e6d6b8 100%);
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle at 20% 50%, rgba(212, 175, 55, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(212, 175, 55, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.container {
    max-width: 1000px;
    margin: 40px auto;
    padding: 60px 40px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 30px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 1;
    animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

header {
    text-align: center;
    padding-bottom: 40px;
    border-bottom: 3px solid transparent;
    border-image: linear-gradient(90deg, transparent 0%, var(--primary-gold) 50%, transparent 100%) 1;
    margin-bottom: 50px;
    position: relative;
}

header::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 60px;
    background: var(--primary-gold);
    border-radius: 50%;
    opacity: 0.2;
}

header h1 {
    font-family: 'Great Vibes', cursive;
    font-size: 5em;
    color: var(--primary-gold);
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.8;
    }
}

header p {
    font-size: 1.4em;
    color: var(--text-light);
    font-style: italic;
}

header p:first-of-type {
    font-size: 1.6em;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.search-section {
    text-align: center;
    margin: 60px 0;
}

.search-section h2 {
    font-size: 2.2em;
    margin-bottom: 15px;
    color: var(--text-dark);
    font-weight: 700;
}

.search-section>p {
    margin-bottom: 30px;
    color: var(--text-light);
    font-size: 1.1em;
}

.search-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 40px 0;
    flex-wrap: wrap;
}

#guest-search {
    padding: 18px 30px;
    font-size: 1.1em;
    border: 3px solid #eee;
    border-radius: 50px;
    width: 450px;
    max-width: 100%;
    outline: none;
    transition: var(--transition);
    background: white;
    font-family: 'Segoe UI', sans-serif;
}

#guest-search:focus {
    border-color: var(--primary-gold);
    box-shadow: 0 0 0 6px rgba(212, 175, 55, 0.1);
    transform: translateY(-2px);
}

#search-btn {
    padding: 18px 45px;
    background: linear-gradient(135deg, var(--primary-gold) 0%, var(--secondary-gold) 100%);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    box-shadow: 0 10px 30px rgba(212, 175, 55, 0.3);
    position: relative;
    overflow: hidden;
}

#search-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

#search-btn:hover::before {
    left: 100%;
}

#search-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(212, 175, 55, 0.4);
}

.suggestions {
    max-width: 450px;
    margin: 25px auto;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.suggestion-item {
    padding: 18px 30px;
    cursor: pointer;
    transition: all 0.2s;
    border-bottom: 1px solid #f5f5f5;
    position: relative;
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-item::before {
    content: '👤';
    margin-right: 10px;
    opacity: 0.5;
}

.suggestion-item:hover {
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.05) 0%, rgba(212, 175, 55, 0.1) 100%);
    padding-left: 40px;
    color: var(--primary-gold);
}

footer {
    text-align: center;
    margin-top: 70px;
    padding-top: 30px;
    border-top: 2px solid transparent;
    border-image: linear-gradient(90deg, transparent 0%, rgba(212, 175, 55, 0.3) 50%, transparent 100%) 1;
    color: #999;
    font-size: 0.95em;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal:not(.hidden) {
    opacity: 1;
    pointer-events: all;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(44, 44, 44, 0.85);
    backdrop-filter: blur(10px);
}

.modal-content {
    position: relative;
    background: white;
    border-radius: 30px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3);
    max-width: 700px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.4s ease-out;
}

@keyframes modalSlideIn {
    from {
        transform: scale(0.9) translateY(-30px);
        opacity: 0;
    }

    to {
        transform: scale(1) translateY(0);
        opacity: 1;
    }
}

.modal-close {
    position: absolute;
    top: 25px;
    right: 25px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    font-size: 2em;
    color: #666;
    cursor: pointer;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
    z-index: 10;
}

.modal-close:hover {
    background: var(--primary-gold);
    color: white;
    transform: rotate(90deg);
}

.modal-header {
    padding: 50px 40px 30px;
    background: linear-gradient(135deg, var(--primary-gold) 0%, var(--secondary-gold) 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.modal-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
}

.modal-header h2 {
    color: white;
    margin-bottom: 15px;
    font-size: 2.5em;
    font-family: 'Great Vibes', cursive;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
    position: relative;
    z-index: 1;
}

.guest-name-display {
    font-size: 1.4em;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 600;
    position: relative;
    z-index: 1;
}

.modal-body {
    padding: 40px;
}

.invitation-text {
    font-size: 1.3em;
    text-align: center;
    margin-bottom: 25px;
    color: var(--text-dark);
}

.companion-info {
    text-align: center;
    color: var(--primary-gold);
    font-style: italic;
    margin-bottom: 35px;
    font-size: 1.1em;
    font-weight: 600;
}

.modal-actions {
    display: flex;
    gap: 15px;
    margin-top: 35px;
    flex-wrap: wrap;
}

.modal-actions button {
    flex: 1;
    min-width: 150px;
    padding: 18px 30px;
    border: none;
    border-radius: 50px;
    font-size: 1.05em;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.modal-actions button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.modal-actions button:hover::before {
    width: 300px;
    height: 300px;
}

.btn-accept,
.btn-confirm {
    background: linear-gradient(135deg, var(--primary-gold), var(--secondary-gold));
    color: white;
    box-shadow: 0 10px 30px rgba(212, 175, 55, 0.3);
}

.btn-accept:hover,
.btn-confirm:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(212, 175, 55, 0.4);
}

.btn-decline,
.btn-back {
    background: #f5f5f5;
    color: #666;
}

.btn-decline:hover,
.btn-back:hover {
    background: #e0e0e0;
    transform: translateY(-2px);
}

.btn-download {
    background: linear-gradient(135deg, var(--primary-gold), var(--secondary-gold));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    box-shadow: 0 10px 30px rgba(212, 175, 55, 0.3);
}

.btn-download:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(212, 175, 55, 0.4);
}

.confirmed-badge {
    background: linear-gradient(135deg, #4CAF50, #45a049);
    color: white;
    padding: 20px 40px;
    border-radius: 50px;
    text-align: center;
    font-size: 1.4em;
    font-weight: 600;
    margin-bottom: 35px;
    box-shadow: 0 10px 30px rgba(76, 175, 80, 0.3);
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

.invite-details {
    background: linear-gradient(135deg, #f9f9f9 0%, #fff 100%);
    padding: 30px;
    border-radius: 20px;
    margin-bottom: 25px;
    border-left: 4px solid var(--primary-gold);
}

.invite-details p {
    margin-bottom: 15px;
    font-size: 1.1em;
}

.invite-details strong {
    color: var(--text-dark);
    display: inline-block;
    min-width: 140px;
    font-weight: 700;
}

.form-group {
    margin-bottom: 28px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 1em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid #eee;
    border-radius: 15px;
    font-size: 1.05em;
    transition: var(--transition);
    background: #fafafa;
    font-family: 'Segoe UI', sans-serif;
}

.form-group input:focus {
    border-color: var(--primary-gold);
    background: white;
    outline: none;
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1);
}

.form-group input:disabled {
    background: #f5f5f5;
    cursor: not-allowed;
    opacity: 0.7;
}

.form-group small {
    display: block;
    margin-top: 8px;
    font-style: italic;
    color: var(--text-light);
}

.modal-state {
    display: block;
}

.modal-state.hidden {
    display: none;
}

.hidden {
    display: none !important;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        margin: 20px;
        padding: 40px 25px;
        border-radius: 20px;
    }

    header h1 {
        font-size: 3.5em;
    }

    .search-container {
        flex-direction: column;
        align-items: center;
    }

    #guest-search,
    #search-btn {
        width: 100%;
    }

    .modal-content {
        width: 95%;
        margin: 20px;
        border-radius: 20px;
    }

    .modal-header,
    .modal-body {
        padding: 30px 20px;
    }

    .modal-actions {
        flex-direction: column;
    }

    .modal-actions button {
        width: 100%;
    }
}