@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;600;700;800&display=swap');

:root {
    --bg-dark: #0b0f19;
    --bg-card: rgba(17, 24, 39, 0.7);
    --border-color: rgba(255, 255, 255, 0.08);
    --text-main: #f3f4f6;
    --text-muted: #9ca3af;
    --primary: #14b8a6; /* Bio-teal */
    --primary-glow: rgba(20, 184, 166, 0.15);
    --secondary: #8b5cf6; /* Scientific purple */
    --secondary-glow: rgba(139, 92, 246, 0.15);
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --font-header: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    background-color: var(--bg-dark);
    background-image: 
        radial-gradient(at 0% 0%, rgba(139, 92, 246, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(20, 184, 166, 0.15) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    padding-bottom: 80px;
}

/* Header & Typography */
header {
    max-width: 1200px;
    margin: 40px auto 20px;
    padding: 0 20px;
    text-align: center;
}

.logo-container {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.logo-icon {
    font-size: 2.5rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 10px rgba(20, 184, 166, 0.3));
}

h1 {
    font-family: var(--font-header);
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    background: linear-gradient(to right, #ffffff, #d1d5db);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 8px;
}

.subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Main Container */
main {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

/* Search and Filter Panel */
.search-panel {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 30px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.input-group {
    flex: 2;
    min-width: 250px;
    position: relative;
}

.select-group {
    flex: 1;
    min-width: 150px;
}

input, select {
    width: 100%;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 14px 16px;
    color: white;
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: var(--transition);
}

input:focus, select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
    background-color: rgba(255, 255, 255, 0.08);
}

select option {
    background-color: var(--bg-dark);
    color: white;
}

/* Buttons */
.btn {
    background: linear-gradient(135deg, var(--primary), #0f766e);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 14px 28px;
    font-family: var(--font-header);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(20, 184, 166, 0.2);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(20, 184, 166, 0.35);
    filter: brightness(1.1);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-color);
    box-shadow: none;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    box-shadow: none;
}

/* Stats Ribbon */
.stats-ribbon {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    color: var(--text-muted);
    font-size: 0.9rem;
    padding: 0 8px;
}

.publish-cta {
    display: flex;
    align-items: center;
    gap: 12px;
}

.publish-cta span {
    font-size: 0.85rem;
    color: var(--primary);
    font-weight: 500;
}

/* Job Cards */
.jobs-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.job-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.job-card:hover {
    border-color: rgba(20, 184, 166, 0.4);
    box-shadow: 0 8px 30px rgba(20, 184, 166, 0.08);
    transform: scale(1.005);
}

.job-card.featured {
    border-left: 4px solid var(--primary);
    background: linear-gradient(to right, rgba(20, 184, 166, 0.05), var(--bg-card));
}

.job-card-header {
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.job-info-primary h3 {
    font-family: var(--font-header);
    font-size: 1.3rem;
    font-weight: 700;
    color: white;
    margin-bottom: 4px;
}

.job-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-top: 8px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.meta-item.company {
    color: var(--primary);
    font-weight: 600;
}

.badge {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

.badge.featured-badge {
    background: rgba(20, 184, 166, 0.15);
    border-color: var(--primary);
    color: var(--primary);
    font-weight: 600;
}

.salary-tag {
    color: var(--success);
    font-weight: 600;
}

/* Expanded Card Body */
.job-card-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
    border-top: 0 solid var(--border-color);
}

.job-card.active .job-card-body {
    max-height: 1500px;
    border-top-width: 1px;
}

.job-details-content {
    padding: 24px;
}

.job-description {
    margin-bottom: 24px;
    color: #d1d5db;
}

.skills-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.skill-tag {
    background: rgba(139, 92, 246, 0.08);
    border: 1px solid rgba(139, 92, 246, 0.2);
    color: #a78bfa;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Scientific Insights Panel */
.science-panel {
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.04), rgba(139, 92, 246, 0.04));
    border: 1px solid rgba(139, 92, 246, 0.15);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.science-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 3px;
    height: 100%;
    background: linear-gradient(to bottom, var(--primary), var(--secondary));
}

.science-panel-title {
    font-family: var(--font-header);
    font-size: 1rem;
    font-weight: 700;
    color: white;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.science-panel-title .pulse {
    width: 8px;
    height: 8px;
    background-color: var(--primary);
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 8px var(--primary);
    animation: pulse 1.8s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(20, 184, 166, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(20, 184, 166, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(20, 184, 166, 0); }
}

.science-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 768px) {
    .science-grid {
        grid-template-columns: 1fr;
    }
}

.science-col h4 {
    font-size: 0.9rem;
    color: #e5e7eb;
    margin-bottom: 8px;
    font-weight: 600;
}

.science-list {
    list-style: none;
}

.science-list li {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 6px;
    padding-left: 14px;
    position: relative;
}

.science-list li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--primary);
}

.science-list li .badge-phase {
    background-color: rgba(20, 184, 166, 0.15);
    color: var(--primary);
    padding: 1px 5px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
}

.science-list li.warning-item::before {
    color: var(--warning);
}

.no-data {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-style: italic;
}

/* Modals */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(7, 10, 17, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 20px;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-container {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active .modal-container {
    transform: scale(1);
}

.modal-header {
    padding: 24px 24px 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-family: var(--font-header);
    font-size: 1.5rem;
    font-weight: 700;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    color: white;
}

.modal-body {
    padding: 24px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: #e5e7eb;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 576px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

textarea {
    width: 100%;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 14px 16px;
    color: white;
    font-family: var(--font-body);
    font-size: 0.95rem;
    min-height: 120px;
    resize: vertical;
    transition: var(--transition);
}

textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.payment-section {
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
    margin-top: 24px;
    text-align: center;
}

.payment-price-tag {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--success);
    font-family: var(--font-header);
    margin-bottom: 4px;
}

.payment-description {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 20px;
}

/* PayPal Button Container */
#paypal-button-container {
    max-width: 350px;
    margin: 0 auto;
}

/* Success State in Modal */
.success-screen {
    text-align: center;
    padding: 40px 20px;
    display: none;
}

.success-icon {
    font-size: 4rem;
    color: var(--success);
    margin-bottom: 20px;
}

.success-screen h3 {
    font-family: var(--font-header);
    font-size: 1.6rem;
    margin-bottom: 12px;
}

.success-screen p {
    color: var(--text-muted);
    margin-bottom: 24px;
}

/* Empty search states */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    color: var(--text-muted);
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: 16px;
    color: var(--secondary);
}

/* Botones de Compartir (Viral Loops) */
.share-buttons-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px dashed var(--border-color);
    flex-wrap: wrap;
}

.share-buttons-container span {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
}

.share-btn {
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.78rem;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
}

.share-btn.wa-btn {
    background-color: rgba(37, 211, 102, 0.1);
    color: #25d366;
    border: 1px solid rgba(37, 211, 102, 0.2);
}

.share-btn.wa-btn:hover {
    background-color: rgba(37, 211, 102, 0.2);
    transform: translateY(-1px);
}

.share-btn.li-btn {
    background-color: rgba(10, 102, 194, 0.1);
    color: #0a66c2;
    border: 1px solid rgba(10, 102, 194, 0.2);
}

.share-btn.li-btn:hover {
    background-color: rgba(10, 102, 194, 0.2);
    transform: translateY(-1px);
}

.share-btn.tw-btn {
    background-color: rgba(255, 255, 255, 0.05);
    color: #ffffff;
    border: 1px solid var(--border-color);
}

.share-btn.tw-btn:hover {
    background-color: rgba(255, 255, 255, 0.12);
    transform: translateY(-1px);
}

/* Opción de publicar gratis compartiendo */
.free-share-option {
    margin-top: 16px;
    padding: 16px;
    background: rgba(139, 92, 246, 0.05);
    border: 1px dashed rgba(139, 92, 246, 0.25);
    border-radius: 12px;
    text-align: center;
}

.free-share-option h4 {
    font-family: var(--font-header);
    font-size: 0.95rem;
    color: white;
    margin-bottom: 6px;
}

.free-share-option p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.free-share-btn-group {
    display: flex;
    justify-content: center;
    gap: 10px;
}
