/* Common Styles for BitPower */
:root {
    --primary: #F7931A; /* BTC Orange */
    --primary-light: #fef3c7;
    --secondary: #3B82F6;
    --bg-light: #F8FAFC;
    --text-main: #1E293B;
}

body {
    background-color: #f0f2f5;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 0; /* 移除内边距，确保贴合 iframe */
}

/* iPhone 15 Frame Style */
.iphone-15 {
    width: 393px;
    height: 852px;
    background: var(--bg-light);
    border-radius: 50px;
    border: 8px solid #333;
    position: relative;
    overflow: hidden;
    box-shadow: none; /* 在 iframe 内部不需要额外的阴影 */
    margin: 0; /* 移除外边距 */
    display: block;
}

/* Dynamic Island */
.dynamic-island {
    position: absolute;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 35px;
    background: black;
    border-radius: 20px;
    z-index: 100;
}

/* Page Container within Frame */
.app-container {
    width: 100%;
    height: 100%;
    overflow-y: auto;
    background: transparent;
    padding-top: 50px; /* 避开灵动岛 */
    padding-bottom: 80px; /* Space for bottom nav */
    position: relative;
}

/* Irregular Tech Background Accents */
.tech-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
    opacity: 0.8;
}

.accent-shape {
    position: absolute;
    background: linear-gradient(135deg, rgba(247, 147, 26, 0.2) 0%, transparent 100%);
    filter: blur(60px);
    border-radius: 50%;
}

.shape-1 { width: 350px; height: 350px; top: -100px; right: -100px; }
.shape-2 { width: 300px; height: 300px; bottom: 100px; left: -80px; background: linear-gradient(135deg, rgba(59, 130, 246, 0.1) 0%, transparent 100%); }

.tech-line {
    position: absolute;
    background: linear-gradient(90deg, transparent, rgba(247, 147, 26, 0.5), transparent);
    height: 2px;
    width: 150%;
    transform-origin: left center;
}

.line-1 { top: 15%; left: -10%; transform: rotate(-15deg); width: 120%; }
.line-2 { top: 45%; left: 20%; transform: rotate(165deg); width: 100%; }
.line-3 { top: 75%; left: -20%; transform: rotate(-10deg); width: 140%; }
.line-4 { top: 30%; right: -10%; transform: rotate(45deg); width: 60%; background: linear-gradient(90deg, transparent, rgba(247, 147, 26, 0.3), transparent); }

/* Ensure content is above accents */
.app-container > *:not(.tech-bg) {
    position: relative;
    z-index: 10;
}

/* Bottom Navigation */
.bottom-nav {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 70px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-around;
    align-items: center;
    border-top: 1px solid #e2e8f0;
    z-index: 50;
    padding-bottom: 10px;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #94a3b8;
    text-decoration: none;
    font-size: 10px;
}

.nav-item.active {
    color: var(--primary);
}

.nav-item i {
    font-size: 20px;
    margin-bottom: 4px;
}

/* Hide scrollbar */
.app-container::-webkit-scrollbar {
    display: none;
}

/* Utility for text gradients */
.text-gradient {
    background: linear-gradient(135deg, var(--primary), #8B5CF6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Mining Animation Background Enhanced */
.mining-bg {
    background: linear-gradient(135deg, #020617 0%, #0f172a 50%, #1e293b 100%);
    position: relative;
    overflow: hidden;
}

/* 3D Moving Grid */
.mining-lines {
    position: absolute;
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    background-image: 
        linear-gradient(rgba(247, 147, 26, 0.2) 1px, transparent 1px),
        linear-gradient(90deg, rgba(247, 147, 26, 0.2) 1px, transparent 1px);
    background-size: 30px 30px;
    transform: perspective(600px) rotateX(45deg);
    animation: move-grid 8s linear infinite;
    mask-image: radial-gradient(circle at center, black 30%, transparent 80%);
}

/* Add a glowing dots overlay for more "tech" feel */
.tech-dots {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(247, 147, 26, 0.3) 1px, transparent 1px);
    background-size: 15px 15px;
    opacity: 0.5;
}

/* Glowing light bar moving across */
.scan-line {
    position: absolute;
    width: 100%;
    height: 100px;
    background: linear-gradient(to bottom, transparent, rgba(247, 147, 26, 0.1), transparent);
    top: -100px;
    animation: scan 4s ease-in-out infinite;
}

@keyframes move-grid {
    0% { transform: perspective(600px) rotateX(45deg) translateY(0); }
    100% { transform: perspective(600px) rotateX(45deg) translateY(30px); }
}

@keyframes scan {
    0% { top: -100px; }
    100% { top: 100%; }
}

