* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #FF6B35;
    --secondary: #F7931E;
    --dark: #2C3E50;
    --light: #ECF0F1;
    --success: #27AE60;
    --danger: #E74C3C;
    --gradient: linear-gradient(135deg, #FF6B35 0%, #F7931E 100%);
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-lg: 0 5px 20px rgba(0,0,0,0.15);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #F5F5F5;
    color: var(--dark);
    line-height: 1.6;
}

/* === HERO SECTION === */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 60px 80px;
    background: linear-gradient(135deg, #FFF5F0 0%, #FFE8DC 100%);
    gap: 60px;
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.hero-title {
    font-size: 64px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
    color: var(--dark);
}

.gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 20px;
    color: #666;
    margin-bottom: 40px;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.phone-mockup {
    width: 300px;
    height: 600px;
    background: white;
    border-radius: 40px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.activity-card {
    text-align: center;
    padding: 40px;
    background: linear-gradient(135deg, #FF6B35 0%, #F7931E 100%);
    border-radius: 20px;
    color: white;
}

.activity-icon {
    font-size: 80px;
    margin-bottom: 20px;
}

.activity-card h3 {
    font-size: 24px;
    margin-bottom: 10px;
}

.activity-card p {
    font-size: 18px;
    opacity: 0.9;
}

/* === BUTTONS === */
.btn {
    display: inline-block;
    padding: 14px 32px;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    text-align: center;
    font-family: inherit;
}

.btn-primary {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-secondary:hover {
    background: var(--primary);
    color: white;
}

.btn-large {
    padding: 16px 40px;
    font-size: 18px;
}

.btn-block {
    width: 100%;
    display: block;
}

/* === FEATURES === */
.features {
    padding: 100px 40px;
    background: white;
}

.features h2 {
    text-align: center;
    font-size: 48px;
    margin-bottom: 60px;
    color: var(--dark);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-card {
    text-align: center;
    padding: 40px 20px;
}

.feature-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 24px;
    margin-bottom: 15px;
    color: var(--dark);
}

.feature-card p {
    color: #666;
    font-size: 16px;
    line-height: 1.6;
}

/* === ACTIVITIES SHOWCASE === */
.activities-showcase {
    padding: 100px 40px;
    background: #FAFAFA;
}

.activities-showcase h2 {
    text-align: center;
    font-size: 48px;
    margin-bottom: 60px;
}

.activities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.activity-type {
    background: white;
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
    box-shadow: var(--shadow);
}

.activity-type:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.activity-emoji {
    font-size: 64px;
    display: block;
    margin-bottom: 15px;
}

.activity-type h3 {
    font-size: 20px;
    color: var(--dark);
}

/* === CTA === */
.cta {
    padding: 100px 40px;
    background: var(--gradient);
    color: white;
    text-align: center;
}

.cta h2 {
    font-size: 48px;
    margin-bottom: 20px;
}

.cta p {
    font-size: 20px;
    margin-bottom: 40px;
    opacity: 0.95;
}

/* === FOOTER === */
footer {
    background: var(--dark);
    color: white;
    padding: 30px 40px;
    text-align: center;
}

/* === AUTH PAGES === */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #FFF5F0 0%, #FFE8DC 100%);
    padding: 20px;
}

.auth-container {
    background: white;
    border-radius: 20px;
    padding: 40px;
    width: 100%;
    max-width: 450px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-header .logo {
    font-size: 36px;
    font-weight: bold;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 10px;
}

.auth-header p {
    color: #666;
    font-size: 16px;
}

.auth-form {
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark);
    font-size: 14px;
}

input, select, textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #E0E0E0;
    border-radius: 10px;
    font-size: 16px;
    font-family: inherit;
    transition: border-color 0.3s;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

.auth-footer {
    text-align: center;
    color: #666;
}

.auth-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* === ALERTS === */
#alert-container {
    margin-bottom: 20px;
}

.alert {
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 15px;
    animation: slideIn 0.3s ease-out;
}

.alert-success {
    background: #D4EDDA;
    color: #155724;
    border: 1px solid #C3E6CB;
}

.alert-error {
    background: #F8D7DA;
    color: #721C24;
    border: 1px solid #F5C6CB;
}

.alert-info {
    background: #D1ECF1;
    color: #0C5460;
    border: 1px solid #BEE5EB;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* === LOADING === */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    color: white;
}

.spinner {
    border: 4px solid rgba(255,255,255,0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#loading-text {
    font-size: 18px;
    font-weight: 500;
}

/* === HEADER/NAVBAR === */
.navbar {
    background: white;
    box-shadow: var(--shadow);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar .logo {
    font-size: 28px;
    font-weight: bold;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-decoration: none;
}

.navbar nav {
    display: flex;
    gap: 30px;
    align-items: center;
}

.navbar nav a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: color 0.3s;
}

.navbar nav a:hover {
    color: var(--primary);
}

.navbar nav a.active {
    color: var(--primary);
    font-weight: 600;
}

/* === MAIN CONTENT === */
.main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    min-height: calc(100vh - 80px);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

/* === PROFILE PAGE === */
.profile-header {
    background: white;
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
}

.profile-main {
    display: flex;
    gap: 30px;
    align-items: start;
}

.profile-photo {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--primary);
}

.profile-photo-placeholder {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    color: white;
    font-weight: bold;
}

.profile-info {
    flex: 1;
}

.profile-name {
    font-size: 32px;
    font-weight: bold;
    margin-bottom: 10px;
}

.profile-meta {
    color: #666;
    font-size: 16px;
    margin-bottom: 20px;
}

.profile-bio {
    font-size: 16px;
    line-height: 1.6;
    color: var(--dark);
    margin-bottom: 20px;
}

.interests-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.interest-tag {
    background: var(--light);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    color: var(--dark);
}

/* === CARDS === */
.card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: var(--shadow);
    margin-bottom: 30px;
}

.card-header {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 20px;
    color: var(--dark);
}

/* === ACTIVITY CARD === */
.activity-item {
    background: white;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 15px;
    border-left: 4px solid var(--primary);
    box-shadow: var(--shadow);
    transition: transform 0.2s;
}

.activity-item:hover {
    transform: translateX(5px);
}

.activity-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.activity-type-badge {
    font-size: 14px;
    padding: 5px 12px;
    border-radius: 15px;
    background: var(--light);
    font-weight: 600;
}

.activity-date {
    color: #666;
    font-size: 14px;
}

.activity-details {
    color: var(--dark);
    line-height: 1.6;
}

/* === FEED === */
.feed-container {
    max-width: 600px;
    margin: 0 auto;
}

.profile-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    margin-bottom: 20px;
}

