:root {
    --green: #173f32;
    --orange: #d96b27;
    --cream: #f5ead2;
    --brown: #3a2a1f;
    --gold: #c79a3b;
    --text: #18211d;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--cream);
    color: var(--text);
}

a {
    color: inherit;
    text-decoration: none;
}

.home {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background:
        radial-gradient(circle at top, rgba(217,107,39,0.18), transparent 35%),
        var(--cream);
}

.hero {
    width: 100%;
    max-width: 420px;
    text-align: center;
}

.logo {
    font-size: 52px;
    font-weight: 900;
    color: var(--green);
    letter-spacing: -1px;
}

.tagline {
    font-size: 20px;
    line-height: 1.35;
    margin: 16px 0 28px;
}

.rufus-card {
    background: rgba(255,255,255,0.65);
    border: 1px solid rgba(58,42,31,0.12);
    border-radius: 24px;
    padding: 22px;
    margin-bottom: 28px;
    box-shadow: 0 12px 30px rgba(58,42,31,0.12);
}

.rufus-placeholder {
    font-size: 80px;
    margin-bottom: 8px;
}

.btn-primary,
.btn-secondary {
    display: block;
    width: 100%;
    padding: 16px 20px;
    border-radius: 999px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 12px;
}

.btn-primary {
    background: var(--orange);
    color: white;
    box-shadow: 0 8px 18px rgba(217,107,39,0.32);
}

.btn-secondary {
    background: white;
    border: 1px solid rgba(23,63,50,0.2);
    color: var(--green);
}

.topbar {
    height: 56px;
    background: var(--green);
    color: white;
    display: flex;
    align-items: center;
    padding: 0 16px;
    position: sticky;
    top: 0;
    z-index: 10;
}

.back-link {
    font-size: 26px;
    margin-right: 12px;
}

.topbar-title {
    font-weight: 800;
    font-size: 20px;
}

.page {
    padding: 20px;
    max-width: 640px;
    margin: 0 auto;
}

.city-header h1 {
    font-size: 36px;
    margin: 10px 0;
    color: var(--green);
}

.city-header p {
    font-size: 17px;
    line-height: 1.45;
}

.progress-box {
    background: white;
    border-radius: 20px;
    padding: 18px;
    margin: 22px 0;
    border: 1px solid rgba(58,42,31,0.12);
}

.progress-title {
    font-weight: 800;
    margin-bottom: 8px;
}

.cards-list h2 {
    margin-top: 30px;
}

.card-row {
    display: flex;
    gap: 14px;
    background: rgba(255,255,255,0.7);
    border: 1px solid rgba(58,42,31,0.12);
    padding: 14px;
    border-radius: 16px;
    margin-bottom: 10px;
}

.card-number {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--green);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.card-row h3 {
    margin: 0;
    font-size: 17px;
}

.card-row p {
    margin: 4px 0 0;
    opacity: 0.7;
    font-size: 14px;
}




/* VILLE.PHP */
.city-page {
    padding-bottom: 40px;
}

.city-hero {
    background:
        radial-gradient(circle at top right, rgba(217,107,39,0.20), transparent 40%),
        rgba(255,255,255,0.74);
    border: 1px solid rgba(58,42,31,0.12);
    border-radius: 26px;
    padding: 22px;
    box-shadow: 0 14px 32px rgba(58,42,31,0.12);
}

