/* --- OFFICIAL COMIC FIESTA FONT: MUSEO SANS ROUNDED --- */
@font-face { font-family: 'Museo Sans Rounded'; src: url('MuseoSansRounded100.otf') format('opentype'); font-weight: 100; font-style: normal; }
@font-face { font-family: 'Museo Sans Rounded'; src: url('MuseoSansRounded300.otf') format('opentype'); font-weight: 300; font-style: normal; }
@font-face { font-family: 'Museo Sans Rounded'; src: url('MuseoSansRounded500.otf') format('opentype'); font-weight: 500; font-style: normal; }
@font-face { font-family: 'Museo Sans Rounded'; src: url('MuseoSansRounded700.otf') format('opentype'); font-weight: 700; font-style: normal; }
@font-face { font-family: 'Museo Sans Rounded'; src: url('MuseoSansRounded900.otf') format('opentype'); font-weight: 900; font-style: normal; }
@font-face { font-family: 'Museo Sans Rounded'; src: url('MuseoSansRounded1000.otf') format('opentype'); font-weight: 1000; font-style: normal; }

:root {
    --cf-red: #E31837;
    --cf-red-hover: #C1122B;

    /* Light Mode */
    --bg-color: #E8EEF5;
    --surface-color: #E8EEF5;
    --text-main: #2D3748;
    --text-muted: #718096;
    --border-color: rgba(255, 255, 255, 0.8);
    --card-bg: #FFFFFF;

    /* Gradients */
    --surface-light: #F0F4F8;
    --surface-dark: #DDE4ED;
    --surface-gradient: linear-gradient(145deg, var(--surface-light), var(--surface-dark));
    --operations-bg: linear-gradient(145deg, #E2E8F0, #D2DCE6);
    --flat-box-bg: linear-gradient(145deg, rgba(0,0,0,0.02), rgba(0,0,0,0.06));
    
    --header-bg: linear-gradient(135deg, #E31837 0%, #A61026 100%);
    --header-text: #FFFFFF;
    --header-border: rgba(0,0,0,0.1);

    --shadow-out: 4px 4px 10px rgba(163,177,198,0.4), -4px -4px 10px rgba(255,255,255, 0.9);
    --shadow-in: inset 3px 3px 6px rgba(163,177,198, 0.5), inset -3px -3px 6px rgba(255,255,255, 0.9);
    --shadow-panel: 0 15px 35px rgba(163,177,198,0.3), -4px -4px 15px rgba(255,255,255, 0.9);
    --shadow-red: 0 6px 15px rgba(227, 24, 55, 0.25);
}

[data-theme="dark"] {
    --bg-color: #16181D;
    --surface-color: #1F2128;
    --text-main: #F7FAFC;
    --text-muted: #8A94A6;
    --border-color: rgba(255, 255, 255, 0.03);
    --card-bg: #2A2D35;

    --surface-light: #262933;
    --surface-dark: #16181D;
    --surface-gradient: linear-gradient(145deg, var(--surface-light), var(--surface-dark));
    --operations-bg: linear-gradient(145deg, #1C1E26, #12141A);
    --flat-box-bg: linear-gradient(145deg, rgba(0,0,0,0.2), rgba(0,0,0,0.4));

    --header-bg: linear-gradient(135deg, #1A1B20 0%, #0D0E12 100%);
    --header-text: #F7FAFC;
    --header-border: var(--cf-red);

    --shadow-out: 5px 5px 12px rgba(0,0,0,0.4), -3px -3px 8px rgba(255,255,255, 0.02);
    --shadow-in: inset 4px 4px 8px rgba(0,0,0,0.5), inset -2px -2px 5px rgba(255,255,255, 0.02);
    --shadow-panel: 0 15px 35px rgba(0,0,0,0.6), -2px -2px 10px rgba(255,255,255, 0.02);
    --shadow-red: 0 6px 15px rgba(227, 24, 55, 0.2);
}

* { box-sizing: border-box; }
body { background-color: var(--bg-color); color: var(--text-main); font-family: 'Museo Sans Rounded', system-ui, -apple-system, sans-serif; margin: 0; padding: 0; overflow-x: hidden; transition: background-color 0.3s ease, color 0.3s ease; }

.header-bg { position: absolute; top: 0; left: 0; width: 100%; height: 35vh; min-height: 280px; max-height: 350px; background: var(--header-bg); z-index: 0; border-bottom: 2px solid var(--header-border); }
.header-btn { background: rgba(255, 255, 255, 0.15); border: 1px solid rgba(255, 255, 255, 0.2); color: var(--header-text); padding: 8px 16px; border-radius: 50px; cursor: pointer; backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); font-weight: 700; text-transform: uppercase; font-size: 0.8rem; display: flex; align-items: center; gap: 8px; transition: all 0.2s ease; }
.header-btn:hover { background: rgba(255, 255, 255, 0.25); transform: translateY(-1px); }
.header-btn:active { transform: scale(0.96); background: rgba(0,0,0,0.1); }

.stat-value { font-size: 1.6rem !important; font-weight: 300 !important; color: var(--cf-red); margin-bottom: 2px; font-family: 'Museo Sans Rounded', sans-serif !important; }
.stat-label { font-size: 0.65rem; text-transform: uppercase; color: var(--text-muted); font-weight: 700; letter-spacing: 0.5px; }
.money-value { font-size: 3.2rem !important; line-height: 1; margin-top: 5px; letter-spacing: -1px; text-shadow: 0 2px 4px rgba(0,0,0,0.05); }

.dossier-panel { background: var(--surface-gradient); border-radius: 24px; box-shadow: var(--shadow-panel); padding: 30px; border: 1px solid var(--border-color); position: relative; z-index: 20; }
.operations-panel { background: var(--operations-bg); border-radius: 24px; box-shadow: var(--shadow-panel); padding: 45px 30px 30px 30px; margin-top: -25px; margin-bottom: 40px; border: 1px solid var(--border-color); position: relative; z-index: 10; }
.neo-panel-title { font-size: 0.9rem; font-weight: 900; color: var(--text-muted); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 25px; display: flex; align-items: center; gap: 10px; opacity: 0.8; }

.bank-bar { background: var(--surface-gradient); box-shadow: var(--shadow-in); border-radius: 16px; padding: 25px 30px; margin-bottom: 15px; border: 1px solid rgba(0,0,0,0.02); transition: all 0.3s ease; }
.combined-stats-box { background: var(--flat-box-bg); border-radius: 16px; padding: 20px; border: 1px solid rgba(0,0,0,0.03); display: flex; justify-content: space-around; align-items: center; box-shadow: 0 2px 5px rgba(0,0,0,0.02); }
[data-theme="dark"] .combined-stats-box { box-shadow: 0 4px 8px rgba(0,0,0,0.2); border: 1px solid rgba(255,255,255,0.02); }
.combined-stat-item { flex: 1; text-align: center; border-right: 1px solid rgba(0,0,0,0.05); }
[data-theme="dark"] .combined-stat-item { border-right: 1px solid rgba(255,255,255,0.05); }
.combined-stat-item:last-child { border-right: none; }

.segment-track { display: flex; gap: 4px; background: rgba(0,0,0,0.04); box-shadow: var(--shadow-in); border-radius: 50px; padding: 6px; margin: 0 auto 30px auto; justify-content: center; align-items: center; border: 1px solid rgba(0,0,0,0.03); width: fit-content; flex-wrap: wrap; }
[data-theme="dark"] .segment-track { background: rgba(0,0,0,0.25); border: 1px solid rgba(255,255,255,0.02); }

.segment-btn { background: transparent; border: none; padding: 10px 24px; font-size: 0.9rem; font-weight: 500; color: var(--text-muted); border-radius: 50px; cursor: pointer; text-transform: uppercase; transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); display: flex; align-items: center; gap: 8px; }
.segment-btn:hover { color: var(--text-main); }
.segment-btn.active { background: linear-gradient(145deg, var(--card-bg), var(--surface-color)); color: var(--cf-red); box-shadow: 0 4px 10px rgba(0,0,0,0.08); transform: scale(1); border: 1px solid rgba(255,255,255,0.6); }
[data-theme="dark"] .segment-btn.active { background: linear-gradient(145deg, #2A2D35, #1A1C23); box-shadow: 0 4px 10px rgba(0,0,0,0.4); border: 1px solid rgba(255,255,255,0.05); }

/* --- GACHA STAGE & SMALL CARDS --- */
.gacha-stage { display: grid; grid-template-columns: repeat(5, 1fr); grid-template-rows: repeat(2, 1fr); gap: 15px; width: 100%; max-width: 900px; perspective: 2000px; margin: 0 auto 30px auto; background: linear-gradient(145deg, rgba(0,0,0,0.04), rgba(0,0,0,0.01)); border-radius: 20px; padding: 20px; box-shadow: var(--shadow-in); border: 1px solid rgba(0,0,0,0.03); min-height: 420px; }
[data-theme="dark"] .gacha-stage { background: linear-gradient(145deg, rgba(0,0,0,0.3), rgba(0,0,0,0.1)); border: 1px solid rgba(255,255,255,0.02); }

.card-container { width: 100%; aspect-ratio: 2.5/3.5; cursor: pointer; position: relative; perspective: 1500px; animation: dealCard 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) backwards; pointer-events: auto !important; }
@keyframes dealCard { 0% { opacity: 0; transform: translateY(-150px) rotateX(-45deg) scale(0.3); } 100% { opacity: 1; transform: translateY(0) rotateX(0deg) scale(1); } }

.dance-wrapper { width: 100%; height: 100%; transform-style: preserve-3d; transform-origin: center center; }
@keyframes danceC { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes danceUC { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-4px) rotate(1deg); } }
@keyframes danceR { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-5px) rotate(-1.5deg); } }
@keyframes danceSR { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 25% { transform: translate(1px, -3px) rotate(2deg); } 75% { transform: translate(-1px, -3px) rotate(-2deg); } }
@keyframes danceSSR { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 25% { transform: translate(2px, -1px) rotate(1deg); } 50% { transform: translate(-2px, -3px) rotate(-1deg); } 75% { transform: translate(1px, 2px) rotate(2deg); } }
@keyframes danceUR { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 20% { transform: translate(-2px, 2px) rotate(-2deg); } 40% { transform: translate(2px, -2px) rotate(2deg); } 60% { transform: translate(-2px, -2px) rotate(0deg); } 80% { transform: translate(2px, 2px) rotate(-1deg); } }
.dancing-C { animation: danceC 4s ease-in-out infinite; } .dancing-UC { animation: danceUC 3s ease-in-out infinite; } .dancing-R { animation: danceR 2s ease-in-out infinite; } .dancing-SR { animation: danceSR 0.8s ease-in-out infinite; } .dancing-SSR { animation: danceSSR 0.3s linear infinite; filter: drop-shadow(0 0 10px rgba(255, 152, 0, 0.4)); } .dancing-UR { animation: danceUR 0.15s linear infinite; filter: drop-shadow(0 0 15px rgba(255, 23, 68, 0.6)); }

