/* General Reset */
body {
    background-color: #10091D;
    margin: 0;
    padding: 0;
    font-family: 'Mulish', sans-serif;
    text-align: center;
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    overflow: hidden;
}

/* Background Layers */
.background {
    position: fixed;
    width: 100%;
    height: 100%;
    overflow: hidden;
    top: 0;
    left: 0;
    z-index: -1;
}

.bg-layer {
    position: absolute;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-repeat: no-repeat;
}

/* Apply background images */
.top-left { background-image: url('top-left-gradient-desktop.png'); top: 0; left: 0; }
.top-right { background-image: url('top-right-gradient-desktop.png'); top: 0; right: 0; }
.bottom-left { background-image: url('left-gradient-desktop.png'); bottom: 0; left: 0; }
.bottom-right { background-image: url('right-gradient-desktop.png'); bottom: 0; right: 0; }

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
}

/* Left Side (Logo + Text) */
.nav-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-logo {
    width: 100px;
}

.nav-text {
    font-size: 22px;
    font-weight: bold;
    color: white;
}

/* Centered Icons */
.nav-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 20px;
}

/* Icon Styling */
.nav-icon {
    width: 30px;
    cursor: pointer;
}

/* Centered Content (Index Page) */
.center-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* Main Logo */
.main-logo {
    width: 150px;
    margin-bottom: 20px;
}

/* Text */
h1 {
    font-size: 26px;
    font-weight: bold;
    margin-bottom: 10px;
}

p {
    font-size: 18px;
    margin-bottom: 20px;
}

/* Verify Button */
.verify-btn {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 20px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
}

.verify-btn:hover {
    opacity: 0.8;
}

/* Footer */
footer {
    position: absolute;
    bottom: 20px;
    text-align: center;
}

footer a {
    color: white;
    margin: 0 15px;
    text-decoration: none;
    font-size: 14px;
}

/* Wallet Selection Page (Verify.html) */
.wallet-selection {
    text-align: center;
    margin-top: 100px;
}

h1 {
    font-size: 28px;
    font-weight: bold;
}

/* Wallet Grid Layout */
.wallet-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    justify-content: center;
    max-width: 900px;
    margin: 20px auto;
}

/* Wallet Buttons */
.wallet-btn {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: 0.3s;
}

.wallet-btn img {
    width: 60px;
    height: 60px;
    display: block;
    margin: 0 auto 10px;
}

.wallet-btn span {
    display: block;
    font-size: 18px;
    color: white;
    font-weight: bold;
}

.wallet-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Modal Styling */
.modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(20, 20, 30, 0.95);
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
    text-align: center;
    z-index: 100;
    width: 350px;
    animation: fadeIn 0.3s ease-in-out;
}

/* Close Button */
.close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 22px;
    cursor: pointer;
    color: white;
}

/* Button Styling */
.modal-content button {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    color: white;
    border: none;
    padding: 12px 20px;
    font-size: 18px;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 10px;
    transition: all 0.3s ease-in-out;
    width: 100%;
}

.modal-content button:hover {
    opacity: 0.8;
}

/* Adjust Button Size */
.modal-content .verify-btn {
    width: auto;
    padding: 10px 20px;
    font-size: 16px;
}

/* Improved Connecting Animation */
.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 10px;
}

.loading-wallet {
    width: 50px;
    height: 50px;
    animation: rotate 1.5s linear infinite;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    margin-top: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    transition: width 0.5s ease-in-out;
}

/* Rotating Wallet Effect */
@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Connection Failed Animation */
.connection-failed {
    color: #ff5555;
    font-size: 22px;
    animation: fadeIn 1s ease-in-out;
}

/* Shake Animation for Failure */
.shake {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0% { transform: translateX(0px); }
    25% { transform: translateX(-5px); }
    50% { transform: translateX(5px); }
    75% { transform: translateX(-5px); }
}

/* Final Waiting Modal */
#waiting-modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(20, 20, 30, 0.95);
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
    text-align: center;
    z-index: 100;
    width: 350px;
}

/* Waiting Message */
.waiting-message {
    font-size: 20px;
    color: white;
    margin-top: 15px;
}

/* Loading Spinner */
.loading-spinner {
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #ffffff;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 15px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
