/* Satoshi Font Family */
@font-face {
  font-family: 'Satoshi';
  src: url('../assets/Satoshi_Complete/Fonts/WEB/fonts/Satoshi-Variable.woff2') format('woff2'),
       url('../assets/Satoshi_Complete/Fonts/WEB/fonts/Satoshi-Variable.woff') format('woff'),
       url('../assets/Satoshi_Complete/Fonts/WEB/fonts/Satoshi-Variable.ttf') format('truetype');
  font-weight: 300 900;
  font-display: swap;
  font-style: normal;
}

@font-face {
  font-family: 'Satoshi';
  src: url('../assets/Satoshi_Complete/Fonts/WEB/fonts/Satoshi-VariableItalic.woff2') format('woff2'),
       url('../assets/Satoshi_Complete/Fonts/WEB/fonts/Satoshi-VariableItalic.woff') format('woff'),
       url('../assets/Satoshi_Complete/Fonts/WEB/fonts/Satoshi-VariableItalic.ttf') format('truetype');
  font-weight: 300 900;
  font-display: swap;
  font-style: italic;
}

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

body {
    font-family: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    background: #f8fafc;
    height: 100vh;
    height: 100dvh; /* Dynamic viewport height for mobile */
    color: #1a1a1a;
    overflow: hidden;
    position: relative;
    -webkit-text-size-adjust: 100%; /* Prevent text size adjustment on mobile */
    text-size-adjust: 100%;
    /* Enable momentum scrolling on iOS for overlays */
    -webkit-overflow-scrolling: touch;
}

/* Social Icons */
.social-icons {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    gap: 8px;
    z-index: 1000;
    transition: opacity 0.3s ease;
    max-width: calc(100vw - 40px);
}

.social-icons.hide {
    opacity: 0;
}

.social-icon {
    width: 36px;
    height: 36px;
    background: #f8fafc;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #9ca3af;
    transition: all 0.2s ease;
    border: 1px solid rgba(0, 0, 0, 0.04);
    cursor: pointer;
}

button.social-icon {
    font-family: inherit;
    padding: 0;
}

.social-icon:hover {
    background: #f8fafc;
    color: #6b7280;
    transform: scale(1.05);
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 60px;
    height: 100vh;
    height: 100dvh; /* Dynamic viewport height for mobile */
    display: flex;
    flex-direction: column;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

/* Header */
header {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    min-height: 0; /* Allow shrinking */
}

header.hide {
    opacity: 0;
    transform: scale(0.95);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0px;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

.header-left {
    flex: 0 0 auto;
    width: 420px;
    max-width: 420px;
    min-width: 350px;
}

.header-right {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: -1;
}

.logo {
    font-size: 72px;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 10px;
    line-height: 1;
}

.tagline {
    font-size: 20px;
    color: #64748b;
    margin-bottom: 40px;
    line-height: 1.5;
    font-weight: 450;
}

.header-buttons {
    display: flex;
    gap: 12px;
    align-items: center;
}

.btn {
    padding: 16px 90px;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 700;
    font-family: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background: #326EEE;
    color: white;
}

.btn-primary:hover {
    background: #2558D5;
}

.btn-secondary {
    background: #f1f5f9;
    color: #64748b;
}

.btn-secondary:hover {
    background: #e2e8f0;
}

.character-image {
    width: 748px;
    height: auto;
    max-width: calc(100vw - 480px);
    min-width: 500px;
    object-fit: contain;
    display: block;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    pointer-events: none;
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
}

/* Main content */
main {
    padding: 0;
    flex: 0;
}

/* Language Selection */
.language-selection {
    display: none !important; /* Ensure it's hidden by default */
    text-align: center;
    padding: 40px 0 100px;
}

/* Removed conflicting mobile layout rule - now handled by progressive responsive layout below */

/* Language Selection as Full Page */
.language-selection.show-page {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: #f8fafc;
    z-index: 1000;
    display: block !important;
    padding: 80px 20px 40px;
    box-sizing: border-box;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
    overscroll-behavior: contain; /* Prevent bounce scrolling */
}

.language-selection h3 {
    font-size: 40px;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 8px;
    line-height: 1.2;
    margin-top: 0;
    text-align: center;
}

.selection-description {
    font-size: 16px;
    color: #64748b;
    margin-bottom: 40px;
    font-weight: 400;
    text-align: center;
}

.language-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    max-width: 400px;
    margin: 0 auto 60px auto;
    width: 100%;
    transition: all 0.3s ease;
}

/* Progressive responsive layout: 3 → 2 → 1 columns */

/* Large screens (widescreen): 3 columns (1200px+) */
@media (min-width: 1200px) {
    .language-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        max-width: 900px !important;
        gap: 20px !important;
    }
    
    /* Center the "Other" segment when it's the last item in 3-column layout */
    .language-grid .suggest-language:last-child:nth-child(3n+1) {
        grid-column: 2;
    }
}