.card-inner { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1); }
.card-container.flipped .card-inner { transform: rotateY(180deg) scale(1.05); }

/* Small Cards (Stage & Collection) */
.card-back, .card-front { 
    position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; 
    border-radius: 12px; border: 2px solid; display: flex; flex-direction: column; align-items: center; justify-content: center; 
    overflow: hidden;
}
.card-back { background: var(--card-bg); border-color: var(--border-color); transform: rotateY(0deg); box-shadow: inset 0 0 15px rgba(0,0,0,0.05); }
.card-back-logo { width: 60%; opacity: 0.8; color: var(--cf-red); font-weight: 900; font-size: 1.5rem; }
.card-front { transform: rotateY(180deg); background: var(--card-bg); padding: 15px; text-align: center; box-shadow: inset 0 0 10px rgba(0,0,0,0.05); color: var(--text-main); }

.collection-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 20px; padding: 25px; background: var(--flat-box-bg); border-radius: 16px; box-shadow: var(--shadow-in); border: 1px solid rgba(0,0,0,0.03); }
[data-theme="dark"] .collection-grid { border: 1px solid rgba(255,255,255,0.02); }
.collection-card-slot { aspect-ratio: 2.5/3.5; position: relative; transition: transform 0.2s ease; cursor: pointer; }
.collection-card-slot:hover { transform: translateY(-8px); z-index: 10; }
.collection-card-slot .card-front { position: relative; transform: none !important; height: 100%; border-color: var(--border-color); }
.collection-card-slot.locked .card-front { filter: grayscale(1) brightness(0.7) opacity(0.6); }

