/* SwoleMates Custom Styles - Teal Blue & Purple Theme */

:root {
    --primary-teal: #20B2AA;
    --primary-purple: #9370DB;
    --dark-teal: #178F88;
    --dark-purple: #6A4CB5;
    --light-teal: #7FFFD4;
    --light-purple: #D8BFD8;
    --bg-gray: #F8F9FA;
    --dark-gray: #343A40;
    --text-gray: #6C757D;
    --white: #FFFFFF;
    --border-color: #DEE2E6;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-gray);
    color: var(--dark-gray);
    line-height: 1.6;
}

/* Brand Logo */
.brand-logo {
    font-size: 2.5rem;
    font-weight: bold;
    background: linear-gradient(135deg, var(--primary-teal), var(--primary-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Authentication Pages */
.auth-page {
    background: linear-gradient(135deg, var(--primary-teal) 0%, var(--primary-purple) 100%);
    min-height: 100vh;
}

.auth-page .card {
    border: none;
    border-radius: 15px;
}

/* Buttons */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-teal), var(--primary-purple));
    border: none;
    padding: 10px 20px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--dark-teal), var(--dark-purple));
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(147, 112, 219, 0.3);
}

.btn-secondary {
    background-color: var(--text-gray);
    border: none;
}

.btn-outline-primary {
    border-color: var(--primary-teal);
    color: var(--primary-teal);
}

.btn-outline-primary:hover {
    background-color: var(--primary-teal);
    border-color: var(--primary-teal);
}

/* Forms */
.form-control:focus {
    border-color: var(--primary-teal);
    box-shadow: 0 0 0 0.2rem rgba(32, 178, 170, 0.25);
}

.form-label {
    font-weight: 600;
    color: var(--dark-gray);
}

/* Main Layout */
.main-wrapper {
    background-color: var(--bg-gray);
    min-height: 100vh;
}

/* Header / Top Navigation */
.top-navbar {
    background: linear-gradient(135deg, var(--primary-teal), var(--primary-purple));
    padding: 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.top-navbar .navbar-brand {
    color: var(--white);
    font-weight: bold;
    font-size: 1.5rem;
}

.top-navbar .nav-link {
    color: rgba(255, 255, 255, 0.9);
    margin: 0 10px;
    transition: all 0.3s ease;
}

.top-navbar .nav-link:hover {
    color: var(--white);
    transform: translateY(-2px);
}

.top-navbar .badge {
    position: absolute;
    top: 0;
    right: -8px;
    background-color: #FF4444;
    font-size: 0.7rem;
}

/* Search Bar */
.search-bar {
    background-color: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 20px;
    color: var(--white);
    padding: 8px 15px;
}

.search-bar::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.search-bar:focus {
    background-color: var(--white);
    color: var(--dark-gray);
    outline: none;
}

/* 3-Column Layout */
.layout-container {
    display: flex;
    max-width: 1400px;
    margin: 20px auto;
    gap: 20px;
    padding: 0 15px;
}

/* Left Sidebar */
.sidebar-left {
    flex: 0 0 280px;
    position: sticky;
    top: 80px;
    height: fit-content;
}

.sidebar-left .card {
    border: none;
    border-radius: 15px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.user-profile-card {
    text-align: center;
    padding: 20px;
}

.user-profile-card img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid var(--primary-teal);
    margin-bottom: 15px;
}

.user-stats {
    display: flex;
    justify-content: space-around;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
}

.stat-item {
    text-align: center;
}

.stat-value {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-purple);
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-gray);
}

/* Navigation Menu */
.nav-menu {
    list-style: none;
    padding: 0;
}

.nav-menu li {
    margin-bottom: 5px;
}