/* Small desktop/Large tablet: 2 columns (768px - 1199px) */
@media (min-width: 768px) and (max-width: 1199px) {
    .language-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        max-width: 700px !important;
        gap: 18px !important;
    }
    
    /* Center the "Other" segment when it's the last item in 2-column layout */
    .language-grid .suggest-language:last-child:nth-child(odd) {
        grid-column: span 2;
        max-width: 350px;
        margin: 0 auto;
    }
}

/* Mobile phones: 1 column (below 768px) */
@media (max-width: 767px) {
    .language-grid {
        grid-template-columns: 1fr !important;
        max-width: 400px !important;
        gap: 16px !important;
        margin: 0 auto !important;
        width: 100% !important;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.language-selection.show-page .language-item {
    animation: fadeInUp 0.3s ease backwards;
    transition: opacity 0.2s ease;
}

.language-selection.show-page .language-item:nth-child(1) { animation-delay: 0.02s; }
.language-selection.show-page .language-item:nth-child(2) { animation-delay: 0.04s; }
.language-selection.show-page .language-item:nth-child(3) { animation-delay: 0.06s; }
.language-selection.show-page .language-item:nth-child(4) { animation-delay: 0.08s; }
.language-selection.show-page .language-item:nth-child(5) { animation-delay: 0.1s; }
.language-selection.show-page .language-item:nth-child(6) { animation-delay: 0.12s; }
.language-selection.show-page .language-item:nth-child(7) { animation-delay: 0.14s; }
.language-selection.show-page .language-item:nth-child(8) { animation-delay: 0.16s; }
.language-selection.show-page .language-item:nth-child(9) { animation-delay: 0.18s; }
.language-selection.show-page .language-item:nth-child(10) { animation-delay: 0.2s; }

.language-item {
    background: #f8f9fa;
    border-radius: 16px;
    padding: 0;
    cursor: pointer;
    transition: transform 0.6s cubic-bezier(0.4, 0.0, 0.2, 1) !important, 
                background-color 0.6s cubic-bezier(0.4, 0.0, 0.2, 1) !important,
                box-shadow 0.6s cubic-bezier(0.4, 0.0, 0.2, 1) !important;
    border: 1px solid #e2e8f0;
    position: relative;
    overflow: hidden;
    min-height: 100px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    will-change: transform, box-shadow;
}

.language-item:hover {
    transform: translateY(-2px);
    background: #ffffff;
}

.language-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    flex: 1;
}

.language-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.flag-circle {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: #e5e7eb;
    border-radius: 50%;
    padding: 6px;
}

.flag-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.other-flag {
    background: #f1f5f9;
    color: #64748b;
}

.language-name {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    line-height: 1.2;
}

.language-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    text-align: left;
}

.language-subtitle {
    font-size: 12px;
    color: #9ca3af;
    font-weight: 400;
    line-height: 1.3;
}

.arrow-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #cbd5e1;
    opacity: 0.7;
    transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.language-item:hover .arrow-icon {
    color: #6b7280;
    opacity: 1;
    transform: translateX(2px);
}

.language-bar {
    height: 4px;
    background: #e2e8f0;
    border-radius: 0 0 16px 16px;
    overflow: hidden;
    width: 100%;
}

.language-bar-fill {
    height: 100%;
    background: #326EEE;
    border-radius: 0 0 16px 16px;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Other language styling */
.other-language {
    background: #f8f9fa;
    border: 1px solid #e2e8f0;
    position: relative;
}

.other-language .flag-circle {
    background: #e5e7eb;
}

.other-language .language-text .language-name {
    font-size: 18px;
}

.other-language .language-text .language-subtitle {
    font-size: 13px;
    color: #9ca3af;
}

/* Suggest Language Button - Other style */
.suggest-language {
    background: #f8f9fa !important;
    border: 1px solid #e2e8f0 !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 100px;
    padding: 0 !important;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    transition: transform 0.6s cubic-bezier(0.4, 0.0, 0.2, 1) !important, 
                background-color 0.6s cubic-bezier(0.4, 0.0, 0.2, 1) !important,
                box-shadow 0.6s cubic-bezier(0.4, 0.0, 0.2, 1) !important;
}

.suggest-language:hover {
    background: #ffffff !important;
    transform: translateY(-2px);
}

.suggest-icon {
    background: #e5e7eb !important;
    color: #6b7280;
    width: 40px !important;
    height: 40px !important;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}


.suggest-language .language-name {
    color: #6b7280;
    font-weight: 500;
    font-size: 16px;
}

.suggest-language .language-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 20px;
    flex: 1;
}

