/* Reset et base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
}

body {
    overflow-x: hidden;
}

:root {
    --primary-color: #00d4ff;
    --secondary-color: #7c3aed;
    --accent-color: #f59e0b;
    --bg-dark: #0a0a0a;
    --bg-card: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --border-color: #333333;
    --gradient-primary: linear-gradient(135deg, #00d4ff 0%, #7c3aed 100%);
    --gradient-card: linear-gradient(145deg, #1a1a1a 0%, #2a2a2a 100%);
}

body {
    font-family: 'Rajdhani', sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    width: 100%;
    max-width: 100vw;
}

/* Navigation */
.navbar {
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0.75rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    box-sizing: border-box;
}

.brand-link {
    text-decoration: none;
}

.nav-brand h1 {
    font-family: 'Orbitron', monospace;
    font-size: 1.3rem;
    font-weight: 900;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: all 0.3s ease;
}

.brand-link:hover h1 {
    transform: scale(1.05);
}

.nav-subtitle {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 300;
    text-decoration: none;
    transition: all 0.3s ease;
}

.nav-subtitle:hover {
    color: var(--primary-color);
    transform: scale(1.1);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
    background: rgba(0, 212, 255, 0.1);
}

.lang-switch {
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    background: transparent;
    cursor: pointer;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 500;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.hamburger-line {
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    margin: 3px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.hamburger.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.hamburger.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* Main content */
.main-content {
    margin-top: 65px;
    min-height: calc(100vh - 65px);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
    box-sizing: border-box;
}

/* Boutons */
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    border: none;
    border-radius: 0.5rem;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    font-size: 1.1rem;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 212, 255, 0.3);
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
}

/* Hero Section */
.hero {
    padding: 6rem 0;
    background: radial-gradient(ellipse at center, rgba(124, 58, 237, 0.15) 0%, transparent 70%);
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    width: 100%;
    box-sizing: border-box;
}

.hero-image {
    text-align: center;
}

.hero-main-image {
    max-width: 100%;
    height: auto;
    border-radius: 1rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.hero-main-image:hover {
    transform: scale(1.02);
}

.hero-content {
    text-align: left;
}

.hero-title {
    font-family: 'Orbitron', monospace;
    font-size: 3.5rem;
    font-weight: 900;
    margin-bottom: 1rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-weight: 300;
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.hero-reward {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 1rem;
    padding: 1.5rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin: 2rem auto 3rem;
    max-width: 600px;
    text-align: center;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.1);
}

.hero-actions {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Game Steps */
.game-steps {
    padding: 6rem 0;
}

.rules-intro {
    text-align: center;
    font-size: 1.2rem;
    margin-bottom: 4rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    color: var(--text-secondary);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.step-card {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.step-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-primary);
}

.step-number {
    display: inline-block;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 60px;
    margin-bottom: 1.5rem;
}

.step-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

/* Concept Page */
.concept-hero {
    padding-top: 4rem;
    text-align: center;
    background: radial-gradient(ellipse at center, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
}

.concept-hero h1 {
    font-family: 'Orbitron', monospace;
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.concept-description {
    font-size: 1.2rem;
    color: var(--text-secondary);
    max-width: 800px;
    margin: 0 auto;
}

.concept-content {
    padding: 4rem 0;
}

.concept-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.concept-card {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 2rem;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.concept-card.full-width {
    grid-column: 1 / -1;
}

.concept-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.concept-visual {
    text-align: center;
}

.plaque-mockup {
    display: inline-block;
    perspective: 1000px;
}

.plaque {
    background: #8B4513;
    width: 200px;
    height: 200px;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transform: rotateX(10deg) rotateY(-10deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.qr-code {
    width: 80px;
    height: 80px;
    background: white;
    margin: 0 auto;
    border-radius: 5px;
}

.plaque h4 {
    color: white;
    font-size: 0.9rem;
    margin: 10px 0;
}

.signature {
    color: white;
    font-size: 0.8rem;
    font-weight: bold;
}

/* Rules Page */
.rules-hero {
    padding-top: 4rem;
    text-align: center;
    background: radial-gradient(ellipse at center, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
}

.rules-hero h1 {
    font-family: 'Orbitron', monospace;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.rules-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.choose-offer {
    font-size: 1.1rem;
    color: var(--accent-color);
    font-weight: 600;
}

.offers-section {
    padding: 4rem 0;
}

.offers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.offer-card {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.offer-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 212, 255, 0.1);
}

.offer-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.offer-card small {
    color: var(--text-secondary);
    font-style: italic;
    display: block;
    margin-top: 1rem;
}

.signature {
    text-align: center;
    font-size: 1.2rem;
    color: var(--text-secondary);
    font-style: italic;
}

/* Game Page */
.game-hero {
    padding: 4rem 0 2rem;
    text-align: center;
}

.game-hero h1 {
    font-family: 'Orbitron', monospace;
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.game-notice {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid var(--accent-color);
    border-radius: 0.5rem;
    padding: 1rem;
    margin: 1.5rem auto;
    max-width: 600px;
}

.game-notice p {
    color: var(--accent-color);
    font-weight: 600;
}

.game-instructions,
.countries-count {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.game-area {
    padding: 2rem 0;
}

#game-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

#world-map {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    min-height: 500px;
    padding: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
}

#photo-gallery {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 1rem;
}

#photo-gallery h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    text-align: center;
}

#photos-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 0.5rem;
}

.game-controls {
    text-align: center;
}

#submit-game:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Rewards Section */
.rewards-section {
    padding: 4rem 0;
    background: rgba(124, 58, 237, 0.05);
}

.rewards-section h2 {
    text-align: center;
    font-family: 'Orbitron', monospace;
    color: var(--primary-color);
    margin-bottom: 3rem;
}

.rewards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.reward-item {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 1rem;
    text-align: center;
    font-size: 0.9rem;
}

.reward-item.special {
    border-color: var(--accent-color);
    background: linear-gradient(145deg, rgba(245, 158, 11, 0.1), rgba(245, 158, 11, 0.05));
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: var(--gradient-card);
    margin: 10% auto;
    padding: 2rem;
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    width: 90%;
    max-width: 500px;
    position: relative;
}

.close {
    color: var(--text-secondary);
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    top: 1rem;
    right: 1.5rem;
}

.close:hover {
    color: var(--primary-color);
}

#wallet-address {
    width: 100%;
    padding: 1rem;
    margin: 1rem 0;
    background: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-family: 'Rajdhani', sans-serif;
}

/* Footer */
.footer {
    background: var(--bg-card);
    border-top: 1px solid var(--border-color);
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.social-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.social-links a:hover {
    color: var(--primary-color);
}

.social-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.social-links a:hover .social-icon {
    transform: scale(1.1);
}

/* Icônes sociales inline pour la page Participer */
.social-icon-inline {
    width: 24px;
    height: 24px;
    object-fit: contain;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 0.25rem;
}

.social-link:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.2);
}

.social-link.twitter:hover .social-icon-inline {
    filter: brightness(1.2);
}

.social-link.instagram:hover .social-icon-inline {
    filter: brightness(1.2);
}

.social-link.linkedin:hover .social-icon-inline {
    filter: brightness(1.2);
}

/* Styles pour l'offre du spéculateur */
.speculator-quote {
    font-style: italic;
    color: var(--accent-color);
    font-size: 1.1rem;
    margin: 1rem 0;
    padding: 1rem;
    background: rgba(245, 158, 11, 0.1);
    border-left: 4px solid var(--accent-color);
    border-radius: 0.5rem;
}

.speculator-links {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1rem;
}

.speculation-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1) 0%, rgba(239, 68, 68, 0.1) 100%);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 0.5rem;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.speculation-link:hover {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2) 0%, rgba(239, 68, 68, 0.2) 100%);
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
    text-align: center;
    color: var(--text-secondary);
}