.deck-area { display: flex; justify-content: space-between; align-items: flex-end; width: 100%; max-width: 900px; background: var(--surface-color); box-shadow: var(--shadow-in); padding: 25px; border-radius: 16px; margin: 40px auto; border: 1px solid rgba(0,0,0,0.02); }
.deck-stack { flex: 1; display: flex; flex-direction: column; align-items: center; cursor: pointer; transition: transform 0.2s ease; }
.deck-stack:hover { transform: translateY(-5px); }
.deck-stack:active { transform: scale(0.95); }
.stack-cards { position: relative; width: 55px; height: 80px; margin-top: 10px; }
.card-mini { position: absolute; width: 100%; height: 100%; background: var(--card-bg); border: 1px solid rgba(150,150,150,0.2); border-radius: 4px; bottom: 0; left: 0; box-shadow: 0 -1px 3px rgba(0,0,0,0.1); }
.card-mini::after { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 10px; height: 10px; background: var(--cf-red); border-radius: 50%; opacity: 0.4; }


/* --- PERFECTED BIG TCG CARD (MODAL) --- */
.card-modal-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(8px); display: flex; justify-content: center; align-items: center; z-index: 10000; animation: fadeIn 0.2s ease-out; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.card-modal-content { width: 340px; aspect-ratio: 2.5/3.5; perspective: 1500px; cursor: pointer; }

