* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #0c0c0c 0%, #1a1a2e 50%, #16213e 100%);
    min-height: 100vh;
    color: #e0e6ed;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse 800px 600px at 10% 20%, rgba(120, 119, 198, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse 600px 800px at 90% 80%, rgba(255, 119, 198, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse 400px 400px at 50% 50%, rgba(120, 219, 255, 0.04) 0%, transparent 50%);
    animation: backgroundFloat 20s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes backgroundFloat {
    0%, 100% { 
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
    33% { 
        transform: scale(1.1) rotate(120deg);
        opacity: 0.8;
    }
    66% { 
        transform: scale(0.9) rotate(240deg);
        opacity: 1.2;
    }
}

.screen {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.hidden {
    display: none !important;
}

/* Login Screen */
.login-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 2rem;
    position: relative;
}

.login-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.2) 0%, transparent 50%);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

.logo {
    text-align: center;
    margin-bottom: 3rem;
    color: #ffffff;
    position: relative;
    z-index: 1;
}

.logo img {
    max-width: 120px;
    height: auto;
    margin-bottom: 1rem;
    filter: drop-shadow(0 0 30px rgba(102, 126, 234, 0.3));
    transition: all 0.3s ease;
}

.logo img:hover {
    filter: drop-shadow(0 0 40px rgba(102, 126, 234, 0.5)) brightness(1.1);
    transform: scale(1.05);
}

.logo i {
    font-size: 4rem;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 20px rgba(102, 126, 234, 0.5));
}

.logo h1 {
    font-size: 2.5rem;
    font-weight: 300;
    text-shadow: 0 0 30px rgba(255, 255, 255, 0.5);
}

.login-form {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    width: 100%;
    max-width: 400px;
    position: relative;
    z-index: 1;
}

.login-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #e0e6ed;
}

.login-form input {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    font-size: 1rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s;
    color: #ffffff;
    backdrop-filter: blur(10px);
}

.login-form input:focus {
    outline: none;
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 20px rgba(102, 126, 234, 0.3);
}

.login-form input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

/* Main App */
#mainApp {
    background: linear-gradient(135deg, #0c0c0c 0%, #1a1a2e 50%, #16213e 100%);
    position: relative;
}

#mainApp::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 10% 20%, rgba(120, 119, 198, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(255, 119, 198, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.app-header {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 1;
}

.app-header h2 {
    color: #ffffff;
    font-weight: 600;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #e0e6ed;
    font-weight: 500;
}

/* Navigation Tabs - Mobile App Style */
.nav-tabs {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    background: rgba(15, 15, 25, 0.98);
    backdrop-filter: blur(25px);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 1rem 1.5rem;
    padding-bottom: calc(env(safe-area-inset-bottom, 0) + 1rem);
    z-index: 1000;
    box-shadow: 
        0 -8px 32px rgba(0, 0, 0, 0.6),
        0 -2px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    min-height: 90px;
}

.nav-tab {
    border: none;
    background: transparent;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    color: #7c8db0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    max-width: 120px;
}

.side-tab {
    padding: 0.75rem 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.75rem;
    font-weight: 500;
    text-align: center;
    position: relative;
    min-height: 70px;
    justify-content: center;
}

.side-tab::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 18px;
    transition: all 0.3s ease;
    opacity: 0;
    scale: 0.8;
}

.side-tab:hover::before {
    opacity: 1;
    scale: 1;
}

.side-tab:hover {
    color: #ffffff;
    transform: translateY(-2px);
}

.side-tab.active {
    color: #667eea;
}

