/* Hannai Platform - Main Application Styles */

:root {
    /* Hannai Brand Colors */
    --color-navy: #0B3954;
    --color-light-blue: #BFD7EA;
    --color-coral: #FF6663;
    --color-lime: #E0FF4F;
    --color-white: #FEFFFE;

    /* Component colors */
    --primary-color: #0B3954;
    --accent-color: #E0FF4F;
    --text-primary: #0B3954;
    --text-secondary: #6B7280;
    --background: #FEFFFE;
    --background-secondary: #BFD7EA;
    --border-color: #BFD7EA;
    --success-color: #E0FF4F;
    --error-color: #FF6663;
    --warning-color: #E0FF4F;
    --shadow: 0 2px 8px rgba(11, 57, 84, 0.1);
    --shadow-lg: 0 10px 40px rgba(11, 57, 84, 0.15);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    color: var(--text-primary);
    background: var(--background);
    line-height: 1.6;
}

/* Navbar */
.navbar {
    background: white;
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -0.02em;
}

.navbar-logo {
    height: 40px;
    width: auto;
}

.navbar-brand-text {
    display: inline-block;
}

.navbar-menu {
    display: flex;
    gap: 2rem;
    align-items: center;
    list-style: none;
}

.navbar-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 400;
    transition: color 0.2s ease;
}

.navbar-link:hover {
    color: var(--text-primary);
}

.navbar-link.active {
    color: var(--text-primary);
    font-weight: 500;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid var(--border-color);
    object-fit: cover;
}

/* Main Container */
.main-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem 2rem;
    min-height: calc(100vh - 200px);
}

/* Page Header */
.page-header {
    margin-bottom: 1.5rem;
    text-align: center;
}

.auth-logo {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.auth-logo img {
    height: 80px;
    width: auto;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 300;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

.page-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 400;
}

/* Cards */
.card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 0;
    padding: 2rem;
    margin-bottom: 1.5rem;
    transition: all 0.2s ease;
}

.card:hover {
    box-shadow: var(--shadow);
}

