@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@400;600;700&family=Quicksand:wght@500;600;700&display=swap');

:root {
    --bg-playful: linear-gradient(135deg, #74ebe5 0%, #89f7fe 100%);
    --card-bg: #ffffff;
    --primary-color: #ff5252;
    --primary-hover: #ff3838;
    --secondary-color: #2ed573;
    --secondary-hover: #26af5f;
    --accent-yellow: #ffa502;
    --accent-purple: #3742fa;
    --accent-pink: #ff78ae;
    --text-dark: #2f3542;
    --text-muted: #747d8c;
    --shadow-container: 0 20px 60px rgba(0, 0, 0, 0.12);
    --shadow-card: 0 8px 20px rgba(0, 0, 0, 0.1);
    --radius-container: 24px;
    --radius-card: 16px;
    --font-heading: 'Fredoka', cursive, sans-serif;
    --font-body: 'Quicksand', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
    -webkit-user-drag: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

html, body {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
    position: fixed;
    top: 0; left: 0;
    margin: 0; padding: 0;
}

body {
    font-family: var(--font-body);
    background: var(--bg-playful);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dark);
}

/* ===================== BACKGROUND FLOATING ELEMENTS ===================== */
.bg-bubbles {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.bubble {
    position: absolute;
    font-size: clamp(2rem, 4vw, 3.2rem);
    opacity: 0.18;
    animation: floatUp 14s infinite linear;
}

@keyframes floatUp {
    0% { transform: translateY(100vh) rotate(0deg); opacity: 0; }
    20% { opacity: 0.25; }
    80% { opacity: 0.25; }
    100% { transform: translateY(-10vh) rotate(360deg); opacity: 0; }
}

/* ===================== APP CONTAINER ===================== */
.app-container {
    position: relative;
    z-index: 10;
    width: calc(100vw - 32px);
    height: calc(100vh - 32px);
    max-width: 1400px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-container);
    box-shadow: var(--shadow-container);
    padding: 16px 20px;
    border: 4px solid #ffffff;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* ===================== OUTER HEADER ===================== */
.header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 8px;
    border-bottom: 2px solid #f1f2f6;
    gap: 8px;
    flex-shrink: 0;
}

.title-box {
    display: flex;
    align-items: center;
    justify-content: center;
}

.title-box h1 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--primary-color);
    text-shadow: 2px 2px 0px #ffe66d;
    line-height: 1;
    white-space: nowrap;
    text-align: center;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.btn-sm {
    font-size: 0.85rem;
    padding: 5px 12px;
    min-height: 34px;
    gap: 4px;
}

.stats-pill-sm {
    padding: 4px 10px;
    font-size: 0.9rem;
}

/* ===================== STATS PILL COMPONENT ===================== */
.stats-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    padding: 6px 14px;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    font-family: var(--font-heading);
    font-size: 1rem;
    border: 2px solid #eccc68;
    color: var(--text-dark);
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.stat-icon {
    font-size: 1.1em;
}

.stat-divider {
    width: 2px;
    height: 14px;
    background: #e0e0e0;
    border-radius: 2px;
}

/* ===================== BUTTONS SYSTEM ===================== */
.btn {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    padding: 8px 18px;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    min-height: 38px;
    font-weight: 700;
    white-space: nowrap;
}

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

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

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 82, 82, 0.35);
}

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