.city-badge {
    display: inline-block;
    background: var(--green);
    color: white;
    border-radius: 999px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.city-hero h1 {
    margin: 16px 0 10px;
    color: var(--green);
    font-size: 40px;
    line-height: 1;
}

.city-hero p {
    margin: 0;
    font-size: 16px;
    line-height: 1.45;
}

.city-progress-card {
    margin-top: 18px;
    background: var(--green);
    color: white;
    border-radius: 20px;
    padding: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.city-progress-card span {
    display: block;
    font-size: 13px;
    opacity: 0.8;
    margin-bottom: 4px;
}

.city-progress-card strong {
    display: block;
    font-size: 24px;
    font-weight: 900;
}

.city-progress-icon {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: rgba(255,255,255,0.16);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
}

.city-actions {
    margin: 18px 0;
    display: grid;
    gap: 10px;
}

.city-rufus-tip {
    background: #fff7df;
    border: 1px solid rgba(217,107,39,0.24);
    border-radius: 20px;
    padding: 16px;
    margin-bottom: 22px;
}

.city-rufus-tip strong {
    color: var(--orange);
    font-weight: 900;
}

.city-rufus-tip p {
    margin: 6px 0 0;
    line-height: 1.45;
    font-size: 15px;
}

.section-title-row {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.section-title-row h2 {
    margin: 0;
    color: var(--green);
    font-size: 24px;
}

.section-title-row span {
    font-size: 13px;
    font-weight: 900;
    color: var(--orange);
}

.city-card-grid {
    display: grid;
    gap: 10px;
}

.city-card-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255,255,255,0.76);
    border: 2px solid rgba(58,42,31,0.12);
    border-radius: 18px;
    padding: 12px;
}

.city-card-number {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: var(--green);
    color: white;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
}

.city-card-content h3 {
    margin: 0;
    font-size: 16px;
    color: var(--text);
}

.city-card-content p {
    margin: 4px 0 0;
    font-size: 13px;
    font-weight: 800;
    opacity: 0.65;
}

.city-card-item.rarity-commune {
    border-color: #173f32;
}

.city-card-item.rarity-rare {
    border-color: #1d5f84;
}

.city-card-item.rarity-epique {
    border-color: #6c3c91;
}

.city-card-item.rarity-legendaire {
    border-color: #c79a3b;
}
.city-collections {
    margin-top: 22px;
}

.collections-list {
    display: grid;
    gap: 14px;
}

.collection-summary-card {
    background: rgba(255,255,255,0.78);
    border: 2px solid rgba(58,42,31,0.12);
    border-radius: 22px;
    padding: 16px;
    box-shadow: 0 10px 24px rgba(58,42,31,0.10);
}

.collection-summary-card.type-visite {
    border-color: rgba(23,63,50,0.42);
}

.collection-summary-card.type-bonus {
    border-color: rgba(199,154,59,0.60);
}

.collection-summary-card.type-evenement {
    border-color: rgba(108,60,145,0.60);
}

.collection-summary-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.collection-type {
    display: inline-block;
    background: var(--green);
    color: white;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.collection-summary-card.type-bonus .collection-type {
    background: #c79a3b;
}

.collection-summary-card.type-evenement .collection-type {
    background: #6c3c91;
}

.collection-summary-card h3 {
    margin: 0;
    font-size: 24px;
    color: var(--green);
    line-height: 1.1;
}

.collection-summary-card p {
    margin: 12px 0 16px;
    line-height: 1.45;
    font-size: 15px;
}

.collection-progress-mini {
    flex: 0 0 auto;
    min-width: 58px;
    height: 58px;
    border-radius: 50%;
    background: var(--green);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    box-shadow: 0 8px 18px rgba(23,63,50,0.22);
}

.collection-summary-actions {
    display: grid;
    gap: 10px;
}












/* COLLECTION.PHP */
.collection-card.unlocked {
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.collection-card.unlocked:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 28px rgba(58,42,31,0.16);
}

.card-detail-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(10, 18, 14, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
}

.card-detail-modal.hidden {
    display: none !important;
}


.card-detail-full {
    width: min(92vw, 460px);
    max-height: 92vh;
    aspect-ratio: 5 / 7;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 26px 70px rgba(0,0,0,0.5);
}

.card-detail-full img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}
.card-detail-close {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 10000;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.92);
    color: var(--green);
    font-size: 30px;
    line-height: 1;
    font-weight: 800;
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}



.rarity-bg-commune {
    background: #173f32;
}

