/* Main Styles for Word Fun Planet App */
body {
    font-family: 'Roboto', 'Helvetica', 'Arial', sans-serif;
    background-color: #f9fafb;
    color: #333;
}

/* iPhone 16 Frame Styles */
.phone-container {
    padding: 20px;
    display: flex;
    justify-content: center;
}

.phone-frame {
    width: 300px;
    height: 600px;
    background-color: #000;
    border-radius: 40px;
    padding: 8px;
    position: relative;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.phone-notch {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 25px;
    background-color: #000;
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
    z-index: 10;
}

.phone-screen {
    width: 100%;
    height: 100%;
    border-radius: 32px;
    overflow: hidden;
    background-color: white;
    position: relative;
    z-index: 1;
}

/* App-specific Styles */
.app-container {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.app-header {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.app-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    background-color: #f9fafb;
}

.app-footer {
    background-color: #fff;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-around;
    padding: 12px 0;
    position: relative;
    z-index: 10;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 12px;
    color: #6b7280;
    transition: all 0.3s;
}

.nav-item.active {
    color: #4f46e5;
}

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

/* Card Components */
.word-card {
    background-color: white;
    border-radius: 16px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    padding: 16px;
    margin-bottom: 16px;
    transition: transform 0.3s ease;
}

.word-card:active {
    transform: scale(0.98);
}

.word-image {
    width: 100%;
    height: 160px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 12px;
}

.achievement-badge {
    background-color: #fef3c7;
    color: #92400e;
    border-radius: 9999px;
    padding: 6px 12px;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    margin: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.achievement-badge i {
    margin-right: 5px;
}

/* Buttons */
.btn {
    border-radius: 9999px;
    padding: 10px 20px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background-color: #4f46e5;
    color: white;
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
}

.btn-primary:hover {
    background-color: #4338ca;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(79, 70, 229, 0.4);
}

.btn-secondary {
    background-color: #f3f4f6;
    color: #111827;
}

.btn-secondary:hover {
    background-color: #e5e7eb;
}

/* Game Elements */
.game-card {
    background-color: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 16px;
}

.game-card-img {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.game-card-content {
    padding: 16px;
}

/* Progress Bar */
.progress-container {
    background-color: #e5e7eb;
    border-radius: 9999px;
    height: 8px;
    overflow: hidden;
    margin: 8px 0;
}

.progress-bar {
    height: 100%;
    border-radius: 9999px;
    background: linear-gradient(to right, #4f46e5, #7c3aed);
}

/* Word Controls */
.word-controls {
    display: flex;
    justify-content: space-between;
    margin-top: 12px;
}

.word-control-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: #f3f4f6;
    color: #4b5563;
    font-size: 18px;
}

.word-control-btn.primary {
    background-color: #4f46e5;
    color: white;
}

/* Statistics */
.stat-card {
    background-color: white;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    margin-bottom: 16px;
}

.stat-value {
    font-size: 24px;
    font-weight: bold;
    color: #4f46e5;
    margin-top: 4px;
}

.stat-label {
    font-size: 14px;
    color: #6b7280;
}

/* Animations */
@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.animate-bounce {
    animation: bounce 2s infinite;
}

/* Character */
.character {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 20px 0;
}

.character img {
    width: 120px;
    height: 120px;
    margin-bottom: 10px;
}

/* Speech Bubble */
.speech-bubble {
    position: relative;
    background: #4f46e5;
    color: white;
    border-radius: 20px;
    padding: 10px 15px;
    margin-top: 10px;
    max-width: 80%;
}

.speech-bubble:after {
    content: '';
    position: absolute;
    top: -10px;
    left: 20px;
    border-width: 0 10px 10px;
    border-style: solid;
    border-color: #4f46e5 transparent;
}

/* Media queries for responsive design */
@media (max-width: 640px) {
    .phone-frame {
        width: 280px;
        height: 560px;
    }
}