* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: #fff;
    min-height: 100vh;
    padding: 10px;
    overflow-x: hidden;
}

.container {
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.header {
    text-align: center;
    margin-bottom: 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.timer {
    font-size: 14px;
    opacity: 0.9;
}

.timer #timer-value {
    display: inline-block;
    min-width: 150px;
    text-align: left;
}

.tabs {
    display: flex;
    gap: 5px;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.1);
    padding: 5px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.tab-btn {
    flex: 1;
    padding: 10px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 14px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.tab-btn.active {
    background: linear-gradient(135deg, #ff6b6b, #ee5a6f);
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.4);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.progress-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.level-info {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 20px;
}

.level-badge {
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    min-width: 100px;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
}

.level-number {
    display: block;
    font-size: 36px;
    font-weight: bold;
    color: #1a1a2e;
}

.level-label {
    display: block;
    font-size: 12px;
    color: #1a1a2e;
    margin-top: 5px;
}

.xp-info {
    flex: 1;
}

.xp-text {
    font-size: 16px;
    margin-bottom: 10px;
    font-weight: 600;
}

.xp-bar-container {
    margin-bottom: 10px;
}

.xp-bar {
    width: 100%;
    height: 20px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.xp-bar-fill {
    height: 100%;
    background: #0ab320;
    border-radius: 10px;
    transition: width 1.5s ease-out;
    will-change: width;
}

.total-xp {
    font-size: 12px;
    opacity: 0.8;
}

.daily-limit {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.limit-text {
    font-size: 14px;
    margin-bottom: 10px;
}

.limit-bar-container {
    margin-bottom: 10px;
}

.limit-bar {
    width: 100%;
    height: 15px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    overflow: hidden;
}

.limit-bar-fill {
    height: 100%;
    background: #ff6b6b;
    border-radius: 8px;
    transition: width 1.5s ease-out;
    will-change: width;
}

.premium-badge {
    margin-top: 15px;
    padding: 10px;
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    border-radius: 10px;
    text-align: center;
    color: #1a1a2e;
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
}

.quests-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.quest-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 15px;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.quest-card.easy {
    border-left: 4px solid #4ecdc4;
}

.quest-card.medium {
    border-left: 4px solid #ffd700;
}

.quest-card.hard {
    border-left: 4px solid #ff6b6b;
}

.quest-card.completed {
    opacity: 0.6;
    background: rgba(76, 175, 80, 0.2);
}

.quest-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.quest-name {
    font-size: 16px;
    font-weight: 600;
}

.quest-xp {
    background: rgba(255, 255, 255, 0.2);
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: bold;
}

.quest-description {
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 10px;
}

.quest-progress {
    display: flex;
    align-items: center;
    gap: 10px;
}

.quest-progress-bar {
    flex: 1;
    height: 8px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    overflow: hidden;
}

.quest-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4ecdc4, #44a08d);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.quest-progress-text {
    font-size: 12px;
    min-width: 60px;
    text-align: right;
}

.rewards-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
}

.reward-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 15px;
    text-align: center;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    position: relative;
    transition: transform 0.3s;
}

.reward-card:hover {
    transform: scale(1.05);
}

.reward-card.locked {
    opacity: 0.5;
}

.reward-card.available {
    border: 2px solid #4ecdc4;
    box-shadow: 0 0 20px rgba(78, 205, 196, 0.5);
}

.reward-card.claimed {
    opacity: 0.6;
    background: rgba(76, 175, 80, 0.2);
}

.reward-level {
    font-size: 12px;
    opacity: 0.8;
    margin-bottom: 5px;
}

.reward-icon {
    font-size: 40px;
    margin: 10px 0;
}

.reward-name {
    font-size: 14px;
    font-weight: 600;
}

.reward-claim-btn {
    margin-top: 10px;
    padding: 8px 15px;
    background: linear-gradient(135deg, #4ecdc4, #44a08d);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-weight: bold;
    cursor: pointer;
    width: 100%;
    transition: all 0.3s;
}

.reward-claim-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(78, 205, 196, 0.4);
}

.reward-claim-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.premium-container {
    display: flex;
    justify-content: center;
}

.premium-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 30px;
    max-width: 400px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    text-align: center;
}

.premium-card h2 {
    font-size: 28px;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.premium-features {
    text-align: left;
    margin-bottom: 30px;
}

.feature {
    padding: 10px;
    font-size: 16px;
    margin-bottom: 10px;
}

.premium-price {
    font-size: 36px;
    font-weight: bold;
    color: #ffd700;
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.buy-btn {
    padding: 15px 30px;
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    border: none;
    border-radius: 12px;
    color: #1a1a2e;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    width: 100%;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
}

.buy-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(255, 215, 0, 0.6);
}

.premium-active {
    padding: 15px;
    background: rgba(76, 175, 80, 0.3);
    border-radius: 12px;
    font-size: 18px;
    font-weight: bold;
    color: #4caf50;
}

.loading {
    text-align: center;
    padding: 40px;
    font-size: 18px;
    opacity: 0.8;
}