.rarity-bg-rare {
    background: #1d5f84;
}

.rarity-bg-epique {
    background: #6c3c91;
}

.rarity-bg-legendaire {
    background: #c79a3b;
}
.mini-cards-preview {
    display: flex;
    gap: 6px;
    margin-top: 12px;
    padding: 8px 0 10px;
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
}

.mini-card-preview {
    flex: 0 0 auto;
    width: 34px;
    height: 48px;
    border-radius: 6px;
    overflow: hidden;
    background: rgba(23,63,50,0.10);
    box-shadow: 0 4px 10px rgba(0,0,0,0.14);
	 transition: transform 0.18s ease, opacity 0.18s ease, box-shadow 0.18s ease;
	 position: relative;
    z-index: 1;

}

.mini-card-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.mini-card-preview.is-locked {
    opacity: 0.38;
    filter: grayscale(0.45);
}

.mini-card-preview.is-unlocked {
    opacity: 1;
    cursor: pointer;
    box-shadow: 0 5px 14px rgba(0,0,0,0.22);
}

.mini-card-preview.is-unlocked:hover {
    transform: translateY(-2px) scale(1.04);
    z-index: 5;
}

.mini-card-preview:nth-child(2n) {
    transform: rotate(2deg);
}

.mini-card-preview:nth-child(2n + 1) {
    transform: rotate(-2deg);
}

.mini-card-preview.is-unlocked {
    opacity: 1;
}












/* INDEX */
.app-home {
    min-height: 100vh;
    padding: 18px;
    background:
        radial-gradient(circle at top, rgba(217,107,39,0.20), transparent 34%),
        linear-gradient(180deg, #f8edcf 0%, #ead8ad 100%);
}

.home-hero {
    max-width: 520px;
    margin: 0 auto;
}

.home-hero-img {
    width: 100%;
    display: block;
    border-radius: 28px;
    box-shadow: 0 18px 42px rgba(58,42,31,0.24);
    border: 2px solid rgba(255,255,255,0.7);
}

.home-intro {
    margin-top: -34px;
    position: relative;
    background: rgba(245,234,210,0.94);
    border: 1px solid rgba(58,42,31,0.12);
    border-radius: 26px;
    padding: 20px;
    box-shadow: 0 14px 32px rgba(58,42,31,0.16);
}

.home-badge {
    display: inline-block;
    background: var(--green);
    color: white;
    border-radius: 999px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.home-intro h1 {
    margin: 14px 0 8px;
    color: var(--green);
    font-size: 34px;
    line-height: 1.05;
}

.home-intro p {
    margin: 0;
    font-size: 16px;
    line-height: 1.45;
}

.home-card {
    max-width: 520px;
    margin: 18px auto 0;
    background: rgba(255,255,255,0.76);
    border: 1px solid rgba(58,42,31,0.14);
    border-radius: 24px;
    padding: 18px;
    box-shadow: 0 12px 28px rgba(58,42,31,0.12);
}

.home-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.home-label {
    display: block;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--orange);
    margin-bottom: 4px;
}

.home-card h2 {
    margin: 0;
    color: var(--green);
    font-size: 23px;
}

.home-card p {
    margin: 14px 0 18px;
    font-size: 15px;
    line-height: 1.45;
}

.home-counter {
    flex: 0 0 auto;
    min-width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--green);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 18px;
    box-shadow: 0 8px 18px rgba(23,63,50,0.26);
}

.home-actions {
    display: grid;
    gap: 10px;
}

.home-info {
    max-width: 520px;
    margin: 18px auto 0;
    display: grid;
    gap: 10px;
}

.home-info article {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(23,63,50,0.08);
    border-radius: 18px;
    padding: 12px;
    border: 1px solid rgba(23,63,50,0.08);
}

.home-info strong {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--orange);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.home-info span {
    font-weight: 700;
    color: var(--green);
}
.home-cities-list {
    max-width: 520px;
    margin: 18px auto 0;
    display: grid;
    gap: 16px;
}