.btn-secondary:hover {
    background: var(--secondary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(46, 213, 115, 0.35);
}

.btn-accent {
    background: var(--accent-pink);
    color: white;
}

.btn-accent:hover {
    background: #ff5293;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 120, 174, 0.4);
}

.btn-hint {
    background: #ffbe76;
    color: #333;
}

.btn-hint:hover {
    background: #f79f1f;
    transform: translateY(-2px);
}

.btn-icon-only {
    padding: 0;
    border-radius: 50%;
    width: 38px;
    height: 38px;
    min-width: 38px;
    flex-shrink: 0;
}

/* ===================== SANAL PATİ DOSTU (VIRTUAL PET BOX) ===================== */
.virtual-pet-container {
    display: flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, #fff9e6 0%, #ffeaa7 50%, #fff0f5 100%);
    border: 3.5px dashed #ffa502;
    border-radius: 22px;
    padding: 12px 20px;
    margin-bottom: 12px;
    box-shadow: 0 8px 20px rgba(254, 202, 87, 0.35);
    flex-shrink: 0;
    width: 100%;
    transition: transform 0.25s ease;
}

.virtual-pet-container:hover {
    transform: scale(1.01);
}

.pet-avatar-wrapper {
    position: relative;
    font-size: 2.8rem;
    cursor: pointer;
    line-height: 1;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    background: #ffffff;
    border-radius: 50%;
    width: 64px;
    height: 64px;
    min-width: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 14px rgba(0,0,0,0.12);
    border: 3px solid #ffbe76;
}

.pet-avatar-wrapper:hover {
    transform: scale(1.18) rotate(-6deg);
}

.pet-hat {
    position: absolute;
    top: -12px;
    right: -6px;
    font-size: 1.4rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.pet-details {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.pet-name {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    color: var(--primary-color);
    font-weight: 700;
    line-height: 1.2;
}

.pet-speech-inline {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-dark);
    background: #ffffff;
    border: 2px solid #ffa502;
    padding: 5px 14px;
    border-radius: 16px;
    margin-top: 4px;
    display: inline-block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-shadow: 0 2px 8px rgba(255, 165, 2, 0.2);
}

/* ===================== MAP CONTROLS BAR ===================== */
.map-controls-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 6px;
}

.control-label {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-dark);
}

.pill-selector {
    display: inline-flex;
    background: #f1f2f6;
    padding: 3px;
    border-radius: 30px;
}

.pill-btn {
    border: none;
    background: transparent;
    padding: 5px 12px;
    border-radius: 25px;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

.pill-btn.active {
    background: #ffffff;
    color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* ===================== VIEWS CONTAINER ===================== */
.level-map-view, .game-view {
    flex: 1;
    display: flex;
    flex-direction: column;
    width: 100%;
    min-height: 0;
    overflow: hidden;
    padding-top: 8px;
}

/* ===================== LEVEL MAP VIEW ===================== */
.map-header {
    text-align: center;
    flex-shrink: 0;
    margin-bottom: 10px;
}

.map-header h2 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--accent-purple);
    margin-bottom: 2px;
}

.map-header p {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 600;
}

.levels-grid-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 0;
    overflow-y: auto;
    padding: 4px;
}

.levels-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    width: 100%;
    max-width: 900px;
    margin: auto;
}