/* Cacher le bouton fermer par défaut (desktop) */
.close-menu-item {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: #000000;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 9999;
    }
    
    .nav-menu.active {
        transform: translateX(0);
    }
    
    .nav-brand h1 {
        font-size: 1.3rem;
    }
    
    .nav-link {
        font-size: 1.2rem;
        padding: 1rem 2rem;
        width: 200px;
        text-align: center;
        border-radius: 0.75rem;
    }
    
    /* Afficher le bouton fermer seulement sur mobile */
    .close-menu-item {
        display: block;
        position: absolute;
        top: 2rem;
        right: 2rem;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }
    
    .nav-menu.active .close-menu-item {
        opacity: 1;
        visibility: visible;
    }
    
    .close-menu-btn {
        background: none;
        border: 2px solid rgba(255, 255, 255, 0.3);
        color: white;
        padding: 0.75rem 1.5rem;
        border-radius: 2rem;
        cursor: pointer;
        font-size: 1rem;
        font-weight: 600;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }
    
    .close-menu-btn:hover {
        background: rgba(255, 255, 255, 0.1);
        border-color: var(--primary-color);
        color: var(--primary-color);
        transform: scale(1.05);
    }
    
    .close-icon {
        font-size: 1.5rem;
        line-height: 1;
    }
    
    .close-text {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .close-menu-btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .close-menu-item {
        top: 1rem;
        right: 1rem;
    }
}

@media (max-width: 768px) {
    .main-content {
        margin-top: 65px;
    }
    
    .hero-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    
    .hero-content {
        text-align: center;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: center;
    }
    
    #game-container {
        grid-template-columns: 1fr;
    }
    
    .container {
        padding: 0 1rem;
    }
    
    /* Prévenir tout débordement sur mobile */
    * {
        max-width: 100%;
    }
    
    .hero-actions {
        width: 100%;
    }
    
    .hero-actions .btn {
        max-width: 280px;
    }
    
    .nav-container {
        padding: 0.75rem 1rem;
    }
    
    /* Grilles responsive écrans moyens */
    .offers-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
        gap: 1.5rem;
    }
    
    .concept-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        gap: 1.5rem;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .container {
        padding: 0 0.75rem;
    }
    
    .nav-container {
        padding: 0.5rem 0.75rem;
    }
    
    .hero-container {
        padding: 0 1rem;
        gap: 2rem;
    }
    
    .hero-actions .btn {
        width: 100%;
        max-width: 250px;
        margin: 0.5rem 0;
    }
    
    /* Grilles responsive très petits écrans */
    .offers-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .concept-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    /* Contraintes sur les éléments internes des cartes */
    .offer-card * {
        max-width: 100%;
        word-wrap: break-word;
    }
    
    .concept-card * {
        max-width: 100%;
        word-wrap: break-word;
    }
    
    .offer-card {
        padding: 1.5rem;
    }
    
    .concept-card {
        padding: 1.5rem;
    }
}