/* ===== GLOBAL RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(45deg, #0a0a0a, #1e0533, #3d1a78, #0f0f23, #2d1b69);
    background-size: 400% 400%;
    min-height: 100vh;
    color: #fff;
    overflow-x: hidden;
    position: relative;
}

/* ===== ANIMATIONS ===== */
@keyframes twinkle {
    0%, 100% {
        opacity: 0.3;
        transform: scale(1);
    }
    25% {
        opacity: 0.8;
        transform: scale(1.1);
    }
    50% {
        opacity: 1;
        transform: scale(1.3);
    }
    75% {
        opacity: 0.6;
        transform: scale(1.1);
    }
}

@keyframes planetRotate {
    0% {
        transform: rotate(0deg) translateY(0);
        filter: brightness(1);
    }
    25% {
        transform: rotate(90deg) translateY(-10px);
        filter: brightness(1.1);
    }
    50% {
        transform: rotate(180deg) translateY(0);
        filter: brightness(0.9);
    }
    75% {
        transform: rotate(270deg) translateY(10px);
        filter: brightness(1.1);
    }
    100% {
        transform: rotate(360deg) translateY(0);
        filter: brightness(1);
    }
}

@keyframes starDrift {
    0% { transform: translateY(0) translateX(0); }
    100% { transform: translateY(-300px) translateX(-50px); }
}

@keyframes goldenGlow {
    0%, 100% { box-shadow: 0 0 20px rgba(255, 215, 0, 0.6); }
    50% { box-shadow: 0 0 30px rgba(255, 215, 0, 0.9); }
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(255, 165, 0, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(255, 165, 0, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 165, 0, 0); }
}