.suggest-language .language-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.suggest-language .language-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    text-align: left;
}

.suggest-language .language-subtitle {
    font-size: 12px;
    color: #9ca3af;
    font-weight: 400;
    line-height: 1.3;
}

/* Waitlist Form Styling */
.waitlist-form {
    display: none !important; /* Ensure it's hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh; /* Dynamic viewport height for mobile */
    background: #f8fafc;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    box-sizing: border-box;
    overflow-y: auto;
    overflow-x: hidden;
}

.waitlist-form.show {
    display: flex !important;
    flex-direction: column;
    animation: fadeIn 0.3s ease;
}

.waitlist-form .back-btn {
    display: flex !important;
    opacity: 1 !important;
    z-index: 1002;
    position: fixed !important;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3) rotate(var(--rotation));
    }
    40% {
        opacity: 1;
        transform: scale(1.05) rotate(var(--rotation));
    }
    70% {
        transform: scale(0.95) rotate(var(--rotation));
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(var(--rotation));
    }
}

@keyframes floatAnimation {
    0%, 100% {
        transform: translateY(0) rotate(var(--rotation));
    }
    50% {
        transform: translateY(-10px) rotate(var(--rotation));
    }
}

@keyframes floatAnimationHover {
    0%, 100% {
        transform: translateY(0) rotate(var(--rotation)) scale(1.12);
    }
    50% {
        transform: translateY(-10px) rotate(var(--rotation)) scale(1.12);
    }
}

