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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #fd5068 0%, #ff8a56 100%);
    background-attachment: fixed;
    min-height: 100vh;
    color: #333;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

#app {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    position: relative;
}

.screen {
    width: 100%;
    max-width: 500px;
    padding: 20px;
    animation: fadeIn 0.3s;
    box-sizing: border-box;
}

@media (max-width: 480px) {
    .screen {
        padding: 15px 10px;
    }
}

.screen.hidden {
    display: none;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.container {
    background: white;
    border-radius: 20px;
    padding: 40px 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    text-align: center;
}

h1 {
    font-size: 28px;
    margin-bottom: 20px;
    color: #fd5068;
}

p {
    font-size: 16px;
    line-height: 1.6;
    color: #666;
    margin-bottom: 30px;
}

.btn-primary {
    background: linear-gradient(135deg, #fd5068 0%, #ff8a56 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 18px;
    border-radius: 30px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    font-weight: 600;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(253, 80, 104, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.loading {
    text-align: center;
    color: white;
    font-size: 20px;
}

/* Question Screen - Tinder Style */
.question-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: 100%;
    min-height: 100vh;
    height: 100vh;
    padding: 15px;
    position: relative;
    max-width: 500px;
    margin: 0 auto;
    overflow: hidden;
}

@media (max-width: 480px) {
    .question-container {
        padding: 10px;
        gap: 15px;
    }
}

/* Подписи для свайпов */
.swipe-labels {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
}

.swipe-label {
    position: absolute;
    font-size: 24px;
    font-weight: bold;
    opacity: 0;
    transition: opacity 0.2s ease, transform 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    pointer-events: none;
    z-index: 10;
}

.swipe-label-left {
    left: 15px;
    top: 50%;
    color: #fd5068;
    border: 3px solid #fd5068;
    padding: 8px 16px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.95);
    font-size: 20px;
    transform: translateY(-50%) scale(0.8);
}

.swipe-label-left.active {
    transform: translateY(-50%) scale(1);
}

.swipe-label-right {
    right: 15px;
    top: 50%;
    color: #00e5b0;
    border: 3px solid #00e5b0;
    padding: 8px 16px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.95);
    font-size: 20px;
    transform: translateY(-50%) scale(0.8);
}

.swipe-label-right.active {
    transform: translateY(-50%) scale(1);
}

.swipe-label-top {
    top: 60px;
    left: 50%;
    color: #ff8a56;
    border: 3px solid #ff8a56;
    padding: 8px 16px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.95);
    font-size: 20px;
    transform: translateX(-50%) scale(0.8);
}

.swipe-label-top.active {
    transform: translateX(-50%) scale(1);
}

.swipe-label-bottom {
    bottom: 120px;
    left: 50%;
    color: #999;
    border: 3px solid #999;
    padding: 8px 16px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.95);
    font-size: 20px;
    transform: translateX(-50%) scale(0.8);
}

.swipe-label-bottom.active {
    transform: translateX(-50%) scale(1);
}

@media (max-width: 480px) {
    .swipe-label {
        font-size: 18px;
        padding: 6px 12px;
    }
    
    .swipe-label-left {
        left: 10px;
    }
    
    .swipe-label-right {
        right: 10px;
    }
    
    .swipe-label-top {
        top: 50px;
    }
    
    .swipe-label-bottom {
        bottom: 100px;
    }
}

.swipe-label.active {
    opacity: 1;
}

/* Карточка вопроса - Tinder Style */
.question-card {
    background: white;
    border-radius: 20px;
    padding: 30px 25px;
    width: 100%;
    max-width: 400px;
    min-height: 350px;
    max-height: 450px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.3);
    touch-action: none;
    user-select: none;
    cursor: grab;
    position: relative;
    transition: transform 0.1s ease-out;
    will-change: transform;
    margin-top: 20px;
}

@media (max-width: 480px) {
    .question-card {
        padding: 25px 20px;
        min-height: 300px;
        max-height: 400px;
        margin-top: 10px;
    }
}

.question-card:active {
    cursor: grabbing;
}

.question-card.swiping-left {
    transform: rotate(-10deg) translateX(-20px);
    background: linear-gradient(135deg, #ffe0e0 0%, #ffcccc 100%);
}

.question-card.swiping-right {
    transform: rotate(10deg) translateX(20px);
    background: linear-gradient(135deg, #e0fff4 0%, #ccffeb 100%);
}

.question-card.swiping-up {
    transform: translateY(-20px) scale(1.05);
    background: linear-gradient(135deg, #fff4e0 0%, #ffe8cc 100%);
}

.question-card.swiping-down {
    transform: translateY(20px) scale(0.95);
    background: linear-gradient(135deg, #f0f0f0 0%, #e0e0e0 100%);
}

.question-text {
    font-size: 22px;
    line-height: 1.5;
    text-align: center;
    color: #333;
    font-weight: 500;
}

@media (max-width: 480px) {
    .question-text {
        font-size: 18px;
        line-height: 1.4;
    }
}

/* Progress Bar */
.progress-bar {
    width: 100%;
    max-width: 400px;
    height: 6px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    overflow: hidden;
    margin-top: 10px;
    padding: 0 10px;
}

.progress-fill {
    height: 100%;
    background: white;
    border-radius: 10px;
    transition: width 0.3s ease;
    width: 0%;
}

/* Нижние кнопки */
.bottom-buttons {
    display: flex;
    gap: 15px;
    width: 100%;
    max-width: 400px;
    margin-top: auto;
    margin-bottom: 20px;
    padding: 0 10px;
}

.bottom-btn {
    flex: 1;
    background: white;
    color: #fd5068;
    border: 2px solid white;
    padding: 15px 20px;
    font-size: 16px;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 600;
    min-height: 48px;
}

@media (max-width: 480px) {
    .bottom-buttons {
        gap: 10px;
        margin-bottom: 15px;
        padding: 0 5px;
    }
    
    .bottom-btn {
        padding: 12px 15px;
        font-size: 14px;
        min-height: 44px;
    }
}

.bottom-btn:hover {
    background: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.3);
}

.bottom-btn:active {
    transform: translateY(0);
}

/* Profile Screen */
#profile-content {
    text-align: left;
    margin: 30px 0;
}

.profile-section {
    background: #f5f5f5;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
}

.profile-section h2 {
    font-size: 18px;
    color: #fd5068;
    margin-bottom: 15px;
}

.profile-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #ddd;
}

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

/* Анимация появления карточки */
@keyframes cardEnter {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.question-card.new {
    animation: cardEnter 0.3s ease-out;
}