.side-tab.active::before {
    opacity: 1;
    scale: 1;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.15), rgba(118, 75, 162, 0.15));
    border: 1px solid rgba(102, 126, 234, 0.3);
    box-shadow: 
        0 4px 20px rgba(102, 126, 234, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.side-tab i {
    font-size: 1.3rem;
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

.side-tab.active i {
    filter: drop-shadow(0 0 8px rgba(102, 126, 234, 0.4));
}

.side-tab span {
    font-weight: 600;
    letter-spacing: 0.3px;
    position: relative;
    z-index: 2;
}

/* Central Vote Button - Horizontal Layout */
.main-vote-btn {
    position: relative;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 30%, #f093fb 60%, #667eea 100%);
    background-size: 300% 300%;
    animation: gradientMorph 6s ease infinite;
    border-radius: 20px;
    margin: 0;
    overflow: hidden;
    transform: none;
    box-shadow: 
        0 12px 30px rgba(102, 126, 234, 0.5),
        0 5px 15px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    min-height: 70px;
}

@keyframes gradientMorph {
    0% { background-position: 0% 50%; }
    25% { background-position: 100% 0%; }
    50% { background-position: 100% 100%; }
    75% { background-position: 0% 100%; }
    100% { background-position: 0% 50%; }
}

@keyframes gradientFlow {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.vote-btn-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    padding: 0.75rem 0.5rem;
    position: relative;
    z-index: 2;
    color: white;
    font-weight: 700;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
    width: 100%;
    height: 100%;
    min-height: 70px;
}

.vote-btn-content i {
    font-size: 1.3rem;
    filter: drop-shadow(0 0 12px rgba(255, 255, 255, 0.6));
    margin-bottom: 0.2rem;
}

.vote-btn-content span {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.vote-btn-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 60%);
    animation: revolut-pulse 3s ease-in-out infinite;
    pointer-events: none;
}

@keyframes revolut-pulse {
    0%, 100% { 
        transform: scale(0.7) rotate(0deg); 
        opacity: 0.4; 
    }
    50% { 
        transform: scale(1.1) rotate(180deg); 
        opacity: 0.7; 
    }
}

.main-vote-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 
        0 12px 30px rgba(102, 126, 234, 0.5),
        0 5px 15px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.main-vote-btn:active {
    transform: translateY(-1px) scale(0.98);
    box-shadow: 
        0 6px 20px rgba(102, 126, 234, 0.3),
        0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Content */
.app-content {
    flex: 1;
    padding: 1rem;
    padding-bottom: 110px; /* Space for new mobile navigation */
    overflow-y: auto;
    position: relative;
    z-index: 1;
    min-height: calc(100vh - 160px);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Tasks */
.tasks-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.category {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 
        0 15px 35px rgba(0, 0, 0, 0.3),
        0 5px 15px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
}

.category::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.8), transparent);
    transition: left 0.8s ease;
}

.category:hover::before {
    left: 100%;
}

.category:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(102, 126, 234, 0.3);
}

.category-header {
    background: linear-gradient(45deg, rgba(102, 126, 234, 0.8), rgba(118, 75, 162, 0.8));
    color: white;
    padding: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.category-header i {
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.5));
}

.task-list {
    padding: 1rem;
}

.task-item {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 15px;
    margin-bottom: 0.5rem;
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid transparent;
}

.task-item::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -10px;
    width: 6px;
    height: 6px;
    background: #667eea;
    border-radius: 50%;
    transform: translateY(-50%) scale(0);
    transition: all 0.3s ease;
    box-shadow: 0 0 15px rgba(102, 126, 234, 0.6);
}

.task-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s;
}

.task-item:hover::before {
    left: 100%;
}