.level-card {
    background: #ffffff;
    border-radius: var(--radius-card);
    padding: 14px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border: 3px solid #f1f2f6;
    box-shadow: var(--shadow-card);
    transition: all 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.level-card.unlocked:hover {
    transform: translateY(-4px);
    border-color: var(--secondary-color);
    box-shadow: 0 10px 22px rgba(46, 213, 115, 0.25);
}

.level-card.locked {
    opacity: 0.6;
    background: #f8f9fa;
    filter: grayscale(0.6);
}

.level-number {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    color: var(--primary-color);
    margin-bottom: 2px;
}

.level-title {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    color: var(--text-dark);
    margin-bottom: 4px;
}

.level-grid-info {
    font-size: 0.75rem;
    color: var(--text-muted);
    background: #f1f2f6;
    padding: 2px 8px;
    border-radius: 20px;
    margin-bottom: 6px;
    font-weight: 700;
}

.stars-display {
    display: flex;
    gap: 2px;
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.star {
    color: #dcdde1;
}

.star.active {
    color: #ffa502;
    filter: drop-shadow(0 2px 4px rgba(255, 165, 2, 0.4));
}

.lock-badge {
    position: absolute;
    top: 6px;
    right: 6px;
    font-size: 1rem;
}

/* ===================== GAME BOARD VIEW ===================== */
.game-header {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 6px;
    flex-shrink: 0;
    margin-bottom: 6px;
}

.game-header-row-1, .game-header-row-2 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 6px;
}

.header-center {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 2px;
}

.current-level-tag {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: var(--accent-purple);
    background: #eccc6833;
    border: 2px solid #ffa502;
    padding: 3px 14px;
    border-radius: 30px;
    text-align: center;
    font-weight: 700;
}

.player-turn-tag {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    color: white;
    background: var(--primary-color);
    padding: 3px 14px;
    border-radius: 20px;
    font-weight: 700;
    animation: pulseTurn 1.5s infinite ease-in-out;
}

@keyframes pulseTurn {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* COMBO BANNER */
.combo-banner {
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%) scale(0);
    background: linear-gradient(135deg, #ff9ff3, #feca57);
    color: white;
    font-family: var(--font-heading);
    font-size: 1.3rem;
    padding: 6px 18px;
    border-radius: 30px;
    box-shadow: 0 10px 25px rgba(254, 202, 87, 0.5);
    z-index: 50;
    pointer-events: none;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.combo-banner.active {
    transform: translateX(-50%) scale(1);
}

/* CARDS GRID CONTAINER */
.cards-grid-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 0;
    overflow: hidden;
}

.cards-grid {
    display: grid;
    justify-content: center;
    align-content: center;
    margin: auto;
}

/* CARD COMPONENT */
.card {
    position: relative;
    aspect-ratio: 1 / 1;
    cursor: pointer;
    transform-style: preserve-3d;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.card.flipped, .card.matched {
    transform: rotateY(180deg);
}

.card.hint-glow {
    animation: hintGlow 1s infinite alternate ease-in-out;
}

@keyframes hintGlow {
    0% { transform: scale(1); box-shadow: 0 0 5px #ffa502; }
    100% { transform: scale(1.08); box-shadow: 0 0 25px #ffa502, 0 0 10px #ff5252; }
}

.card-face {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: var(--radius-card);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 16px rgba(0,0,0,0.1);
    border: 3px solid #ffffff;
    overflow: hidden;
}

.card-back {
    background: linear-gradient(135deg, #ff9ff3 0%, #feca57 100%);
    color: white;
    border: 3.5px solid #ffffff;
    box-shadow: inset 0 0 15px rgba(255, 255, 255, 0.4), 0 8px 16px rgba(0,0,0,0.15);
}

.card-back.skin-rainbow { 
    background: radial-gradient(circle at 30% 30%, #ff9a9e 0%, #fecfef 50%, #a1c4fd 100%);
    border: 3.5px solid #ff758c;
    box-shadow: inset 0 0 15px rgba(255, 255, 255, 0.6), 0 8px 20px rgba(255, 117, 140, 0.3);
}

.card-back.skin-jungle { 
    background: repeating-linear-gradient(45deg, #11998e, #11998e 12px, #2ed573 12px, #2ed573 24px);
    border: 3.5px solid #ffeaa7;
    box-shadow: inset 0 0 15px rgba(0, 0, 0, 0.2), 0 8px 20px rgba(46, 213, 115, 0.35);
}

.card-back.skin-ocean { 
    background: radial-gradient(circle at 50% 50%, #74b9ff 0%, #0984e3 60%, #002766 100%);
    border: 3.5px solid #81ecec;
    box-shadow: inset 0 0 15px rgba(255, 255, 255, 0.5), 0 8px 20px rgba(9, 132, 227, 0.35);
}

.card-back.skin-space { 
    background: radial-gradient(circle at 50% 50%, #5f27cd 0%, #341f97 60%, #0c2461 100%);
    border: 3.5px solid #ff9ff3;
    box-shadow: inset 0 0 20px rgba(255, 159, 243, 0.5), 0 8px 20px rgba(95, 39, 205, 0.4);
}

.card-back.skin-gold { 
    background: linear-gradient(135deg, #ffeaa7 0%, #fdcb6e 50%, #e1b12c 100%);
    border: 4px solid #ffffff;
    box-shadow: inset 0 0 25px rgba(255, 255, 255, 0.8), 0 0 25px rgba(253, 203, 110, 0.6);
}

.card-back-pattern {
    font-size: clamp(1.4rem, 3.5vw, 2.8rem);
    animation: pulseIcon 2s infinite ease-in-out;
}

@keyframes pulseIcon {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.card-front {
    background: #ffffff;
    transform: rotateY(180deg);
    flex-direction: column;
}

.card-front img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* DIE-CUT STICKER CARTOON CARD ARTWORK (MATCHING USER SAMPLE) */
.card-front-illustrated {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 6px 4px;
    border-radius: var(--radius-card);
    position: relative;
    overflow: hidden;
}

.card-front-wild {
    background: radial-gradient(circle at 50% 35%, #fff9c4 0%, #a8e6cf 45%, #2ed573 80%, #11998e 100%);
    border: 4px solid #ffffff;
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.8), 0 8px 18px rgba(0,0,0,0.18);
}

.card-front-sea {
    background: radial-gradient(circle at 50% 35%, #e0f7fa 0%, #81d4fa 45%, #0984e3 80%, #002766 100%);
    border: 4px solid #ffffff;
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.8), 0 8px 18px rgba(0,0,0,0.18);
}

/* DIE-CUT STICKER EFFECT (WHITE THICK BORDER OUTLINE AROUND CHARACTER) */
.card-character-avatar {
    font-size: clamp(3rem, 7vw, 4.6rem);
    filter: drop-shadow(0 4px 0px #ffffff) 
            drop-shadow(0 -4px 0px #ffffff) 
            drop-shadow(4px 0px 0px #ffffff) 
            drop-shadow(-4px 0px 0px #ffffff) 
            drop-shadow(3px 3px 0px #ffffff) 
            drop-shadow(-3px -3px 0px #ffffff) 
            drop-shadow(0 10px 18px rgba(0,0,0,0.3));
    margin-top: 6px;
    line-height: 1;
    transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.card:hover .card-character-avatar {
    transform: scale(1.2) rotate(6deg);
}

.card-character-badge {
    position: absolute;
    top: 5px;
    left: 6px;
    background: #ffffff;
    border: 1.5px solid #ffa502;
    font-size: clamp(0.6rem, 1vw, 0.75rem);
    font-family: var(--font-heading);
    padding: 2px 8px;
    border-radius: 12px;
    color: var(--primary-color);
    font-weight: 700;
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
    z-index: 2;
}

.card-character-ribbon {
    width: 94%;
    background: linear-gradient(135deg, #ff5252 0%, #ff793f 100%);
    border: 2px solid #ffffff;
    color: white;
    font-family: var(--font-heading);
    font-size: clamp(0.7rem, 1.2vw, 0.9rem);
    font-weight: 700;
    text-align: center;
    padding: 3px 6px;
    border-radius: 14px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.25);
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    z-index: 2;
    margin-bottom: 2px;
}

.card-front-sea .card-character-ribbon {
    background: linear-gradient(135deg, #0984e3 0%, #3742fa 100%);
}

.card-emoji-icon {
    font-size: clamp(2rem, 5vw, 3.6rem);
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.2));
}

.card-emoji-label {
    font-family: var(--font-heading);
    font-size: clamp(0.65rem, 1.2vw, 0.85rem);
    color: #ffffff;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.6);
    font-weight: 700;
    margin-top: 2px;
}

.card.matched .card-front {
    border-color: #2ed573;
    box-shadow: 0 0 20px rgba(46, 213, 115, 0.6);
    animation: popMatch 0.4s ease-out;
}

@keyframes popMatch {
    0% { transform: rotateY(180deg) scale(1); }
    50% { transform: rotateY(180deg) scale(1.1); }
    100% { transform: rotateY(180deg) scale(1); }
}

/* ===================== GIFT BOX / STICKER CARD MODALS ===================== */
.modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 16px;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-card {
    background: #ffffff;
    border-radius: var(--radius-container);
    padding: 20px 24px;
    width: 100%;
    max-width: 440px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0,0,0,0.25);
    transform: scale(0.85);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 4px solid #ffa502;
    max-height: 88vh;
    display: flex;
    flex-direction: column;
}

.shop-modal-card, .album-modal-card {
    max-width: 660px;
}

.modal-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
    flex-shrink: 0;
}

.modal-header-row h2 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--primary-color);
}

.btn-close {
    border: none;
    background: #f1f2f6;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    font-size: 1rem;
    cursor: pointer;
    flex-shrink: 0;
}

.modal-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 10px;
    flex-shrink: 0;
}

.shop-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    flex-shrink: 0;
}

.shop-tab {
    flex: 1;
    padding: 7px;
    border: none;
    background: #f1f2f6;
    border-radius: 20px;
    font-family: var(--font-heading);
    font-weight: 700;
    cursor: pointer;
    font-size: 0.9rem;
}

.shop-tab.active {
    background: var(--primary-color);
    color: white;
}

.shop-content, .album-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    overflow-y: auto;
    padding-right: 4px;
    max-height: 60vh;
}

/* GIFT & STICKER CARD STYLE */
.shop-item, .album-item {
    background: linear-gradient(135deg, #ffffff 0%, #fff9e6 100%);
    border: 3px solid #feca57;
    border-radius: 18px;
    padding: 12px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    box-shadow: 0 6px 14px rgba(254, 202, 87, 0.25);
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.shop-item:hover, .album-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 20px rgba(254, 202, 87, 0.4);
}

.gift-badge {
    position: absolute;
    top: -8px;
    right: 8px;
    background: #ff5252;
    color: white;
    font-size: 0.65rem;
    font-family: var(--font-heading);
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 700;
}

.shop-item-icon {
    font-size: 2.4rem;
    margin-bottom: 4px;
    filter: drop-shadow(0 3px 6px rgba(0,0,0,0.15));
}

.shop-item-name {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    color: var(--text-dark);
    margin-bottom: 2px;
}

.shop-item-price {
    font-size: 0.85rem;
    color: var(--accent-yellow);
    font-weight: 700;
    margin-bottom: 8px;
}

/* CONFETTI CANVAS */
#confetti-canvas {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    pointer-events: none;
    z-index: 99;
}

/* ===================== RESPONSIVE BREAKPOINTS ===================== */
@media (min-width: 768px) {
    body { padding: 16px; }
    .levels-grid { grid-template-columns: repeat(3, 1fr); gap: 14px; }
    .shop-content, .album-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 767px) {
    body { padding: 0; }
    .app-container { 
        width: 100vw; 
        height: 100vh; 
        height: 100dvh;
        border-radius: 0; 
        border: none; 
        padding: 4px 6px; 
    }
    .header { 
        padding-bottom: 4px; 
        gap: 4px; 
        flex-wrap: nowrap;
    }
    .title-box h1 { font-size: 0.92rem; text-shadow: none; }
    .header-right { gap: 3px; }
    .btn-sm { font-size: 0.72rem; padding: 3px 7px; min-height: 28px; gap: 2px; }
    .stats-pill-sm { padding: 2px 6px; font-size: 0.78rem; border-width: 1.5px; }
    .btn-icon-only { width: 28px; height: 28px; min-width: 28px; }
    
    /* Virtual Pet Mobile Box */
    .virtual-pet-container { 
        padding: 6px 10px; 
        gap: 8px; 
        margin-bottom: 6px; 
        border-width: 2.5px;
        border-radius: 16px;
    }
    .pet-avatar-wrapper { 
        width: 44px; 
        height: 44px; 
        min-width: 44px; 
        font-size: 1.7rem; 
        border-width: 2px;
    }
    .pet-name { font-size: 0.95rem; }
    .pet-speech-inline { font-size: 0.72rem; padding: 2px 6px; border-radius: 10px; }
    
    /* Map & Headers Mobile */
    .map-controls-bar { margin-bottom: 6px; }
    .map-header { margin-bottom: 6px; }
    .map-header h2 { font-size: 1.2rem; }
    .map-header p { font-size: 0.78rem; }
    .levels-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .level-card { padding: 8px 6px; }
    .level-number { font-size: 0.95rem; }
    .level-title { font-size: 0.82rem; }
    .stars-display { font-size: 1rem; margin-bottom: 4px; }
    
    /* Game Board Header Mobile */
    .game-header { gap: 4px; margin-bottom: 4px; }
    .current-level-tag { font-size: 0.8rem; padding: 2px 8px; }
    .player-turn-tag { font-size: 0.72rem; padding: 2px 8px; }
    
    /* Modals Mobile */
    .modal-card { padding: 14px 12px; border-radius: 18px; max-width: 94vw; }
    .modal-header-row h2 { font-size: 1.2rem; }
    .shop-content, .album-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; max-height: 58vh; }
    .shop-item, .album-item { padding: 8px 6px; border-radius: 14px; }
    .shop-item-icon { font-size: 2rem; }
    .shop-item-name { font-size: 0.8rem; }
}