@keyframes dotPulse {
    0%, 80%, 100% {
        transform: scale(0.6);
        opacity: 0.35;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ===== ROCKET ANIMATIONS - FIXED VERSION ===== */
@keyframes rocketVerticalFly {
    0% {
        transform: translateY(3px) rotate(-45deg);
    }
    50% {
        transform: translateY(-8px) rotate(-45deg);
    }
    100% {
        transform: translateY(3px) rotate(-45deg);
    }
}

/* ===== BACKGROUND LAYERS ===== */
.starLayer,
.nebula,
.dustStars,
.cosmicDust {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.nebula {
    background: radial-gradient(ellipse at 15% 85%, rgba(138, 43, 226, 0.15) 0%, transparent 40%),
                radial-gradient(ellipse at 85% 15%, rgba(255, 69, 0, 0.12) 0%, transparent 45%),
                radial-gradient(ellipse at 50% 50%, rgba(0, 191, 255, 0.08) 0%, transparent 50%),
                radial-gradient(ellipse at 70% 30%, rgba(255, 215, 0, 0.1) 0%, transparent 35%),
                radial-gradient(ellipse at 30% 70%, rgba(255, 20, 147, 0.12) 0%, transparent 40%);
    z-index: 0;
}

.dustStars {
    background-image: radial-gradient(1px 1px at 20% 30%, #fff, transparent),
                      radial-gradient(1px 1px at 40% 70%, rgba(255, 255, 255, 0.8), transparent),
                      radial-gradient(1px 1px at 90% 40%, rgba(255, 255, 255, 0.6), transparent),
                      radial-gradient(1px 1px at 6% 90%, #fff, transparent),
                      radial-gradient(1px 1px at 70% 10%, rgba(255, 255, 255, 0.7), transparent),
                      radial-gradient(1px 1px at 80% 60%, rgba(255, 255, 255, 0.5), transparent),
                      radial-gradient(2px 2px at 25% 50%, rgba(255, 255, 255, 0.9), transparent),
                      radial-gradient(1px 1px at 60% 80%, rgba(255, 255, 255, 0.4), transparent);
    background-repeat: repeat;
    background-size: 300px 300px, 250px 250px, 200px 200px, 350px 350px, 180px 180px, 220px 220px, 280px 280px, 160px 160px;
    animation: starDrift 120s linear infinite;
}

.cosmicDust {
    background-image: radial-gradient(0.5px 0.5px at 10% 20%, rgba(255, 165, 0, 0.3), transparent),
                      radial-gradient(0.5px 0.5px at 30% 60%, rgba(255, 69, 0, 0.2), transparent),
                      radial-gradient(0.5px 0.5px at 60% 10%, rgba(255, 215, 0, 0.25), transparent),
                      radial-gradient(0.5px 0.5px at 80% 80%, rgba(255, 140, 0, 0.2), transparent),
                      radial-gradient(0.5px 0.5px at 50% 90%, rgba(255, 165, 0, 0.15), transparent);
    background-repeat: repeat;
    background-size: 100px 100px, 120px 120px, 80px 80px, 150px 150px, 90px 90px;
}

/* ===== STARS ===== */
.star {
    position: absolute;
    background: #fff;
    border-radius: 50%;
    animation: twinkle 3s infinite;
}

.star.tiny {
    width: 1px;
    height: 1px;
    box-shadow: 0 0 2px rgba(255, 255, 255, 0.8);
    animation-duration: 4s;
}

.star.small {
    width: 2px;
    height: 2px;
    box-shadow: 0 0 4px rgba(255, 255, 255, 0.9);
    animation-duration: 3s;
}

.star.medium {
    width: 3px;
    height: 3px;
    box-shadow: 0 0 8px #fff;
    animation-duration: 2.5s;
}

.star.large {
    width: 4px;
    height: 4px;
    box-shadow: 0 0 12px #fff, 0 0 20px rgba(255, 255, 255, 0.5);
    animation-duration: 2s;
}

/* ===== PLANETS ===== */
.planet {
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 1;
}

.planet1 {
    width: 100px;
    height: 100px;
    background: radial-gradient(circle at 25% 25%, #ff8a80, #ff5722, #d84315);
    top: 10%;
    left: 85%;
    box-shadow: 0 0 40px rgba(255, 87, 34, 0.6), inset -20px -20px 40px rgba(0, 0, 0, 0.3);
    animation: planetRotate 30s infinite linear;
}

.planet2 {
    width: 80px;
    height: 80px;
    background: radial-gradient(circle at 30% 30%, #81c784, #4caf50, #2e7d32);
    top: 70%;
    left: 5%;
    box-shadow: 0 0 35px rgba(76, 175, 80, 0.5), inset -15px -15px 30px rgba(0, 0, 0, 0.3);
    animation: planetRotate 40s infinite linear reverse;
}

.planet3 {
    width: 60px;
    height: 60px;
    background: radial-gradient(circle at 30% 30%, #ba68c8, #9c27b0, #6a1b9a);
    top: 35%;
    left: 2%;
    box-shadow: 0 0 30px rgba(156, 39, 176, 0.4), inset -12px -12px 25px rgba(0, 0, 0, 0.3);
    animation: planetRotate 25s infinite linear;
}

.planet4 {
    width: 45px;
    height: 45px;
    background: radial-gradient(circle at 35% 35%, #ffb74d, #ff9800, #f57c00);
    top: 50%;
    right: 8%;
    box-shadow: 0 0 25px rgba(255, 152, 0, 0.4), inset -10px -10px 20px rgba(0, 0, 0, 0.3);
    animation: planetRotate 35s infinite linear reverse;
}

/* ===== METEORS ===== */
.meteor {
    position: fixed;
    width: 3px;
    height: 3px;
    background: #fff;
    pointer-events: none;
    z-index: 3;
    border-radius: 50%;
}

.meteor::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 150px;
    background: linear-gradient(to bottom, #fff 0%, rgba(255, 165, 0, 0.8) 30%, rgba(255, 69, 0, 0.6) 60%, transparent 100%);
    transform: rotate(45deg);
    transform-origin: 0 0;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

/* ===== LAYOUT ===== */
.container {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
    gap: 20px;
}

.mainPanel,
.activityPanel {
    background: rgba(30, 30, 50, 0.9);
    border: 2px solid #ffa500;
    box-shadow: 0 0 30px rgba(255, 165, 0, 0.4), inset 0 0 30px rgba(255, 165, 0, 0.1);
    border-radius: 15px;
    padding: 30px;
    backdrop-filter: blur(10px);
    width: 100%;
    max-width: 730px;
}

.activityPanel {
    padding: 20px;
}

/* ===== HEADER ===== */
.header {
    background: linear-gradient(90deg, #ffa500, #ff4500);
    box-shadow: 0 0 25px rgba(255, 165, 0, 0.5);
    color: #fff;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    overflow: hidden;
    position: relative;
}

/* ===== ROCKET ICON - SIMPLE WITHOUT FIRE ===== */
.rocketIcon {
    font-size: 24px;
    display: inline-block;
    position: relative;
    /* Rotasi -45deg untuk meluruskan emoji rocket yang miring */
    transform: rotate(-45deg);
    animation: rocketVerticalFly 2.5s ease-in-out infinite;
    transform-origin: center center;
    filter: drop-shadow(0 0 8px rgba(255, 165, 0, 0.4));
    line-height: 1;
    margin-top: 2px;
}

.rocketIcon:hover {
    animation-duration: 1.5s;
    filter: drop-shadow(0 0 15px rgba(255, 165, 0, 0.8));
}

.header h1 {
    font-family: 'Orbitron', 'Segoe UI', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 20px #ffa500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===== FIBONACCI INFO ===== */
.fibonacciInfo {
    background: linear-gradient(135deg, #FFD700, #FFA500, #FF8C00);
    color: #fff;
    border: 2px solid #FFD700;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.6);
    border-radius: 10px;
    padding: 10px 20px;
    text-align: center;
    font-weight: bold;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 25px;
    position: relative;
    overflow: hidden;
    animation: goldenGlow 3s ease-in-out infinite;
    text-shadow: 0 0 8px rgba(0, 0, 0, 0.5);
}

/* ===== FORMS ===== */
.formSection {
    margin-bottom: 25px;
}

.inputGroup {
    margin-bottom: 20px;
}

.inputGroup label {
    display: block;
    margin-bottom: 8px;
    color: #fff;
    font-size: 14px;
    font-weight: 500;
}

.inputGroup input {
    width: 100%;
    padding: 12px;
    border: 2px solid #ffa500;
    border-radius: 8px;
    background: rgba(17, 24, 39, 0.8);
    color: #fff;
    font-size: 14px;
    box-shadow: 0 0 15px rgba(255, 165, 0, 0.2);
}

.inputGroup input:focus {
    outline: none;
    border-color: #ff4500;
    box-shadow: 0 0 20px rgba(255, 69, 0, 0.4);
}

/* ===== BUTTONS ===== */
.button {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 8px;
    font-family: 'Orbitron', 'Segoe UI', sans-serif;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.buttonPrimary {
    background: linear-gradient(135deg, #ffa500, #ff6600);
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 165, 0, 0.3);
}

.buttonSecondary {
    background: linear-gradient(135deg, #ff6600, #ff4500);
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 102, 0, 0.3);
}

.buttonSuccess {
    background: linear-gradient(135deg, #ffa500, #ff6600);
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 165, 0, 0.3);
}

.buttonPrimary:hover,
.buttonSuccess:hover {
    background: linear-gradient(135deg, #ff6600, #ff4500);
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(255, 165, 0, 0.5);
}

.buttonSecondary:hover {
    background: linear-gradient(135deg, #ff4500, #c30);
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(255, 69, 0, 0.5);
}

/* ===== INFO ELEMENTS ===== */
.infoText {
    background: rgba(255, 165, 0, 0.1);
    border: 2px solid rgba(255, 165, 0, 0.3);
    box-shadow: 0 0 15px rgba(255, 165, 0, 0.2);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    color: #e5e7eb;
    font-size: 14px;
    line-height: 1.5;
}

.botStatus {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 165, 0, 0.06);
    border: 2px solid rgba(255, 165, 0, 0.3);
    box-shadow: 0 0 15px rgba(255, 165, 0, 0.2);
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 20px;
}

.statusIndicator {
    width: 10px;
    height: 10px;
    background: #ffa500;
    border-radius: 50%;
    animation: pulse 2s infinite;
    flex-shrink: 0;
    box-shadow: 0 0 10px #ffa500;
}

/* ===== LOADING DOTS ===== */
.loadingDots {
    display: inline-flex;
    gap: 6px;
    margin-left: 8px;
    vertical-align: middle;
}

.loadingDots .dot {
    width: 6px;
    height: 6px;
    background: #ffa500;
    border-radius: 50%;
    opacity: 0.35;
    transform: scale(0.6);
    animation: dotPulse 1.1s infinite ease-in-out;
    box-shadow: 0 0 5px #ffa500;
}

.loadingDots .dot:nth-child(1) {
    animation-delay: 0s;
}

.loadingDots .dot:nth-child(2) {
    animation-delay: 0.18s;
}

.loadingDots .dot:nth-child(3) {
    animation-delay: 0.36s;
}

/* ===== CONSOLE ===== */
.console {
    background: rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 165, 0, 0.3);
    box-shadow: 0 0 15px rgba(255, 165, 0, 0.2);
    border-radius: 15px;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 12px;
    margin-bottom: 15px;
    backdrop-filter: blur(10px);
}

.consoleLine {
    margin-bottom: 5px;
}

.consoleSuccess {
    color: #ffa500;
    text-shadow: 0 0 10px #ffa500;
    font-family: 'Courier New', monospace;
}

.consoleInfo {
    color: #ff6600;
    text-shadow: 0 0 10px #ff6600;
    font-family: 'Courier New', monospace;
}

/* ===== PREDICTION TABLE ===== */
.predictionTableContainer {
    margin: 15px 0;
    border-radius: 10px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.3);
}

.predictionTableHeader {
    background: rgba(0, 0, 0, 0.5);
    padding: 15px 0;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
    color: #ffa500;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 14px;
    text-shadow: 0 0 10px #ffa500;
    border-bottom: 2px solid rgba(255, 165, 0, 0.3);
}

.predictionTable {
    width: 100%;
    border-collapse: collapse;
}

.predictionTable th {
    background: rgba(0, 0, 0, 0.5);
    padding: 12px;
    text-align: center;
    color: #ffa500;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 12px;
    text-shadow: 0 0 8px #ffa500;
    border-bottom: 1px solid rgba(255, 165, 0, 0.3);
}

.predictionTable th:nth-child(1),
.predictionTable td:nth-child(1) {
    width: 30%;
}

.predictionTable th:nth-child(2),
.predictionTable td:nth-child(2) {
    width: 30%;
}

.predictionTable th:nth-child(3),
.predictionTable td:nth-child(3) {
    width: 40%;
}

.predictionTable td {
    padding: 15px 12px;
    text-align: center;
    font-size: 14px;
    font-weight: bold;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.predictionTable tr:last-child td {
    border-bottom: none;
}

.predictionTable tr:hover {
    background: rgba(255, 165, 0, 0.1);
}

.predictionTable .tableCell {
    color: #fff;
}

.predictionTable .tableGoldCell {
    color: #ffa500;
    text-shadow: 0 0 10px rgba(255, 165, 0, 0.5);
}

.predictionTable .tableActiveCell {
    color: #0f0;
    text-shadow: 0 0 10px rgba(0, 255, 0, 0.5);
}

/* ===== ACTIVITY PANEL ===== */
.activityHeader {
    color: #ffa500;
    text-shadow: 0 0 20px #ffa500;
    text-align: center;
    margin-bottom: 20px;
    font-family: 'Orbitron', 'Segoe UI', sans-serif;
    font-weight: 700;
    font-size: 17px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.recentActivityContainer {
    background: rgba(6, 78, 59, 0.2);
    border: 1px solid rgba(255, 165, 0, 0.3);
    border-radius: 10px;
    padding: 20px;
    overflow: hidden;
}

.activityContainer {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
    overflow: hidden;
}

.activityItem {
    width: 100%;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border-left: 3px solid #ffa500;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    opacity: 1;
    transition: all 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    transform: translateY(0) scale(1);
    height: 35px;
    box-sizing: border-box;
}

.activityItem:hover {
    background: rgba(255, 165, 0, 0.1);
}

.activityItem p {
    margin: 0;
    color: #e0e0e0;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    white-space: nowrap;
    overflow: hidden;
    line-height: 1;
    width: 100%;
}

.flagIcon {
    width: 22px;
    height: 16px;
    background: linear-gradient(to bottom, #dc2626 0%, #dc2626 50%, #fff 50%, #fff 100%);
    border-radius: 2px;
    position: relative;
    display: inline-block;
    vertical-align: middle;
    flex-shrink: 0;
}

.username {
    color: #ffa500;
    font-weight: 600;
    flex-shrink: 0;
    font-size: 12px;
    text-shadow: 0 0 10px rgba(255, 165, 0, 0.5);
}

.activityText {
    color: #ff6600;
    font-size: 12px;
    font-weight: 400;
}

/* ===== UTILITY CLASSES ===== */
.hidden {
    display: none;
}

.page {
    display: block;
}

.page.hidden {
    display: none;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .mainPanel,
    .activityPanel {
        margin: 10px;
        padding: 20px;
        max-width: 95%;
    }

    .header h1 {
        font-size: 18px;
    }

    .container {
        gap: 15px;
    }

    .activityItem p,
    .username,
    .activityText {
        font-size: 11px;
    }

    .flagIcon {
        width: 18px;
        height: 12px;
    }
    
    .rocketIcon {
        font-size: 20px;
    }
}