/* dialog.css - Dialog-specific styles */

.dialog {
    background-color: rgba(255, 255, 255, 0.9);
    width: 450px;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    padding: 40px;
    display: none;
    flex-direction: column;
    justify-content: flex-start;
    transition: all 0.3s ease;
    position: relative;
}

.dialog-body {
    flex-grow: 1;
    margin: 10px 0;
    display: flex;
    flex-direction: column;
    overflow-y: visible;
    /* padding-bottom: 20px; */
}

.dialog.active {
    display: flex;
}

.dialog-header {
    text-align: center;
    flex-shrink: 0;
}

.dialog-logo {
    max-width: 85px;
    margin: 0 auto 20px auto;
    display: block;
}

.dialog-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 10px;
}

.dialog-subtitle {
    font-size: 14px;
    color: #666;
    margin-bottom: 10px;
}

.dialog-footer {
    padding-top: 15px;
    flex-shrink: 0;
    display: flex;
    justify-content: flex-end;
    width: 100%;
    padding-bottom: 10px;
    position: relative;
}

.dialog-footer button {
    margin-left: 10px;
}

/* Dialog-specific styles */
#passwordDialog {
    height: auto;
    min-height: 600px;
    max-height: 85vh;
    overflow-y: auto;
}

/* Region selection dialog */
.region-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    border: 2px solid #ddd;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 150px;
    flex: 0 0 auto;
    box-sizing: border-box;
}

.region-option:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.region-option.selected {
    border: 1px solid var(--primary-color);
    background-color: #f8d4a970;
}

.region-selection {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 20px 0 40px;
    flex-wrap: wrap;
}

.region-flag {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin-bottom: 10px;
    border: 2px solid #ddd;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
}

/* Membership check dialog */
.check-item {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px;
    border-radius: 4px;
    background-color: var(--light-gray);
}

.check-icon {
    width: 24px;
    height: 24px;
    margin-right: 15px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
}

.check-icon.success {
    background-color: var(--success-color);
}

.check-icon.error {
    background-color: var(--danger-color);
}

.check-text {
    flex-grow: 1;
}

/* Success dialog */
.success-status {
    display: flex;
    align-items: center;
    margin-top: 10px;
    padding: 10px;
    background-color: rgba(40, 167, 69, 0.1);
    border-radius: 4px;
}

.success-status .check-icon {
    width: 20px;
    height: 20px;
    font-size: 12px;
}

#confetti-canvas,
.confetti-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1000;
    opacity: 1;
}

.password-success {
    margin-top: 15px;
    margin-bottom: 15px;
    background-color: rgba(76, 175, 80, 0.1);
    padding: 12px 15px;
    border-radius: 8px;
    border: 1px solid rgba(76, 175, 80, 0.3);
    display: flex;
    align-items: center;
    color: #2E7D32;
    font-size: 14px;
    animation: fadeIn 0.5s ease;
}

.success-icon {
    font-size: 18px;
    margin-right: 10px;
    font-weight: bold;
}

.success-message {
    text-align: center;
    margin-bottom: 25px;
}

.success-icon-container {
    margin: 0 auto 20px;
    width: 55px;
    height: 55px;
    background-color: var(--success-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.success-checkmark {
    color: white;
    font-size: 35px;
}

.account-details {
    background-color: #f8f8f8;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 10px;
}

.account-details h3 {
    margin-bottom: 10px;
    font-size: 18px;
    font-weight: 500;
    color: #444;
}

.detail-row {
    display: flex;
    margin-bottom: 5px;
    margin-top: 12px;
}

.detail-label {
    font-weight: 500;
    margin-right: 8px;
    margin-top: 2px;
}

.next-steps {
    margin-top: 20px;
}

.next-steps h3 {
    margin-bottom: 10px;
    font-size: 16px;
    color: #444;
}

.next-steps ul {
    padding-left: 20px;
    list-style: none;
}

.next-steps li {
    margin-bottom: 5px;
    font-size: 16px;
}

.confetti-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.status-display {
    display: flex;
    align-items: center;
}

.status-indicator {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-left: 10px;
    margin-top: 2px;
}

.status-green {
    background-color: #2ecc71;
    /* Green color */
    box-shadow: 0 0 5px rgba(46, 204, 113, 0.5);
}

.status-yellow {
    background-color: #f1c40f;
    /* Yellow color */
    box-shadow: 0 0 5px rgba(241, 196, 15, 0.5);
}

.app-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.app-button {
    display: inline-block;
    transition: transform 0.2s ease, opacity 0.2s ease;
    opacity: 0.8;
}

.app-button:hover {
    transform: translateY(-2px);
    opacity: 1;
}

.app-button img {
    height: 60px;
    width: auto;
    border-radius: 8px;
}

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

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

/* Responsive styles for the dialog */
/* Adjust the dialog width and padding for smaller screens */
@media (max-width: 480px) {
    .dialog {
        width: 90%;
        padding: 20px;
        max-height: 90vh;
        /* Slightly higher on mobile */
    }

    .region-selection {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .region-option {
        width: 80%;
        max-width: 200px;
        margin-bottom: 10px;
    }
}

/* Adjust the dialog width and padding for medium screens */
@media (min-width: 481px) and (max-width: 768px) {
    .dialog {
        width: 80%;
    }

    .region-selection {
        gap: 20px;
    }
}