.card-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.card-body {
    color: var(--text-secondary);
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-size: 0.875rem;
    font-weight: 500;
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 0;
    font-size: 0.875rem;
    font-family: inherit;
    transition: all 0.2s ease;
    background: white;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-textarea {
    min-height: 100px;
    resize: vertical;
}

.form-help {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.form-error {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: var(--error-color);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 2rem;
    border: 1px solid;
    border-radius: 0;
    font-size: 0.875rem;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    text-align: center;
    letter-spacing: 0.05em;
}

.btn-primary {
    background: #0B3954;
    border-color: #0B3954;
    color: white;
}

.btn-primary:hover {
    background: #0d4a66;
    border-color: #0d4a66;
    color: white;
}

.btn-secondary {
    background: transparent;
    border-color: var(--border-color);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: var(--primary-color);
    border-color: var(--accent-color);
    color: var(--accent-color);
}

.btn-danger {
    background: transparent;
    border-color: var(--error-color);
    color: var(--error-color);
}

.btn-danger:hover {
    background: var(--error-color);
    color: white;
}

.btn-block {
    width: 100%;
}

.btn-upgrade {
    background: linear-gradient(135deg, #E0FF4F 0%, #0B3954 100%);
    border: none;
    color: white;
    display: inline-flex;
    align-items: center;
}

.btn-upgrade:hover {
    background: linear-gradient(135deg, #d4f343 0%, #0d4a66 100%);
    color: white;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.stat-card {
    background: white;
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    text-align: center;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 300;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* Profile */
.profile-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.profile-avatar-large {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 2px solid var(--border-color);
    object-fit: cover;
}

.profile-info h1 {
    font-size: 2rem;
    font-weight: 300;
    margin-bottom: 0.5rem;
}

.profile-bio {
    color: var(--text-secondary);
    max-width: 600px;
}

/* User List */
.user-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.user-card {
    background: white;
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    text-align: center;
    transition: all 0.2s ease;
}

.user-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.user-card-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 2px solid var(--border-color);
    margin: 0 auto 1rem;
    object-fit: cover;
}

.user-card-name {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

/* Profile Type Badges with specific colors */
.profile-type-badge {
    font-size: 0.7rem;
    padding: 0.3rem 0.75rem;
    border-radius: 12px;
    display: inline-block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    text-transform: none;
}

/* Perfil 1: Emerging Professional Immigrant Women - Navy */
.profile-type-recent_immigrant {
    background: #0B3954;
    color: #FFFFFF;
}

/* Perfil 2: Advancing Professional Immigrant Women - Lime */
.profile-type-established_immigrant {
    background: #E0FF4F;
    color: #0B3954;
}

/* Perfil 3: Local Origin Professionals - Coral */
.profile-type-local_professional {
    background: #FF6663;
    color: #FFFFFF;
}

/* Perfil 4: Organizations & Companies - Light Blue */
.profile-type-company {
    background: #BFD7EA;
    color: #0B3954;
}

/* Legacy class - keep for backwards compatibility */
.user-card-profile-type {
    font-size: 0.75rem;
    color: #1e3a8a;
    background: rgba(30, 58, 138, 0.1);
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    display: inline-block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.user-card-title {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

/* Filter Tags */
.filter-tag {
    display: inline-flex;
    align-items: center;
    background: var(--border-color);
    padding: 0.375rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    color: var(--text-primary);
}

.filter-tag a {
    text-decoration: none;
    font-weight: bold;
    font-size: 1.25rem;
    line-height: 1;
}

.filter-tag a:hover {
    opacity: 0.7;
}

/* Messages Container */
.messages-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem 0 2rem;
}

/* Alerts */
.alert {
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    border: 1px solid;
    border-radius: 0;
}

.alert-success {
    background: #f0fdf4;
    border-color: var(--success-color);
    color: #166534;
}

.alert-error {
    background: #fef2f2;
    border-color: var(--error-color);
    color: #991b1b;
}

.alert-warning {
    background: #fffbeb;
    border-color: var(--warning-color);
    color: #92400e;
}

.alert-info {
    background: #eff6ff;
    border-color: #3b82f6;
    color: #1e40af;
}

/* Badge */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    border: 1px solid;
    border-radius: 0;
    letter-spacing: 0.05em;
}

.badge-success {
    background: #f0fdf4;
    border-color: var(--success-color);
    color: #166534;
}

.badge-warning {
    background: #fffbeb;
    border-color: var(--warning-color);
    color: #92400e;
}

/* Progress Bar */
.progress-bar {
    height: 8px;
    background: var(--background-secondary);
    border: 1px solid var(--border-color);
    margin-top: 0.5rem;
}

.progress-fill {
    height: 100%;
    background: var(--accent-color);
    transition: width 0.3s ease;
}

/* Footer */
.footer {
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* Responsive */
@media (max-width: 768px) {
    .navbar-container {
        padding: 0 1rem;
    }

    .navbar-menu {
        gap: 1rem;
    }

    .messages-container {
        padding: 1rem 1rem 0 1rem;
    }

    .main-container {
        padding: 1rem 1rem;
    }

    .page-title {
        font-size: 2rem;
    }

    .profile-header {
        flex-direction: column;
        text-align: center;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .user-grid {
        grid-template-columns: 1fr;
    }
}

/* Dashboard Styles */
.dashboard-header {
    margin-bottom: 2rem;
}

.dashboard-welcome {
    font-size: 2.5rem;
    font-weight: 300;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.dashboard-profile-type {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.dashboard-profiles-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.dashboard-profiles-badges .profile-type-badge {
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
}

/* Dashboard Stats Grid */
.dashboard-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.dashboard-stat-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon-navy {
    background: var(--primary-color);
    color: white;
}

.stat-icon-yellow {
    background: var(--accent-color);
    color: var(--primary-color);
}

.stat-icon-coral {
    background: var(--error-color);
    color: white;
}

.stat-icon-light {
    background: var(--background-secondary);
    color: var(--primary-color);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.stat-text {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

/* Coming Soon Badge and Button */
.btn-coming-soon {
    opacity: 0.6;
    cursor: not-allowed;
}

.badge-coming-soon {
    display: inline-block;
    background: var(--color-coral);
    color: white;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 0.2rem 0.5rem;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 0.5rem;
}

.dashboard-stat-card .badge-coming-soon {
    display: block;
    width: fit-content;
    margin: 0.5rem auto 0;
}

/* Dashboard Content Grid */
.dashboard-content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
}

.dashboard-main-column {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.dashboard-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Dashboard Sections */
.dashboard-section {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.dashboard-section-header {
    background: var(--primary-color);
    color: white;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.dashboard-section-header h2 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.section-icon {
    font-size: 1.25rem;
    color: var(--accent-color);
}

.dashboard-section-body {
    padding: 1.5rem;
}

/* Matches and Contacts Lists */
.matches-list,
.contacts-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.match-item,
.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.match-item:last-child,
.contact-item:last-child {
    border-bottom: none;
}

.match-avatar,
.contact-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.match-avatar-placeholder,
.contact-avatar-placeholder {
    background: var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.match-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.match-name,
.contact-name {
    font-weight: 600;
    color: var(--text-primary);
}

.match-title {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.contact-name {
    flex: 1;
}

.empty-state-text {
    color: var(--text-secondary);
    text-align: center;
    padding: 2rem 0;
}

/* Guidance Section */
.guidance-section .dashboard-section-body {
    padding: 1rem 1.5rem;
}

.guidance-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.guidance-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: var(--text-primary);
    line-height: 1.5;
}

.guidance-check {
    color: #22c55e;
    font-weight: bold;
    font-size: 1rem;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    background: #dcfce7;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Dashboard Responsive */
@media (max-width: 1024px) {
    .dashboard-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .dashboard-content-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .dashboard-stats-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-welcome {
        font-size: 1.75rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.fade-in {
    animation: fadeIn 0.5s ease;
}