.nav-menu a {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: var(--dark-gray);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.nav-menu a:hover, .nav-menu a.active {
    background: linear-gradient(135deg, var(--primary-teal), var(--primary-purple));
    color: var(--white);
    transform: translateX(5px);
}

.nav-menu i {
    margin-right: 10px;
    width: 20px;
}

/* Center Content Area */
.content-center {
    flex: 1;
    min-width: 0;
}

/* Post Creation Box */
.post-create-box {
    background: var(--white);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.post-create-box textarea {
    width: 100%;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 15px;
    resize: none;
    font-size: 1rem;
}

.post-create-box textarea:focus {
    outline: none;
    border-color: var(--primary-teal);
}

.post-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
}

.post-options {
    display: flex;
    gap: 15px;
}

.post-option {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.post-option:hover {
    background-color: var(--bg-gray);
}

/* Post Card */
.post-card {
    background: var(--white);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.post-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.post-header img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    margin-right: 15px;
    border: 2px solid var(--primary-teal);
}

.post-user-info h6 {
    margin: 0;
    font-weight: bold;
}

.post-time {
    font-size: 0.85rem;
    color: var(--text-gray);
}

.post-content {
    margin-bottom: 15px;
    line-height: 1.6;
}

.post-image {
    width: 100%;
    border-radius: 10px;
    margin: 15px 0;
}

/* Post Reactions */
.post-reactions {
    display: flex;
    gap: 10px;
    padding: 15px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.reaction-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 8px;
    background: transparent;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.reaction-btn:hover {
    background-color: var(--bg-gray);
}

.reaction-btn.active {
    color: var(--primary-purple);
    font-weight: bold;
}

.reaction-like { color: #FF6B6B; }
.reaction-encourage { color: #4ECDC4; }
.reaction-congratulate { color: #FFD93D; }
.reaction-angry { color: #FF6347; }
.reaction-sad { color: #6C757D; }

/* Comments Section */
.comments-section {
    margin-top: 15px;
}

.comment {
    display: flex;
    gap: 10px;
    padding: 10px 0;
}

.comment img {
    width: 35px;
    height: 35px;
    border-radius: 50%;
}

.comment-content {
    flex: 1;
    background-color: var(--bg-gray);
    padding: 10px 15px;
    border-radius: 15px;
}

.comment-author {
    font-weight: bold;
    margin-bottom: 5px;
}

.comment-input {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.comment-input input {
    flex: 1;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 8px 15px;
}

/* Right Sidebar */
.sidebar-right {
    flex: 0 0 300px;
    position: sticky;
    top: 80px;
    height: fit-content;
}

.sidebar-right .card {
    border: none;
    border-radius: 15px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    padding: 20px;
}

.sidebar-right h5 {
    margin-bottom: 15px;
    color: var(--dark-gray);
}

/* Suggested Partners */
.partner-suggestion {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 10px;
    margin-bottom: 10px;
    transition: background-color 0.3s;
}

.partner-suggestion:hover {
    background-color: var(--bg-gray);
}

.partner-suggestion img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    margin-right: 10px;
}

.partner-info {
    flex: 1;
}

.partner-name {
    font-weight: bold;
    margin: 0;
}

.partner-match {
    font-size: 0.85rem;
    color: var(--primary-purple);
}

/* Level Badge */
.level-badge {
    display: inline-block;
    padding: 5px 15px;
    background: linear-gradient(135deg, var(--primary-teal), var(--primary-purple));
    color: var(--white);
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.9rem;
}

/* Achievements */
.achievement-item {
    display: flex;
    align-items: center;
    padding: 10px;
    background-color: var(--bg-gray);
    border-radius: 10px;
    margin-bottom: 10px;
}

.achievement-icon {
    width: 40px;
    height: 40px;
    margin-right: 10px;
    font-size: 1.5rem;
}

.achievement-info h6 {
    margin: 0;
    font-size: 0.9rem;
}

.achievement-info p {
    margin: 0;
    font-size: 0.8rem;
    color: var(--text-gray);
}

/* Profile Page */
.profile-header {
    background: linear-gradient(135deg, var(--primary-teal), var(--primary-purple));
    color: var(--white);
    padding: 40px;
    border-radius: 15px;
    margin-bottom: 20px;
    position: relative;
}

.profile-picture {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    border: 5px solid var(--white);
    margin-bottom: 15px;
}

/* Responsive Design */
@media (max-width: 992px) {
    .layout-container {
        flex-direction: column;
    }

    .sidebar-left,
    .sidebar-right {
        flex: 1;
        position: static;
    }

    .sidebar-right {
        order: 3;
    }
}

@media (max-width: 768px) {
    .brand-logo {
        font-size: 1.5rem;
    }

    .user-stats {
        flex-direction: column;
        gap: 10px;
    }
}

/* Utilities */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-teal), var(--primary-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient {
    background: linear-gradient(135deg, var(--primary-teal), var(--primary-purple));
}

/* Loading Spinner */
.spinner {
    border: 3px solid var(--bg-gray);
    border-top: 3px solid var(--primary-teal);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Notification Badge */
.notification-badge {
    position: relative;
}

.notification-badge .badge {
    position: absolute;
    top: -5px;
    right: -10px;
    background-color: #FF4444;
    border-radius: 10px;
    padding: 2px 6px;
    font-size: 0.7rem;
}

/* Card hover effects */
.card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Workout and Recipe Post Styles */
.workout-exercises .table {
    margin-bottom: 0;
}

.workout-exercises .table th {
    font-size: 0.9rem;
    font-weight: 600;
}

.workout-exercises .table td {
    font-size: 0.9rem;
}

.workout-meta, .recipe-meta {
    padding: 10px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.workout-notes, .recipe-notes {
    border-left: 3px solid var(--primary-teal);
}

.recipe-ingredients ul {
    margin-bottom: 0;
}

.recipe-ingredients li {
    padding: 5px 0;
}

.recipe-instructions {
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

/* Active post option */
.post-option.active {
    background-color: var(--bg-gray);
    border: 1px solid var(--primary-teal);
}