.home-city-card {
    background: rgba(255,255,255,0.78);
    border: 1px solid rgba(58,42,31,0.14);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 12px 28px rgba(58,42,31,0.12);
}

.home-city-img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    display: block;
}

.home-city-content {
    padding: 18px;
}

.home-city-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.home-city-card h3 {
    margin: 0;
    color: var(--green);
    font-size: 25px;
}

.home-city-card p {
    margin: 12px 0 16px;
    line-height: 1.45;
    font-size: 15px;
}

.home-city-count {
    flex: 0 0 auto;
    min-width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--green);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    box-shadow: 0 8px 18px rgba(23,63,50,0.22);
}
.home-main-actions {
    display: grid;
    gap: 12px;
}

.home-big-action {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--orange);
    color: white;
    border-radius: 22px;
    padding: 18px;
    box-shadow: 0 10px 24px rgba(217,107,39,0.25);
}

.home-big-action.secondary {
    background: white;
    color: var(--green);
    border: 1px solid rgba(23,63,50,0.18);
    box-shadow: 0 10px 24px rgba(58,42,31,0.10);
}

.home-big-icon {
    width: 54px;
    height: 54px;
    flex: 0 0 auto;
    border-radius: 18px;
    background: rgba(255,255,255,0.20);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
}

.home-big-action.secondary .home-big-icon {
    background: rgba(23,63,50,0.08);
}

.home-big-action strong {
    display: block;
    font-size: 22px;
    font-weight: 900;
}

.home-big-action small {
    display: block;
    margin-top: 3px;
    font-size: 14px;
    opacity: 0.85;
}














/* CARTE */
.gps-box {
    background: white;
    border-radius: 20px;
    padding: 16px;
    margin: 20px 0;
    border: 1px solid rgba(58,42,31,0.12);
}

#gpsStatus {
    font-weight: 700;
    margin-bottom: 12px;
}

.discover-card {
    background: rgba(255,255,255,0.75);
    border: 1px solid rgba(58,42,31,0.12);
    border-radius: 18px;
    padding: 16px;
    margin-bottom: 14px;
}

.discover-top {
    display: flex;
    gap: 14px;
    align-items: center;
}

.discover-top h3 {
    margin: 0;
    font-size: 18px;
}

.discover-top p {
    margin: 4px 0 0;
    font-size: 14px;
    opacity: 0.7;
}

.discover-status {
    margin: 14px 0 6px;
    font-weight: 900;
}

.discover-desc {
    margin: 0 0 14px;
    line-height: 1.4;
}

.discover-card.near {
    border-color: var(--orange);
    box-shadow: 0 10px 24px rgba(217,107,39,0.18);
}

.discover-card.near .discover-status {
    color: var(--orange);
}

.discover-card.unlocked {
    border-color: var(--green);
    background: rgba(255,255,255,0.9);
}

.discover-card.unlocked .discover-status {
    color: var(--green);
}

.btn-disabled {
    display: block;
    width: 100%;
    padding: 16px 20px;
    border-radius: 999px;
    border: 0;
    font-weight: 800;
    color: rgba(24,33,29,0.45);
    background: rgba(24,33,29,0.08);
}
.page-map {
    padding-bottom: 40px;
}

.map-box {
    background: white;
    border-radius: 22px;
    padding: 10px;
    margin: 20px 0;
    border: 1px solid rgba(58,42,31,0.12);
    box-shadow: 0 10px 24px rgba(58,42,31,0.10);
}


#baladexMap {
    width: 100%;
    height: 420px;
    min-height: 420px;
    border-radius: 16px;
    overflow: hidden;
    background: #ddd;
}