.task-item:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateX(8px) translateY(-2px);
    border-left: 4px solid #667eea;
    border-color: rgba(102, 126, 234, 0.3);
    box-shadow: 
        0 10px 25px rgba(0, 0, 0, 0.2),
        0 0 0 1px rgba(102, 126, 234, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.task-item:hover::after {
    transform: translateY(-50%) scale(1);
    right: 15px;
}

.task-item.voted {
    background: linear-gradient(45deg, rgba(40, 180, 99, 0.2), rgba(39, 174, 96, 0.2));
    border-left: 3px solid #27ae60;
    cursor: not-allowed;
}

.voting-task-disabled {
    opacity: 0.7;
    cursor: not-allowed !important;
    pointer-events: none;
}

.voting-task-disabled:hover {
    transform: none !important;
    border-left: 3px solid #27ae60 !important;
}

.voting-task-disabled::before {
    display: none;
}

.task-title {
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.25rem;
}

.task-description {
    color: #a8b2d1;
    font-size: 0.9rem;
}

.task-points {
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

/* Results */
.results-container {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.results-header {
    text-align: center;
    margin-bottom: 2rem;
}

.results-header h3 {
    color: #ffffff;
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.results-header i {
    color: #f39c12;
    filter: drop-shadow(0 0 10px rgba(243, 156, 18, 0.5));
}

.results-header p {
    color: #a8b2d1;
}

.results-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.result-item {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.result-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.05), transparent);
    transform: translateX(-100%);
    transition: transform 0.5s;
}

.result-item:hover::before {
    transform: translateX(100%);
}

.result-item:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 
        0 15px 40px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(102, 126, 234, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(102, 126, 234, 0.4);
}

.result-item:hover .result-rank {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 
        0 8px 25px rgba(102, 126, 234, 0.5),
        0 0 20px rgba(102, 126, 234, 0.3);
}

.result-item:hover .result-points {
    transform: scale(1.1);
    text-shadow: 0 0 20px rgba(102, 126, 234, 0.8);
}

.top-result {
    background: linear-gradient(45deg, rgba(255, 215, 0, 0.1), rgba(255, 193, 7, 0.1));
    border-color: rgba(255, 215, 0, 0.3);
}

.result-rank {
    width: 50px;
    height: 50px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: white;
    font-size: 1.2rem;
    position: relative;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.result-rank i {
    position: absolute;
    top: -5px;
    right: -5px;
    color: #f39c12;
    font-size: 0.8rem;
    filter: drop-shadow(0 0 5px rgba(243, 156, 18, 0.8));
}

.result-content {
    flex: 1;
    min-width: 0;
}

.result-title {
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.5rem;
    word-wrap: break-word;
    hyphens: auto;
}

.result-stats {
    color: #a8b2d1;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: nowrap;
}

.votes-count {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.25rem 0.5rem;
    border-radius: 10px;
    font-size: 0.8rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.result-category {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex-shrink: 1;
    min-width: 0;
}

.result-points {
    font-size: 1.5rem;
    font-weight: 700;
    color: #667eea;
    text-shadow: 0 0 10px rgba(102, 126, 234, 0.5);
}

/* Buttons */
.primary-btn {
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 15px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.3);
}

.primary-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.primary-btn:hover::before {
    left: 100%;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

.secondary-btn {
    background: rgba(108, 117, 125, 0.8);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 15px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin-top: 0.5rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.secondary-btn:hover {
    background: rgba(90, 98, 104, 0.9);
    transform: translateY(-2px);
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin: 1rem;
    border-radius: 20px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

.modal-header {
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 20px 20px 0 0;
}

.points-display {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    backdrop-filter: blur(10px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.modal-body {
    padding: 1.5rem;
    color: #e0e6ed;
}

.tutorial-text, .voting-question, .confirm-text {
    line-height: 1.6;
    margin-bottom: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 1rem;
    border-radius: 10px;
    border-left: 3px solid #667eea;
}

.voting-summary {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1rem;
    border-radius: 15px;
    margin-top: 1rem;
}

.success-message {
    text-align: center;
    padding: 1.5rem 1rem;
    margin-bottom: 1.5rem;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 15px;
}

.success-icon {
    font-size: 3rem;
    color: #22c55e;
    margin-bottom: 1rem;
}

.success-message h4 {
    color: #ffffff;
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
    font-weight: 600;
}

.success-message p {
    color: #e0e6ed;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.success-message .divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    margin: 0 auto;
    width: 80%;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.summary-item:hover {
    background: rgba(255, 255, 255, 0.05);
    padding-left: 0.5rem;
    border-radius: 5px;
}

.summary-item:last-child {
    border-bottom: none;
}

.modal-footer {
    padding: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Modal */
.modal-content {
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin: 1rem;
    border-radius: 20px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

/* Voting Mode */
#mainApp.voting-mode .app-content {
    visibility: hidden;
}

#mainApp.voting-mode .nav-tabs {
    visibility: hidden;
}

#mainApp.voting-mode .app-header {
    visibility: hidden;
}

.voting-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    min-height: 100vh;
    background: rgba(12, 12, 12, 0.98);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    z-index: 999;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.voting-header {
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.3);
}

.voting-points-display {
    background: rgba(255, 255, 255, 0.2);
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    backdrop-filter: blur(10px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.overlay-question {
    font-size: 1.1rem;
    font-weight: 500;
    opacity: 0.9;
}

.voting-tasks-fullscreen {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
}

/* Voting History Styles */
.voting-history {
    margin-top: 1rem; 
    padding: 1rem; 
    background: rgba(255, 255, 255, 0.1) !important;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    color: #e0e6ed;
}

.voting-history h4 {
    color: #ffffff;
    margin-bottom: 1rem;
    font-weight: 600;
}

.voting-history .summary-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    border-radius: 10px;
    border-left: 3px solid #667eea;
}

.voting-history .summary-item:last-child {
    margin-bottom: 0;
}

.voting-history .task-points {
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Mobile Optimizations */
body {
    padding-bottom: env(safe-area-inset-bottom, 0);
}

.app-header {
    position: sticky;
    top: 0;
    z-index: 100;
}

.app-header h2 {
    font-size: 1.4rem;
    font-weight: 700;
}

/* Floating Particles Animation */
@keyframes float-particles {
    0% { 
        transform: translateY(100vh) translateX(0) rotate(0deg);
        opacity: 0;
    }
    10% { 
        opacity: 0.6;
    }
    90% { 
        opacity: 0.6;
    }
    100% { 
        transform: translateY(-10vh) translateX(50px) rotate(360deg);
        opacity: 0;
    }
}

.app-content::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(102, 126, 234, 0.1) 1px, transparent 1px),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.08) 1px, transparent 1px),
        radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.06) 1px, transparent 1px);
    background-size: 150px 150px, 200px 200px, 100px 100px;
    animation: float-particles 25s linear infinite;
    pointer-events: none;
    z-index: -1;
}

/* Enhanced Button Effects */
.primary-btn {
    position: relative;
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 15px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    width: 100%;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    overflow: hidden;
    box-shadow: 
        0 8px 25px rgba(102, 126, 234, 0.3),
        0 2px 10px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.primary-btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.primary-btn:hover::after {
    width: 300px;
    height: 300px;
}

.primary-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 
        0 15px 35px rgba(102, 126, 234, 0.4),
        0 5px 15px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .logo img {
        max-width: 100px;
    }

    .modal-content {
        margin: 0.5rem;
        margin-bottom: 115px;
    }

    .app-content {
        padding-bottom: 115px;
    }

    .nav-tabs {
        padding: 0.75rem 1rem;
        padding-bottom: calc(env(safe-area-inset-bottom, 0) + 0.75rem);
        min-height: 85px;
        gap: 1.5rem;
    }

    .side-tab {
        font-size: 0.7rem;
        padding: 0.6rem 0.4rem;
        gap: 0.3rem;
        min-height: 65px;
    }

    .side-tab i {
        font-size: 1.2rem;
    }

    .main-vote-btn {
        min-height: 65px;
    }

    .vote-btn-content {
        padding: 0.6rem 0.4rem;
        min-height: 65px;
    }

    .vote-btn-content i {
        font-size: 1.2rem;
    }

    .vote-btn-content span {
        font-size: 0.7rem;
    }

    .voting-header {
        padding: 1rem;
    }

    .voting-tasks-fullscreen {
        padding: 1rem;
        padding-bottom: 110px;
    }

    .user-info {
        font-size: 0.9rem;
    }
}

/* Ultra Mobile (smaller screens) */
@media (max-width: 480px) {
    .logo img {
        max-width: 80px;
    }

    .nav-tabs {
        padding: 0.6rem 0.8rem;
        padding-bottom: calc(env(safe-area-inset-bottom, 0) + 0.6rem);
        gap: 1rem;
        min-height: 80px;
    }

    .side-tab {
        font-size: 0.65rem;
        min-height: 60px;
        padding: 0.5rem 0.3rem;
    }

    .side-tab i {
        font-size: 1.1rem;
    }

    .main-vote-btn {
        min-height: 60px;
    }

    .vote-btn-content {
        min-height: 60px;
        padding: 0.5rem 0.3rem;
    }

    .vote-btn-content i {
        font-size: 1.1rem;
    }

    .vote-btn-content span {
        font-size: 0.65rem;
    }
}

/* Footer */
.app-footer {
    position: fixed;
    bottom: 110px;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 0.5rem;
    text-align: center;
    z-index: 50;
    pointer-events: none;
}

.version-info {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.4);
    font-weight: 300;
}

.version-info span:first-child {
    font-weight: 500;
}

.version {
    background: rgba(102, 126, 234, 0.2);
    padding: 0.1rem 0.4rem;
    border-radius: 8px;
    font-size: 0.65rem;
    font-weight: 600;
    color: rgba(102, 126, 234, 0.8);
    border: 1px solid rgba(102, 126, 234, 0.3);
}

/* Mobile adjustments for footer */
@media (max-width: 768px) {
    .app-footer {
        bottom: 90px;
    }
}

@media (max-width: 480px) {
    .app-footer {
        bottom: 85px;
    }
    
    .version-info {
        font-size: 0.65rem;
    }
    
    .version {
        font-size: 0.6rem;
        padding: 0.1rem 0.3rem;
    }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, #5a6fd8, #6a42a0);
}