/* Base styles shared across all pages */

/* Custom Fonts */
@font-face {
    font-family: 'HurmeGeometricSans4';
    src: url('fonts/HurmeGeometricSans4-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'HurmeGeometricSans4';
    src: url('fonts/HurmeGeometricSans4-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'HurmeGeometricSans4';
    src: url('fonts/HurmeGeometricSans4-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

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

html, body {
    touch-action: none;
}

button, a, input {
    touch-action: auto;
}

body {
    font-family: 'HurmeGeometricSans4', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    min-height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    color: #333;
    line-height: 1.6;
    position: relative;
    overflow: hidden;
    overscroll-behavior: none;
}

.container {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    padding: 1rem;
    position: relative;
    z-index: 1;
    flex: 1;
    overflow-x: hidden;
    overflow-y: auto;
    touch-action: pan-y;
    overscroll-behavior: contain;
}

h1 {
    font-size: 1.25rem;
    margin-bottom: 0;
    color: #2c3e50;
}

.loading {
    text-align: center;
    padding: 2rem;
    font-size: 1.2rem;
    color: #666;
}

.error {
    background-color: #fee;
    color: #c33;
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: #ffffff;
    background-image: radial-gradient(circle at top left, #C5E67380 0%, transparent 40%, transparent 100%),
                      radial-gradient(circle at top right, #3C4BFB4D 0%, transparent 50%),
                      radial-gradient(circle at center, #D4B9FB80 0%, transparent 60%),
                      radial-gradient(circle at bottom left, #C5E67380 0%, transparent 40%, transparent 100%),
                      radial-gradient(circle at bottom right, #3C4BFB4D 0%, transparent 50%);
    position: relative;
    padding: 2.5rem 2rem;
    border-radius: 20px;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    animation: modalSlideIn 0.3s ease-out;
}

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

.modal-close {
    position: absolute;
    right: 1.5rem;
    top: 1.5rem;
    color: #666;
    font-size: 2rem;
    font-weight: 300;
    cursor: pointer;
    transition: color 0.2s;
    line-height: 1;
}

.modal-close:hover {
    color: #333;
}

.modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    text-align: center;
}

.modal-features {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem 0;
}

.modal-features li {
    padding: 0.75rem 0;
    padding-left: 1.75rem;
    position: relative;
    color: #333;
    font-size: 1rem;
    line-height: 1.5;
}

.modal-features li::before {
    content: '';
    position: absolute;
    left: 0.5rem;
    color: #3C4BFB;
    font-size: 1.5rem;
    line-height: 1;
}

.modal-store-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding-top: 1rem;
}

.modal-store-link {
    display: inline-block;
    transition: transform 0.2s;
}

.modal-store-link:hover {
    transform: scale(1.05);
}

@media (min-width: 768px) {
    .modal-content {
        padding: 3rem 2.5rem;
    }

    .modal-title {
        font-size: 1.5rem;
    }

    .modal-features li {
        font-size: 1.1rem;
    }

    h1 {
        font-size: 1.5rem;
    }
}

/* Snackbar */
.snackbar {
    visibility: hidden;
    min-width: 250px;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 8px;
    padding: 16px;
    position: fixed;
    z-index: 10001;
    left: 50%;
    bottom: 30px;
    transform: translateX(-50%);
    font-size: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.snackbar.show {
    visibility: visible;
    animation: fadein 0.3s, fadeout 0.3s 2.7s;
}

@keyframes fadein {
    from { bottom: 0; opacity: 0; }
    to { bottom: 30px; opacity: 1; }
}

@keyframes fadeout {
    from { bottom: 30px; opacity: 1; }
    to { bottom: 0; opacity: 0; }
}