.leaflet-popup-content {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.map-popup-title {
    font-weight: 900;
    color: var(--green);
    margin-bottom: 4px;
}

.map-popup-meta {
    font-size: 13px;
    opacity: 0.75;
}
.map-card-marker {
    position: relative;
    width: 32px;
    height: 45px;
    transform: rotate(-4deg);
    border-radius: 5px;
    box-shadow: 0 5px 12px rgba(0,0,0,0.28);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.map-card-marker img {
    width: 32px;
    height: 45px;
    object-fit: cover;
    display: block;
    border-radius: 5px;
    border: 2px solid rgba(255,255,255,0.9);
}

.map-card-marker:hover {
    transform: rotate(0deg) scale(1.18);
    box-shadow: 0 8px 18px rgba(0,0,0,0.35);
}

.map-card-number {
    position: absolute;
    top: -7px;
    right: -7px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: 999px;
    background: var(--green);
    color: white;
    font-size: 9px;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid white;
}

.map-card-marker.is-near {
    animation: cardPulse 1.4s infinite;
}

.map-card-marker.is-near img {
    border-color: var(--orange);
}

.map-card-marker.is-near .map-card-number {
    background: var(--orange);
}

.map-card-marker.is-unlocked {
    transform: rotate(0deg);
}

.map-card-marker.is-unlocked img {
    border-color: var(--green);
    filter: saturate(1.1) contrast(1.05);
}

.map-card-marker.is-unlocked .map-card-number {
    background: var(--green);
}
.map-card-marker.is-unlocked img {
    object-fit: cover;
}
.map-card-marker.is-unlocked {
    width: 36px;
    height: 50px;
}

.map-card-marker.is-unlocked img {
    width: 36px;
    height: 50px;
}

.map-card-marker.is-rare img {
    border-color: #1d5f84;
}

.map-card-marker.is-epique img {
    border-color: #6c3c91;
}

.map-card-marker.is-legendaire img {
    border-color: #c79a3b;
}

@keyframes cardPulse {
    0% {
        transform: rotate(-4deg) scale(1);
        box-shadow: 0 5px 12px rgba(0,0,0,0.28);
    }

    50% {
        transform: rotate(0deg) scale(1.18);
        box-shadow: 0 9px 20px rgba(217,107,39,0.42);
    }

    100% {
        transform: rotate(-4deg) scale(1);
        box-shadow: 0 5px 12px rgba(0,0,0,0.28);
    }
}

.map-popup-card {
    min-width: 180px;
}

.map-popup-title {
    font-weight: 900;
    color: var(--green);
    margin-bottom: 5px;
}

.map-popup-meta {
    font-size: 13px;
    opacity: 0.75;
    margin-bottom: 10px;
}

.map-popup-hint {
    font-size: 13px;
    font-style: italic;
    opacity: 0.75;
}

.map-popup-btn {
    display: block;
    width: 100%;
    border: 0;
    border-radius: 999px;
    padding: 10px 14px;
    background: var(--orange);
    color: white;
    font-weight: 900;
    text-align: center;
    cursor: pointer;
    font-size: 14px;
}
.map-screen-body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    background: var(--green);
}

.map-screen {
    position: fixed;
    inset: 0;
    overflow: hidden;
}

.fullscreen-map {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.map-top-overlay {
    position: fixed;
    top: 14px;
    left: 14px;
    right: 14px;
    z-index: 800;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    pointer-events: none;
}

.map-logo-small {
    background: rgba(23,63,50,0.94);
    color: white;
    border-radius: 999px;
    padding: 9px 14px;
    font-weight: 900;
    box-shadow: 0 8px 20px rgba(0,0,0,0.22);
}

.map-gps-status {
    background: rgba(255,255,255,0.94);
    color: var(--green);
    border-radius: 999px;
    padding: 8px 12px;
    font-size: 12px;
    font-weight: 800;
    box-shadow: 0 8px 20px rgba(0,0,0,0.18);
    max-width: 58vw;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bottom-nav {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 12px;
    z-index: 900;
    height: 66px;
    background: rgba(255,255,255,0.94);
    border-radius: 24px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    align-items: center;
    box-shadow: 0 14px 34px rgba(0,0,0,0.26);
    border: 1px solid rgba(23,63,50,0.12);
    backdrop-filter: blur(10px);
}

.bottom-nav-item {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    color: rgba(23,63,50,0.62);
    font-weight: 800;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
}


.bottom-nav-item small {
    font-size: 11px;
}

.bottom-nav-item span {
    line-height: 1;
}

.bottom-nav-item.active span {
    transform: none;
}


.debug-box-map {
    position: fixed;
    left: 14px;
    right: 14px;
    bottom: 90px;
    z-index: 850;
    max-height: 38vh;
    overflow-y: auto;
}
.map-recenter-btn {
    position: fixed;
    right: 16px;
    bottom: 92px;
    z-index: 900;
    width: 52px;
    height: 52px;
    border: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.96);
    color: var(--green);
    font-size: 30px;
    font-weight: 900;
    line-height: 1;
    box-shadow: 0 10px 26px rgba(0,0,0,0.28);
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-tap-highlight-color: transparent;
}

.map-recenter-btn:active {
    transform: scale(0.94);
}


.empty-map-card {
    border-style: dashed;
    background: rgba(255,255,255,0.82);
}

.empty-map-card .card-number {
    background: rgba(23,63,50,0.10);
    color: var(--green);
}
















/* COLLECTION */
.collection-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 22px 0;
}

.collection-card {
    background: rgba(255,255,255,0.78);
    border-radius: 18px;
    overflow: hidden;
    border: 2px solid rgba(58,42,31,0.12);
    box-shadow: 0 10px 22px rgba(58,42,31,0.08);
}
.collection-card.unlocked {
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(217,107,39,0.18);
}

.collection-img-wrap {
    aspect-ratio: 5 / 7;
    background: rgba(24,33,29,0.08);
    overflow: hidden;
}

.collection-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.collection-info {
    padding: 10px;
}

.collection-number {
    font-size: 12px;
    font-weight: 900;
    color: var(--green);
    margin-bottom: 4px;
}

.collection-info h3 {
    margin: 0;
    font-size: 14px;
    line-height: 1.2;
}

.collection-info p {
    margin: 5px 0 0;
    font-size: 12px;
    font-weight: 800;
    opacity: 0.7;
}

.locked {
    opacity: 0.75;
}

.locked-card {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background:
        radial-gradient(circle at top, rgba(217,107,39,0.15), transparent 40%),
        linear-gradient(145deg, rgba(23,63,50,0.18), rgba(23,63,50,0.06));
}

.locked-number {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--green);
    color: white;
    font-weight: 900;
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 12px;
}