/* The Main Frame: Solid Rarity Background */
.modal-card-front-only { 
    position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; 
    border-radius: 20px; 
    overflow: hidden; 
    display: flex; flex-direction: column;
    box-shadow: 0 30px 60px rgba(0,0,0,0.5); 
    background: transparent; 
}

/* The White Inner Container */
.big-card-inner-bg {
    background-color: #FFFFFF;
    position: relative;
    flex-grow: 1;
    border-radius: 12px; 
    overflow: hidden;
    display: flex;
    flex-direction: column;
    z-index: 1;
}

/* Faint Logo */
.card-bg-logo { 
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); 
    width: 85%; height: 85%; background-image: url('logo_faint.svg'); 
    background-size: contain; background-position: center; background-repeat: no-repeat; 
    z-index: 0; pointer-events: none; opacity: 0.35; 
}

/* Centered Content Stack */
.big-card-content {
    position: relative; z-index: 1; 
    flex-grow: 1; display: flex; flex-direction: column; 
    align-items: center; justify-content: center; text-align: center; 
    padding: 20px;
}

/* Upper Left Card Type */
.big-card-type-wrapper { position: absolute; top: 15px; left: 15px; z-index: 2; }
.big-card-type { 
    border: 2px solid var(--text-main); color: var(--text-main); 
    border-radius: 50px; padding: 4px 10px; 
    font-weight: 900; font-size: 0.75rem; text-transform: uppercase; background: #FFFFFF; 
}

/* Upper Right Owned Badge */
.big-card-owned { 
    position: absolute; top: 15px; right: 15px; z-index: 2; 
    padding: 5px 12px; border-radius: 50px; font-size: 0.75rem; font-weight: 900; 
}

.big-card-art { font-size: 7.5rem; margin-bottom: 20px; filter: drop-shadow(0 10px 15px rgba(0,0,0,0.1)); position: relative; z-index: 1; }

