/* Custom romantic theme variables */
:root {
    --primary-gradient: linear-gradient(135deg, #ff6b9d, #c44569);
    --secondary-gradient: linear-gradient(135deg, #ffeaa7, #fdcb6e);
    --accent-gradient: linear-gradient(135deg, #74b9ff, #0984e3);
    --background-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --chat-bg: rgba(255, 255, 255, 0.95);
    --message-bg: linear-gradient(135deg, #ff9a9e, #fecfef);
    --shadow-soft: 0 20px 40px rgba(0, 0, 0, 0.1);
    --shadow-strong: 0 30px 60px rgba(0, 0, 0, 0.2);
    --border-radius: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: 'Poppins', sans-serif;
    background: var(--background-gradient);
    overflow: hidden;
    position: relative;
}

/* Animated background particles */
#particles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.particle {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    pointer-events: none;
    animation: float 6s ease-in-out infinite;
}

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

/* Main chat container */
.chat-container {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    background: var(--chat-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-strong);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
    transition: var(--transition);
}

/* Profile section */
.profile-section {
    padding: 2rem;
    background: var(--primary-gradient);
    color: white;
    text-align: center;
}

.profile-image-container {
    position: relative;
    display: inline-block;
    margin-bottom: 1rem;
}

.profile-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid rgba(255, 255, 255, 0.3);
    object-fit: cover;
    transition: var(--transition);
}

.profile-image:hover {
    transform: scale(1.05);
}

.online-indicator {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 20px;
    height: 20px;
    background: #00b894;
    border: 3px solid white;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(0, 184, 148, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(0, 184, 148, 0); }
    100% { box-shadow: 0 0 0 0 rgba(0, 184, 148, 0); }
}

.girl-name {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.girl-status {
    opacity: 0.9;
    font-size: 0.9rem;
}

/* Quick match card */
.quick-match-card {
    padding: 2rem;
    text-align: center;
}

.match-icon {
    width: 60px;
    height: 60px;
    background: var(--secondary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.5rem;
    color: white;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

.match-title {
    color: #2d3436;
    font-weight: 600;
    margin-bottom: 1rem;
}

.match-description {
    color: #636e72;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.countdown {
    font-weight: 700;
    color: #e17055;
    font-size: 1.1em;
}

/* Buttons */
.btn {
    border-radius: 50px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background: var(--primary-gradient);
    padding: 0.8rem 2rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 107, 157, 0.3);
}

.pulse-animation {
    animation: pulse-btn 2s infinite;
}

@keyframes pulse-btn {
    0% { box-shadow: 0 0 0 0 rgba(255, 107, 157, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(255, 107, 157, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 107, 157, 0); }
}

/* Chat screen */
.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: white;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.chat-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-gradient);
}

.chat-timer {
    background: var(--accent-gradient);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
}

.chat-messages {
    height: 400px;
    overflow-y: auto;
    padding: 1rem;
    background: #f8f9fa;
}

.message {
    margin-bottom: 1rem;
    animation: slideInUp 0.5s ease;
}

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

.message-bubble {
    background: var(--message-bg);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 20px 20px 5px 20px;
    max-width: 80%;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    position: relative;
}

/* Outgoing (user) message */
.message.outgoing {
    display: flex;
    justify-content: flex-end;
}

.message.outgoing .message-bubble {
    background: linear-gradient(135deg, #74b9ff, #0984e3);
    border-radius: 20px 5px 20px 20px;
}

.message-time {
    font-size: 0.75rem;
    opacity: 0.8;
    margin-top: 0.5rem;
}

.typing-indicator {
    display: flex;
    align-items: center;
    padding: 1rem 1.5rem;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px 20px 20px 5px;
    max-width: 80%;
    margin-bottom: 1rem;
}

.typing-dots {
    display: flex;
    gap: 0.3rem;
}

.typing-dot {
    width: 8px;
    height: 8px;
    background: #636e72;
    border-radius: 50%;
    animation: typing 1.4s infinite ease-in-out;
}

.typing-dot:nth-child(1) { animation-delay: -0.32s; }
.typing-dot:nth-child(2) { animation-delay: -0.16s; }

@keyframes typing {
    0%, 80%, 100% { transform: scale(0.8); opacity: 0.5; }
    40% { transform: scale(1); opacity: 1; }
}

.chat-input {
    padding: 1.5rem;
    background: white;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.chat-input .form-control {
    border-radius: 25px;
    border: 1px solid #dee2e6;
    padding: 0.8rem 1.5rem;
}

.chat-input .btn {
    border-radius: 50%;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.decision-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2.5rem;
    text-align: center;
    max-width: 400px;
    width: 90%;
    box-shadow: var(--shadow-strong);
    animation: slideInScale 0.5s ease;
}

@keyframes slideInScale {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.decision-header {
    position: relative;
    margin-bottom: 2rem;
}

.decision-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--primary-gradient);
}

.decision-icon {
    position: absolute;
    top: -10px;
    right: 50%;
    transform: translateX(50%);
    width: 40px;
    height: 40px;
    background: var(--secondary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.decision-title {
    color: #2d3436;
    font-weight: 600;
    margin-bottom: 1rem;
}

.decision-text {
    color: #636e72;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.decision-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.btn-success {
    background: linear-gradient(135deg, #00b894, #00a085);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 184, 148, 0.3);
}

.btn-danger {
    background: linear-gradient(135deg, #e17055, #d63031);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(225, 112, 85, 0.3);
}

/* Responsive design */
@media (max-width: 768px) {
    body {
        overflow-y: auto;
    }
    
    .container-fluid {
        padding: 2rem 0.5rem;
        align-items: center;
        min-height: 100vh;
    }
    
    .chat-container {
        margin: 0.5rem;
        max-width: calc(100% - 1rem);
        width: 100%;
        height: auto;
        min-height: auto;
        max-height: none;
        position: relative;
    }
    
    .profile-section {
        padding: 1.5rem 1rem;
    }
    
    .profile-image {
        width: 100px;
        height: 100px;
    }
    
    .girl-name {
        font-size: 1.5rem;
    }
    
    .quick-match-card {
        padding: 1.5rem 1rem;
    }
    
    .match-description {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }
    
    .chat-header {
        padding: 1rem;
    }
    
    .chat-messages {
        height: 350px;
        padding: 0.8rem;
    }
    
    .chat-input {
        padding: 1rem;
    }
    
    .decision-overlay {
        padding: 1rem;
        align-items: center;
    }
    
    .decision-card {
        padding: 1.5rem;
        margin: 0;
        width: 100%;
        max-width: 350px;
    }
    
    .decision-buttons {
        flex-direction: column;
        gap: 0.8rem;
    }
    
    .decision-buttons .btn {
        width: 100%;
        margin: 0;
        padding: 0.8rem 1.5rem;
    }
    
    .decision-avatar {
        width: 80px;
        height: 80px;
    }
    
    .decision-title {
        font-size: 1.3rem;
    }
    
    .decision-text {
        font-size: 0.9rem;
    }
}

/* Extra small devices (phones in landscape, 576px and down) */
@media (max-width: 576px) {
    .container-fluid {
        padding: 1.5rem 0.25rem;
    }
    
    .chat-container {
        margin: 0.25rem;
        max-width: calc(100% - 0.5rem);
        border-radius: 15px;
        height: auto;
    }
    
    .profile-section {
        padding: 1rem 0.8rem;
    }
    
    .profile-image {
        width: 90px;
        height: 90px;
    }
    
    .girl-name {
        font-size: 1.3rem;
    }
    
    .quick-match-card {
        padding: 1rem 0.8rem;
    }
    
    .match-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .match-title {
        font-size: 1.2rem;
    }
    
    .chat-messages {
        height: 300px;
        padding: 0.6rem;
    }
    
    .message-bubble {
        padding: 0.8rem 1rem;
        font-size: 0.9rem;
    }
    
    .decision-card {
        padding: 1.2rem;
        max-width: 320px;
    }
}

/* Scrollbar styling */
.chat-messages::-webkit-scrollbar {
    width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: var(--primary-gradient);
    border-radius: 10px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: #ff6b9d;
}