.locked-question {
    font-size: 64px;
    font-weight: 900;
    color: rgba(23,63,50,0.35);
}

.rarity-commune {
    border-color: #173f32;
}

.rarity-rare {
    border-color: #1d5f84;
}

.rarity-epique {
    border-color: #6c3c91;
}

.rarity-legendaire {
    border-color: #c79a3b;
}







/* MON COMPTE */
.account-page {
    padding-bottom: 110px;
}

.account-card {
    background: rgba(255,255,255,0.78);
    border: 1px solid rgba(58,42,31,0.14);
    border-radius: 22px;
    padding: 18px;
    margin-top: 18px;
    box-shadow: 0 12px 28px rgba(58,42,31,0.10);
}

.account-card h2 {
    margin: 0 0 12px;
    color: var(--green);
    font-size: 23px;
}

.account-card p {
    margin: 0 0 14px;
    line-height: 1.45;
    font-size: 15px;
}

.account-status {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.account-status-dot {
    width: 14px;
    height: 14px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--orange);
    margin-top: 4px;
    box-shadow: 0 0 0 5px rgba(217,107,39,0.16);
}

.account-status strong {
    display: block;
    color: var(--green);
    font-size: 18px;
    margin-bottom: 4px;
}

.account-status p {
    margin: 0;
}

.account-help {
    opacity: 0.72;
}