.big-card-info { width: 100%; display: flex; flex-direction: column; align-items: center; text-align: center; margin-bottom: auto; }
.big-card-title { font-weight: 900; font-size: 1.7rem; line-height: 1.1; margin-bottom: 5px; color: #11111d; }
.big-card-team { font-weight: 900; font-size: 0.95rem; opacity: 0.6; text-transform: uppercase; margin-bottom: 30px; color: #11111d; letter-spacing: 1px; }
.big-card-desc { font-size: 1rem; line-height: 1.4; color: #333333; font-weight: 500; }
.big-card-flavor { font-style: italic; font-size: 0.85rem; opacity: 0.5; margin-top: 15px; color: #11111d; }

/* The Thick Bottom Bar */
.big-card-bottom-bar {
    width: 100%; padding: 20px 10px; 
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    color: #FFFFFF; flex-shrink: 0; background: transparent;
    z-index: 1;
}
.big-card-rarity-name { font-weight: 900; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 6px; text-shadow: 0 2px 4px rgba(0,0,0,0.2); margin-right: -6px;}
.big-card-stars { display: flex; gap: 4px; font-size: 1.1rem; margin-top: 8px; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2)); color: #FFFFFF; }


/* --- SUPERCHARGED ACTION BUTTONS --- */
#btn-pull { background: linear-gradient(135deg, #FF4D6D 0%, var(--cf-red) 50%, #A61026 100%); color: #FFFFFF !important; border: none; padding: 16px 45px; border-radius: 50px; font-size: 1.2rem; font-weight: 500; box-shadow: 0 8px 20px rgba(227, 24, 55, 0.4), inset 0 2px 0 rgba(255, 255, 255, 0.3), inset 0 -3px 0 rgba(0, 0, 0, 0.2); border-top: 1px solid #FF8096; cursor: pointer; text-transform: uppercase; letter-spacing: 1.5px; transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1); text-shadow: 0 2px 4px rgba(0,0,0,0.2); }
#btn-pull:active, #btn-pull:disabled { transform: scale(0.96) translateY(2px); box-shadow: 0 2px 5px rgba(227, 24, 55, 0.4), inset 0 3px 8px rgba(0,0,0,0.3); background: linear-gradient(135deg, #A61026 0%, var(--cf-red) 50%, #FF4D6D 100%); border-top: 1px solid transparent; }
.btn-reveal { background: linear-gradient(145deg, var(--surface-light), var(--surface-dark)); border: 1px solid var(--border-color); color: var(--text-main); padding: 14px 28px; border-radius: 50px; font-weight: 500; cursor: pointer; box-shadow: var(--shadow-out), inset 0 2px 0 rgba(255,255,255,0.4); transition: all 0.15s ease; text-transform: uppercase; letter-spacing: 1px; }
.btn-reveal:active { box-shadow: var(--shadow-in); transform: scale(0.97); color: var(--cf-red); }

/* --- BASE FX (Small Cards) --- */
.rarity-C { border-color: #8B9DAF; } .rarity-UC { border-color: #4CAF50; } .rarity-R { border-color: #2196F3; } .rarity-SR { border-color: #9C27B0; box-shadow: 0 0 15px rgba(156, 39, 176, 0.3); } .rarity-SSR { border-color: #FF9800; box-shadow: 0 0 20px rgba(255, 152, 0, 0.4); } .rarity-UR { border-color: #FF1744; box-shadow: 0 0 25px rgba(255, 23, 68, 0.5); }

/* --- MODAL ONLY PERSISTENT FX --- */
@keyframes cleanSpinIn { 0% { transform: scale(0.5) rotateY(-90deg) rotateZ(-10deg); opacity: 0; } 100% { transform: scale(1) rotateY(0deg) rotateZ(0deg); opacity: 1; } }
@keyframes pulseGlow { 0%, 100% { box-shadow: 0 30px 60px rgba(0,0,0,0.5); } 50% { box-shadow: 0 30px 80px var(--pulse-color); } }
@keyframes godRaysRotate { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
@keyframes floatParticle { 0% { transform: translateY(0) scale(0.5); opacity: 0; } 20% { opacity: var(--max-op); } 80% { opacity: var(--max-op); } 100% { transform: translateY(-300px) scale(1.2); opacity: 0; } }

.modal-card-front-only.fx-SR { animation: cleanSpinIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards, pulseGlow 3s ease-in-out infinite 0.5s; }
.modal-card-front-only.fx-SSR { animation: cleanSpinIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards, pulseGlow 2s ease-in-out infinite 0.5s; }
.modal-card-front-only.fx-UR { animation: cleanSpinIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards, pulseGlow 1.2s ease-in-out infinite 0.5s; }

.big-card-fx-layer { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; border-radius: 12px; }

.big-card-god-rays { position: absolute; top: -50%; left: -50%; width: 200%; height: 200%; animation: godRaysRotate 20s linear infinite; }
.fx-SSR .big-card-god-rays { opacity: 0.5; }
.fx-UR .big-card-god-rays { opacity: 0.8; animation-duration: 10s; }

.big-card-particles { position: absolute; inset: 0; }
.fx-particle { position: absolute; border-radius: 50%; opacity: 0; filter: blur(1px); width: var(--size); height: var(--size); left: var(--left); bottom: -10%; animation: floatParticle var(--dur) ease-in infinite var(--del); }


@keyframes shaking { 0%, 100% { transform: translate(0,0); } 25% { transform: translate(3px,3px); } 75% { transform: translate(-3px,-3px); } }
.shaking { animation: shaking 0.1s infinite; }
.flash-overlay { position: fixed; inset: 0; background: white; opacity: 0; pointer-events: none; z-index: 99999; }
.flash-overlay.active { animation: flashEffect 0.8s ease-out; }
@keyframes flashEffect { 0% { opacity: 1; } 100% { opacity: 0; } }

.duplicate-badge { position: absolute; top: -10px; right: -10px; background: var(--text-main); color: var(--surface-color); border-radius: 50%; width: 26px; height: 26px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 900; border: 2px solid var(--surface-color); box-shadow: 0 3px 6px rgba(0,0,0,0.15); z-index: 15; }

.new-sticker { position: absolute; background: var(--cf-red); color: var(--cf-white); padding: 3px 6px; border-radius: 4px; font-weight: 900; font-size: 0.7rem; text-transform: uppercase; border: 2px solid var(--surface-color); box-shadow: 0 3px 6px rgba(0,0,0,0.15); z-index: 10; pointer-events: none; line-height: 1; }
.crisis-mode { filter: grayscale(0.8) sepia(0.4) contrast(1.2); background-color: #1a0000 !important; }
.crisis-mode::after { content: "ACCOUNTS IS WATCHING"; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%) rotate(-30deg); font-size: 8rem; font-weight: 300; color: rgba(255, 0, 0, 0.25); text-shadow: 0 0 20px rgba(255, 0, 0, 0.5); pointer-events: none; z-index: -1; white-space: nowrap; animation: warningPulse 2s infinite alternate; }
@keyframes warningPulse { from { opacity: 0.8; transform: translate(-50%, -50%) rotate(-30deg) scale(1); } to { opacity: 1; transform: translate(-50%, -50%) rotate(-30deg) scale(1.05); } }

/* --- MOBILE --- */
@media (max-width: 768px) {
    .header-bg { height: 30vh; }
    .dossier-panel { padding: 20px; border-radius: 20px; }
    .operations-panel { padding: 40px 20px 20px 20px; margin-top: -25px; border-radius: 20px; }
    .gacha-stage { grid-template-columns: repeat(5, 1fr); gap: 6px; min-height: 280px; padding: 15px;}
    .money-value { font-size: 2.2rem !important; }
    .combined-stats-box { flex-wrap: wrap; gap: 15px; }
    .combined-stat-item { flex: 1 1 40%; border-right: none !important; }
    .bank-bar { flex-direction: column; align-items: flex-start !important; gap: 15px; padding: 20px; }
    .bank-bar > div:last-child { text-align: left !important; max-width: 100% !important; }
    .segment-track { width: 100%; border-radius: 20px; padding: 6px; justify-content: center; }
    .segment-btn { flex: 1 1 auto; justify-content: center; padding: 10px 12px; font-size: 0.75rem; border-radius: 14px; }
    .header-btn span { display: none; }
    .card-modal-content { width: 85vw; }
}