/**
 * Fixed References Layout
 * Clean, professional, and well-aligned reference cards
 */

/* Override the malformed reference card layout */
.reference-card {
    background: white !important;
    border: 2px solid #e2e8f0 !important;
    border-radius: 12px !important;
    padding: 24px !important;
    margin-bottom: 20px !important;
    transition: all 0.3s ease !important;
}

.reference-card:hover {
    border-color: #d4af37 !important;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.1) !important;
}

/* Header with number and title */
.reference-header {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    margin-bottom: 20px !important;
    padding-bottom: 16px !important;
    border-bottom: 2px solid #f1f5f9 !important;
}

.reference-number {
    width: 40px !important;
    height: 40px !important;
    background: linear-gradient(135deg, #d4af37, #b8941f) !important;
    color: white !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 1.2rem !important;
    font-weight: 600 !important;
    flex-shrink: 0 !important;
}

.reference-header h4 {
    font-family: 'Cormorant Garamond', serif !important;
    font-size: 1.3rem !important;
    color: #2d3748 !important;
    margin: 0 !important;
    flex: 1 !important;
}

/* Remove button */
.remove-reference-btn {
    background: #fed7d7 !important;
    color: #c53030 !important;
    border: none !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s ease !important;
    font-size: 14px !important;
}

.remove-reference-btn:hover {
    background: #feb2b2 !important;
    transform: scale(1.1) !important;
}

/* Form fields grid - 2 columns */
.reference-form {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 16px !important;
}

.reference-form-group {
    display: flex !important;
    flex-direction: column !important;
}

.reference-form-group label {
    font-weight: 600 !important;
    color: #4a5568 !important;
    margin-bottom: 8px !important;
    font-size: 0.95rem !important;
}

.reference-form-group input,
.reference-form-group select {
    width: 100% !important;
    padding: 12px 16px !important;
    border: 2px solid #e2e8f0 !important;
    border-radius: 8px !important;
    background: white !important;
    font-family: 'Montserrat', sans-serif !important;
    font-size: 14px !important;
    color: #2d3748 !important;
    transition: all 0.3s ease !important;
}

.reference-form-group input:focus,
.reference-form-group select:focus {
    outline: none !important;
    border-color: #d4af37 !important;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1) !important;
}

.reference-form-group input::placeholder {
    color: #a0aec0 !important;
}

/* Relationship suggestions */
.relationship-suggestions {
    grid-column: 1 / -1 !important;
    margin-top: 8px !important;
}

.relationship-suggestions p {
    font-size: 0.85rem !important;
    color: #718096 !important;
    margin-bottom: 8px !important;
}

.suggestion-tags {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
}

.suggestion-tag {
    background: #f7fafc !important;
    border: 1px solid #e2e8f0 !important;
    padding: 6px 14px !important;
    border-radius: 20px !important;
    font-size: 0.85rem !important;
    color: #4a5568 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
}

.suggestion-tag:hover {
    background: #d4af37 !important;
    border-color: #d4af37 !important;
    color: white !important;
}

/* Add reference button */
.add-reference-btn {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    width: 100% !important;
    padding: 16px !important;
    background: linear-gradient(135deg, #f7fafc, #edf2f7) !important;
    border: 2px dashed #cbd5e0 !important;
    border-radius: 8px !important;
    color: #4a5568 !important;
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 600 !important;
    font-size: 0.95rem !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    margin-top: 12px !important;
}

.add-reference-btn:hover {
    background: linear-gradient(135deg, #edf2f7, #e2e8f0) !important;
    border-color: #d4af37 !important;
    color: #d4af37 !important;
    transform: translateY(-2px) !important;
}

.add-reference-btn i {
    font-size: 16px !important;
}

/* Responsive design */
@media (max-width: 768px) {
    .reference-form {
        grid-template-columns: 1fr !important;
    }
    
    .relationship-suggestions {
        grid-column: 1 !important;
    }
}

/* Hide the old malformed card design */
.reference-card-left {
    display: none !important;
}

.reference-card-right {
    width: 100% !important;
}