.account-uid {
    display: block;
    width: 100%;
    padding: 12px;
    background: rgba(23,63,50,0.08);
    border-radius: 12px;
    color: var(--green);
    font-size: 12px;
    word-break: break-all;
}

.account-actions {
    display: grid;
    gap: 10px;
}

.account-note {
    margin-top: 12px !important;
    font-size: 13px !important;
    opacity: 0.65;
}
.account-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    width: 100%;
}

.account-stats-grid div {
    background: rgba(255,255,255,0.72);
    border-radius: 16px;
    padding: 12px 10px;
    text-align: center;
}

.account-stats-grid span {
    display: block;
    font-size: 12px;
    font-weight: 700;
    opacity: 0.7;
    margin-bottom: 5px;
}

.account-stats-grid strong {
    display: block;
    color: var(--green);
    font-size: 26px;
    font-weight: 900;
}









/* AUTH */
.auth-form {
    background: rgba(255,255,255,0.78);
    border: 1px solid rgba(58,42,31,0.14);
    border-radius: 22px;
    padding: 18px;
    margin-top: 18px;
    box-shadow: 0 12px 28px rgba(58,42,31,0.10);
    display: grid;
    gap: 16px;
}

.auth-form label {
    display: grid;
    gap: 7px;
    font-weight: 800;
    color: var(--green);
}

.auth-form input {
    width: 100%;
    border: 1px solid rgba(58,42,31,0.22);
    border-radius: 14px;
    padding: 14px;
    font: inherit;
    background: white;
    color: var(--text);
}

.form-error {
    background: #ffe5e5;
    color: #8d1f1f;
    border: 1px solid rgba(141,31,31,0.18);
    border-radius: 16px;
    padding: 14px;
    margin-top: 18px;
    font-weight: 800;
}









/* NAV */
.nav-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-icon svg {
    width: 24px;
    height: 24px;
    display: block;
    fill: currentColor;
}

.bottom-nav-item small {
    font-size: 11px;
    line-height: 1;
}

.bottom-nav-item.active .nav-icon {
    transform: translateY(-1px) scale(1.08);
}
.app-home {
    padding-bottom: 96px;
}













/* MODAL */
.unlock-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(10, 18, 14, 0.82);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
}

.unlock-modal.hidden {
    display: none !important;
}

.unlock-modal-content {
    position: relative;
    width: 100%;
    max-width: 420px;
    max-height: 92vh;
    overflow-y: auto;
    background:
        radial-gradient(circle at top, rgba(217,107,39,0.18), transparent 35%),
        var(--cream);
    border-radius: 28px;
    padding: 22px;
    text-align: center;
    box-shadow: 0 24px 60px rgba(0,0,0,0.35);
    border: 2px solid rgba(199,154,59,0.45);
}

.unlock-close {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 50%;
    background: rgba(23,63,50,0.12);
    color: var(--green);
    font-size: 26px;
    line-height: 1;
    font-weight: 800;
}

.unlock-card-full {
    width: min(92vw, 460px);
    max-height: 92vh;
    aspect-ratio: 5 / 7;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 26px 70px rgba(0,0,0,0.5);
}

.unlock-card-full img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.unlock-close.simple-close {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 10000;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.92);
    color: var(--green);
    font-size: 30px;
    line-height: 1;
    font-weight: 800;
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}


.mini-card-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(10, 18, 14, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.mini-card-modal.hidden {
    display: none !important;
}

.mini-card-modal-content {
    width: min(90vw, 430px);
    max-height: 90vh;
    aspect-ratio: 5 / 7;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 26px 70px rgba(0,0,0,0.55);
    animation: miniCardZoomIn 0.22s ease-out;
}

.mini-card-modal-content img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.mini-card-modal-close {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 10000;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.92);
    color: var(--green);
    font-size: 30px;
    line-height: 1;
    font-weight: 800;
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}