.back-btn {
    position: fixed;
    top: 40px;
    left: 40px;
    width: 44px;
    height: 44px;
    background: white;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    color: #1e293b;
    animation: fadeIn 0.4s ease 0.2s both;
    z-index: 1001;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

.back-btn:hover {
    background: white;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.back-btn:active {
    transform: scale(1);
}

.form-container {
    text-align: center;
    max-width: 500px;
    width: 100%;
    position: relative;
    margin: auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    animation: slideInUp 0.5s ease 0.2s backwards;
}

.character-emotes {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: min(900px, 100vw);
    height: 650px;
    pointer-events: none;
    z-index: 1;
    max-width: calc(100vw - 40px);
}

.emote {
    position: absolute;
    width: 280px;
    height: 280px;
    object-fit: contain;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    pointer-events: auto;
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    cursor: pointer;
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94), filter 0.5s ease;
    animation: bounceIn 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

.emote-top-left {
    top: -20px;
    left: -50px;
    --rotation: -12deg;
    transform: rotate(-12deg);
    animation-delay: 0.3s;
}

.emote-top-right {
    top: -20px;
    right: -50px;
    --rotation: 12deg;
    transform: rotate(12deg);
    animation-delay: 0.4s;
}

.emote-bottom-left {
    bottom: -20px;
    left: -50px;
    --rotation: -8deg;
    transform: rotate(-8deg);
    animation-delay: 0.5s;
}

.emote-bottom-right {
    bottom: -20px;
    right: -50px;
    --rotation: 8deg;
    transform: rotate(8deg);
    animation-delay: 0.6s;
}

/* Add floating animation after initial animation */
.waitlist-form.show .emote {
    opacity: 0;
    animation: bounceIn 1s cubic-bezier(0.34, 1.56, 0.64, 1) forwards,
               floatAnimation 4s ease-in-out infinite;
}

.waitlist-form.show .emote-top-left {
    animation-delay: 0.1s, 1.1s;
}

.waitlist-form.show .emote-top-right {
    animation-delay: 0.2s, 1.2s;
}

.waitlist-form.show .emote-bottom-left {
    animation-delay: 0.3s, 1.3s;
}

.waitlist-form.show .emote-bottom-right {
    animation-delay: 0.4s, 1.4s;
}

/* Hover effect for emotes - gentle scale with maintained rotation */
.waitlist-form.show .emote {
    transform-origin: center;
    transition: width 0.5s ease-out, height 0.5s ease-out, filter 0.5s ease;
}

.waitlist-form.show .emote:hover {
    width: 295px;
    height: 295px;
    filter: brightness(1.05);
    z-index: 10;
}

.waitlist-form h3 {
    font-size: 48px;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 12px;
    line-height: 1.1;
    position: relative;
    z-index: 10;
    animation: fadeInScale 0.5s ease 0.1s backwards;
}

.form-description {
    font-size: 18px;
    color: #64748b;
    margin-bottom: 40px;
    line-height: 1.4;
    position: relative;
    z-index: 10;
    animation: fadeInScale 0.5s ease 0.15s backwards;
}

.waitlist-form .form-group {
    margin-bottom: 16px;
    position: relative;
    z-index: 10;
    animation: fadeInScale 0.5s ease 0.25s backwards;
}

.waitlist-form input[type="email"] {
    width: 100%;
    max-width: 400px;
    padding: 18px 24px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: 16px;
    color: #1e293b;
    font-family: inherit;
    transition: all 0.2s ease;
    box-sizing: border-box;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.waitlist-form input[type="email"]:focus {
    outline: none;
    border-color: #326EEE;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.waitlist-form input[type="email"]::placeholder {
    color: #cbd5e1;
}

.waitlist-form .submit-btn {
    width: 100%;
    max-width: 400px;
    padding: 16px 90px;
    background: #326EEE;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 700;
    font-family: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 0;
    box-sizing: border-box;
    position: relative;
    z-index: 10;
    animation: fadeInScale 0.5s ease 0.3s backwards;
}

.waitlist-form .submit-btn:hover {
    background: #2558D5;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.waitlist-form .success-message {
    display: none;
    margin-top: 16px;
    padding: 12px 16px;
    background: #34c759;
    color: white;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
}

.waitlist-form .success-message.show {
    display: block;
}

.language-request-form {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #f8fafc;
    z-index: 1500;
    padding: 80px 20px 40px;
    box-sizing: border-box;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
    overscroll-behavior: contain; /* Prevent bounce scrolling */
}

.language-request-form.show {
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

.language-request-form .back-btn {
    display: flex !important;
    z-index: 1002;
    position: fixed !important;
}

.language-request-form h3 {
    font-size: 40px;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 8px;
    text-align: center;
    animation: fadeInScale 0.4s ease 0.1s backwards;
}

.language-request-form .request-description {
    font-size: 16px;
    color: #64748b;
    margin-bottom: 40px;
    text-align: center;
    animation: fadeInScale 0.4s ease 0.15s backwards;
}

.language-request-form .form-group {
    width: 100%;
    max-width: 400px;
    margin: 0 auto 20px;
    animation: fadeInScale 0.4s ease 0.2s backwards;
}

.language-dropdown {
    width: 100%;
    padding: 18px 24px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: 16px;
    color: #1e293b;
    font-family: inherit;
    transition: all 0.2s ease;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 20px center;
    background-size: 20px;
    padding-right: 50px;
}

.language-dropdown:focus {
    outline: none;
    border-color: #326EEE;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.language-request-form .submit-btn {
    width: 100%;
    max-width: 400px;
    padding: 16px 90px;
    background: #326EEE;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 700;
    font-family: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    animation: fadeInScale 0.4s ease 0.25s backwards;
}

.language-request-form .submit-btn:hover {
    background: #2558D5;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.language-request-form .success-message {
    display: none;
    margin-top: 20px;
    padding: 12px 20px;
    background: #34c759;
    color: white;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    text-align: center;
    max-width: 400px;
}

.language-request-form .success-message.show {
    display: block;
    animation: fadeInScale 0.3s ease;
}

/* Thank You Page */
.thank-you-page {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: #f8fafc;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    box-sizing: border-box;
    z-index: 2000;
}

.thank-you-page.show {
    display: flex;
    animation: fadeIn 0.15s ease; /* Faster fade in */
}

.thank-you-content {
    text-align: center;
    max-width: 500px;
    width: 100%;
    animation: slideInUp 0.2s ease forwards;
}

.sleeping-marmunch {
    width: 300px;
    max-width: 80%;
    height: auto;
    margin-bottom: 30px;
    animation: bounceIn 0.25s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    pointer-events: none;
    -webkit-user-drag: none;
}

.thank-you-page h2 {
    font-size: 36px;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 12px;
    animation: fadeInScale 0.2s ease 0.05s backwards;
}

.thank-you-page p {
    font-size: 18px;
    color: #64748b;
    animation: fadeInScale 0.2s ease 0.1s backwards;
}

.loading {
    color: #64748b;
    font-style: italic;
    padding: 40px 0;
}

/* Loading animation */
.loading-container {
    padding: 60px 20px;
    text-align: center;
}

.loading-bar {
    max-width: 300px;
    height: 4px;
    background: #e2e8f0;
    border-radius: 2px;
    margin: 0 auto 20px;
    overflow: hidden;
    position: relative;
}

.loading-bar-progress {
    height: 100%;
    background: linear-gradient(90deg, #326EEE, #326EEE);
    border-radius: 2px;
    width: 30%;
    position: absolute;
    left: -30%;
    animation: loadingSlide 1.5s ease-in-out infinite;
}

@keyframes loadingSlide {
    0% {
        left: -30%;
    }
    50% {
        left: 100%;
    }
    100% {
        left: -30%;
    }
}

.loading-text {
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
    margin: 0;
}

/* Skeleton Loader */
.skeleton-item {
    pointer-events: none;
    animation: none !important;
}

.skeleton-flag {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

.skeleton-text {
    background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
}

.skeleton-title {
    width: 120px;
    height: 18px;
    margin-bottom: 6px;
}

.skeleton-subtitle {
    width: 80px;
    height: 12px;
}

.skeleton-bar {
    height: 4px;
    background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 0 0 16px 16px;
}

@keyframes shimmer {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Footer */
footer {
    text-align: center;
    padding: 20px 0;
    color: #9ca3af;
    font-size: 14px;
    transition: opacity 0.3s ease;
    position: relative;
    z-index: 1;
    flex-shrink: 0;
}

footer.hide {
    opacity: 0;
    pointer-events: none;
}

.privacy-link {
    margin-top: 8px;
    font-size: 11px;
}

.privacy-link a {
    color: #9ca3af;
    text-decoration: none;
    transition: color 0.2s ease;
}

.privacy-link a:hover {
    color: #6b7280;
    text-decoration: underline;
}

/* Extra Large Desktop - Maximize screen usage */
@media (min-width: 1800px) {
    .container {
        max-width: 1600px;
        padding: 0 80px;
    }
    
    .header-left {
        flex: 0 0 auto;
        width: 500px;
        max-width: 500px;
    }
    
    /* Keep text and button sizes consistent - removed size overrides */
    
    .character-image {
        width: 805px;
        max-width: 50vw;
        height: auto;
    }
    
    .character-emotes {
        width: 1200px;
        height: 800px;
    }
    
    .emote {
        width: 350px;
        height: 350px;
    }
    
    .waitlist-form.show .emote:hover {
        width: 368px;
        height: 368px;
    }
}

/* Large Desktop - Bigger Image */
@media (min-width: 1400px) and (max-width: 1799px) {
    /* Keep text sizes consistent - removed font-size overrides */
    
    .character-image {
        width: 748px;
        max-width: 50vw;
        min-width: 633px;
        height: auto;
    }
    
    .character-emotes {
        width: 1000px;
        height: 700px;
    }
    
    .emote {
        width: 320px;
        height: 320px;
    }
    
    .waitlist-form.show .emote:hover {
        width: 335px;
        height: 335px;
    }
}

/* Desktop */
@media (max-width: 1400px) and (min-width: 1200px) {
    /* Keep text sizes consistent - removed font-size overrides */
    
    .character-image {
        width: 690px;
        max-width: 48vw;
        min-width: 575px;
        height: auto;
    }
    
    .character-emotes {
        width: 900px;
        height: 650px;
    }
    
    .emote {
        width: 280px;
        height: 280px;
    }
    
    .waitlist-form.show .emote:hover {
        width: 295px;
        height: 295px;
    }
}

/* Small Desktop / Large Tablet */
@media (max-width: 1200px) and (min-width: 992px) {
    header {
        padding: 50px 0;
    }
    
    .header-content {
        gap: 30px;
        align-items: center;
        justify-content: flex-start;
    }
    
    .header-left {
        flex: 0 0 auto;
        width: 500px;
        max-width: 500px;
    }
    
    .character-image {
        width: 633px;
        max-width: 45vw;
        min-width: 518px;
        height: auto;
    }
    
    /* Keep text and button sizes consistent - removed size overrides */
    
    .character-emotes {
        width: 800px;
        height: 580px;
    }
    
    .emote {
        width: 240px;
        height: 240px;
    }
    
    .waitlist-form.show .emote:hover {
        width: 252px;
        height: 252px;
    }
    
    .language-selection.show-page {
        padding: 70px 30px 30px;
    }
    
    /* Language grid desktop rules handled by main media query */
    
}

/* Mobile scrolling improvements for tablet and landscape */
@media (max-width: 991px) and (min-width: 481px) {
    .language-selection.show-page {
        padding-bottom: 50px !important; /* Ensure scroll space */
        min-height: calc(100vh + 1px) !important;
        min-height: calc(100dvh + 1px) !important;
    }
}

/* Tablet */
@media (max-width: 991px) and (min-width: 768px) {
    .container {
        padding: 0 30px;
    }
    
    header {
        padding: 60px 0 40px;
        min-height: 0;
    }
    
    .header-content {
        gap: 40px;
        flex-direction: column;
        text-align: center;
        position: static;
    }
    
    .header-right {
        position: static;
        transform: none;
        z-index: auto;
    }
    
    .header-left {
        flex: none;
        max-width: 500px;
        text-align: center;
        margin-top: 20px;
    }
    
    .header-buttons {
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
    }
    
    .logo {
        font-size: 48px;
        text-align: center;
        margin-bottom: 10px;
    }
    
    .tagline {
        font-size: 16px;
        text-align: center;
        margin-bottom: 40px;
    }
    
    .character-image {
        max-height: 380px;
        margin-bottom: 20px;
    }
    
    .character-emotes {
        width: 700px;
        height: 500px;
    }
    
    .emote {
        width: 200px;
        height: 200px;
    }
    
    .waitlist-form.show .emote:hover {
        width: 210px;
        height: 210px;
    }
    
    .emote-bottom-left,
    .emote-bottom-right {
        bottom: -60px;
    }
    
    /* language-grid layout now handled by main progressive responsive rules */
    
    .language-selection.show-page {
        padding: 70px 30px 40px;
    }
    
    .language-item {
        min-height: 100px;
    }
    
    .language-name {
        font-size: 17px;
    }
    
    .language-subtitle {
        font-size: 12px;
    }
    
    .waitlist-form h3 {
        font-size: 40px;
    }
    
    .form-description {
        font-size: 16px;
    }
}

/* Mobile Landscape / Small Tablet */
@media (max-width: 767px) and (min-width: 481px) {
    .container {
        padding: 0 25px;
    }
    
    .social-icons {
        top: 15px;
        right: 15px;
    }
    
    .social-icon {
        width: 38px;
        height: 38px;
    }
    
    header {
        padding: 35px 0;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 35px;
        position: static;
    }
    
    .header-right {
        position: static;
        transform: none;
        z-index: auto;
    }
    
    .header-left {
        flex: none;
        max-width: 400px;
        width: 100%;
    }
    
    .logo {
        font-size: 42px;
        text-align: center;
        margin-bottom: 10px;
    }
    
    .tagline {
        font-size: 15px;
        text-align: center;
        margin-bottom: 40px;
    }
    
    .header-buttons {
        justify-content: center;
    }
    
    .character-image {
        max-height: 320px;
        width: auto;
        max-width: 100%;
    }
    
    .language-selection h3 {
        font-size: 36px;
    }
    
    .selection-description {
        font-size: 15px;
        margin-bottom: 32px;
    }
    
    /* language-grid layout now handled by main progressive responsive rules */
    
    .language-selection.show-page {
        padding: 70px 25px 40px;
    }
    
    
    .character-emotes {
        width: 550px;
        height: 420px;
    }
    
    .emote {
        width: 160px;
        height: 160px;
    }
    
    .waitlist-form.show .emote:hover {
        width: 168px;
        height: 168px;
    }
    
    .emote-top-left,
    .emote-bottom-left {
        left: -30px;
    }
    
    .emote-top-right,
    .emote-bottom-right {
        right: -30px;
    }
    
    .emote-bottom-left,
    .emote-bottom-right {
        bottom: -80px;
    }
    
    .waitlist-form h3 {
        font-size: 36px;
    }
    
    .form-description {
        font-size: 15px;
        margin-bottom: 28px;
    }
    
    .form-container {
        max-width: 380px;
        margin: auto;
    }
    
    .waitlist-form input[type="email"],
    .waitlist-form .submit-btn {
        max-width: 340px;
        padding: 14px 60px;
        font-size: 16px;
    }
    
    .back-btn {
        width: 42px;
        height: 42px;
        position: fixed !important;
        top: 25px !important;
        left: 25px !important;
        z-index: 1002 !important;
    }
}

/* Small Mobile - between portrait and landscape */
@media (max-width: 575px) and (min-width: 481px) {
    /* language-grid layout now handled by main progressive responsive rules */
    
    .language-selection.show-page {
        padding: 70px 20px 40px;
    }
    
    .language-item {
        min-height: 95px;
    }
    
    .language-name {
        font-size: 16px;
    }
    
    .language-subtitle {
        font-size: 11px;
    }
    
    /* Center email form vertically */
    .waitlist-form {
        padding: 20px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    
    .waitlist-form.show {
        display: flex !important;
    }
    
    .emote-bottom-left,
    .emote-bottom-right {
        bottom: -80px;
    }
}

/* Touch target improvements for mobile */
@media (max-width: 767px) {
    .language-selection.show-page {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100%;
        overflow-y: scroll !important;
        overflow-x: hidden !important;
        -webkit-overflow-scrolling: touch !important;
        overscroll-behavior-y: contain;
        display: block !important;
        padding: 70px 20px 100px !important;
        box-sizing: border-box;
    }
    
    /* language-grid layout now handled by main progressive responsive rules */
    
    .language-item {
        cursor: pointer;
        -webkit-tap-highlight-color: rgba(78, 93, 255, 0.1);
        tap-highlight-color: rgba(78, 93, 255, 0.1);
        min-height: 90px;
    }
    
    .language-item:active {
        transform: translateY(0) scale(0.98);
        background: #f1f5f9;
    }
    
    /* Ensure Other button spans full width on mobile */
    .suggest-language:last-child {
        grid-column: 1;
        max-width: none;
        margin: 0;
    }
    
    .flag-circle {
        width: 36px;
        height: 36px;
    }
    
    /* Language request form mobile improvements */
    .language-request-form {
        padding: 60px 20px 40px;
    }
    
    .language-request-form h3 {
        font-size: 32px;
        margin-bottom: 12px;
    }
    
    .language-request-form .request-description {
        font-size: 15px;
        margin-bottom: 32px;
    }
    
    .language-dropdown {
        padding: 16px 20px;
        padding-right: 45px;
        font-size: 16px;
        border-radius: 10px;
        background-size: 18px;
        background-position: right 16px center;
    }
    
    .language-request-form .submit-btn {
        padding: 16px 60px;
        font-size: 16px;
        border-radius: 10px;
    }
}

/* Additional mobile scrolling fixes */
@media (max-width: 480px) {
    .language-selection.show-page {
        padding: 70px 20px 100px !important; /* Add bottom padding for scroll space */
        min-height: 100vh;
        min-height: 100dvh;
    }
    
    .language-grid {
        margin-bottom: 80px; /* Extra space at bottom */
        padding-bottom: 20px;
    }
    
    .back-btn {
        position: fixed !important;
        top: 20px !important;
        left: 20px !important;
        z-index: 1002 !important;
    }
}

/* Mobile Portrait */
@media (max-width: 480px) {
    .container {
        padding: 0 20px;
    }
    
    .language-selection.show-page {
        display: block !important;
        overflow-y: scroll !important;
        padding: 70px 20px 120px !important;
        height: 100vh !important;
        height: 100dvh !important;
    }
    
    .social-icons {
        top: 12px;
        right: 12px;
    }
    
    .social-icon {
        width: 36px;
        height: 36px;
    }
    
    /* Center email form vertically on mobile */
    .waitlist-form {
        padding: 20px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    
    .waitlist-form.show {
        display: flex !important;
    }
    
    header {
        padding: 30px 0;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 30px;
        position: static;
    }
    
    .header-right {
        position: static;
        transform: none;
        z-index: auto;
    }
    
    .header-left {
        flex: none;
        max-width: none;
        width: 100%;
    }
    
    .logo {
        font-size: 36px;
        text-align: center;
        margin-bottom: 10px;
    }
    
    .tagline {
        font-size: 14px;
        text-align: center;
        margin-bottom: 40px;
    }
    
    .header-buttons {
        justify-content: center;
        flex-direction: column;
        width: 100%;
        gap: 10px;
    }
    
    .btn {
        width: 100%;
        max-width: 320px;
        padding: 14px 60px;
        font-size: 16px;
    }
    
    .character-image {
        max-height: 280px;
        width: auto;
        max-width: 100%;
    }
    
    .language-selection.show-page {
        padding: 70px 20px 40px;
    }
    
    .language-selection h3 {
        font-size: 28px;
        margin-bottom: 6px;
    }
    
    .selection-description {
        font-size: 14px;
        margin-bottom: 24px;
    }
    
    .language-grid {
        grid-template-columns: 1fr;
        gap: 12px;
        max-width: 350px;
        width: 100%;
        margin: 0 auto 60px auto;
        padding: 0;
    }
    
    .language-item {
        min-height: 95px;
        padding: 0;
    }
    
    .language-content {
        padding: 16px;
    }
    
    .language-name {
        font-size: 16px;
    }
    
    .language-subtitle {
        font-size: 11px;
    }
    
    
    .character-emotes {
        width: min(450px, calc(100vw - 20px));
        height: 360px;
    }
    
    .emote {
        width: 130px;
        height: 130px;
    }
    
    .waitlist-form.show .emote:hover {
        width: 137px;
        height: 137px;
    }
    
    .emote-top-left,
    .emote-bottom-left {
        left: 10px;
    }
    
    .emote-top-right,
    .emote-bottom-right {
        right: 10px;
    }
    
    .emote-top-left,
    .emote-top-right {
        top: -60px;
    }
    
    .emote-bottom-left,
    .emote-bottom-right {
        bottom: -60px;
    }
    
    .waitlist-form h3 {
        font-size: 32px;
        margin-bottom: 8px;
    }
    
    .form-description {
        font-size: 14px;
        margin-bottom: 24px;
        line-height: 1.3;
    }
    
    .form-container {
        max-width: 320px;
        padding: 32px 24px;
        margin: auto;
    }
    
    .waitlist-form input[type="email"],
    .waitlist-form .submit-btn {
        max-width: 100%;
        padding: 14px 50px;
        font-size: 16px;
    }
    
    .waitlist-form input[type="email"] {
        border-radius: 10px;
    }
    
    .waitlist-form .submit-btn {
        border-radius: 10px;
    }
    
    .back-btn {
        width: 40px;
        height: 40px;
        position: fixed !important;
        top: 20px !important;
        left: 20px !important;
        z-index: 1002 !important;
    }
    
    footer {
        padding: 30px 0;
        font-size: 12px;
    }
    
    .privacy-link {
        font-size: 10px;
    }
}

/* Mobile styles for Thank You page */
@media (max-width: 767px) {
    .thank-you-page {
        padding: 30px 20px;
        min-height: 100vh;
        min-height: 100dvh;
    }
    
    .thank-you-content {
        max-width: 100%;
        padding: 0 20px;
    }
    
    .sleeping-marmunch {
        width: 250px;
        max-width: 90%;
        margin-bottom: 24px;
    }
    
    .thank-you-page h2 {
        font-size: 28px;
        margin-bottom: 16px;
        line-height: 1.2;
    }
    
    .thank-you-page p {
        font-size: 16px;
        line-height: 1.4;
    }
}

/* Small Mobile - iPhone SE, older phones */
@media (max-width: 380px) {
    .container {
        padding: 0 16px;
    }
    
    .logo {
        font-size: 32px;
        margin-bottom: 10px;
    }
    
    .tagline {
        font-size: 13px;
        margin-bottom: 40px;
    }
    
    .btn {
        padding: 14px 60px;
        font-size: 16px;
    }
    
    .character-image {
        max-height: 240px;
        width: auto;
        max-width: 100%;
    }
    
    .language-selection.show-page {
        padding: 50px 16px 20px;
    }
    
    .language-selection h3 {
        font-size: 26px;
    }
    
    .selection-description {
        font-size: 13px;
        margin-bottom: 20px;
    }
    
    .language-grid {
        max-width: 300px;
        width: 100%;
    }
    
    .language-item {
        min-height: 90px;
        padding: 0;
    }
    
    .language-content {
        padding: 14px;
    }
    
    .language-name {
        font-size: 15px;
    }
    
    
    .character-emotes {
        width: min(380px, calc(100vw - 20px));
        height: 400px;
    }
    
    .emote {
        width: 100px;
        height: 100px;
    }
    
    .waitlist-form.show .emote:hover {
        width: 105px;
        height: 105px;
    }
    
    .emote-top-left,
    .emote-top-right {
        top: -50px;
    }
    
    .emote-bottom-left,
    .emote-bottom-right {
        bottom: -50px;
    }
    
    .emote-top-left,
    .emote-bottom-left {
        left: 5px;
    }
    
    .emote-top-right,
    .emote-bottom-right {
        right: 5px;
    }
    
    .waitlist-form h3 {
        font-size: 28px;
    }
    
    .form-description {
        font-size: 13px;
    }
    
    .form-container {
        max-width: 290px;
        padding: 28px 20px;
        margin: auto;
    }
    
    .waitlist-form input[type="email"],
    .waitlist-form .submit-btn {
        padding: 14px 40px;
        font-size: 16px;
    }
    
    /* Thank you page improvements for small mobile */
    .thank-you-page {
        padding: 20px 16px;
    }
    
    .sleeping-marmunch {
        width: 200px;
        max-width: 85%;
        margin-bottom: 20px;
    }
    
    .thank-you-page h2 {
        font-size: 24px;
        margin-bottom: 12px;
    }
    
    .thank-you-page p {
        font-size: 15px;
    }
}

/* Removed - layout now handled by progressive responsive rules above */

/* Clean responsive layout solution */