.profile-card-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    background: linear-gradient(135deg, #FF6B35 0%, #F7931E 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 120px;
    color: white;
}

.profile-card-content {
    padding: 25px;
}

.profile-card-name {
    font-size: 28px;
    font-weight: bold;
    margin-bottom: 5px;
}

.profile-card-meta {
    color: #666;
    margin-bottom: 15px;
}

.profile-card-bio {
    color: var(--dark);
    line-height: 1.6;
    margin-bottom: 15px;
}

.action-buttons {
    display: flex;
    justify-content: center;
    gap: 30px;
    padding: 20px;
}

.action-btn {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    font-size: 32px;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.action-btn:hover {
    transform: scale(1.1);
}

.btn-skip {
    background: white;
    color: #999;
}

.btn-like {
    background: var(--gradient);
    color: white;
}

/* === MATCHES LIST === */
.matches-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.match-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.match-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.match-photo {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 80px;
    color: white;
}

.match-info {
    padding: 15px;
}

.match-name {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 5px;
}

.match-message {
    color: #666;
    font-size: 14px;
}

/* === CHAT === */
/* === CHAT === */
.chat-container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    height: calc(100vh - 160px);
}

.chat-header {
    background: var(--gradient);
    color: white;
    padding: 20px 25px;
    font-size: 20px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-shrink: 0;
}

.chat-back-btn {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.messages-container {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    background: #F9F9F9;
    display: flex;
    flex-direction: column;
}

.message {
    margin-bottom: 16px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    max-width: 100%;
    animation: fadeIn 0.2s ease-out;
}

.message.own {
    flex-direction: row-reverse;
}

.message-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--gradient);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
    flex-shrink: 0;
    margin-top: 4px;
}

.message-wrapper {
    display: flex;
    flex-direction: column;
    max-width: 70%;
}

.message.own .message-wrapper {
    align-items: flex-end;
}

.message-content {
    background: white;
    padding: 12px 16px;
    border-radius: 20px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
    line-height: 1.5;
    font-size: 15px;
    max-width: 100%;
    white-space: pre-wrap;
}

.message.own .message-content {
    background: var(--gradient);
    color: white;
    border-bottom-right-radius: 6px;
}

.message:not(.own) .message-content {
    border-bottom-left-radius: 6px;
}

.message-time {
    font-size: 11px;
    color: #999;
    margin-top: 4px;
    padding: 0 4px;
}

.message-input-container {
    padding: 20px;
    background: white;
    border-top: 1px solid #E0E0E0;
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

.message-input-container input {
    flex: 1;
    padding: 14px 18px;
    border: 2px solid #E0E0E0;
    border-radius: 25px;
    font-size: 15px;
    font-family: inherit;
}

.message-input-container input:focus {
    border-color: var(--primary);
    outline: none;
}

.message-input-container button {
    padding: 14px 28px;
    background: var(--gradient);
    color: white;
    border: none;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
    font-size: 15px;
    white-space: nowrap;
}

.message-input-container button:hover {
    transform: scale(1.05);
}

.message-input-container button:active {
    transform: scale(0.98);
}

/* Скролл */
.messages-container::-webkit-scrollbar {
    width: 6px;
}

.messages-container::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.messages-container::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

.messages-container::-webkit-scrollbar-thumb:hover {
    background: #999;
}

@media (max-width: 768px) {
    .chat-container {
        height: 100vh;
        border-radius: 0;
        max-width: 100%;
    }

    .chat-header {
        padding: 15px 20px;
        font-size: 18px;
    }

    .messages-container {
        padding: 15px;
    }

    .message-wrapper {
        max-width: 75%;
    }

    .message-content {
        padding: 10px 14px;
        font-size: 14px;
    }

    .message-input-container {
        padding: 12px 15px;
        gap: 10px;
    }

    .message-input-container input {
        padding: 12px 16px;
        font-size: 15px;
    }

    .message-input-container button {
        padding: 12px 20px;
        font-size: 14px;
    }
}