@keyframes miniCardZoomIn {
    from {
        opacity: 0;
        transform: scale(0.72) translateY(18px);
    }

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















/* MES COLLECTIONS */
.my-collections-page {
    padding-bottom: 110px;
}

.my-collections-list {
    margin-top: 22px;
    display: grid;
    gap: 22px;
}

.my-city-block {
    background: rgba(255,255,255,0.64);
    border: 1px solid rgba(58,42,31,0.12);
    border-radius: 24px;
    padding: 16px;
    box-shadow: 0 12px 28px rgba(58,42,31,0.10);
}

.my-city-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
}

.my-city-header h2 {
    margin: 0;
    color: var(--green);
    font-size: 28px;
}

.my-city-progress {
    flex: 0 0 auto;
    min-width: 58px;
    height: 58px;
    border-radius: 50%;
    background: var(--green);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    box-shadow: 0 8px 18px rgba(23,63,50,0.22);
}

.my-collection-cards {
    display: grid;
    gap: 12px;
}

.my-collection-card {
    background: rgba(255,255,255,0.82);
    border: 2px solid rgba(58,42,31,0.12);
    border-radius: 20px;
    padding: 14px;
	 overflow: visible;
}

.my-collection-card.type-visite {
    border-color: rgba(23,63,50,0.42);
}

.my-collection-card.type-bonus {
    border-color: rgba(199,154,59,0.60);
}

.my-collection-card.type-evenement {
    border-color: rgba(108,60,145,0.60);
}

.my-collection-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.my-collection-card h3 {
    margin: 0;
    color: var(--green);
    font-size: 22px;
}

.my-collection-card p {
    margin: 12px 0 14px;
    font-size: 15px;
    line-height: 1.45;
}

.collection-progress-bar {
    width: 100%;
    height: 9px;
    background: rgba(23,63,50,0.12);
    border-radius: 999px;
    overflow: hidden;
    margin-top: 12px;
}

.collection-progress-bar div {
    height: 100%;
    background: var(--orange);
    border-radius: 999px;
}

.empty-collection-box {
    background: rgba(255,255,255,0.78);
    border: 1px solid rgba(58,42,31,0.12);
    border-radius: 22px;
    padding: 18px;
    text-align: center;
}

.empty-collection-box h2 {
    margin: 0 0 8px;
    color: var(--green);
}

.empty-collection-box p {
    margin: 0 0 16px;
    line-height: 1.45;
}

.page-bottom-nav {
    position: fixed;
}
.my-collection-section {
    display: grid;
    gap: 14px;
}

.my-collection-section + .my-collection-section {
    margin-top: 24px;
}

.my-collection-section-title h2 {
    margin: 0;
    color: var(--green);
    font-size: 25px;
}

.my-collection-section-title p {
    margin: 5px 0 0;
    font-size: 14px;
    line-height: 1.4;
    opacity: 0.75;
}

.empty-collection-box.compact {
    text-align: left;
    padding: 14px 16px;
}

.empty-collection-box.compact p {
    margin: 0;
}
















/* DEBUG */
.debug-box {
    background: #fff7df;
    border: 2px dashed var(--orange);
    border-radius: 18px;
    padding: 14px;
    margin: 20px 0;
}

.debug-box strong {
    color: var(--orange);
    font-weight: 900;
}

.debug-box p {
    margin: 6px 0 12px;
    font-size: 14px;
}

.debug-buttons {
    display: grid;
    gap: 8px;
}

.debug-btn {
    width: 100%;
    border: 0;
    border-radius: 999px;
    padding: 11px 14px;
    background: var(--green);
    color: white;
    font-weight: 800;
    text-align: left;
}





html,
body {
    width: 100%;
    min-height: 100%;
}

body.map-screen-body {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 100vh;
    min-height: 100dvh;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background: var(--green);
}

.map-screen {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
}

#baladexMap.fullscreen-map,
.fullscreen-map {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    min-height: 100vh !important;
    min-height: 100dvh !important;
    z-index: 1;
}



